/* ========== Reset & Base ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --cocoa-darkest: #2A1409;
    --cocoa-dark: #3D1F0F;
    --cocoa: #5C2E12;
    --cocoa-mid: #8B4513;
    --caramel: #C68642;
    --gold: #D4A574;
    --gold-light: #E8B57F;
    --cream: #FFF8F0;
    --cream-warm: #F5E6D3;
    --ivory: #FDF6EC;
    --shadow-soft: 0 8px 30px rgba(42, 20, 9, 0.12);
    --shadow-deep: 0 20px 60px rgba(42, 20, 9, 0.25);
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--cocoa-dark);
    background: var(--ivory);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--cocoa-darkest);
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.01em; }
h3 { font-size: 1.5rem; }

a { color: inherit; text-decoration: none; transition: color 0.3s ease; }
img { max-width: 100%; display: block; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

/* ========== Navigation ========== */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(253, 246, 236, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(139, 69, 19, 0.08);
}

.nav-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.1rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.brand {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cocoa-darkest);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.brand-icon {
    display: inline-block;
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--cocoa) 0%, var(--cocoa-darkest) 100%);
    border-radius: 6px;
    position: relative;
    box-shadow: inset 0 -3px 0 rgba(0,0,0,0.2);
}

.brand-icon::after {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid rgba(212, 165, 116, 0.4);
    border-radius: 3px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    align-items: center;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--cocoa);
    position: relative;
    padding: 0.25rem 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: width 0.3s ease;
}

.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-links a.active { color: var(--cocoa-darkest); }

.nav-login {
    background: linear-gradient(135deg, var(--cocoa) 0%, var(--cocoa-darkest) 100%);
    color: var(--cream) !important;
    padding: 0.55rem 1.4rem !important;
    border-radius: 50px;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(92, 46, 18, 0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.nav-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(92, 46, 18, 0.4);
}

.nav-login::after { display: none !important; }

/* ========== Buttons ========== */
.btn {
    display: inline-block;
    padding: 0.95rem 2.2rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--cocoa) 0%, var(--cocoa-darkest) 100%);
    color: var(--cream);
    box-shadow: 0 4px 20px rgba(92, 46, 18, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(92, 46, 18, 0.5);
}

.btn-secondary {
    background: transparent;
    color: var(--cocoa-darkest);
    border: 2px solid var(--cocoa-darkest);
}

.btn-secondary:hover {
    background: var(--cocoa-darkest);
    color: var(--cream);
}

/* ========== Hero ========== */
.hero {
    position: relative;
    min-height: 88vh;
    display: flex;
    align-items: center;
    background:
        linear-gradient(135deg, rgba(42, 20, 9, 0.85) 0%, rgba(92, 46, 18, 0.65) 100%),
        url('https://images.unsplash.com/photo-1606312619070-d48b4c652a52?w=1600&q=80') center/cover;
    color: var(--cream);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top right, rgba(212, 165, 116, 0.25), transparent 60%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: 720px;
    padding: 4rem 1.5rem;
    margin: 0 auto;
    text-align: center;
    animation: fadeUp 1s ease-out;
}

.hero-eyebrow {
    display: inline-block;
    font-size: 0.85rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold-light);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.hero h1 {
    color: var(--cream);
    margin-bottom: 1.5rem;
}

.hero h1 em {
    font-style: italic;
    color: var(--gold-light);
    font-weight: 400;
}

.hero-tagline {
    font-size: 1.15rem;
    color: rgba(255, 248, 240, 0.85);
    margin-bottom: 2.5rem;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-actions .btn-secondary {
    color: var(--cream);
    border-color: var(--cream);
}

.hero-actions .btn-secondary:hover {
    background: var(--cream);
    color: var(--cocoa-darkest);
}

/* ========== Section base ========== */
section { padding: 6rem 0; }

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-eyebrow {
    display: inline-block;
    font-size: 0.8rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--caramel);
    margin-bottom: 1rem;
    font-weight: 600;
}

.section-header p {
    color: var(--cocoa);
    max-width: 600px;
    margin: 1rem auto 0;
    font-size: 1.05rem;
}

