@import url("https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,wght@0,300;0,400;0,500;0,600;1,300&display=swap");

/* =============================================
   DESIGN TOKENS â€” DARK LUXURY THEME
   ============================================= */
:root {
    /* Core Palette */
    --bg: #0a0d14;
    --bg-2: #0f1420;
    --bg-3: #141926;
    --surface: #161c2d;
    --surface-2: #1d2540;
    --surface-3: #222d4a;

    /* Text */
    --text-main: #f0f2f8;
    --text-secondary: #8b95b8;
    --text-muted: #5a6480;

    /* Accent â€” Electric Indigo + Gold */
    --accent: #6366f1;
    --accent-2: #818cf8;
    --accent-glow: rgba(99, 102, 241, 0.25);
    --gold: #f5c842;
    --gold-dim: rgba(245, 200, 66, 0.15);

    /* Borders */
    --border: rgba(99, 102, 241, 0.12);
    --border-2: rgba(99, 102, 241, 0.22);
    --border-solid: #1e2844;

    /* Effects */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.6);
    --shadow-accent: 0 8px 32px rgba(99, 102, 241, 0.3);
    --glow-gold: 0 0 60px rgba(245, 200, 66, 0.08);

    /* Radius */
    --r-sm: 8px;
    --r: 14px;
    --r-lg: 20px;
    --r-xl: 28px;

    /* Nav */
    --nav-h: 68px;

    /* Transitions */
    --t: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --t-slow: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);

    /* Typography */
    --font-display: 'Syne', sans-serif;
    --font-body: 'DM Sans', sans-serif;
}

/* Light theme override */
[data-theme="light"] {
    --bg: #f5f6fa;
    --bg-2: #eef0f8;
    --bg-3: #e8eaf5;
    --surface: #ffffff;
    --surface-2: #f0f2fc;
    --surface-3: #e6e9f7;
    --text-main: #0d1020;
    --text-secondary: #4a5170;
    --text-muted: #8a90a8;
    --border: rgba(99, 102, 241, 0.1);
    --border-2: rgba(99, 102, 241, 0.2);
    --border-solid: #dde0f0;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.12);
    --shadow-accent: 0 8px 32px rgba(99, 102, 241, 0.15);
}

/* =============================================
   RESET & BASE
   ============================================= */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text-main);
    line-height: 1.6;
    font-size: 1rem;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    position: relative;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
}

button {
    font-family: inherit;
}

/* =============================================
   AMBIENT BACKGROUND EFFECTS
   ============================================= */
.grain-overlay {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 200px;
}

.ambient-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, transparent 70%);
    top: -200px;
    right: -100px;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(245, 200, 66, 0.06) 0%, transparent 70%);
    bottom: 200px;
    left: -150px;
}

.orb-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.08) 0%, transparent 70%);
    top: 50%;
    left: 40%;
}

[data-theme="light"] .ambient-orb {
    opacity: 0.4;
}

[data-theme="light"] .grain-overlay {
    opacity: 0;
}

.navbar-inner {
     max-width: 83%;
     margin: 0 auto;
     width: 100%;
     display: flex;
     align-items: center;
     justify-content: space-between;
     padding: 0 2rem;
}
/* =============================================
    NAVBAR
    ============================================= */
.navbar {
    height: var(--nav-h);
    position: sticky;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 2.5rem;
    padding: 12px;
  
    background: rgba(10, 13, 20, 0.7);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border);
    transition: var(--t);
}

/* Reduce extra vertical spacing in hero section */

.navbar.scrolled {
    background: rgba(10, 13, 20, 0.92);
    border-bottom-color: var(--border-2);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}

[data-theme="light"] .navbar {
    background: rgba(245, 246, 250, 0.85);
}

[data-theme="light"] .navbar.scrolled {
    background: rgba(245, 246, 250, 0.97);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-shrink: 0;
    text-decoration: none;
    margin-right: 1.2rem;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.9rem;
    box-shadow: 0 4px 14px var(--accent-glow);
}

.logo-text {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.logo-accent {
    color: var(--accent-2);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    list-style: none;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.75rem;
    border-radius: var(--r-sm);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--t);
    white-space: nowrap;
}

.nav-links a i {
    font-size: 0.8rem;
    opacity: 0.7;
}

.nav-links a:hover {
    color: var(--text-main);
    background: var(--surface-2);
}

.nav-links a.active {
    color: var(--accent-2);
    background: rgba(99, 102, 241, 0.1);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-shrink: 0;
    margin-left: 0;
}

/* Search */
.search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon-nav {
    position: absolute;
    left: 0.85rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    pointer-events: none;
    z-index: 1;
}

.search-bar {
    height: 38px;
    width: 220px;
    padding: 0 1rem 0 2.4rem;
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: 99px;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.85rem;
    outline: none;
    transition: var(--t);
}

.search-bar::placeholder {
    color: var(--text-muted);
}

