/* style.css */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    /* Color Palette */
    --c-deep-black: #0B0A08;
    --c-warm-black: #12100D;
    --c-champagne: #C9A86A;
    --c-soft-gold: #E0C58A;
    --c-antique-gold: #9E7A43;
    --c-ivory: #F5F0E7;
    --c-warm-white: #FAF8F3;
    --c-muted: #9E988D;
    
    /* Semantic Colors */
    --bg-main: var(--c-deep-black);
    --bg-surface: var(--c-warm-black);
    --text-main: var(--c-ivory);
    --text-muted: var(--c-muted);
    --border-subtle: rgba(201, 168, 106, 0.15); /* Champagne with low opacity */
    --border-strong: rgba(201, 168, 106, 0.4);
    
    --positive: #65A765;
    --negative: #C85A5A;
    
    /* Typography */
    --font-primary: 'Outfit', sans-serif;
}

[data-theme="light"] {
    --bg-main: var(--c-warm-white);
    --bg-surface: #ffffff;
    --text-main: var(--c-deep-black);
    --text-muted: #736b5e;
    --border-subtle: rgba(201, 168, 106, 0.25);
    --border-strong: rgba(201, 168, 106, 0.5);
}

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

body {
    font-family: var(--font-primary);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color 0.3s ease, color 0.3s ease;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 500;
    line-height: 1.2;
    color: var(--text-main);
}

.text-gold { color: var(--c-champagne); }
.text-ivory { color: var(--text-main); }
.text-muted { color: var(--text-muted); }
.text-positive { color: var(--positive); }
.text-negative { color: var(--negative); }

.serif { font-family: var(--font-primary); }
.sans { font-family: var(--font-primary); }

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    background: transparent;
}

.btn-primary {
    background-color: var(--c-champagne);
    color: var(--c-deep-black);
}

.btn-primary:hover {
    background-color: var(--c-soft-gold);
}

.btn-outline {
    border: 1px solid var(--c-champagne);
    color: var(--c-champagne);
}

.btn-outline:hover {
    background-color: var(--c-champagne);
    color: var(--c-deep-black);
}

/* Navbar */
.top-bar {
    background-color: var(--c-deep-black);
    color: var(--text-muted);
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-subtle);
    text-align: center;
}

.navbar {
    background-color: var(--bg-main);
    padding: 1.5rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border-subtle);
    transition: background-color 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 2px;
    color: var(--text-main);
    text-transform: uppercase;
    white-space: nowrap;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    font-family: var(--font-primary);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    text-transform: uppercase;
    position: relative;
    padding-bottom: 0.25rem;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--c-champagne);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 1px;
    background-color: var(--c-champagne);
    transition: width 0.3s ease;
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* Mobile Bottom Nav */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-subtle);
    padding: 1rem;
    justify-content: space-around;
    z-index: 100;
}

.bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 500;
    gap: 0.3rem;
    color: var(--text-muted);
}

.bottom-nav a.active {
    color: var(--c-champagne);
}

.bottom-nav a svg {
    width: 22px;
    height: 22px;
}

/* Footer */
footer {
    background-color: var(--bg-surface);
    padding: 6rem 0 3rem 0;
    margin-top: auto;
    border-top: 1px solid var(--border-subtle);
}

.footer-hero {
    text-align: center;
    margin-bottom: 5rem;
}

.footer-hero h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--c-champagne);
}

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

.footer-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 4rem;
    border-bottom: 1px solid var(--border-subtle);
    padding-bottom: 4rem;
}

.footer-col h4 {
    font-family: var(--font-primary);
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-main);
    margin-bottom: 1.5rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 0.8rem;
}

