/* ============================================================
   Lernnetz-Schule.de – Hauptstyles
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&family=Nunito+Sans:wght@400;600&display=swap');

:root {
    --primary:        #7c3aed;
    --primary-light:  #8b5cf6;
    --primary-dark:   #5b21b6;
    --primary-bg:     #ede9fe;
    --primary-bg2:    #f5f3ff;
    --accent-pink:    #ec4899;
    --accent-yellow:  #f59e0b;
    --accent-teal:    #14b8a6;
    --accent-blue:    #3b82f6;
    --text:           #1e1b4b;
    --text-muted:     #6b7280;
    --text-light:     #9ca3af;
    --border:         #e5e7eb;
    --bg:             #fafafa;
    --white:          #ffffff;
    --success:        #059669;
    --success-bg:     #d1fae5;
    --warning:        #d97706;
    --warning-bg:     #fef3c7;
    --danger:         #dc2626;
    --danger-bg:      #fee2e2;
    --info:           #2563eb;
    --info-bg:        #dbeafe;
    --radius-sm:      6px;
    --radius:         12px;
    --radius-lg:      20px;
    --radius-xl:      28px;
    --shadow-sm:      0 1px 3px rgba(124,58,237,.08), 0 1px 2px rgba(0,0,0,.06);
    --shadow:         0 4px 16px rgba(124,58,237,.12), 0 2px 4px rgba(0,0,0,.06);
    --shadow-lg:      0 12px 40px rgba(124,58,237,.18), 0 4px 8px rgba(0,0,0,.08);
    --font:           'Nunito', sans-serif;
    --font-body:      'Nunito Sans', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-body); color: var(--text); background: var(--bg); line-height: 1.65; min-height: 100vh; }
h1,h2,h3,h4,h5,h6 { font-family: var(--font); font-weight: 800; line-height: 1.25; color: var(--text); }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

/* ============================================================
   HEADER & NAVIGATION
   ============================================================ */

.site-header {
    background: var(--white);
    border-bottom: 2px solid var(--primary-bg);
    position: sticky;
    top: 0;
    z-index: 200;
    box-shadow: 0 2px 12px rgba(124,58,237,.08);
    overflow: visible;
}

.nav-inner {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: 68px;
    position: relative;
}

/* Logo Startseite — hängt nach unten */
.logo-home {
    position: absolute;
    top: 0;
    left: 32px;
    z-index: 100;
    display: block;
    text-decoration: none;
}
.logo-home-img {
    height: 110px;
    width: auto;
    filter: drop-shadow(0 4px 12px rgba(124,58,237,.15));
}
.logo-home-spacer {
    min-width: 260px;
    flex-shrink: 0;
}

/* Logo kompakt */
.logo-compact {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}
.logo-compact-icon { height: 44px; width: 44px; }
.logo-compact-text { line-height: 1.1; display: flex; flex-direction: column; }
.logo-compact-l { font-size: 17px; font-weight: 800; color: #7c3aed; font-family: var(--font); letter-spacing: -0.5px; }
.logo-compact-s { font-size: 15px; font-weight: 800; color: #ec4899; font-family: var(--font); letter-spacing: -0.5px; }

/* Desktop Nav */
.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: nowrap;
    margin-left: auto;
}
.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    padding: 8px 14px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font);
    transition: all .2s;
    white-space: nowrap;
    display: block;
}
.nav-links a:hover { background: var(--primary-bg); color: var(--primary); }
.nav-links .btn-nav { background: var(--primary); color: white !important; padding: 8px 18px; border-radius: var(--radius); }
.nav-links .btn-nav:hover { background: var(--primary-dark) !important; color: white !important; }

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: var(--primary-bg);
    border: 2px solid var(--primary-bg);
    border-radius: var(--radius);
    cursor: pointer;
    padding: 10px;
    flex-shrink: 0;
    transition: all .2s;
}
.hamburger:hover { background: #ddd6fe; border-color: var(--primary); }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--primary); border-radius: 2px; transition: all .3s ease; }
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Nav */
.mobile-nav {
    display: none;
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    z-index: 190;
    padding: 16px;
    overflow-y: auto;
    border-top: 2px solid var(--primary-bg);
}
.mobile-nav.open { display: block; }
.mobile-nav ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.mobile-nav ul li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 700;
    font-family: var(--font);
    color: var(--text);
    text-decoration: none;
    transition: all .2s;
}
.mobile-nav ul li a:hover { background: var(--primary-bg); color: var(--primary); }
.btn-nav-mobile {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: white !important;
    padding: 14px 18px;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 700;
    font-family: var(--font);
    text-decoration: none;
    margin-top: 8px;
}
.nav-divider { height: 1px; background: var(--border); margin: 8px 0; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 24px; border: none; border-radius: var(--radius); font-size: 15px; font-weight: 700; font-family: var(--font); cursor: pointer; text-decoration: none; transition: all .2s; line-height: 1; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--primary); color: white; box-shadow: 0 4px 14px rgba(124,58,237,.35); }
.btn-primary:hover { background: var(--primary-dark); color: white; box-shadow: 0 6px 20px rgba(124,58,237,.45); }
.btn-secondary { background: var(--primary-bg); color: var(--primary); }
.btn-secondary:hover { background: #ddd6fe; color: var(--primary-dark); }
.btn-outline { background: transparent; border: 2px solid var(--border); color: var(--text-muted); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-bg2); }
.btn-success { background: var(--success); color: white; }
.btn-danger  { background: var(--danger);  color: white; }
.btn-pink    { background: var(--accent-pink); color: white; }
.btn-lg { padding: 14px 32px; font-size: 17px; border-radius: var(--radius-lg); }
.btn-sm { padding: 7px 16px; font-size: 13px; border-radius: var(--radius-sm); }