.search-bar:focus {
    width: 350px;
    border-color: var(--accent);
    background: var(--surface-2);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.nav-history-btn {
    height: 38px;
    padding: 0 1rem;
    background: var(--surface-2);
    border: 1px solid var(--border-solid);
    border-radius: 99px;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: var(--t);
    white-space: nowrap;
}

.nav-history-btn:hover {
    background: var(--surface-3);
    color: var(--text-main);
    border-color: var(--border-2);
}

.theme-toggle {
    width: 38px;
    height: 38px;
    border-radius: 99px;
    background: var(--surface);
    border: 1px solid var(--border-solid);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    transition: var(--t);
    flex-shrink: 0;
}

.theme-toggle:hover {
    background: var(--surface-2);
    color: var(--gold);
    border-color: var(--gold-dim);
}

.hamburger {
    display: none;
    width: 38px;
    height: 38px;
    border-radius: var(--r-sm);
    background: var(--surface);
    border: 1px solid var(--border-solid);
    cursor: pointer;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    flex-shrink: 0;
}

.hamburger span {
    display: block;
    width: 16px;
    height: 1.5px;
    background: var(--text-secondary);
    border-radius: 2px;
    transition: var(--t);
    transform-origin: center;
}

.hamburger.open span:nth-child(1) {
    transform: translateY(5.5px) rotate(45deg);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.hamburger.open span:nth-child(3) {
    transform: translateY(-5.5px) rotate(-45deg);
}


/* =============================================
   MOBILE MENU
   ============================================= */
.menu-active {
    overflow: hidden !important;
    height: 100vh;
}

.mobile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 998;
    backdrop-filter: blur(4px);
}

.mobile-overlay.open {
    display: block;
}

/* Fix mobile search results layout */
.mobile-menu .search-container {
    display: block;
    width: 100%;
}

.mobile-menu {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-2);
    border-top: 1px solid var(--border-solid);
    z-index: 999;
    padding: 1.5rem 1.25rem 2rem;
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.2);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.mobile-menu.open {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
}

.mobile-search-wrap {
    position: relative;
    margin-bottom: 1.5rem;
    flex-shrink: 0;
    width: 100%;
}

.mobile-search-wrap > i {
    position: absolute;
    left: 1.1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent);
    font-size: 0.95rem;
    z-index: 2;
}

.mobile-search-wrap input {
    width: 100%;
    height: 52px;
    padding: 0 1rem 0 3.2rem;
    background: var(--surface);
    border: 1.5px solid var(--border-solid);
    border-radius: 14px;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 1.05rem;
    outline: none;
    transition: var(--t);
    box-shadow: var(--shadow-sm);
}

.mobile-search-wrap input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
}

.mobile-nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mobile-nav-links a {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.9rem 1rem;
    border-radius: 12px;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    transition: var(--t);
    text-decoration: none;
}

.mobile-nav-links a i {
    font-size: 0.9rem;
    width: 20px;
    text-align: center;
}

.mobile-nav-links a:hover,
.mobile-nav-links a.active {
    color: var(--accent);
    background: var(--accent-glow);
}

.mobile-history-btn {
    width: 100%;
    margin-top: 1.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    border: none;
    border-radius: 14px;
    color: white;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    box-shadow: 0 4px 16px var(--accent-glow);
}

/* =============================================
   SEARCH RESULTS
   ============================================= */
.search-results-overlay {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r);
    box-shadow: var(--shadow-lg);
    z-index: 2000;
    max-height: 420px;
    overflow-y: auto;
    display: none;
}

/* Mobile specific search result adjustments */
.mobile-search-results {
    position: relative;
    top: 0;
    margin-top: 0.5rem;
    max-height: none;
    box-shadow: none;
    border: none;
    background: var(--bg-2);
    padding-bottom: 2rem;
}

.search-results-overlay.active {
    display: block;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    color: var(--text-main);
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--t);
    border-bottom: 1px solid var(--border-solid);
    cursor: pointer;
    text-decoration: none;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover,
.search-result-item.selected {
    background: var(--accent-glow);
    color: var(--accent);
}


.search-result-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--accent-glow);
    color: var(--accent);
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1.15rem;
    flex-shrink: 0;
    transition: var(--t);
}

.search-result-icon i {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100%;
    height: 100%;
    margin: 0 !important;
    text-align: center;
}



.search-result-item:hover .search-result-icon,
.search-result-item.selected .search-result-icon {
    background: var(--accent) !important;
    color: white !important;
}


.search-result-icon i {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100%;
    height: 100%;
    margin: 0 !important;
    text-align: center;
}


.search-result-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.search-result-name {
    display: block;
}

.search-result-category {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 400;
}


.hero {
    min-height: calc(95vh - var(--nav-h));
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    padding: 5rem 0 5rem;
    max-width: 83%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

/* Add space to left hero content at large widths */
@media (min-width: 1201px) {
    .hero > :first-child {
        margin-left: 3vw;
        margin-right: 2vw;
        text-align: left;
    }
}

@media (min-width: 1400px) {
    .hero {
        gap: 2rem;
        grid-template-columns: 1fr 1fr;
    }
    .hero > :first-child {
        justify-self: start;
        margin-left: 2rem;
        margin-right: 0;
        max-width: 680px;
    }
    .hero-visual {
        justify-self: start;
        margin-left: 3vw;
        transform: scale(1.25);
        transform-origin: center left;
        padding: 0;
        width: 380px;
    }
    .calc-preview-card {
        width: 100%;
    }
    .pill-1 { right: -28%; }
    .pill-2 { left: -25%; }
    .pill-3 { right: -32%; }
    .hero-title {
        font-size: clamp(3.5rem, 5vw, 5.5rem);
    }
    .hero-subtitle {
        font-size: 1.25rem;
        max-width: 600px;
    }
    .hero-eyebrow {
        font-size: 1rem;
        padding: 0.6rem 1.6rem;
    }
    .btn-primary, .btn-ghost {
        font-size: 1.05rem;
        padding: 1rem 2rem;
    }
    .stat-num {
        font-size: 2.2rem;
    }
    .stat-label {
        font-size: 0.9rem;
    }

    /* Category Cards - Large Screen Enhancements */
    .calc-card {
        border-radius: var(--r-xl);
    }
    .card-inner {
        padding: 3rem 2.4rem;
        gap: 1.5rem;
    }
    .card-icon-wrap {
        width: 64px;
        height: 64px;
        font-size: 1.6rem;
        border-radius: var(--r-lg);
    }
    .card-content h3 {
        font-size: 1.65rem;
        margin-bottom: 0.8rem;
        font-weight: 800;
    }
    .card-content p {
        font-size: 1.15rem;
        line-height: 1.7;
        font-weight: 400;
    }
    .card-arrow {
        width: 48px;
        height: 48px;
        font-size: 1.1rem;
    }
    .card-tag {
        padding: 0.75rem 2.4rem;
        font-size: 0.9rem;
    }

    .categories-section {
        max-width: 1200px;
        margin: 0 auto;
    }
}

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-2);
    background: linear-gradient(90deg, rgba(99,102,241,0.18) 0%, rgba(245,200,66,0.13) 100%);
    border: 1.5px solid rgba(99, 102, 241, 0.22);
    box-shadow: 0 2px 12px 0 rgba(99,102,241,0.07);
    padding: 0.5rem 1.3rem;
    border-radius: 99px;
    margin-bottom: 1.75rem;
    transition: background 0.3s;
}

.eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-2);
    box-shadow: 0 0 8px var(--accent-2);
    animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.6;
        transform: scale(0.8);
    }
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.75rem, 5.5vw, 4.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.04em;
    color: var(--text-main);
    margin-bottom: 1.5rem;
}

.hero-title-accent {
    background: linear-gradient(135deg, var(--accent-2) 0%, var(--gold) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.75;
    max-width: 480px;
    margin-bottom: 2.5rem;
    font-weight: 300;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 1.75rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: white;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 99px;
    border: none;
    cursor: pointer;
    transition: var(--t);
    box-shadow: 0 6px 20px var(--accent-glow);
    text-decoration: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px var(--accent-glow);
    color: white;
}

.btn-primary:active {
    transform: translateY(2px) scale(0.98);
    filter: brightness(0.95);
    box-shadow: 0 6px 15px var(--accent-glow);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 1.75rem;
    background: transparent;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: 99px;
    border: 1px solid var(--border-solid);
    cursor: pointer;
    transition: var(--t);
    text-decoration: none;
}

.btn-ghost:hover {
    color: var(--text-main);
    background: var(--surface);
    border-color: var(--border-2);
    transform: translateY(-2px);
}

.btn-ghost:active {
    transform: translateY(2px) scale(0.98);
    background: var(--surface-2);
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.hero-stat {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.stat-num {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1;
}

.stat-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.hero-stat-divider {
    width: 1px;
    height: 36px;
    background: var(--border-solid);
}

/* Hero Visual */
.hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.calc-preview-card {
    width: 320px;
    background: var(--surface);
    border: 1px solid var(--border-2);
    border-radius: var(--r-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg), 0 0 80px rgba(99, 102, 241, 0.1);
    position: relative;
    z-index: 2;
}

[data-theme="light"] .calc-preview-card {
    box-shadow: var(--shadow-lg);
}

.preview-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: var(--surface-2);
    border-bottom: 1px solid var(--border);
}

.preview-dots {
    display: flex;
    gap: 5px;
}

.preview-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.preview-dots span:nth-child(1) {
    background: #ff5f57;
}

.preview-dots span:nth-child(2) {
    background: #febc2e;
}

.preview-dots span:nth-child(3) {
    background: #28c840;
}

.preview-title {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-left: 0.25rem;
}

.preview-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.preview-field label {
    display: block;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.4rem;
}

.preview-input {
    background: var(--bg-3);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-sm);
    padding: 0.6rem 0.85rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-main);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-input span {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: var(--surface-2);
    padding: 2px 8px;
    border-radius: 4px;
}

.preview-result {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(129, 140, 248, 0.06));
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--r);
    padding: 1.25rem;
    text-align: center;
    margin-top: 0.5rem;
}

.preview-result-label {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-2);
    margin-bottom: 0.4rem;
}

.preview-result-value {
    font-family: var(--font-display);
    font-size: 2.75rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.preview-result-badge {
    display: inline-block;
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 12px;
    border-radius: 99px;
    border: 1px solid rgba(74, 222, 128, 0.2);
}

/* Floating pills */
.floating-pill {
    position: absolute;
    background: var(--surface);
    border: 1px solid var(--border-2);
    border-radius: 99px;
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow);
    backdrop-filter: blur(8px);
    z-index: 3;
    animation: float-pill 4s ease-in-out infinite;
}

.floating-pill i {
    color: var(--accent-2);
    font-size: 0.8rem;
}

.pill-1 {
    top: 15%;
    right: -10%;
    animation-delay: 0s;
}

.pill-2 {
    bottom: 22%;
    left: -8%;
    animation-delay: 1.3s;
}

.pill-3 {
    top: 55%;
    right: -15%;
    animation-delay: 0.7s;
}

@keyframes float-pill {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}



/* =============================================
   SEARCH NO RESULTS OVERHAUL
   ============================================= */
.search-no-results {
    padding: 1.5rem 1rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    background: linear-gradient(180deg, var(--surface), var(--bg-2));
    border-radius: 20px;
    margin: 0.5rem;
    position: relative;
    overflow: hidden;
    animation: scaleFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.search-no-results::before {
    content: "";
    position: absolute;
    top: -50px;
    right: -50px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    z-index: 0;
    pointer-events: none;
}

.snr-image-wrap {
    width: 90px;
    height: 90px;
    position: relative;
    z-index: 1;
    padding: 8px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    border-radius: 50%;
    box-shadow: 0 10px 30px var(--accent-glow);
    animation: snr-heartbeat 2s ease-in-out infinite;
}

.snr-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    background: var(--surface);
    border: 4px solid var(--surface);
}

@keyframes snr-heartbeat {
    0% { transform: scale(1); box-shadow: 0 10px 30px var(--accent-glow); }
    14% { transform: scale(1.05); box-shadow: 0 15px 40px var(--accent-glow); }
    28% { transform: scale(1); box-shadow: 0 10px 30px var(--accent-glow); }
    42% { transform: scale(1.05); box-shadow: 0 15px 40px var(--accent-glow); }
    70% { transform: scale(1); box-shadow: 0 10px 30px var(--accent-glow); }
}

.snr-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
    letter-spacing: -0.01em;
    z-index: 1;
}

