/* ============================================================
   SL-Urlaubsplaner — Benutzer-Einführung
   Design-System (passend zum Hilfe-Portal)
   ============================================================ */

:root {
    --primary: #2563EB;
    --primary-light: #3B82F6;
    --primary-dark: #1D4ED8;
    --accent: #06B6D4;
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --border-radius: 12px;
    --max-width: 860px;
}

/* Reset & Basics */
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--gray-50);
    color: var(--gray-800);
    line-height: 1.7;
    font-size: 17px;
    margin: 0;
    padding: 0;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* ── Header ─────────────────────────────────────────── */
.guide-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 2.5rem 1.5rem 2rem;
    text-align: center;
    position: relative;
}
.guide-header h1 {
    font-size: 2rem;
    font-weight: 800;
    margin: 0 0 .4rem;
    letter-spacing: -.5px;
}
.guide-header .subtitle {
    font-size: 1.05rem;
    opacity: .85;
    font-weight: 400;
}
.guide-header .logo-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: rgba(255,255,255,.15);
    border-radius: 30px;
    padding: .4rem 1.2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    font-size: .95rem;
}

/* ── Breadcrumb ─────────────────────────────────────── */
.breadcrumb-bar {
    background: white;
    border-bottom: 1px solid var(--gray-200);
    padding: .75rem 1.5rem;
    font-size: .9rem;
}
.breadcrumb-bar a {
    color: var(--gray-500);
    text-decoration: none;
}
.breadcrumb-bar a:hover { color: var(--primary); }
.breadcrumb-bar .sep { color: var(--gray-300); margin: 0 .4rem; }
.breadcrumb-bar .current { color: var(--gray-800); font-weight: 600; }

/* ── Main Content ───────────────────────────────────── */
.guide-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
}

/* ── Kapitel-Karten (index.html) ────────────────────── */
.chapter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.25rem;
    margin: 2rem 0;
}
.chapter-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    text-decoration: none;
    color: var(--gray-800);
    transition: transform .2s, box-shadow .2s;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}
.chapter-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    text-decoration: none;
    color: var(--gray-800);
}
.chapter-card .icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}
.chapter-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
}
.chapter-card p {
    font-size: .9rem;
    color: var(--gray-500);
    margin: 0;
    line-height: 1.5;
}
.chapter-card .chapter-nr {
    font-size: .75rem;
    color: var(--gray-500);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}

/* ── Abschnitte ─────────────────────────────────────── */
.section-heading {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--gray-900);
    margin: 2.5rem 0 1rem;
    padding-bottom: .5rem;
    border-bottom: 3px solid var(--primary);
    display: inline-block;
}
.sub-heading {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--gray-800);
    margin: 2rem 0 .75rem;
}

/* ── Schritte (nummeriert) ──────────────────────────── */
.schritt {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.25rem;
    align-items: flex-start;
}
.schritt-nr {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: .95rem;
    flex-shrink: 0;
    margin-top: 2px;
}
.schritt-inhalt {
    flex: 1;
}
.schritt-inhalt h4 {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 .3rem;
    color: var(--gray-800);
}
.schritt-inhalt p {
    margin: 0;
    color: var(--gray-600);
}

/* ── Tipp / Warnung / Info Boxen ────────────────────── */
.tipp-box, .warnung-box, .info-box {
    border-radius: var(--border-radius);
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
    font-size: .95rem;
    line-height: 1.6;
    display: flex;
    gap: .75rem;
    align-items: flex-start;
}
.tipp-box {
    background: #ecfdf5;
    border-left: 4px solid var(--success);
    color: #065f46;
}
.warnung-box {
    background: #fffbeb;
    border-left: 4px solid var(--warning);
    color: #92400e;
}
.info-box {
    background: #eff6ff;
    border-left: 4px solid var(--primary);
    color: #1e40af;
}
.tipp-box .box-icon,
.warnung-box .box-icon,
.info-box .box-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
    line-height: 1;
    margin-top: 2px;
}
.box-label {
    font-weight: 700;
}

/* ── Screenshot-Platzhalter ─────────────────────────── */
.screenshot {
    background: var(--gray-100);
    border: 2px dashed var(--gray-300);
    border-radius: var(--border-radius);
    padding: 2.5rem 1.5rem;
    text-align: center;
    margin: 1.5rem 0;
    color: var(--gray-500);
    font-size: .9rem;
}
.screenshot .placeholder-icon {
    font-size: 2.5rem;
    margin-bottom: .5rem;
    opacity: .5;
}
.screenshot img {
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--gray-200);
}
.screenshot figcaption {
    margin-top: .5rem;
    font-size: .85rem;
    color: var(--gray-500);
    font-style: italic;
}

