/* =========================================
   1. ROOT VARIABLES & THEME SETUP
   ========================================= */
:root {
    /* Primary Colors - Professional Navy & Emerald */
    --primary: #0f172a;       /* Deep Navy */
    --primary-light: #1e293b; /* Lighter Navy */
    --accent: #10b981;        /* Emerald Green */
    --accent-hover: #059669;
    
    /* Semantic Colors */
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    
    /* Text Colors */
    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-light: #f8fafc;
    
    /* Backgrounds */
    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    --bg-input: #f1f5f9;
    
    /* Borders & Shadows - Refined for a "Legitimate" Look */
    --border: #e2e8f0;
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 25px rgba(16, 185, 129, 0.2);
    
    /* Typography */
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    
    /* Spacing */
    --container-width: 1200px;
    --radius: 12px; /* Professional rounded corners */
}

/* Dark Mode Support (System Preference) */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-body: #020617;
        --bg-card: #0f172a;
        --bg-input: #1e293b;
        --text-main: #f1f5f9;
        --text-muted: #94a3b8;
        --border: #1e293b;
        --primary: #f8fafc;
        --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5);
        --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5);
    }
}

/* =========================================
   2. GLOBAL RESET & BASE STYLES
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.3s ease, color 0.3s ease;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* =========================================
   3. UTILITIES & LAYOUT
   ========================================= */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.highlight {
    color: var(--accent);
}

/* =========================================
   4. NAVIGATION BAR (UPDATED: Dark Blue & Bold)
   ========================================= */
.navbar {
    background-color: #0f172a; /* Dark Blue Background */
    border-bottom: 1px solid rgba(255,255,255,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.4rem;
    font-weight: 800;
    color: #9333ea; /* Dark Purple Logo */
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-weight: 700; /* Bold Links */
    color: #94a3b8; /* Lighter blue-grey for contrast on dark bg */
    font-size: 0.95rem;
    position: relative;
}

.nav-links a:hover, .nav-links a.active {
    color: #ffffff; /* White on hover */
}

/* Underline animation for nav links */
.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: #9333ea; /* Purple underline */
    transition: width 0.3s ease;
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #ffffff;
}

/* =========================================
   5. HERO SECTION
   ========================================= */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, #1e293b 100%);
    color: var(--text-light);
    padding: 5rem 0 4rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 20% 50%, rgba(16, 185, 129, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.small-hero {
    padding: 3.5rem 0;
}

.eyebrow {
    display: inline-block;
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
    padding: 0.35rem 1rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -1px;
}

.sub-headline {
    font-size: 1.25rem;
    color: #cbd5e1;
    max-width: 700px;
    margin: 0 auto 2.5rem;
    line-height: 1.6;
}

.trust-badges {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 0;
}

.badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.6rem 1.2rem;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    backdrop-filter: blur(5px);
}

/* =========================================
   6. ADSENSE SLOTS
   ========================================= */
.ad-slot {
    margin: 3rem auto;
    text-align: center;
}

.ad-placeholder {
    background-color: var(--bg-input);
    border: 1px dashed var(--border);
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    border-radius: var(--radius);
    max-width: 728px;
    margin: 0 auto;
    transition: border-color 0.3s;
}

.ad-placeholder:hover {
    border-color: var(--accent);
}

/* =========================================
   7. CALCULATOR GRID (TWO COLUMN)
   ========================================= */
.calculator-section {
    padding: 3rem 0 5rem;
}

.calculator-grid {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
}