.snr-sub {
    font-size: 0.9rem;
    color: var(--text-secondary);
    max-width: 300px;
    line-height: 1.6;
    margin: 0;
    z-index: 1;
}

.snr-sub strong {
    color: var(--accent);
    font-weight: 700;
}

.snr-tips {
    margin-top: 0.5rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
    padding: 1.25rem 1rem;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid var(--border-solid);
    z-index: 1;
    width: 100%;
}

[data-theme="light"] .snr-tips {
    background: rgba(0, 0, 0, 0.02);
}

.snr-tips span {
    width: 100%;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.snr-tips span::before,
.snr-tips span::after {
    content: "";
    height: 1px;
    background: var(--border-solid);
    flex: 1;
}

.snr-tips code {
    background: var(--surface);
    color: var(--text-main);
    padding: 0.5rem 1.1rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--border-solid);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    font-family: var(--font-body);
}

.snr-tips code:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 20px var(--accent-glow);
}



/* =============================================
   CATEGORIES SECTION
   ============================================= */
.categories-section {
    padding: 3rem 0;
    max-width: 90%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-2);
    margin-bottom: 0.85rem;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(1.75rem, 3.5vw, 2.75rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
    color: var(--text-main);
    margin-bottom: 1rem;
}

.section-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
    font-weight: 300;
}

/* Calc Cards Grid */
.calc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.calc-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-lg);
    padding: 0;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: var(--t-slow);
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.calc-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-2);
    box-shadow: var(--shadow-lg);
}

.card-glow {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    border-radius: var(--r-lg);
}

.calc-card[data-color="rose"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(244, 63, 94, 0.08) 0%, transparent 60%);
}

.calc-card[data-color="gold"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(245, 200, 66, 0.08) 0%, transparent 60%);
}

.calc-card[data-color="blue"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(59, 130, 246, 0.08) 0%, transparent 60%);
}

.calc-card[data-color="teal"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(20, 184, 166, 0.08) 0%, transparent 60%);
}

.calc-card[data-color="violet"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(139, 92, 246, 0.08) 0%, transparent 60%);
}

.calc-card[data-color="amber"] .card-glow {
    background: radial-gradient(ellipse at top left, rgba(251, 146, 60, 0.08) 0%, transparent 60%);
}

.calc-card:hover .card-glow {
    opacity: 1;
}

.card-inner {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    padding: 1.4rem;
    flex: 1;
}

.card-icon-wrap {
    width: 42px;
    height: 42px;
    border-radius: var(--r);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: var(--t);
    flex-shrink: 0;
}

.calc-card[data-color="rose"] .card-icon-wrap {
    background: rgba(244, 63, 94, 0.1);
    color: #f43f5e;
    border: 1px solid rgba(244, 63, 94, 0.2);
}

.calc-card[data-color="gold"] .card-icon-wrap {
    background: rgba(245, 200, 66, 0.1);
    color: #f5c842;
    border: 1px solid rgba(245, 200, 66, 0.2);
}

.calc-card[data-color="blue"] .card-icon-wrap {
    background: rgba(59, 130, 246, 0.1);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.calc-card[data-color="teal"] .card-icon-wrap {
    background: rgba(20, 184, 166, 0.1);
    color: #2dd4bf;
    border: 1px solid rgba(20, 184, 166, 0.2);
}

.calc-card[data-color="violet"] .card-icon-wrap {
    background: rgba(139, 92, 246, 0.1);
    color: #a78bfa;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.calc-card[data-color="amber"] .card-icon-wrap {
    background: rgba(251, 146, 60, 0.1);
    color: #fb923c;
    border: 1px solid rgba(251, 146, 60, 0.2);
}

.calc-card:hover .card-icon-wrap {
    transform: scale(1.08);
}

.card-content {
    flex: 1;
}

.card-content h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.4rem;
    letter-spacing: -0.02em;
}

.card-content p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
    font-weight: 300;
}

.card-arrow {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    transition: var(--t);
    align-self: flex-end;
    border: 1px solid var(--border-solid);
}

.calc-card:hover .card-arrow {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateX(3px);
    box-shadow: 0 4px 12px var(--accent-glow);
}

.card-tag {
    padding: 0.4rem 1.4rem;
    border-top: 1px solid var(--border);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: var(--bg-3);
}

/* =============================================
   FEATURES STRIP
   ============================================= */
.features-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 2.5rem 3rem;
    background: var(--surface);
    border-top: 1px solid var(--border-solid);
    border-bottom: 1px solid var(--border-solid);
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem 3rem;
    flex: 1;
    min-width: 200px;
    justify-content: center;
}

.feature-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--r-sm);
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    color: var(--accent-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.feature-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.feature-text strong {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
}

.feature-text span {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 300;
}

.feature-divider {
    width: 1px;
    height: 48px;
    background: var(--border-solid);
    flex-shrink: 0;
}

/* =============================================
   ABOUT SECTION
   ============================================= */
.about-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: start;
    padding: 7rem 3rem;
    max-width: 83%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.about-content .section-label {
    margin-bottom: 0.75rem;
}

.about-content .section-title {
    text-align: left;
    margin-bottom: 1.5rem;
    font-size: clamp(1.6rem, 3vw, 2.25rem);
}

.about-content p {
    font-size: 0.975rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1.25rem;
    font-weight: 300;
}

.about-content .btn-primary {
    margin-top: 1rem;
}

.about-cards {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.about-stat-card {
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-lg);
    padding: 1.5rem;
    transition: var(--t);
    position: relative;
    overflow: hidden;
}

.about-stat-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, transparent, var(--accent), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.about-stat-card:hover::before {
    opacity: 1;
}

.about-stat-card:hover {
    border-color: var(--border-2);
    box-shadow: var(--shadow);
    transform: translateX(4px);
}

.about-stat-card.highlight {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(99, 102, 241, 0.02));
    border-color: rgba(99, 102, 241, 0.2);
}