/* ========== Features grid (home) ========== */
.features {
    background: var(--cream-warm);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--ivory);
    padding: 2.5rem 2rem;
    border-radius: 16px;
    text-align: center;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    box-shadow: 0 2px 12px rgba(42, 20, 9, 0.06);
    border: 1px solid rgba(139, 69, 19, 0.06);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-soft);
}

.feature-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold) 0%, var(--caramel) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cocoa-darkest);
    font-size: 1.6rem;
    font-weight: 700;
    font-family: 'Playfair Display', serif;
}

.feature-card h3 {
    margin-bottom: 0.75rem;
    font-size: 1.3rem;
}

.feature-card p {
    color: var(--cocoa);
    font-size: 0.95rem;
}

/* ========== Showcase (alternating) ========== */
.showcase {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-bottom: 6rem;
}

.showcase:last-child { margin-bottom: 0; }
.showcase.reverse .showcase-image { order: 2; }

.showcase-image {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-deep);
    aspect-ratio: 4/5;
    position: relative;
}

.showcase-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.showcase-image:hover img { transform: scale(1.05); }

.showcase-text h2 {
    margin-bottom: 1.5rem;
}

.showcase-text p {
    color: var(--cocoa);
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

/* ========== Product grid ========== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--ivory);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-deep);
}

.product-image {
    aspect-ratio: 4/3;
    overflow: hidden;
    position: relative;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.product-card:hover .product-image img { transform: scale(1.08); }

.product-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--cocoa-darkest);
    color: var(--gold-light);
    padding: 0.35rem 0.9rem;
    border-radius: 50px;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 600;
}

.product-info {
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.product-info h3 {
    margin-bottom: 0.5rem;
    font-size: 1.35rem;
}

.product-cocoa {
    color: var(--caramel);
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.product-desc {
    color: var(--cocoa);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex: 1;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(139, 69, 19, 0.1);
}

.product-price {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cocoa-darkest);
}

.product-cart {
    background: var(--cocoa-darkest);
    color: var(--cream);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.product-cart:hover {
    background: var(--gold);
    color: var(--cocoa-darkest);
    transform: scale(1.1);
}

/* ========== Recipes ========== */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
}

.recipe-card {
    background: var(--ivory);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: transform 0.4s ease;
}

.recipe-card:hover { transform: translateY(-6px); }

.recipe-image {
    aspect-ratio: 16/10;
    overflow: hidden;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.recipe-card:hover .recipe-image img { transform: scale(1.06); }

.recipe-info { padding: 2rem; }

.recipe-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
    color: var(--caramel);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
}

.recipe-info h3 { margin-bottom: 1rem; }

.recipe-info p {
    color: var(--cocoa);
    margin-bottom: 1.5rem;
}

.recipe-steps {
    list-style: none;
    counter-reset: step;
}

.recipe-steps li {
    counter-increment: step;
    padding-left: 2.5rem;
    position: relative;
    margin-bottom: 0.85rem;
    color: var(--cocoa);
    font-size: 0.95rem;
}

.recipe-steps li::before {
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 28px;
    height: 28px;
    background: var(--gold);
    color: var(--cocoa-darkest);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    font-family: 'Playfair Display', serif;
}

/* ========== Timeline (about page) ========== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, transparent, var(--caramel) 10%, var(--caramel) 90%, transparent);
    transform: translateX(-50%);
}

.timeline-item {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 2rem;
    align-items: center;
    margin-bottom: 3rem;
}

.timeline-item:nth-child(odd) .timeline-text { text-align: right; }
.timeline-item:nth-child(even) .timeline-text { grid-column: 3; text-align: left; }
.timeline-item:nth-child(even) .timeline-spacer { grid-column: 1; }

.timeline-dot {
    width: 18px;
    height: 18px;
    background: var(--gold);
    border: 4px solid var(--ivory);
    border-radius: 50%;
    box-shadow: 0 0 0 2px var(--caramel);
    grid-column: 2;
    z-index: 1;
}

.timeline-year {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    color: var(--caramel);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.timeline-text h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.timeline-text p {
    color: var(--cocoa);
    font-size: 0.95rem;
}

/* ========== Stats ========== */
.stats {
    background: linear-gradient(135deg, var(--cocoa-darkest) 0%, var(--cocoa) 100%);
    color: var(--cream);
    position: relative;
    overflow: hidden;
}