/* Input Panel */
.input-panel {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.input-panel:hover {
    box-shadow: var(--shadow-lg);
}

.panel-header h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.panel-sub {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.input-group {
    margin-bottom: 1.75rem;
}

.input-group label {
    display: block;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-main);
}

.form-select, input[type="number"] {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background-color: var(--bg-input);
    color: var(--text-main);
    font-family: var(--font-main);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.form-select:focus, input[type="number"]:focus {
    outline: none;
    border-color: var(--accent);
    background-color: var(--bg-card);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

/* Slider Styles */
.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.slider-value {
    font-weight: 700;
    color: var(--accent);
    font-size: 1rem;
    background: rgba(16, 185, 129, 0.1);
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
}

.range-slider {
    width: 100%;
    height: 8px;
    background: var(--bg-input);
    border-radius: 5px;
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    transition: transform 0.1s, box-shadow 0.2s;
    border: 2px solid var(--bg-card);
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 0 10px var(--accent);
}

.info-tip {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    font-style: italic;
}

/* Buttons */
.btn-reset {
    width: 100%;
    padding: 0.85rem;
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-muted);
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 1.5rem;
    font-size: 1rem;
}

.btn-reset:hover {
    border-color: var(--danger);
    color: var(--danger);
    background: rgba(239, 68, 68, 0.05);
}

.privacy-note {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* Results Panel */
.results-panel {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* --- LIVE DASHBOARD --- */
.dashboard-card {
    background: var(--primary);
    color: var(--text-light);
    padding: 2.25rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
    border: 1px solid rgba(255,255,255,0.1);
}

.dashboard-card h3 {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 1rem;
}

.tiles-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.tile {
    background: rgba(255, 255, 255, 0.08);
    padding: 1.75rem 1rem;
    border-radius: 12px;
    text-align: center;
    transition: transform 0.2s, background 0.2s;
    border: 1px solid rgba(255,255,255,0.05);
}

.tile:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
}

.tile-label {
    display: block;
    font-size: 0.85rem;
    opacity: 0.8;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.tile-value {
    display: block;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.tile-value.nominal {
    text-decoration: none; 
    opacity: 1;
    font-size: 1.25rem;
    color: #cbd5e1;
}

.tile-value.real {
    color: var(--accent);
    font-size: 1.6rem;
    text-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
}

.tile-value.tax {
    color: #f87171;
}

.tile-value.percent {
    color: #fbbf24;
}

/* Interpretation Card */
.interpretation-card {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.interpretation-card h3 {
    margin-bottom: 1.5rem;
    color: var(--text-main);
    font-size: 1.4rem;
}

.placeholder-text {
    color: var(--text-muted);
    font-style: italic;
    line-height: 1.8;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-action {
    flex: 1;
    padding: 0.85rem;
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-main);
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    font-size: 0.95rem;
}

.btn-action:hover {
    background: var(--border);
    transform: translateY(-1px);
}

/* =========================================
   8. SEO CONTENT & FAQ
   ========================================= */
.seo-content {
    background: var(--bg-card);
    padding: 5rem 0;
    border-top: 1px solid var(--border);
}

.content-block h2, .faq-block h2 {
    font-size: 2rem;
    margin-bottom: 3rem;
    color: var(--text-main);
    text-align: center;
    font-weight: 800;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
    margin-bottom: 4rem;
}

.step {
    text-align: center;
    padding: 2rem;
    background: var(--bg-body);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    transition: transform 0.3s;
}

.step:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.step-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    display: inline-block;
    background: var(--bg-card);
    width: 60px;
    height: 60px;
    line-height: 60px;
    border-radius: 50%;
    box-shadow: var(--shadow-sm);
}

.step h3 {
    margin-bottom: 1rem;
    color: var(--text-main);
    font-size: 1.2rem;
}

.step p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.faq-item {
    background: var(--bg-body);
    margin-bottom: 1.5rem;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: all 0.3s;
}

.faq-item[open] {
    background: var(--bg-card);
    box-shadow: var(--shadow-sm);
}

.faq-item summary {
    padding: 1.25rem 1.5rem;
    cursor: pointer;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-main);
    font-size: 1.05rem;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.5rem;
    color: var(--accent);
    font-weight: 300;
}

.faq-item[open] summary::after {
    content: '-';
}

.faq-item p {
    padding: 0 1.5rem 1.5rem;
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

/* =========================================
   9. ABOUT & PRIVACY PAGES SPECIFIC
   ========================================= */
.content-section {
    padding: 4rem 0;
}

.about-article, .privacy-article {
    max-width: 850px;
    margin: 0 auto;
    background: var(--bg-card);
    padding: 3.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

.about-article h2, .privacy-article h2 {
    margin-top: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    font-size: 1.75rem;
}

.about-article p, .privacy-article p {
    margin-bottom: 1.25rem;
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.8;
}

.feature-list {
    margin: 1.5rem 0 1.5rem 1.5rem;
    list-style: disc;
    color: var(--text-muted);
}

.feature-list li {
    margin-bottom: 0.75rem;
    padding-left: 0.5rem;
}

.divider {
    border: 0;
    height: 1px;
    background: var(--border);
    margin: 3rem 0;
}

.math-box {
    background: var(--bg-input);
    padding: 1.5rem;
    border-left: 4px solid var(--accent);
    font-family: monospace;
    margin: 1.5rem 0;
    border-radius: 0 8px 8px 0;
    font-size: 1.1rem;
    color: var(--text-main);
}

.privacy-highlight-box {
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 2rem;
    border-radius: var(--radius);
    margin-bottom: 2.5rem;
}

.privacy-highlight-box h2 {
    margin-top: 0 !important;
    color: var(--accent) !important;
}

.privacy-highlight-box p {
    color: var(--text-main) !important;
    margin-bottom: 0 !important;
    font-weight: 500;
}

.last-updated {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-style: italic;
    margin-top: 2.5rem;
}

.cta-box {
    text-align: center;
    margin-top: 4rem;
    padding: 2.5rem;
    background: var(--bg-input);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.btn-primary {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 0.85rem 2.5rem;
    border-radius: 10px;
    font-weight: 700;
    margin-top: 1.5rem;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(16, 185, 129, 0.4);
}

/* =========================================
   10. CONTACT PAGE SPECIFIC
   ========================================= */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.full-width-card {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    text-align: center;
}

.contact-info-card h2 {
    margin-bottom: 1rem;
    color: var(--text-main);
}

.intro-text {
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
}

.info-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    align-items: center;
    justify-content: center;
    text-align: left;
    background: var(--bg-body);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    transition: transform 0.2s;
}

.info-item:hover {
    transform: translateX(5px);
    border-color: var(--accent);
}

.info-icon {
    font-size: 2rem;
    background: var(--bg-card);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: var(--shadow-sm);
}

.info-item div strong {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-bottom: 0.25rem;
}

.info-item div p {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
}

.social-links.expanded {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.social-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.social-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.2s;
    border: 1px solid var(--border);
    background: var(--bg-body);
    color: var(--text-main);
}

.social-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateY(-2px);
}

/* =========================================
   11. FOOTER
   ========================================= */
footer {
    background: var(--primary);
    color: var(--text-light);
    padding: 4rem 0;
    margin-top: auto;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-content {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
}

.footer-center p {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.disclaimer {
    font-size: 0.8rem;
    color: #94a3b8;
    max-width: 600px;
    line-height: 1.6;
    opacity: 0.8;
}

/* =========================================
   12. RESPONSIVE DESIGN (MOBILE)
   ========================================= */
@media (max-width: 900px) {
    .calculator-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    .hero h1 {
        font-size: 2.25rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #0f172a; /* Match navbar dark blue */
        padding: 1.5rem;
        box-shadow: var(--shadow-lg);
        border-top: 1px solid rgba(255,255,255,0.1);
        gap: 1.5rem;
    }

    .nav-links.active {
        display: flex;
    }
    
    .mobile-menu-toggle {
        display: block;
    }

    .hero {
        padding: 3rem 0;
    }

    .hero h1 {
        font-size: 1.85rem;
    }

    .sub-headline {
        font-size: 1rem;
    }

    .tiles-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-card {
        padding: 1.5rem;
    }
    
    .about-article, .privacy-article, .full-width-card {
        padding: 1.5rem;
    }

    .info-item {
        flex-direction: column;
        text-align: center;
    }
}

/* =========================================
   13. HIDE NUMBER INPUT SPINNERS (LATEST DEMAND)
   ========================================= */
.no-spinner::-webkit-outer-spin-button,
.no-spinner::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.no-spinner {
    -moz-appearance: textfield; /* Firefox */
}