.ast-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--r-sm);
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    margin-bottom: 0.85rem;
    border: 1px solid rgba(99, 102, 241, 0.18);
}

.about-stat-card h4 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.4rem;
    letter-spacing: -0.01em;
}

.about-stat-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.65;
    font-weight: 300;
}

/* =============================================
   FAQ SECTION
   ============================================= */
.faq-section-wrap {
    padding: 5rem 3rem 7rem;
    max-width: 860px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.faq-section-wrap .section-header {
    margin-bottom: 2.5rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.faq-item {
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r);
    overflow: hidden;
    transition: var(--t);
}

.faq-item:hover {
    border-color: var(--border-2);
}

.faq-item.active {
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.08);
}

.faq-question {
    width: 100%;
    padding: 1.1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.975rem;
    font-weight: 500;
    color: var(--text-main);
    transition: var(--t);
}

.faq-question:hover {
    color: var(--accent-2);
}

.faq-chevron {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.75rem;
    flex-shrink: 0;
    transition: var(--t);
}

.faq-item.active .faq-chevron {
    background: var(--accent);
    color: white;
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.3s ease, opacity 0.3s ease;
    opacity: 0;
}

.faq-item.active .faq-answer {
    max-height: 300px;
    opacity: 1;
    padding-bottom: 1.25rem;
}

.faq-answer p {
    padding: 0 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.75;
    font-weight: 300;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    background: var(--surface);
    border-top: 1px solid var(--border-solid);
    position: relative;
    z-index: 1;
}

.footer-inner {
    max-width: 83%;
    margin: 0 auto;
    padding: 3.5rem 3rem 2.5rem;
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    align-items: start;
}

.footer-brand .nav-logo {
    margin-bottom: 0.85rem;
}

.footer-brand p {
    font-size: 0.875rem;
    color: var(--text-muted);
    max-width: 280px;
    line-height: 1.65;
    font-weight: 300;
}

.footer-links {
    display: flex;
    gap: 3rem;
}



.footer-col {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-col h5 {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    position: relative;
    padding-left: 1.25rem;
    line-height: 1.2;
}

.footer-col h5::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, var(--accent), var(--accent-2));
    border-radius: 4px;
}

.footer-col a {
    font-size: 0.92rem;
    color: var(--text-muted);
    transition: var(--t);
    font-weight: 400;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.footer-col a::before {
    content: "";
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0.25;
    transition: var(--t);
    flex-shrink: 0;
    box-shadow: 0 0 0 2px transparent;
}

.footer-col a:hover {
    color: var(--accent);
    padding-left: 0.5rem;
}

.footer-col a:hover::before {
    opacity: 1;
    transform: scale(1.2);
    background: var(--accent-2);
    box-shadow: 0 0 10px var(--accent-glow);
}


.footer-col a:hover::before {
    opacity: 1;
    transform: scale(1.4);
    background: var(--accent-2);
}


.footer-bottom {
    border-top: 1px solid var(--border-solid);
    padding: 1.5rem 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 83%;
    margin: 0 auto;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 300;
    gap: 1rem;
    flex-wrap: wrap;
}

/* =============================================
   SCROLL TOP
   ============================================= */
.scroll-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    box-shadow: 0 6px 20px var(--accent-glow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(16px);
    transition: var(--t);
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px var(--accent-glow);
}

/* =============================================
   LEGACY CLASSES â€” preserved for sub-pages
   ============================================= */
.container {
    width: 90%;
    max-width: 83%;
    margin: 0 auto;
    padding: 2.5rem 0;
    position: relative;
    z-index: 1;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-lg);
    max-width: 1050px;
    width: 100%;
    margin: 0 auto 2rem auto;
    padding: 1.75rem 2.25rem;
    box-shadow: var(--shadow-sm);
}

.card-title {
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3.5vw, 1.9rem);
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.card-desc {
    color: var(--text-secondary);
    font-size: 0.975rem;
    line-height: 1.7;
}

.category-title {
    display: flex;
    align-items: center;
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 1.25rem;
    margin-top: 2rem;
    gap: 0.65rem;
    background: var(--surface);
    border-left: 4px solid var(--accent);
    border-radius: 0 var(--r-sm) var(--r-sm) 0;
    padding: 0.5rem 1rem;
    box-shadow: var(--shadow-sm);
}

.form-group {
    margin-bottom: 1.4rem;
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}

.input-field {
    width: 100%;
    padding: 0.825rem 1rem;
    background: var(--bg-3);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-sm);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.975rem;
    outline: none;
    transition: var(--t);
    -webkit-appearance: none;
}

.input-field::placeholder {
    color: var(--text-muted);
}

.input-field:focus {
    border-color: var(--accent);
    background: var(--bg-2);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.select-field {
    width: 100%;
    padding: 0.825rem 1rem;
    background: var(--bg-3);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-sm);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.975rem;
    outline: none;
    transition: var(--t);
    -webkit-appearance: none;
    cursor: pointer;
}

.btn {
    width: 100%;
    padding: 0.9rem 1.5rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: white;
    border: none;
    border-radius: var(--r);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.975rem;
    cursor: pointer;
    transition: var(--t);
    box-shadow: 0 6px 20px var(--accent-glow);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px var(--accent-glow);
}

.result-box {
    display: none;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(99, 102, 241, 0.02));
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--r-lg);
    padding: 2rem;
    margin-top: 1.75rem;
}

.result-box.active {
    display: block;
    animation: scaleFadeIn 0.45s cubic-bezier(0.21, 1.11, 0.32, 1.05);
}

.result-title {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-2);
    margin-bottom: 0.4rem;
}

.result-value {
    font-family: var(--font-display);
    font-size: clamp(2.25rem, 7vw, 3.25rem);
    font-weight: 800;
    background: linear-gradient(135deg, var(--text-main), var(--accent-2));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.1;
}

.content-section {
    margin-top: 3rem;
}