.stats::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(212, 165, 116, 0.15), transparent 50%);
    pointer-events: none;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 2rem;
    text-align: center;
    position: relative;
}

.stat-number {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--gold-light);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(255, 248, 240, 0.75);
}

/* ========== Contact form ========== */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 4rem;
    align-items: start;
}

.contact-info h2 { margin-bottom: 1.5rem; }
.contact-info > p {
    color: var(--cocoa);
    margin-bottom: 2.5rem;
    font-size: 1.05rem;
}

.contact-detail {
    display: flex;
    gap: 1.2rem;
    margin-bottom: 1.8rem;
    align-items: flex-start;
}

.contact-detail-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--gold), var(--caramel));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cocoa-darkest);
    font-weight: 700;
    flex-shrink: 0;
}

.contact-detail-text strong {
    display: block;
    color: var(--cocoa-darkest);
    margin-bottom: 0.25rem;
    font-weight: 600;
}

.contact-detail-text span {
    color: var(--cocoa);
    font-size: 0.95rem;
}

.contact-form {
    background: var(--cream-warm);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: var(--shadow-soft);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.form-field { margin-bottom: 1.25rem; }

.form-field label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--cocoa-darkest);
    margin-bottom: 0.5rem;
    letter-spacing: 0.05em;
}

.form-field input,
.form-field textarea,
.form-field select {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1.5px solid rgba(139, 69, 19, 0.15);
    border-radius: 10px;
    background: var(--ivory);
    font-family: inherit;
    font-size: 0.95rem;
    color: var(--cocoa-darkest);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
    outline: none;
    border-color: var(--caramel);
    box-shadow: 0 0 0 3px rgba(198, 134, 66, 0.15);
}

.form-field textarea {
    resize: vertical;
    min-height: 130px;
}

/* ========== Page header (interior pages) ========== */
.page-header {
    background: linear-gradient(135deg, var(--cocoa-darkest) 0%, var(--cocoa) 100%);
    color: var(--cream);
    padding: 5rem 0 4rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center bottom, rgba(212, 165, 116, 0.2), transparent 60%);
}

.page-header h1 {
    color: var(--cream);
    margin-bottom: 1rem;
    position: relative;
}

.page-header p {
    max-width: 600px;
    margin: 0 auto;
    color: rgba(255, 248, 240, 0.85);
    font-size: 1.1rem;
    position: relative;
}

/* ========== Footer ========== */
.footer {
    background: var(--cocoa-darkest);
    color: rgba(255, 248, 240, 0.7);
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer h4 {
    color: var(--gold-light);
    font-size: 1.05rem;
    margin-bottom: 1.2rem;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 600;
}

.footer-about p {
    font-size: 0.95rem;
    line-height: 1.7;
    margin-top: 1rem;
}

.footer-about .brand { color: var(--cream); margin-bottom: 0.5rem; }

.footer ul { list-style: none; }

.footer li {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.footer a:hover { color: var(--gold-light); }

.footer-bottom {
    border-top: 1px solid rgba(255, 248, 240, 0.1);
    padding-top: 2rem;
    text-align: center;
    font-size: 0.875rem;
    color: rgba(255, 248, 240, 0.5);
}

/* ========== Animations ========== */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========== Responsive ========== */
@media (max-width: 900px) {
    .showcase,
    .contact-wrapper,
    .footer-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .showcase.reverse .showcase-image { order: 0; }
    .nav-links { gap: 1.2rem; }
    section { padding: 4rem 0; }
    .timeline::before { left: 20px; }
    .timeline-item {
        grid-template-columns: 40px 1fr;
        text-align: left !important;
    }
    .timeline-item .timeline-text,
    .timeline-item:nth-child(odd) .timeline-text,
    .timeline-item:nth-child(even) .timeline-text {
        grid-column: 2;
        text-align: left;
    }
    .timeline-dot { grid-column: 1; }
    .timeline-spacer { display: none; }
    .contact-form { padding: 2rem; }
    .form-row { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .nav-links { display: none; }
    .nav-links.mobile-open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--ivory);
        padding: 1.5rem;
        box-shadow: var(--shadow-soft);
    }
    .mobile-toggle {
        display: block;
        background: none;
        border: none;
        color: var(--cocoa-darkest);
        font-size: 1.5rem;
        cursor: pointer;
    }
    .hero { min-height: 75vh; }
    .stat-number { font-size: 2.5rem; }
}

.mobile-toggle { display: none; }

/* ================================================== */
/* ============== AUTH (login) PAGE ================= */
/* ================================================== */

.auth-body {
    background: var(--ivory);
    min-height: 100vh;
}

.auth-shell {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
}

.auth-aside {
    background:
        linear-gradient(135deg, rgba(42, 20, 9, 0.92) 0%, rgba(92, 46, 18, 0.75) 100%),
        url('https://images.unsplash.com/photo-1511381939415-e44015466834?w=1400&q=80') center/cover;
    color: var(--cream);
    padding: 3.5rem;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.auth-aside::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top right, rgba(212, 165, 116, 0.25), transparent 60%);
    pointer-events: none;
}

