/* ============================================
   4sell.ai — Design System (Green Accent)
   ============================================ */

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: rgba(18, 18, 30, 0.6);
    --bg-card-hover: rgba(28, 28, 45, 0.8);

    --text-primary: #f0f0f5;
    --text-secondary: #8888a0;
    --text-muted: #55556a;

    --accent-light: #57F357;
    --accent-dark: #14AA14;
    --accent-glow: rgba(87, 243, 87, 0.4);
    --accent-subtle: rgba(87, 243, 87, 0.08);
    --accent-border: rgba(87, 243, 87, 0.2);

    --gradient-main: linear-gradient(135deg, #57F357 0%, #14AA14 100%);
    --gradient-main-hover: linear-gradient(135deg, #6fff6f 0%, #1cc41c 100%);

    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);

    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

    --nav-height: 72px;
    --container-width: 1200px;

    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: 0.2s var(--ease-out-expo);
    --transition-medium: 0.4s var(--ease-out-expo);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

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

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================
   Particles & Cursor Glow
   ============================================ */
#particleCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

#cursorGlow {
    position: fixed;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(87, 243, 87, 0.06) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
    transform: translate(-50%, -50%);
    will-change: transform;
}

/* ============================================
   Navigation
   ============================================ */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    z-index: 1000;
    transition: all var(--transition-medium);
}

#navbar.scrolled {
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    z-index: 1001;
}

.logo-img {
    height: 32px;
    width: auto;
}

/* Nav Links — flex between logo and actions */
.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    flex: 1;
    min-width: 0;
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
    position: relative;
    padding: 4px 0;
    white-space: nowrap;
    flex-shrink: 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--gradient-main);
    border-radius: 1px;
    transition: width var(--transition-medium);
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link:hover::after {
    width: 100%;
}

/* Active state */
.nav-link.active {
    color: var(--text-primary);
}

.nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-shrink: 0;
}

/* Dropdown */
.nav-dropdown {
    position: relative;
    flex-shrink: 0;
}

.nav-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
}

.dropdown-arrow {
    transition: transform var(--transition-medium);
    opacity: 0.5;
}

.nav-dropdown:hover .dropdown-arrow,
.nav-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
    opacity: 1;
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 260px;
    background: rgba(14, 14, 22, 0.95);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(8px);
    transition: all var(--transition-medium);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown.open .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-item {
    display: block;
    padding: 10px 16px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: 8px;
    transition: all var(--transition-fast);
}

.dropdown-item:hover {
    background: var(--accent-subtle);
    color: var(--accent-light);
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--gradient-main);
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-medium);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, transparent 50%);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-sm {
    padding: 10px 20px;
    font-size: 0.85rem;
    border-radius: 10px;
}

.btn-emoji {
    font-size: 1.1em;
    line-height: 1;
}

/* Burger — hidden desktop */
.nav-burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    z-index: 1001;
    padding: 4px;
    flex-shrink: 0;
}

.nav-burger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all var(--transition-medium);
    transform-origin: center;
}

/* Fullscreen menu — hidden desktop */
/* Mobile/Desktop visibility helpers */
.nav-mobile-only {
    display: none;
}

.nav-desktop-only {
    display: inline-flex;
}

/* ============================================
   Main Content
   ============================================ */
.main-content {
    flex: 1;
    position: relative;
    z-index: 2;
    margin-top: var(--nav-height);
}

/* ============================================
   Hero Section — Typewriter
   ============================================ */
.hero {
    min-height: calc(100vh - var(--nav-height));
    min-height: calc(100dvh - var(--nav-height));
    display: flex;
    align-items: center;
    position: relative;
    padding: 40px 0;
}

.hero-container {
    text-align: left;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 20px;
    width: 100%;
    max-width: var(--container-width);
    padding: 10px 0 60px;
    margin: 0 auto;
    height: calc(100vh - var(--nav-height));
    height: calc(100dvh - var(--nav-height));
    box-sizing: border-box;
}

.hero-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.hero-visual {
    flex: 1;
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding-top: 40px;
    padding-bottom: 60px;
}