.footer-col ul a {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.footer-col ul a:hover {
    color: var(--c-champagne);
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}
.footer-logo {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    letter-spacing: 2px;
}
.footer-copy {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Main Layout */
main {
    flex: 1;
}

/* Form Inputs (Minimalist) */
.input-group {
    margin-bottom: 2rem;
}
.input-label {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}
.input-minimal {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-strong);
    color: var(--text-main);
    font-family: var(--font-primary);
    font-size: 1.25rem;
    padding: 0.5rem 0;
    transition: border-color 0.3s;
}
.input-minimal:focus {
    outline: none;
    border-bottom-color: var(--c-champagne);
}
select.input-minimal {
    appearance: none;
    cursor: pointer;
}

/* Split Layout (Calculators) */
.split-layout {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 200px);
}
@media (min-width: 992px) {
    .split-layout {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
}
.split-left {
    padding: 3rem 1.5rem;
    border-right: none;
    border-top: 1px solid var(--border-subtle);
}
@media (min-width: 992px) {
    .split-left {
        padding: 4rem 2rem;
        border-right: 1px solid var(--border-subtle);
        border-top: none;
    }
}
.split-right {
    padding: 3rem 1.5rem;
    background-color: var(--bg-surface);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}
@media (min-width: 992px) {
    .split-right {
        padding: 4rem 2rem;
    }
}
.result-box {
    text-align: center;
    position: sticky;
    top: 6rem;
}
.result-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}
.result-value {
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 3.5rem;
    color: var(--c-champagne);
    margin-bottom: 2rem;
    word-break: break-all;
}

/* Mobile Sticky Total Bar */
.mobile-sticky-total {
    display: none;
}

/* Editorial Tables / Lists */
.editorial-list {
    width: 100%;
}
.ed-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border-subtle);
    align-items: center;
}
.ed-row:hover {
    background-color: rgba(255,255,255,0.01);
}
.ed-header {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-strong);
}
.ed-name {
    font-family: var(--font-primary);
    font-weight: 500;
    font-size: 1.25rem;
}
.ed-val {
    font-family: var(--font-primary);
    font-size: 1.1rem;
    font-weight: 500;
}
.ed-right {
    text-align: right;
}
@media (max-width: 768px) {
    .ed-header { display: none; }
    .ed-row {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        padding: 1.5rem 0;
    }
    .ed-val { text-align: left; }
    .ed-right { text-align: left; }
    .ed-val::before {
        content: attr(data-label) ": ";
        color: var(--text-muted);
        font-size: 0.85rem;
        margin-right: 0.5rem;
    }
}

/* Sections */
.section-padding {
    padding: 6rem 0;
}
.section-title {
    font-family: var(--font-primary);
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--text-main);
}

/* Hero Component */
.lux-hero {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 70vh;
    border-bottom: 1px solid var(--border-subtle);
}
@media (min-width: 992px) {
    .lux-hero {
        grid-template-columns: 1.2fr 0.8fr;
    }
}
.lux-hero-content {
    padding: 6rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.lux-hero-eyebrow {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--c-champagne);
    margin-bottom: 1.5rem;
}
.lux-hero-title {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}
.lux-hero-desc {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 500px;
    margin-bottom: 3rem;
}
.lux-hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}
.lux-hero-visual {
    background-color: var(--bg-surface);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}
/* Abstract luxury texture simulation for hero right side */
.lux-hero-visual::before {
    content: '';
    position: absolute;
    width: 150%;
    height: 150%;
    background: radial-gradient(circle at center, rgba(201, 168, 106, 0.15) 0%, transparent 60%);
    opacity: 0.8;
}
.lux-hero-visual::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    border: 1px solid rgba(201, 168, 106, 0.2);
    border-radius: 50%;
    box-shadow: 0 0 100px rgba(201, 168, 106, 0.05);
}

/* Media Queries for Navbar */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .bottom-nav {
        display: flex;
    }
    
    main {
        padding-bottom: 0;
    }
    
    footer {
        padding-bottom: 6.5rem; /* Extra padding so bottom-nav doesn't hide content */
    }
    
    body:has(.mobile-sticky-total) footer {
        padding-bottom: 11.5rem; /* Extra padding for sticky total bar + bottom-nav */
    }
    
    .lux-hero-title {
        font-size: 2.5rem;
    }
    .result-value {
        font-size: 2.5rem;
    }

    .result-box {
        position: relative;
        top: auto;
    }

    .mobile-sticky-total {
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: fixed;
        bottom: 73px; /* Just above bottom-nav which is ~73px tall */
        left: 0;
        right: 0;
        background: var(--bg-surface);
        padding: 1rem 1.5rem;
        border-top: 1px solid var(--border-subtle);
        z-index: 99;
        box-shadow: 0 -4px 15px rgba(0,0,0,0.4);
    }
}