/* ── Farb-Legende / Status-Tabelle ──────────────────── */
.farb-tabelle {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    margin: 1.5rem 0;
    font-size: .95rem;
}
.farb-tabelle th {
    background: var(--gray-800);
    color: white;
    padding: .75rem 1rem;
    text-align: left;
    font-weight: 600;
}
.farb-tabelle td {
    padding: .65rem 1rem;
    border-bottom: 1px solid var(--gray-100);
    background: white;
    vertical-align: middle;
}
.farb-tabelle tr:last-child td { border-bottom: none; }
.farb-tabelle tr:hover td { background: var(--gray-50); }

.farb-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    color: white;
    font-weight: 700;
    font-size: .85rem;
}
.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    margin-right: .5rem;
}

/* ── Tastatur-Hinweis ───────────────────────────────── */
.kbd {
    display: inline-block;
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: 5px;
    padding: .15rem .5rem;
    font-size: .85rem;
    font-family: 'SF Mono', 'Consolas', monospace;
    font-weight: 600;
    color: var(--gray-700);
    box-shadow: 0 1px 0 var(--gray-300);
    white-space: nowrap;
}

/* ── Navigation Vorher/Nachher ──────────────────────── */
.page-nav {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--gray-200);
}
.page-nav a {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .75rem 1.25rem;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    font-weight: 600;
    font-size: .95rem;
    color: var(--primary);
    text-decoration: none;
    transition: transform .2s, box-shadow .2s;
}
.page-nav a:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    text-decoration: none;
}
.page-nav .prev::before { content: '\2190\00a0'; }
.page-nav .next::after { content: '\00a0\2192'; }

/* ── FAQ / Akkordeon ────────────────────────────────── */
.faq-item {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: .75rem;
    overflow: hidden;
}
.faq-item summary {
    padding: 1rem 1.25rem;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    gap: .5rem;
    color: var(--gray-800);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before {
    content: '\25B6';
    font-size: .7rem;
    color: var(--primary);
    transition: transform .2s;
}
.faq-item[open] summary::before { transform: rotate(90deg); }
.faq-item .faq-body {
    padding: 0 1.25rem 1rem;
    color: var(--gray-600);
    line-height: 1.7;
}

/* ── Checkliste ─────────────────────────────────────── */
.checkliste {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}
.checkliste li {
    padding: .5rem 0 .5rem 2rem;
    position: relative;
    border-bottom: 1px solid var(--gray-100);
}
.checkliste li::before {
    content: '\2610';
    position: absolute;
    left: 0;
    font-size: 1.2rem;
    color: var(--primary);
}

/* ── Footer ─────────────────────────────────────────── */
.guide-footer {
    background: var(--gray-900);
    color: var(--gray-400);
    padding: 2rem 1.5rem;
    text-align: center;
    font-size: .85rem;
}
.guide-footer a { color: var(--gray-300); }
.guide-footer a:hover { color: white; }

/* ── Beispiel-Box ───────────────────────────────────── */
.beispiel-box {
    background: #faf5ff;
    border-left: 4px solid #8b5cf6;
    border-radius: var(--border-radius);
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
    color: #4c1d95;
    font-size: .95rem;
}
.beispiel-box .box-label { color: #6d28d9; }

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 600px) {
    body { font-size: 16px; }
    .guide-header h1 { font-size: 1.5rem; }
    .guide-header { padding: 1.5rem 1rem; }
    .guide-content { padding: 1.25rem 1rem 3rem; }
    .chapter-grid { grid-template-columns: 1fr; }
    .page-nav { flex-direction: column; }
    .page-nav a { justify-content: center; }
    .schritt { gap: .75rem; }
    .farb-tabelle { font-size: .85rem; }
}

@media (min-width: 601px) and (max-width: 900px) {
    .chapter-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── TTS-Widget ─────────────────────────────────────── */
.tts-widget {
    position: absolute;
    top: .85rem;
    right: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .25rem;
    user-select: none;
}
.tts-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,.5);
    background: rgba(255,255,255,.15);
    color: white;
    cursor: pointer;
    font-size: 1rem;
    transition: background .15s, border-color .15s;
    padding: 0;
    line-height: 1;
    backdrop-filter: blur(4px);
}
.tts-btn:hover {
    background: rgba(255,255,255,.3);
    border-color: rgba(255,255,255,.9);
}
.tts-btn.playing {
    background: rgba(239,68,68,.7);
    border-color: white;
}
.tts-duration {
    font-size: .7rem;
    color: rgba(255,255,255,.75);
    white-space: nowrap;
}
@media (max-width: 480px) {
    .tts-widget { display: none; }
}

/* ── Print ──────────────────────────────────────────── */
@media print {
    .guide-header { background: white; color: black; border-bottom: 2px solid black; }
    .breadcrumb-bar, .page-nav, .guide-footer, .tts-bar { display: none; }
    .chapter-card, .faq-item, .tipp-box, .warnung-box, .info-box { box-shadow: none; border: 1px solid #ccc; }
    .screenshot { border-style: solid; }
    body { font-size: 12pt; }
}