.content-section h2 {
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3.5vw, 1.9rem);
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 1.1rem;
    letter-spacing: -0.02em;
    padding-bottom: 0.5rem;
    position: relative;
}

.content-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
    border-radius: 2px;
}

.content-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
    margin: 1.75rem 0 0.6rem;
}

.content-section p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.8;
    margin-bottom: 1rem;
    font-weight: 300;
}

.content-section ul {
    margin-left: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.content-section li {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    font-weight: 300;
}

.formula-box {
    background: var(--bg-2);
    border-left: 3px solid var(--accent);
    padding: 1.1rem 1.4rem;
    margin: 1.4rem 0;
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    font-size: 0.9rem;
    border-radius: 0 var(--r) var(--r) 0;
    color: var(--text-main);
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-all;
}

.faq-section {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-legacy {
    background: var(--surface);
    border-top: 1px solid var(--border-solid);
    padding: 2rem;
    margin-top: 4rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    position: relative;
    z-index: 1;
}

/* Action bar */
.result-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.6rem;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-solid);
    flex-wrap: wrap;
}

.action-btn {
    background: var(--surface-2);
    border: 1px solid var(--border-solid);
    color: var(--accent-2);
    height: 38px;
    padding: 0 1rem;
    border-radius: 99px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--t);
    font-family: var(--font-body);
}

.action-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: scale(1.04);
    box-shadow: 0 4px 14px var(--accent-glow);
}

/* Manager sidebar */
.calc-manager-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.calc-manager-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.calc-manager-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background: var(--bg-2);
    border-left: 1px solid var(--border-solid);
    z-index: 10001;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

.calc-manager-sidebar.open {
    right: 0;
}

.manager-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 1.5rem 1rem;
}

.manager-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--t);
    border-radius: 6px;
}

.manager-close:hover {
    color: var(--text-main);
    background: var(--surface-3);
}

.manager-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.manager-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-solid);
}

.manager-tab {
    flex: 1;
    padding: 0.9rem 0;
    text-align: center;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    transition: var(--t);
    font-family: var(--font-body);
}

.manager-tab.active {
    color: var(--accent-2);
    border-bottom-color: var(--accent);
}

.manager-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    background: var(--bg);
}

.manager-panel {
    display: none;
    flex-direction: column;
    gap: 0.75rem;
}

.manager-panel.active {
    display: flex;
}

.saved-item {
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r);
    padding: 1.1rem;
    transition: var(--t);
}

.saved-item:hover {
    border-color: var(--border-2);
    box-shadow: var(--shadow-sm);
}

.saved-item-title {
    font-weight: 600;
    color: var(--text-main);
    font-size: 0.95rem;
}

.saved-item-date {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.saved-item-expr {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin-bottom: 0.6rem;
    background: var(--bg-2);
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    word-break: break-word;
    font-weight: 300;
}

.saved-item-result {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-2);
    margin-bottom: 0.75rem;
}

.saved-item-actions {
    display: flex;
    gap: 0.4rem;
    justify-content: flex-end;
    border-top: 1px solid var(--border-solid);
    padding-top: 0.6rem;
}

.item-btn {
    background: none;
    border: none;
    font-size: 0.85rem;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.35rem;
    border-radius: 4px;
    transition: var(--t);
}

.item-btn:hover {
    color: var(--accent-2);
    background: var(--surface-2);
}

.item-btn.delete {
    color: #f87171;
}

.item-btn.delete:hover {
    background: rgba(248, 113, 113, 0.1);
}

.manager-empty {
    text-align: center;
    color: var(--text-muted);
    padding: 3rem 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.85rem;
}

.manager-empty i {
    font-size: 2.5rem;
    color: var(--border-solid);
}

.clear-history-btn {
    width: 100%;
    padding: 0.7rem;
    background: none;
    border: 1px dashed var(--border-solid);
    color: var(--text-muted);
    border-radius: var(--r-sm);
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.875rem;
    transition: var(--t);
    margin-top: 0.85rem;
}

.clear-history-btn:hover {
    border-color: #f87171;
    color: #f87171;
    background: rgba(248, 113, 113, 0.06);
}

.nav-manager-btn {
    height: 38px;
    padding: 0 1rem;
    background: var(--surface-2);
    border: 1px solid var(--border-solid);
    border-radius: 99px;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: var(--t);
    flex-shrink: 0;
}

.nav-manager-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

/* Segmented control */
.box-segmented {
    background: var(--bg-3);
    padding: 0.3rem;
    border-radius: var(--r);
    display: flex;
    width: 100%;
    border: 1px solid var(--border-solid);
    overflow: hidden;
}

.box-segmented input[type="radio"] {
    display: none;
}

.box-segmented input[type="radio"]:checked+span {
    background: var(--surface);
    color: var(--accent-2);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

.box-segmented span {
    padding: 0.5rem 1rem;
    display: block;
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--text-muted);
    transition: var(--t);
    cursor: pointer;
    flex: 1;
    text-align: center;
}

/* Input suffix */
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-suffix {
    position: absolute;
    right: 0.7rem;
    color: var(--text-muted);
    font-weight: 500;
    pointer-events: none;
    background: var(--surface-2);
    padding: 0.12rem 0.45rem;
    border-radius: 4px;
    font-size: 0.8rem;
    border-left: 1px solid var(--border-solid);
    white-space: nowrap;
}

.input-with-suffix {
    padding-right: 4.5rem;
}

/* Radio inline */
.radio-inline label {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: var(--t);
}

.radio-inline label:hover {
    color: var(--text-main);
}

.radio-inline input[type="radio"] {
    accent-color: var(--accent);
    width: 1rem;
    height: 1rem;
}

/* Breadcrumb */
.breadcrumb a {
    color: var(--accent-2);
}

/* Gauge */
.gauge-container {
    width: 100%;
    max-width: 450px;
    margin: 1.25rem auto 0.5rem;
    text-align: center;
}