/* ============================================================
   FLASH MESSAGES
   ============================================================ */
.flash-container { margin: 20px 0 0; }
.flash { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-radius: var(--radius); margin-bottom: 10px; font-size: 14px; font-weight: 600; font-family: var(--font); }
.flash-success { background: var(--success-bg); color: var(--success); border-left: 4px solid var(--success); }
.flash-error   { background: var(--danger-bg);  color: var(--danger);  border-left: 4px solid var(--danger); }
.flash-info    { background: var(--info-bg);    color: var(--info);    border-left: 4px solid var(--info); }
.flash-warning { background: var(--warning-bg); color: var(--warning); border-left: 4px solid var(--warning); }

/* ============================================================
   MAIN & HERO
   ============================================================ */
.main-content { padding: 40px 24px 60px; min-height: calc(100vh - 68px - 80px); }

.hero { background: linear-gradient(135deg, #f5f3ff 0%, #fce7f3 50%, #ede9fe 100%); border-radius: var(--radius-xl); padding: 72px 48px; text-align: center; position: relative; overflow: hidden; margin-bottom: 48px; }
.hero-badge { display: inline-flex; align-items: center; gap: 6px; background: white; color: var(--primary); border: 2px solid var(--primary-bg); padding: 6px 16px; border-radius: 20px; font-size: 13px; font-weight: 700; font-family: var(--font); margin-bottom: 24px; }
.hero h1 { font-size: clamp(32px, 5vw, 54px); font-weight: 900; margin-bottom: 20px; background: linear-gradient(135deg, var(--primary-dark), var(--accent-pink)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero p { font-size: 18px; color: var(--text-muted); max-width: 560px; margin: 0 auto 36px; line-height: 1.7; }
.hero-buttons { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 32px; justify-content: center; margin-top: 48px; flex-wrap: wrap; }
.hero-stat .number { font-family: var(--font); font-size: 28px; font-weight: 900; color: var(--primary); }
.hero-stat .label { font-size: 13px; color: var(--text-muted); font-weight: 600; }

/* ============================================================
   FEATURE CARDS
   ============================================================ */
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-bottom: 48px; }
.feature-card { background: var(--white); border: 2px solid var(--border); border-radius: var(--radius-lg); padding: 28px; transition: all .25s; }
.feature-card:hover { border-color: var(--primary-light); box-shadow: var(--shadow); transform: translateY(-3px); }
.feature-icon { width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 26px; margin-bottom: 16px; }
.feature-icon.purple { background: var(--primary-bg); }
.feature-icon.pink   { background: #fce7f3; }
.feature-icon.teal   { background: #ccfbf1; }
.feature-icon.yellow { background: #fef9c3; }
.feature-card h3 { font-size: 17px; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-muted); line-height: 1.6; }

/* ============================================================
   CARDS
   ============================================================ */
.card { background: var(--white); border: 2px solid var(--border); border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow-sm); }
.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 2px solid var(--primary-bg); }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 22px; }
.form-group label { display: block; font-size: 14px; font-weight: 700; font-family: var(--font); margin-bottom: 7px; color: var(--text); }
.form-group label .required { color: var(--accent-pink); margin-left: 3px; }
.form-control { width: 100%; padding: 11px 16px; border: 2px solid var(--border); border-radius: var(--radius); font-size: 15px; font-family: var(--font-body); color: var(--text); background: var(--white); transition: all .2s; outline: none; }
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(124,58,237,.1); }
.form-control::placeholder { color: var(--text-light); }
textarea.form-control { resize: vertical; min-height: 100px; }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 5px; }
.error-box { background: var(--danger-bg); border: 2px solid #fca5a5; border-radius: var(--radius); padding: 14px 18px; margin-bottom: 24px; }
.error-box ul { list-style: none; }
.error-box li { color: var(--danger); font-size: 14px; font-weight: 600; font-family: var(--font); padding: 3px 0; }
.error-box li::before { content: '✕ '; font-size: 12px; }

/* ============================================================
   LISTINGS
   ============================================================ */
.listing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; margin-top: 28px; }
.listing-card { background: var(--white); border: 2px solid var(--border); border-radius: var(--radius-lg); padding: 22px; transition: all .25s; text-decoration: none; color: inherit; display: block; position: relative; }
.listing-card:hover { border-color: var(--primary-light); box-shadow: var(--shadow); transform: translateY(-3px); color: inherit; }
.listing-card .subject-badge { display: inline-flex; align-items: center; gap: 6px; background: var(--primary-bg); color: var(--primary); padding: 5px 12px; border-radius: 20px; font-size: 13px; font-weight: 700; font-family: var(--font); margin-bottom: 12px; }
.listing-card h3 { font-size: 18px; margin-bottom: 4px; }
.listing-card .meta { font-size: 13px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.listing-card .price { font-size: 20px; font-weight: 800; font-family: var(--font); color: var(--primary); margin-top: 12px; }
.listing-card .verified-badge { position: absolute; top: 16px; right: 16px; background: var(--success-bg); color: var(--success); padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 700; font-family: var(--font); }

/* ============================================================
   BADGES
   ============================================================ */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; font-family: var(--font); }