.auth-aside-inner {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 3rem;
    max-width: 440px;
}

.auth-brand { color: var(--cream); }

.auth-headline {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 3.5vw, 3rem);
    line-height: 1.15;
    color: var(--cream);
    margin: 0.75rem 0 1rem;
}

.auth-subhead {
    color: rgba(255, 248, 240, 0.85);
    font-size: 1.05rem;
}

.auth-quote {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 1.05rem;
    color: rgba(255, 248, 240, 0.85);
    border-left: 2px solid var(--gold-light);
    padding-left: 1.2rem;
    line-height: 1.6;
}

.auth-quote span {
    display: block;
    font-style: normal;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    color: var(--gold-light);
    margin-top: 0.5rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.auth-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    position: relative;
}

.auth-back {
    position: absolute;
    top: 2rem;
    left: 2rem;
    color: var(--cocoa);
    font-size: 0.9rem;
    font-weight: 500;
}

.auth-back:hover { color: var(--cocoa-darkest); }

.auth-card {
    width: 100%;
    max-width: 440px;
}

.auth-title {
    margin-bottom: 0.5rem;
}

.auth-lede {
    color: var(--cocoa);
    margin-bottom: 2rem;
    font-size: 1rem;
}

.auth-form .form-field { margin-bottom: 1.25rem; }

.auth-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.75rem;
    font-size: 0.9rem;
}

.auth-check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--cocoa);
    cursor: pointer;
}

.auth-check input {
    accent-color: var(--cocoa-darkest);
    width: 16px;
    height: 16px;
}

.auth-link {
    color: var(--caramel);
    font-weight: 600;
}

.auth-link:hover { color: var(--cocoa-darkest); }

.auth-submit {
    width: 100%;
    font-size: 1rem;
    padding: 1rem;
}

.auth-msg {
    margin-top: 1rem;
    font-size: 0.9rem;
    text-align: center;
    min-height: 1.4em;
    color: var(--cocoa);
}

.auth-msg.success { color: #2d7a3d; font-weight: 600; }

.auth-hint {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.82rem;
    color: var(--caramel);
    font-style: italic;
}

@media (max-width: 900px) {
    .auth-shell { grid-template-columns: 1fr; }
    .auth-aside { padding: 2.5rem; min-height: 280px; }
    .auth-aside-inner { gap: 1.5rem; }
    .auth-quote { display: none; }
    .auth-back { top: 1rem; left: 1rem; }
}

/* ================================================== */
/* ============= ADMIN PANEL ======================== */
/* ================================================== */

.admin-body {
    background: #F4ECE0;
    min-height: 100vh;
    overflow-x: hidden;
}

.admin-shell {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: 100vh;
}

/* Sidebar */
.admin-sidebar {
    background: var(--cocoa-darkest);
    color: var(--cream);
    padding: 2rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    position: sticky;
    top: 0;
    height: 100vh;
}

.admin-brand {
    color: var(--cream);
    padding: 0 0.5rem;
}

.admin-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
}