.gauge-svg {
    width: 100%;
    height: auto;
    overflow: visible;
}

/* Scroll indicator */
#cursor-orb {
    display: none;
}

/* Animations */
@keyframes fadeSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleFadeIn {
    from {
        opacity: 0;
        transform: scale(0.96);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Selection */
::selection {
    background: var(--accent);
    color: white;
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* =============================================
   RESPONSIVE
   ============================================= */

@media (max-width: 1355px) and (min-width: 1201px) {
    .search-bar {
        width: 38px;
        padding: 0;
        cursor: pointer;
        background: var(--surface-2);
        color: transparent;
    }
    .search-bar::placeholder {
        color: transparent;
    }
    .search-container .search-icon-nav {
        left: 50%;
        transform: translateX(-50%);
        color: var(--text-secondary);
        transition: var(--t);
    }
    .search-container:focus-within .search-bar {
        width: 220px;
        padding: 0 1rem 0 2.4rem;
        cursor: text;
        color: var(--text-main);
        background: var(--surface-2);
    }
    .search-container:focus-within .search-bar::placeholder {
        color: var(--text-muted);
    }
    .search-container:focus-within .search-icon-nav {
        left: 0.85rem;
        transform: none;
        color: var(--text-muted);
    }
}

/* Hide nav links, show hamburger at 1200px */
@media (max-width: 1200px) {
    .nav-links {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .navbar {
        justify-content: space-between;
        padding: 0;
    }

    .navbar-inner {
        max-width: 100%;
        padding: 0 1.5rem;
    }

    .nav-right {
        margin-left: 0;
    }

    /* Make hero section stack vertically earlier to avoid merging */
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 4rem 2rem;
        gap: 3rem;
        min-height: auto;
    }
    .hero-visual {
        margin: 0 auto;
    }
    .hero-title, .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-actions, .hero-stats {
        justify-content: center;
    }
    .hero-stats {
        flex-wrap: wrap;
        gap: 1.5rem;
    }
    .hero-actions {
        flex-wrap: wrap;
        gap: 1rem;
    }
}

@media (max-width: 1024px) {
    /* .hero responsiveness now handled at 1200px */

    .hero-visual {
        display: none;
    }

    .about-section {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding: 5rem 2rem;
    }

    .about-content .section-title {
        text-align: center;
    }

    .about-content .section-label {
        text-align: center;
        display: block;
    }

    .about-content p {
        text-align: center;
    }

    .about-content .btn-primary {
        margin: 1rem auto 0;
        display: inline-flex;
    }
}

@media (max-width: 900px) {
    .calc-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .features-strip {
        flex-direction: column;
        gap: 0;
        padding: 2rem 1.5rem;
    }

    .feature-divider {
        width: 100%;
        height: 1px;
    }

    .feature-item {
        width: 100%;
        padding: 1rem 0;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .categories-section {
        padding: 3rem 0.2rem;
    }

    .search-container {
        display: none;
    }

    .nav-history-btn {
        display: none;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 0;
        gap: 0.75rem;
    }
    .navbar-inner {
        padding: 0 1rem;
    }

    .nav-logo {
        margin-right: auto;
    }

    .theme-toggle {
        display: flex;
    }

    .logo-text {
        font-size: 1.1rem;
    }

    .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
}

@media (max-width: 640px) {
    .calc-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .card-inner {
        padding: 1.1rem;
        gap: 0.7rem;
    }

    .card-icon-wrap {
        width: 36px;
        height: 36px;
        font-size: 0.95rem;
    }

    .card-content h3 {
        font-size: 1.05rem;
        margin-bottom: 0.25rem;
    }

    .card-content p {
        font-size: 0.82rem;
        line-height: 1.5;
    }

    .card-tag {
        padding: 0.35rem 1.1rem;
        font-size: 0.68rem;
    }

    .hero {
        padding: 3rem 1.25rem;
    }

    .hero-title {
        font-size: clamp(1.8rem, 8vw, 2.5rem);
        line-height: 1.1;
    }

    .hero-stats {
        flex-wrap: wrap;
        gap: 1.25rem;
        justify-content: center;
    }

    .faq-section-wrap {
        padding: 3rem 1.25rem 4rem;
    }

    .footer-inner {
        padding: 2.5rem 1.25rem 2rem;
    }

    .footer-bottom {
        padding: 1.25rem;
        flex-direction: column;
        text-align: center;
    }

    .footer-links {
        flex-direction: column;
        gap: 1.75rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn-primary,
    .btn-ghost {
        width: 100%;
        justify-content: center;
    }

    .nav-history-btn {
        display: none !important;
    }

    .scroll-top {
        bottom: 1.25rem;
        right: 1.25rem;
    }
}

@media (max-width: 380px) {
    .hero-title {
        font-size: clamp(1.75rem, 8vw, 2rem);
    }

    .hero-eyebrow {
        font-size: 0.7rem;
    }

    .logo-text {
        font-size: 1.05rem;
    }

    .logo-icon {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
}

/* Ultra-wide */
@media (min-width: 2350px) {
    .navbar {
        height: 82px;
        padding: 0 5rem;
    }

    .nav-logo {
        font-size: 1.5rem;
    }

    .nav-links a {
        font-size: 1rem;
    }

    .hero {
        padding: 6rem 5rem;
        max-width: 2000px;
    }

    .categories-section {
        max-width: 1400px;
        padding: 7rem 5rem;
    }

    .about-section {
        max-width: 2000px;
        padding: 8rem 5rem;
    }

    .faq-section-wrap {
        max-width: 1100px;
    }

    .container {
        padding: 3rem;
    }
}
/* =============================================
   FOOTER
   ============================================= */
.footer {
    background: var(--surface);
    border-top: 1px solid var(--border-solid);
    position: relative;
    z-index: 1;
    margin-top: 4rem;
}

.footer-inner {
    max-width: 95%;
    margin: 0 auto;
    padding: 4rem 3rem 3rem;
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 4rem;
    align-items: start;
}

.footer-brand .nav-logo {
    margin-bottom: 0.85rem;
}

.footer-brand p {
    font-size: 0.875rem;
    color: var(--text-muted);
    max-width: 280px;
    line-height: 1.65;
    font-weight: 300;
}

.footer-links {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}



.footer-col {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-col h5 {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    position: relative;
    padding-left: 1.25rem;
    line-height: 1.2;
}

.footer-col h5::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, var(--accent), var(--accent-2));
    border-radius: 4px;
}

.footer-col a {
    font-size: 0.92rem;
    color: var(--text-muted);
    transition: var(--t);
    font-weight: 400;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.footer-col a::before {
    content: "";
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0.25;
    transition: var(--t);
    flex-shrink: 0;
    box-shadow: 0 0 0 2px transparent;
}

.footer-col a:hover {
    color: var(--accent);
    padding-left: 0.5rem;
}

.footer-col a:hover::before {
    opacity: 1;
    transform: scale(1.2);
    background: var(--accent-2);
    box-shadow: 0 0 10px var(--accent-glow);
}


.footer-col a:hover::before {
    opacity: 1;
    transform: scale(1.4);
    background: var(--accent-2);
}


.footer-bottom {
    border-top: 1px solid var(--border-solid);
    padding: 1.5rem 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 95%;
    margin: 0 auto;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 300;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (max-width: 1350px) {
    .footer-inner {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding: 4rem 2rem;
    }

    .footer-brand {
        max-width: 100%;
        text-align: left;
    }

    .footer-brand p {
        max-width: 450px;
    }

    .footer-links {
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 1000px) {
    .footer-links {
        grid-template-columns: repeat(4, 1fr);
    }
    .footer-col:nth-child(5) {
        display: none;
    }
}

@media (max-width: 780px) {
    .footer-links {
        grid-template-columns: repeat(3, 1fr);
    }
    .footer-col:nth-child(4) {
        display: none;
    }
}

@media (max-width: 600px) {
    .footer-inner {
        padding: 3rem 1.5rem;
    }

    .footer-links {
        grid-template-columns: repeat(2, 1fr);
        gap: 3.5rem 2rem;
    }

    /* Restore visibility of items hidden in larger breakpoints */
    .footer-col:nth-child(4),
    .footer-col:nth-child(5) {
        display: flex;
    }

    /* Last item spans 1 column in a 2-column grid, creating the 2x2x1 look */
    .footer-col:nth-child(5) {
        grid-column: span 1;
    }

    .footer-bottom {
        padding: 1.5rem;
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
}

@media (max-width: 362px) {
    .footer-links {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
}





/* Fix for ultra-small screens to ensure search bar is visible */
@media (max-width: 360px) {
    .mobile-menu {
        padding-top: 1rem;
    }
    .mobile-search-wrap {
        margin-bottom: 1rem;
    }
    .mobile-search-wrap input {
        height: 46px;
        font-size: 0.95rem;
    }
}

/* =============================================
   ULTRA-MOBILE OPTIMIZATION (STUNNING AESTHETICS)
   ============================================= */
@media (max-width: 546px) {
    /* HERO TITLE - Maximum Impact */
    h1, .hero-title, .card-title, .hero-title span { font-size: 2.1rem !important; letter-spacing: -0.03em !important; line-height: 1.1 !important; }
    .hero-subtitle { font-size: 1.05rem !important; line-height: 1.6 !important; opacity: 1; }
    .hero-eyebrow { font-size: 0.9rem !important; font-weight: 700 !important; }

    /* Other Typography (Balanced) */
    h2, .section-title, .category-title { font-size: 1.4rem !important; letter-spacing: -0.01em !important; }
    h3 { font-size: 1.2rem !important; }
    h4 { font-size: 1.05rem !important; }
    p, .footer-brand p, .calc-card p, .card-desc { font-size: 0.9rem !important; line-height: 1.6 !important; opacity: 1; }
    a, .nav-links a, .footer-col a, label, .input-label, .form-label, span, .breadcrumb { font-size: 0.85rem !important; }

    /* Spacing & Layout Optimization */
    .container, .navbar-inner, .hero, .footer-inner, .faq-section-wrap, .tool-container, .card {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
        max-width: 100% !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .hero { padding-top: 2rem !important; padding-bottom: 2rem !important; min-height: auto !important; }
    .calc-grid, .grid, .calc-form { gap: 1rem !important; }
    .form-group { gap: 0.4rem !important; }
    
    /* Card & Component Refinement */
    .calc-card, .card, .tool-container, .result-box, .result-main, .result-item {
        padding: 1rem !important;
        border-radius: 14px !important;
        margin-bottom: 0.85rem !important;
    }
    
    .card-header { margin-bottom: 1.25rem !important; }
    .result-box { margin-top: 1.5rem !important; padding-top: 1.5rem !important; }

    /* Form Elements */
    .input-field, .search-bar, select {
        height: 44px !important;
        font-size: 0.95rem !important;
        padding: 0 0.85rem !important;
        border-radius: 10px !important;
    }

    .btn-primary, .btn-ghost, .btn-calculate, .btn-premium {
        height: 46px !important;
        padding: 0 1.25rem !important;
        font-size: 0.95rem !important;
        border-radius: 10px !important;
        width: 100% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin-top: 0.4rem !important;
    }

    /* Icon & Visual Scaling */
    .category-icon, .card-icon-wrap, .logo-icon, .divider-icon-box, .feature-icon-wrap, .step-num {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        font-size: 1rem !important;
    }
    
    .logo-text { font-size: 1.1rem !important; }
    
    /* Result Specifics */
    .result-value { font-size: 2.2rem !important; }
    .result-label, .res-label { font-size: 0.75rem !important; }
}