/* === Cafe Animation === */
.cafe-anim {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    backdrop-filter: blur(12px);
    box-shadow: var(--glass-shadow);
    overflow: hidden;
    position: relative;
}

.cafe-bubble,
.cafe-system,
.cafe-success,
.cafe-bonus {
    opacity: 0;
    transform: translateY(16px);
    max-height: 0;
    overflow: hidden;
    margin: 0;
    flex-shrink: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        max-height 0.5s cubic-bezier(0.16, 1, 0.3, 1),
        margin-bottom 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.cafe-bubble.show,
.cafe-system.show,
.cafe-success.show,
.cafe-bonus.show {
    opacity: 1;
    transform: translateY(0);
    max-height: 200px;
    margin-bottom: 12px;
}

.cafe-bubble {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cafe-cashier {
    flex-direction: row-reverse;
    text-align: right;
}

.cafe-avatar {
    font-size: 1.6rem;
    flex-shrink: 0;
}

.cafe-msg {
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 0.85rem;
    line-height: 1.4;
    max-width: 280px;
}

.cafe-msg-wrap {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cafe-name {
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.cafe-cashier .cafe-name {
    text-align: right;
}

.cafe-customer .cafe-msg {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
}

.cafe-cashier .cafe-msg {
    background: rgba(87, 243, 87, 0.12);
    color: var(--accent-light);
    border-bottom-right-radius: 4px;
}

.cafe-avatar-logo {
    height: 24px;
    width: auto;
    flex-shrink: 0;
}

.cafe-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid var(--glass-border);
    border-top-color: var(--accent-light);
    border-radius: 50%;
    animation: cafe-spin 0.8s linear infinite;
    display: inline-block;
    vertical-align: middle;
    margin-left: 6px;
}

@keyframes cafe-spin {
    to {
        transform: rotate(360deg);
    }
}

.cafe-checkmark {
    display: inline-flex;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--gradient-main);
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #000;
    box-shadow: 0 0 12px var(--accent-glow);
    vertical-align: middle;
    margin-right: 4px;
}

.cafe-bonus-msg {
    background: rgba(87, 243, 87, 0.15) !important;
    border: 1px solid rgba(87, 243, 87, 0.25);
    box-shadow: 0 0 20px rgba(87, 243, 87, 0.12);
}

.cafe-bonus-msg strong {
    color: var(--accent-light);
}

/* Earnings summary */
.cafe-earnings {
    opacity: 0;
    transform: translateY(16px);
    max-height: 0;
    overflow: hidden;
    margin: 0;
    flex-shrink: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        max-height 0.5s cubic-bezier(0.16, 1, 0.3, 1),
        margin-bottom 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0;
}

.cafe-earnings.show {
    opacity: 1;
    transform: translateY(0);
    max-height: 200px;
    padding: 14px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
}

.cafe-earn-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cafe-earn-icon {
    font-size: 1.1rem;
}

.cafe-earn-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
    flex: 1;
}

.cafe-earn-value {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--accent-light);
}

/* Dashboard */
.cafe-dashboard {
    opacity: 0;
    transform: translateY(16px);
    flex-shrink: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    margin-top: 4px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
}

.cafe-dashboard.show {
    opacity: 1;
    transform: translateY(0);
}

.cafe-dash-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.cafe-dash-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.cafe-dash-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 10px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
}

.cafe-dash-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-light);
}

.cafe-dash-label {
    font-size: 0.84rem;
    color: var(--text-muted);
    line-height: 1.2;
}

/* Growth animation */
.cafe-growth {
    opacity: 0;
    transform: translateY(16px);
    flex-shrink: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    margin-top: 12px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
}

.cafe-growth.show {
    opacity: 1;
    transform: translateY(0);
}

