/* Mail-Assistent — Design nach salewski.it (Theme sw-minimal): Roboto, Leitfarbe #4582B4 */
:root {
  --sw-primary: #4582B4;
  --sw-primary-dark: #3a6f9a;
  --sw-primary-tint: rgba(69, 130, 180, .08);
  --sw-text: #505050;
  --sw-heading: #333;
  --sw-border: #e0e0e0;
  --sw-bg: #f6f8fb;
  --sw-card: #fff;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Roboto', system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--sw-text);
  background: var(--sw-bg);
}

h1, h2, h3, h4 { color: var(--sw-heading); font-weight: 700; line-height: 1.3; }
h1 { font-size: 1.5rem; margin: 0 0 1.2rem; }
h2 { font-size: 1.15rem; margin: 1.4rem 0 .6rem; }
a { color: var(--sw-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.sw-container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

/* Topbar */
.sw-topbar { background: #f8f9fa; border-bottom: 1px solid rgba(0,0,0,.06); font-size: 13px; color: #555; }
.sw-topbar-inner { display: flex; align-items: center; gap: 8px; padding: 6px 0; }
.sw-topbar-sep { color: rgba(0,0,0,.2); }
.sw-topbar-sub { color: #888; }

/* Header */
.sw-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,.05);
}
.sw-header-inner { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; }
.sw-logo { font-weight: 700; font-size: 20px; letter-spacing: .5px; color: var(--sw-heading); }
.sw-logo:hover { text-decoration: none; }
.sw-logo span { color: var(--sw-primary); }
.sw-nav { display: flex; align-items: center; gap: 14px; }
.sw-user { font-size: 14px; color: #666; }
.sw-logout-form { margin: 0; }

.sw-main { padding-top: 28px; padding-bottom: 48px; min-height: 60vh; }

/* Footer */
.sw-footer { border-top: 1px solid var(--sw-border); color: #999; font-size: 13px; padding: 20px 0; margin-top: 40px; }

/* Buttons */
.sw-btn {
  cursor: pointer; display: inline-block; font-family: inherit; font-size: 14px; font-weight: 500;
  border: 1px solid var(--sw-border); background: #fff; color: var(--sw-heading);
  border-radius: 8px; padding: 8px 16px; transition: background .2s, color .2s, box-shadow .2s;
}
.sw-btn:hover { background: var(--sw-primary-tint); color: var(--sw-primary); text-decoration: none; }
.sw-btn-cta {
  background: var(--sw-primary); color: #fff !important; border-color: var(--sw-primary);
  border-radius: 50px; padding: 8px 22px; font-weight: 600;
}
.sw-btn-cta:hover { background: var(--sw-primary-dark); color: #fff; box-shadow: 0 4px 12px rgba(69,130,180,.35); }
.sw-btn-ghost { background: transparent; }
.sw-btn:disabled { opacity: .55; cursor: default; }

/* Cards */
.sw-card { background: var(--sw-card); border: 1px solid var(--sw-border); border-radius: 10px; padding: 18px 20px; margin-bottom: 16px; }
.sw-card-muted { background: #fafbfc; }

/* Vorgangsliste */
.vorgang-liste { list-style: none; margin: 0; padding: 0; }
.vorgang {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--sw-card); border: 1px solid var(--sw-border); border-left: 4px solid var(--sw-primary);
  border-radius: 10px; padding: 14px 18px; margin-bottom: 12px; transition: box-shadow .2s;
  color: inherit; text-decoration: none;
}
.vorgang:hover { box-shadow: 0 3px 14px rgba(0,0,0,.06); text-decoration: none; color: inherit; }
.vorgang-betreff { font-weight: 600; color: var(--sw-heading); }
.vorgang-absender { color: #888; font-size: 13px; }
.vorgang-meta { display: flex; flex-direction: column; gap: 2px; }

/* Status-Badges */
.badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 50px; white-space: nowrap; }
.badge-neu             { background: #eef4fb; color: #34608f; }
.badge-in_arbeit       { background: #fff4e0; color: #a76a12; }
.badge-entwurf_bereit  { background: #e6f6ec; color: #1c7a44; }
.badge-wartet_auf_infos{ background: #fdeede; color: #b4531a; }
.badge-gesendet        { background: #e5f3f1; color: #147a6b; }
.badge-fehler          { background: #fdeaea; color: #b3261e; }
.badge-verworfen       { background: #eeeeee; color: #777; }

.placeholder { color: #888; background: var(--sw-card); border: 1px dashed var(--sw-border); border-radius: 10px; padding: 28px; text-align: center; }

/* Forms */
label { display: block; margin-bottom: 12px; font-size: 14px; font-weight: 500; color: var(--sw-heading); }
input[type=text], input[type=password], input[type=email], textarea, select {
  width: 100%; margin-top: 5px; padding: 10px 12px; font-family: inherit; font-size: 15px;
  border: 1px solid var(--sw-border); border-radius: 8px; background: #fff; color: var(--sw-text);
}
input:focus, textarea:focus { outline: none; border-color: var(--sw-primary); box-shadow: 0 0 0 3px var(--sw-primary-tint); }
textarea { min-height: 160px; resize: vertical; line-height: 1.5; }
.error { color: #b3261e; background: #fdeaea; border-radius: 8px; padding: 10px 12px; margin-bottom: 14px; }
.hinweis { color: #a76a12; background: #fff4e0; border-radius: 8px; padding: 10px 12px; }

/* Login */
.sw-login-wrap { max-width: 420px; margin: 6vh auto 0; }
.sw-login-card { background: var(--sw-card); border: 1px solid var(--sw-border); border-radius: 14px; padding: 32px 28px; box-shadow: 0 8px 30px rgba(0,0,0,.06); }
.sw-login-card h1 { text-align: center; }
.sw-login-card .sw-btn-cta { width: 100%; text-align: center; margin-top: 8px; }

/* Detail-Hilfen */
.mail-original { white-space: pre-wrap; font-size: 14px; color: #444; }
.quelle-liste { list-style: none; padding: 0; margin: 8px 0 0; font-size: 13px; }
.quelle-liste li { padding: 4px 0; color: #666; }
.fehlende-infos { margin: 8px 0 0; padding-left: 18px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