.admin-nav-label {
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255, 248, 240, 0.45);
    padding: 1rem 0.85rem 0.5rem;
    font-weight: 600;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.7rem 0.85rem;
    border-radius: 10px;
    color: rgba(255, 248, 240, 0.78);
    font-size: 0.92rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.admin-nav-link:hover {
    background: rgba(255, 248, 240, 0.08);
    color: var(--cream);
}

.admin-nav-link.active {
    background: linear-gradient(135deg, var(--cocoa-mid), var(--cocoa));
    color: var(--gold-light);
    box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}

.admin-nav-icon {
    font-size: 1rem;
    width: 18px;
    display: inline-flex;
    justify-content: center;
    color: var(--gold);
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem;
    background: rgba(255, 248, 240, 0.06);
    border-radius: 12px;
}

.admin-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), var(--caramel));
    color: var(--cocoa-darkest);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    flex-shrink: 0;
}

.admin-user-info { flex: 1; min-width: 0; line-height: 1.3; }
.admin-user-info strong { display: block; font-size: 0.88rem; color: var(--cream); }
.admin-user-info span { font-size: 0.75rem; color: rgba(255, 248, 240, 0.6); }

.admin-logout {
    background: none;
    border: 1px solid rgba(255, 248, 240, 0.15);
    color: rgba(255, 248, 240, 0.7);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.admin-logout:hover {
    background: rgba(220, 80, 80, 0.2);
    color: #ffaaaa;
    border-color: rgba(220, 80, 80, 0.4);
}

/* Main area */
.admin-main {
    padding: 2rem 2.5rem;
    overflow-x: hidden;
}

.admin-topbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 2rem;
    gap: 2rem;
}

.admin-page-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    color: var(--cocoa-darkest);
    margin-bottom: 0.25rem;
}

.admin-page-sub { color: var(--cocoa); font-size: 0.95rem; }

.admin-search input {
    padding: 0.7rem 1rem;
    border: 1.5px solid rgba(139, 69, 19, 0.15);
    border-radius: 50px;
    background: var(--ivory);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--cocoa-darkest);
    width: 280px;
    transition: all 0.2s ease;
}

.admin-search input:focus {
    outline: none;
    border-color: var(--caramel);
    box-shadow: 0 0 0 3px rgba(198, 134, 66, 0.15);
}

/* Sections */
.admin-section { display: none; animation: fadeUp 0.4s ease; }
.admin-section.active { display: block; }

/* Stat cards */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.admin-stat-card {
    background: var(--ivory);
    padding: 1.5rem;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(42, 20, 9, 0.06);
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    border: 1px solid rgba(139, 69, 19, 0.06);
}

.admin-stat-label {
    font-size: 0.78rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--caramel);
    font-weight: 600;
}

.admin-stat-value {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--cocoa-darkest);
    font-weight: 700;
    line-height: 1;
}

