:root {
    --navy: #0b1c3d;
    --cream: #faf4e8;
    --text-main: #1f2430;
    --text-muted: #606575;
    --border-subtle: rgba(11, 28, 61, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: radial-gradient(circle at top left, #ffffff 0%, var(--cream) 60%, #f2ecdf 100%);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--navy);
    padding: 1rem 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    max-width: none;
}

.header-content {
    max-width: 1120px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.brand-logo img {
    height: 48px;
    width: auto;
    border-radius: 8px;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    color: #f9fafb;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.brand-tagline {
    color: rgba(241, 245, 249, 0.7);
    font-size: 0.75rem;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: nowrap;
}

.main-nav a {
    color: #111827;
    font-size: 0.85rem;
    background: #ffb653;
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-weight: 500;
    box-shadow: 0 4px 18px rgba(255, 182, 83, 0.35);
    transition: opacity 0.2s;
    white-space: nowrap;
}

.main-nav a:hover {
    opacity: 0.9;
}

.main-nav a.active {
    opacity: 1;
    box-shadow: 0 4px 18px rgba(255, 182, 83, 0.5);
}

/* Page Navigation Dropdown - Hidden on desktop, visible on mobile */
#page-nav-select {
    display: none;
    border-radius: 999px;
    padding: 0.55rem 1.2rem;
    padding-right: 2.5rem;
    font-size: 0.85rem;
    background-color: #ffb653;
    background-image: url('data:image/svg+xml;utf8,<svg fill="%23111827" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>');
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    background-size: 1.2em;
    color: #111827;
    border: none;
    outline: none;
    cursor: pointer;
    font-weight: 500;
    box-shadow: 0 4px 18px rgba(255, 182, 83, 0.35);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Orange Contact Button */
.nav-cta {
    background: #ffb653;
    color: #111827 !important;
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-weight: 500;
    box-shadow: 0 4px 18px rgba(255, 182, 83, 0.35);
    border: none !important;
    transition: opacity 0.2s;
}

.nav-cta:hover {
    opacity: 0.9;
}

/* Language Dropdown */
#lang-switch {
    border-radius: 999px;
    padding: 0.35rem 0.9rem;
    font-size: 0.8rem;
    background: rgba(255, 255, 255, 0.08);
    color: #f9fafb;
    border: 1px solid rgba(248, 250, 252, 0.3);
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

#lang-switch:focus {
    border-color: #ffb653;
}

#lang-switch:hover {
    background: rgba(255, 255, 255, 0.12);
}

.lang-switcher {
    color: rgba(241, 245, 249, 0.6);
    font-size: 0.85rem;
}

.lang-switcher a {
    color: rgba(241, 245, 249, 0.7);
    padding: 0 0.25rem;
}

.lang-switcher a:hover,
.lang-switcher a.active {
    color: #fff;
}

/* Main Content */
.page {
    max-width: 1120px;
    margin: 0 auto;
    padding: 160px 2rem 4rem;
}

.page.narrow {
    max-width: 800px;
}

/* Typography */
h1 {
    font-size: 2.5rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: 1.75rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

p {
    margin-bottom: 1rem;
}

p:last-child {
    margin-bottom: 0;
}

.lead {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

/* Sections */
section {
    margin-bottom: 4rem;
}

section:last-child {
    margin-bottom: 0;
}

/* Links */
.text-link {
    color: var(--navy);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.text-link:hover {
    text-decoration-thickness: 2px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: 1px solid var(--navy);
    border-radius: 4px;
    color: var(--navy);
    font-size: 0.9rem;
    transition: background-color 0.2s, color 0.2s;
}

.btn:hover {
    background: var(--navy);
    color: #fff;
}

/* Status Badge */
.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(11, 28, 61, 0.05);
    border: 1px solid var(--border-subtle);
    border-radius: 4px;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Project Card */
.project-card {
    padding: 2rem;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    margin-bottom: 2rem;
}

.project-card h3 {
    margin-bottom: 0.5rem;
}

.project-card p {
    color: var(--text-muted);
}

/* Principles List */
.principles-list {
    list-style: none;
}

.principles-list li {
    padding: 2rem 0;
    border-bottom: 1px solid var(--border-subtle);
}

.principles-list li:first-child {
    padding-top: 0;
}

.principles-list li:last-child {
    border-bottom: none;
}

.principles-list h3 {
    margin-bottom: 0.5rem;
}

.principles-list p {
    color: var(--text-muted);
}

/* Contact */
.contact-info {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Legal */
.legal-content h2 {
    margin-top: 2rem;
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

/* Footer */
.site-footer {
    max-width: 1120px;
    margin: 0 auto;
    padding: 3rem 2rem 2rem;
    border-top: 1px solid var(--border-subtle);
    margin-top: 4rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* lœrn project page */
.loern-page {
    --loern-primary: #6366F1;
    --loern-primary-light: #818CF8;
    --loern-primary-dark: #4F46E5;
    --loern-secondary: #10B981;
    --loern-accent: #F59E0B;
    --loern-background: #F9FAFB;
    --loern-surface: #FFFFFF;
    --loern-surface-variant: #F3F4F6;
    --loern-border: #E5E7EB;
    --loern-text: #111827;
    --loern-text-secondary: #6B7280;

    color: var(--loern-text);
}

.loern-hero {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    gap: 2rem;
    align-items: center;
    padding: 2rem;
    border-radius: 14px;
    border: 1px solid var(--loern-border);
    background: linear-gradient(180deg, rgba(99, 102, 241, 0.10) 0%, rgba(249, 250, 251, 1) 70%);
    margin-bottom: 3rem;
}

.loern-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(99, 102, 241, 0.25);
    background: rgba(99, 102, 241, 0.08);
    color: var(--loern-primary-dark);
    font-size: 0.85rem;
    margin-bottom: 0.9rem;
}

.loern-lead {
    font-size: 1.1rem;
    color: var(--loern-text-secondary);
    margin-top: 0.75rem;
    margin-bottom: 1.5rem;
}

.loern-cta {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.loern-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1.05rem;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid var(--loern-border);
    background: var(--loern-surface);
    color: var(--loern-text);
    transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.loern-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(17, 24, 39, 0.10);
}

.loern-btn.primary {
    background: var(--loern-primary);
    border-color: rgba(79, 70, 229, 0.35);
    color: #fff;
}

.loern-btn.primary:hover {
    background: var(--loern-primary-dark);
}

.loern-btn.secondary {
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.30);
    color: #065F46;
}

.loern-btn.secondary:hover {
    background: rgba(16, 185, 129, 0.12);
}

.loern-logo-card {
    border-radius: 16px;
    padding: 1.25rem;
    background: radial-gradient(circle at top left, var(--loern-primary-light) 0%, var(--loern-primary) 55%, var(--loern-primary-dark) 100%);
    border: 1px solid rgba(79, 70, 229, 0.35);
    box-shadow: 0 16px 40px rgba(79, 70, 229, 0.25);
}

.loern-logo-card img {
    width: 100%;
    height: auto;
    display: block;
}

.loern-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.loern-feature {
    display: flex;
    gap: 0.85rem;
    padding: 1.05rem;
    border-radius: 12px;
    border: 1px solid var(--loern-border);
    background: var(--loern-surface);
}

.loern-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    background: rgba(99, 102, 241, 0.10);
    border: 1px solid rgba(99, 102, 241, 0.18);
    color: var(--loern-primary-dark);
    font-size: 1.05rem;
}

.loern-feature h3 {
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.loern-feature p {
    color: var(--loern-text-secondary);
    margin-bottom: 0;
    font-size: 0.92rem;
}

.loern-screenshots {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.loern-shot {
    background: var(--loern-surface);
    border: 1px solid var(--loern-border);
    border-radius: 14px;
    padding: 0.75rem;
    box-shadow: 0 10px 22px rgba(17, 24, 39, 0.06);
}

.loern-shot img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
}

/* Responsive */
@media (max-width: 768px) {
    .site-header {
        padding: 1rem;
    }
    
    .header-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    /* Hide individual page links on mobile */
    .main-nav a {
        display: none !important;
    }
    
    /* Show page navigation dropdown on mobile */
    #page-nav-select {
        display: block !important;
    }
    
    /* Keep language dropdown visible */
    #lang-switch {
        display: block !important;
    }
    
    .main-nav {
        gap: 0.75rem;
        font-size: 0.85rem;
    }
    
    .brand-logo img {
        height: 40px;
    }
    
    .page {
        padding: 100px 1.25rem 3rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .lead {
        font-size: 1.1rem;
    }

    .loern-hero {
        grid-template-columns: 1fr;
        padding: 1.25rem;
    }

    .loern-grid {
        grid-template-columns: 1fr;
    }

    .loern-screenshots {
        grid-template-columns: 1fr;
    }
}