.badge-purple { background: var(--primary-bg); color: var(--primary); }
.badge-green  { background: var(--success-bg); color: var(--success); }
.badge-yellow { background: var(--warning-bg); color: var(--warning); }
.badge-red    { background: var(--danger-bg);  color: var(--danger); }
.badge-blue   { background: var(--info-bg);    color: var(--info); }
.badge-pink   { background: #fce7f3; color: var(--accent-pink); }

/* ============================================================
   PAGE HEADER
   ============================================================ */
.page-header { margin-bottom: 32px; }
.page-header h1 { font-size: 32px; margin-bottom: 8px; }
.page-header p { color: var(--text-muted); font-size: 16px; }

/* ============================================================
   AUTH
   ============================================================ */
.auth-wrapper { min-height: calc(100vh - 148px); display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.auth-card { background: var(--white); border: 2px solid var(--border); border-radius: var(--radius-xl); padding: 40px; width: 100%; max-width: 460px; box-shadow: var(--shadow-lg); }
.auth-card h2 { font-size: 26px; text-align: center; margin-bottom: 6px; }
.auth-sub { text-align: center; color: var(--text-muted); font-size: 14px; margin-bottom: 28px; }

/* ============================================================
   WEEKDAY BUTTONS
   ============================================================ */
.weekday-btn { padding: 6px 12px; border: 2px solid var(--border); border-radius: var(--radius); font-size: 13px; font-weight: 700; font-family: var(--font); cursor: pointer; transition: all .2s; }
.weekday-btn.active { background: var(--primary); color: white; border-color: var(--primary); }
.weekday-btn:not(.active) { background: var(--bg); color: var(--text-light); border-color: var(--border); text-decoration: line-through; opacity: 0.5; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--text); color: #a5b4fc; padding: 32px 24px; text-align: center; font-size: 14px; }
.site-footer a { color: #c4b5fd; }
.site-footer a:hover { color: white; }
.site-footer .footer-links { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeInUp { from { opacity:0; transform:translateY(16px); } to { opacity:1; transform:translateY(0); } }
@keyframes slideDown { from { opacity:0; transform:translateY(-8px); } to { opacity:1; transform:translateY(0); } }
.animate-in { animation: fadeInUp .4s ease forwards; }

/* ============================================================
   RANGE SLIDER
   ============================================================ */
input[type=range] { -webkit-appearance: none; appearance: none; background: transparent; cursor: pointer; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 20px; height: 20px; border-radius: 50%; background: var(--primary); border: 3px solid white; box-shadow: 0 2px 6px rgba(124,58,237,.4); pointer-events: all; cursor: grab; margin-top: -7px; }
input[type=range]::-webkit-slider-thumb:active { cursor: grabbing; }
input[type=range]::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: var(--primary); border: 3px solid white; box-shadow: 0 2px 6px rgba(124,58,237,.4); pointer-events: all; cursor: grab; }
input[type=range]::-webkit-slider-runnable-track { background: transparent; }
input[type=range]::-moz-range-track { background: transparent; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    /* Navigation */
    .hamburger { display: flex; }
    .nav-links  { display: none; }
    .nav-inner  { padding: 0 16px; }

    /* Logo auf Mobile — kein Überhang, kompakt */
    .logo-home {
        position: static;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    .logo-home-img {
        height: 40px;
        width: auto;
        filter: none;
    }
    .logo-home-spacer { display: none; }

    /* Content */
    .main-content { padding: 24px 16px 40px; }
    .hero { padding: 36px 20px; }
    .hero h1 { font-size: 28px; }
    .features-grid { grid-template-columns: 1fr; }
    .listing-grid { grid-template-columns: 1fr; }
    .hero-buttons { flex-direction: column; align-items: stretch; }
    .hero-stats { gap: 20px; }

    /* Cards */
    .card { padding: 20px; }
    .auth-card { padding: 24px 20px; }
    .page-header h1 { font-size: 24px; }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
}
@media (max-width: 768px) {
    .cta-grid { grid-template-columns: 1fr !important; }
	}
@media print {
    .site-header,
    .mobile-nav,
    .site-footer,
    .hamburger {
        display: none !important;
    }
    .main-content {
        padding: 0 !important;
    }
}