.cafe-growth-title {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.cafe-growth-values {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.cafe-growth-from,
.cafe-growth-to {
    font-size: 1.1rem;
    font-weight: 700;
}

.cafe-growth-from {
    color: var(--text-secondary);
}

.cafe-growth-to {
    color: var(--accent-light);
}

.cafe-growth-arrow {
    color: var(--accent-light);
    font-size: 1.2rem;
}

.cafe-growth-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 3px;
    overflow: hidden;
}

.cafe-growth-fill {
    height: 100%;
    width: 0%;
    background: var(--gradient-main);
    border-radius: 3px;
    transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 0 8px var(--accent-glow);
}

.cafe-growth.show .cafe-growth-fill {
    width: 100%;
}

/* Dot navigation */
.cafe-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.cafe-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    padding: 0;
    transition: all 0.3s ease;
}

.cafe-dot:hover {
    background: rgba(255, 255, 255, 0.3);
}

.cafe-dot.active {
    background: var(--accent-light);
    border-color: var(--accent-light);
    box-shadow: 0 0 8px var(--accent-glow);
}

@media (max-width: 768px) {
    .hero-container {
        flex-direction: column;
    }

    .hero-visual {
        display: none;
    }
}

/* Typewriter */
.tw-lines {
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.tw-line {
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.15;
    word-break: normal;
    overflow-wrap: normal;
}

.tw-prefix {
    color: var(--text-primary);
}

.tw-typed {
    background: var(--gradient-main);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tw-cursor {
    display: inline-block;
    color: var(--accent-light);
    font-weight: 300;
    margin-left: 1px;
    opacity: 0;
}

.tw-cursor.active {
    opacity: 1;
    animation: tw-blink 0.7s step-end infinite;
}

.tw-cursor.active::after {
    content: '|';
}

@keyframes tw-blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Hero bottom: CTA — left-aligned under text */
.hero-bottom {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-top: 36px;
}

.btn-hero {
    padding: 18px 40px;
    font-size: 1.1rem;
    border-radius: 14px;
    box-shadow: 0 4px 24px var(--accent-glow);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
}

.btn-hero.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* При поддержке */
.backed-by {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 16px;
}

.nav-backed {
    margin-top: 0;
    gap: 10px;
}

.nav-backed .backed-logo {
    height: 22px;
}

.backed-by-label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.05em;
    white-space: nowrap;
}

.backed-by-logos {
    display: flex;
    align-items: center;
    gap: 20px;
}

.backed-logo {
    height: 28px;
    width: auto;
    opacity: 0.6;
    filter: grayscale(100%) brightness(1.8);
    transition: all var(--transition-fast);
}

.backed-logo:hover {
    opacity: 1;
    filter: grayscale(0%) brightness(1);
}

/* ============================================
   Footer
   ============================================ */
.footer {
    position: relative;
    z-index: 2;
    border-top: 1px solid var(--glass-border);
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 16px;
    line-height: 1.6;
    max-width: 280px;
}

.footer-social {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.social-link:hover {
    background: var(--accent-subtle);
    color: var(--accent-light);
    transform: translateY(-2px);
}

.footer-col h4 {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding: 5px 0;
    transition: color var(--transition-fast);
}

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

.footer-backed {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 24px 0;
    border-top: 1px solid var(--glass-border);
    margin-bottom: 0;
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 24px;
    border-top: 1px solid var(--glass-border);
    gap: 16px;
    flex-wrap: wrap;
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.footer-links a {
    font-size: 0.8rem;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* ============================================
   Tablet (≤1024px)
   ============================================ */
@media (max-width: 1024px) {
    .nav-links {
        gap: 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }
}

/* ============================================
   Mobile (≤768px)
   ============================================ */
@media (max-width: 768px) {
    :root {
        --nav-height: 56px;
    }

    .container {
        padding: 0 16px;
    }

    /* --- Nav bar --- */
    .logo-img {
        height: 24px;
    }

    .nav-container {
        padding: 0 12px;
        gap: 12px;
    }

    /* Nav links — horizontal scroll between logo & burger */
    .nav-links {
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 20px;
        mask-image: linear-gradient(to right, transparent 0, black 8px, black calc(100% - 8px), transparent 100%);
        -webkit-mask-image: linear-gradient(to right, transparent 0, black 8px, black calc(100% - 8px), transparent 100%);
    }

    .nav-links::-webkit-scrollbar {
        display: none;
    }

    .nav-link {
        font-size: 0.8rem;
        padding: 2px 0;
    }

    /* Hide dropdown on mobile nav bar (it's in the burger) */
    .nav-dropdown {
        display: none;
    }

    /* Hide CTA button */
    .nav-actions {
        display: none;
    }

    /* Show burger */
    .nav-burger {
        display: flex;
    }

    .nav-burger.open span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-burger.open span:nth-child(2) {
        opacity: 0;
    }

    .nav-burger.open span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    /* --- Fullscreen burger menu --- */
    .nav-fullscreen {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(10, 10, 15, 0.97);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        z-index: 998;
        overflow-y: auto;
    }

    .nav-fullscreen.open {
        display: flex;
    }

    .nav-fullscreen-inner {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        min-height: 100%;
        padding: 100px 32px 40px;
        gap: 20px;
    }

    .nav-fs-link {
        font-size: 1.5rem;
        font-weight: 700;
        color: var(--text-primary);
        padding: 8px 0;
        transition: color var(--transition-fast);
    }

    .nav-fs-link:hover {
        color: var(--accent-light);
    }

    .nav-fs-group {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        margin-top: 8px;
    }

    .nav-fs-label {
        font-size: 1.5rem;
        font-weight: 700;
        color: var(--text-primary);
        padding: 8px 0 0;
    }

    .nav-fs-sublink {
        font-size: 1rem;
        color: var(--text-secondary);
        padding: 4px 0;
        transition: color var(--transition-fast);
    }

    .nav-fs-sublink:hover {
        color: var(--accent-light);
    }

    .btn-fs-cta {
        margin-top: 24px;
        padding: 16px 36px;
        font-size: 1.1rem;
        border-radius: 14px;
    }

    /* --- Hero — fills the screen --- */
    .hero {
        min-height: calc(100vh - var(--nav-height));
        min-height: calc(100dvh - var(--nav-height));
        padding: 0;
        align-items: stretch;
    }

    .hero-container {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding-top: 10px;
        padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
        height: calc(100vh - var(--nav-height));
        height: calc(100dvh - var(--nav-height));
        width: 98%;
    }

    /* Typewriter — centered, uniform paragraph */
    .tw-lines {
        flex: 1;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0;
    }


    /* Button at bottom */
    .btn-hero {
        justify-content: center;
        padding: 18px 32px;
        font-size: 1.05rem;
        border-radius: 14px;
        flex-shrink: 0;
        align-self: stretch;
    }

    /* Nav visibility */
    .nav-mobile-only {
        display: inline-flex;
    }

    .nav-desktop-only {
        display: none;
    }

    /* Fullscreen menu */
    .nav-fullscreen {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(10, 10, 15, 0.97);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        z-index: 998;
        overflow-y: auto;
    }

    .nav-fullscreen.open {
        display: flex;
    }

    /* Backed-by mobile */
    .backed-by {
        align-self: center;
        flex-direction: column;
        gap: 8px;
        align-items: center;
    }

    .backed-logo {
        height: 22px;
    }

    /* Hero bottom on mobile */
    .hero-bottom {
        flex-shrink: 0;
        align-items: stretch;
        gap: 16px;
    }

    /* --- Footer --- */
    .footer {
        padding: 40px 0 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 28px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .footer-brand p {
        max-width: none;
    }

    .footer-col h4 {
        font-size: 0.8rem;
        margin-bottom: 12px;
    }

    .footer-col a {
        font-size: 0.85rem;
        padding: 6px 0;
        min-height: 36px;
        display: flex;
        align-items: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .footer-links {
        justify-content: center;
    }
}

/* ============================================
   Small phones (≤400px)
   ============================================ */
@media (max-width: 400px) {
    .tw-line {
        font-size: clamp(1.6rem, 9vw, 2.5rem);
    }

    .nav-link {
        font-size: 0.75rem;
    }

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

    .nav-fs-link,
    .nav-fs-label {
        font-size: 1.3rem;
    }
}

/* ============================================
   Scrollbar & Selection
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: rgba(20, 170, 20, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(20, 170, 20, 0.5);
}

::selection {
    background: rgba(87, 243, 87, 0.25);
    color: var(--text-primary);
}