.admin-stat-delta { font-size: 0.82rem; font-weight: 500; }
.admin-stat-delta.up { color: #2d7a3d; }
.admin-stat-delta.down { color: #a85c1f; }

/* Panels */
.admin-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.admin-panel {
    background: var(--ivory);
    padding: 1.75rem;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(42, 20, 9, 0.06);
    border: 1px solid rgba(139, 69, 19, 0.06);
    margin-bottom: 1.5rem;
}

.admin-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.admin-panel-head h3 {
    font-size: 1.15rem;
    margin: 0;
}

.admin-pill {
    background: var(--cream-warm);
    color: var(--cocoa);
    padding: 0.3rem 0.85rem;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.admin-link {
    color: var(--caramel);
    font-size: 0.88rem;
    font-weight: 600;
}

.admin-link:hover { color: var(--cocoa-darkest); }

.admin-btn-sm {
    padding: 0.55rem 1.1rem;
    font-size: 0.85rem;
}

/* Activity feed */
.admin-activity { list-style: none; display: flex; flex-direction: column; gap: 1rem; }
.admin-activity li {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    font-size: 0.92rem;
    color: var(--cocoa);
}
.admin-activity strong { color: var(--cocoa-darkest); font-weight: 600; }
.admin-time {
    display: block;
    font-size: 0.78rem;
    color: var(--caramel);
    margin-top: 0.2rem;
}

.admin-act-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-top: 6px;
    flex-shrink: 0;
}
.admin-act-dot.ok { background: #4caf6d; box-shadow: 0 0 0 3px rgba(76, 175, 109, 0.18); }
.admin-act-dot.warn { background: #d68a3a; box-shadow: 0 0 0 3px rgba(214, 138, 58, 0.18); }
.admin-act-dot.info { background: #6a8db8; box-shadow: 0 0 0 3px rgba(106, 141, 184, 0.18); }

/* Rank list */
.admin-rank { list-style: none; display: flex; flex-direction: column; gap: 1.25rem; }
.admin-rank li {
    display: grid;
    grid-template-columns: 28px 1fr;
    gap: 0.85rem;
    align-items: center;
}

.admin-rank-num {
    font-family: 'Playfair Display', serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--caramel);
    text-align: center;
}

.admin-rank-info { line-height: 1.35; }
.admin-rank-info strong { display: block; color: var(--cocoa-darkest); font-size: 0.95rem; }
.admin-rank-info span { font-size: 0.82rem; color: var(--cocoa); }

.admin-bar {
    grid-column: 2;
    height: 5px;
    background: var(--cream-warm);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 0.4rem;
}

.admin-bar span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--caramel), var(--gold));
    border-radius: 4px;
}

/* Tables */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.admin-table thead th {
    text-align: left;
    padding: 0.85rem 1rem;
    color: var(--caramel);
    font-size: 0.72rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    font-weight: 600;
    border-bottom: 1px solid rgba(139, 69, 19, 0.12);
}

.admin-table tbody td {
    padding: 1rem;
    border-bottom: 1px solid rgba(139, 69, 19, 0.06);
    color: var(--cocoa);
}

.admin-table tbody tr:hover { background: var(--cream-warm); }
.admin-table tbody tr:last-child td { border-bottom: none; }

.admin-tag {
    display: inline-block;
    padding: 0.25rem 0.7rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}
.admin-tag.ok { background: rgba(76, 175, 109, 0.15); color: #2d7a3d; }
.admin-tag.warn { background: rgba(214, 138, 58, 0.18); color: #a85c1f; }
.admin-tag.info { background: rgba(106, 141, 184, 0.18); color: #3d6396; }

.admin-mini {
    background: none;
    border: 1px solid rgba(139, 69, 19, 0.2);
    color: var(--cocoa-darkest);
    padding: 0.35rem 0.85rem;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.admin-mini:hover {
    background: var(--cocoa-darkest);
    color: var(--cream);
    border-color: var(--cocoa-darkest);
}

/* Simple chart */
.admin-chart {
    display: flex;
    align-items: flex-end;
    gap: 0.85rem;
    height: 200px;
    padding-top: 1rem;
}

.admin-chart-bar {
    flex: 1;
    background: linear-gradient(to top, var(--cocoa) 0%, var(--caramel) 100%);
    border-radius: 6px 6px 0 0;
    position: relative;
    transition: opacity 0.3s ease;
    min-height: 20px;
}

.admin-chart-bar:hover { opacity: 0.85; }

.admin-chart-bar span {
    position: absolute;
    bottom: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: var(--cocoa);
    font-weight: 600;
    letter-spacing: 0.05em;
}

.admin-check {
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

/* Responsive admin */
@media (max-width: 1000px) {
    .admin-grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
    .admin-shell { grid-template-columns: 1fr; }
    .admin-sidebar {
        position: relative;
        height: auto;
        flex-direction: column;
    }
    .admin-main { padding: 1.5rem; }
    .admin-topbar { flex-direction: column; align-items: stretch; gap: 1rem; }
    .admin-search input { width: 100%; }
    .admin-table { font-size: 0.82rem; }
    .admin-table thead th,
    .admin-table tbody td { padding: 0.7rem 0.5rem; }
}
