:root {
    --bg: #f6f5f1;
    --surface: #ffffff;
    --surface-soft: #faf9f6;

    --ink: #191919;
    --muted: #74736f;
    --muted-light: #999791;

    --line: #deddd8;
    --line-dark: #cbc9c3;

    --accent: #5954d9;
    --accent-dark: #4843c4;
    --accent-soft: #eeecff;

    --chart-net: #5954d9;
    --chart-federal: #e7a23b;
    --chart-fica: #e06c5d;
    --chart-state: #72a86f;
    --chart-deductions: #aaa9a3;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;

    --shadow: 0 10px 30px rgba(25, 25, 25, 0.06);

    --max-width: 1120px;
    --content-width: 760px;
}


/* =========================
   RESET
========================= */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;

    background: var(--bg);
    color: var(--ink);

    font-family:
        Inter,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;

    line-height: 1.6;

    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

button,
input,
textarea,
select {
    font: inherit;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    color: var(--accent-dark);
}


/* =========================
   GLOBAL CONTAINER
========================= */

.container {
    width: min(var(--max-width), calc(100% - 32px));
    margin-inline: auto;
}


/* =========================
   HEADER
========================= */

.site-header {
    position: relative;
    z-index: 1000;

    width: 100%;

    background: var(--surface);
    border-bottom: 1px solid var(--line);
}

.header-inner {
    position: relative;

    min-height: 64px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;

    color: var(--ink);

    font-size: 1.25rem;
    font-weight: 800;

    line-height: 1;

    white-space: nowrap;
}

.logo:hover {
    color: var(--ink);
}


/* =========================
   DESKTOP NAVIGATION
========================= */

.main-nav {
    display: flex;
    align-items: center;

    gap: 5px;
}

.main-nav > a,
.nav-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 40px;

    padding: 7px 10px;

    border: 0;
    border-radius: var(--radius-sm);

    background: transparent;
    color: var(--ink);

    font-size: 0.92rem;
    font-weight: 600;

    line-height: 1;

    text-decoration: none;

    cursor: pointer;
    white-space: nowrap;
}

.main-nav > a:hover,
.nav-dropdown-toggle:hover {
    background: var(--surface-soft);
    color: var(--accent);
}


/* =========================
   FINANCE DROPDOWN
========================= */

.nav-dropdown {
    position: relative;
}

.dropdown-arrow {
    margin-left: 6px;

    font-size: 11px;

    transition: transform 0.18s ease;
}

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

.nav-dropdown-menu {
    position: absolute;
    z-index: 2000;

    top: calc(100% + 6px);
    right: 0;

    width: 235px;

    padding: 7px;

    background: var(--surface);

    border: 1px solid var(--line);
    border-radius: var(--radius-md);

    box-shadow: var(--shadow);

    display: none;
}

.nav-dropdown.open .nav-dropdown-menu {
    display: block;
}

.nav-dropdown-menu a {
    display: block;

    padding: 10px 12px;

    border-radius: var(--radius-sm);

    color: var(--ink);

    font-size: 13px;
    font-weight: 500;

    line-height: 1.4;

    text-decoration: none;
}

.nav-dropdown-menu a:hover {
    background: var(--surface-soft);
    color: var(--accent);
}


/* =========================
   MOBILE MENU BUTTON
========================= */

.mobile-menu-toggle {
    display: none;

    width: 42px;
    height: 42px;

    padding: 8px;

    border: 1px solid var(--line);
    border-radius: var(--radius-sm);

    background: var(--surface);
    color: var(--ink);

    cursor: pointer;
}

.mobile-menu-toggle span {
    display: block;

    width: 20px;
    height: 2px;

    margin: 4px auto;

    background: var(--ink);

    border-radius: 2px;

    transition:
        transform 0.2s ease,
        opacity 0.2s ease;
}


/* =========================
   HAMBURGER → X
========================= */

.mobile-menu-toggle.open span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.mobile-menu-toggle.open span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.open span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}


/* =========================
   MAIN
========================= */

.legal-page {
    width: 100%;

    padding: 48px 0 64px;
}

.legal-container {
    width: min(820px, calc(100% - 32px));

    margin-inline: auto;

    padding: 46px;

    background: var(--surface);

    border: 1px solid var(--line);
    border-radius: 18px;
}

.contact-container {
    max-width: 760px;
}


/* =========================
   PAGE HEADER
========================= */

.legal-header {
    margin: 0 0 34px;
    padding: 0 0 28px;

    border-bottom: 1px solid var(--line);
}

.eyebrow {
    margin: 0 0 9px;

    color: var(--accent);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 0.13em;

    line-height: 1.4;
}

.legal-header h1 {
    margin: 0;

    color: var(--ink);

    font-size: clamp(32px, 5vw, 44px);
    font-weight: 800;

    line-height: 1.1;

    letter-spacing: -1.4px;
}

.updated {
    margin: 12px 0 0;

    color: var(--muted);

    font-size: 14px;

    line-height: 1.5;
}


/* =========================
   CONTENT
========================= */

.legal-section {
    margin: 0 0 34px;
}

.legal-section:last-of-type {
    margin-bottom: 0;
}

.legal-section h2 {
    margin: 0 0 10px;

    color: var(--ink);

    font-size: 20px;
    font-weight: 750;

    line-height: 1.3;

    letter-spacing: -0.3px;
}

.legal-section p {
    margin: 0 0 13px;

    color: #55544f;

    font-size: 15px;

    line-height: 1.7;
}

.legal-section p:last-child {
    margin-bottom: 0;
}

.legal-section ul {
    margin: 10px 0 0;

    padding: 0 0 0 21px;

    color: #55544f;

    font-size: 15px;

    line-height: 1.7;
}

.legal-section li {
    margin: 0 0 6px;
}

.legal-section li:last-child {
    margin-bottom: 0;
}


/* =========================
   EMAIL BOX
========================= */

.contact-box {
    margin: 20px 0 0;
    padding: 18px;

    background: var(--surface-soft);

    border: 1px solid var(--line);
    border-radius: 13px;
}

.contact-label {
    display: block;

    margin: 0 0 5px;

    color: var(--muted);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 0.08em;

    text-transform: uppercase;
}

.contact-box a {
    display: inline-block;

    max-width: 100%;

    color: var(--accent);

    font-size: 16px;
    font-weight: 700;

    line-height: 1.5;

    overflow-wrap: anywhere;
    word-break: break-word;
}

.contact-box a:hover {
    color: var(--accent-dark);
}

.small-note {
    margin-top: 8px !important;

    color: var(--muted) !important;

    font-size: 13px !important;
}


/* =========================
   BRAND NOTE
========================= */

.legal-note {
    display: flex;
    flex-direction: column;

    gap: 2px;

    margin: 40px 0 0;
    padding: 22px 0 0;

    border-top: 1px solid var(--line);
}

.legal-note strong {
    margin: 0;

    color: var(--ink);

    font-size: 14px;

    line-height: 1.5;
}

.legal-note span {
    margin: 0;

    color: var(--muted);

    font-size: 13px;

    line-height: 1.5;
}


/* =========================
   FOOTER
========================= */

.site-footer {
    width: 100%;

    padding: 26px 0 32px;

    border-top: 1px solid var(--line);

    text-align: center;
}

.site-footer p {
    width: min(500px, calc(100% - 32px));

    margin: 0 auto 10px;

    color: var(--muted);

    font-size: 13px;

    line-height: 1.5;
}

.footer-links {
    width: min(100%, calc(100% - 32px));

    margin-inline: auto;

    display: flex;
    justify-content: center;
    align-items: center;

    flex-wrap: wrap;

    gap: 16px;
}

.footer-links a {
    color: var(--muted);

    font-size: 13px;

    line-height: 1.5;
}

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


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 760px) {

    .container {
        width: calc(100% - 24px);
    }

    /* Header */

    .header-inner {
        min-height: 58px;

        padding: 8px 0;
    }

    .logo {
        font-size: 19px;
    }

    /* Hamburger */

    .mobile-menu-toggle {
        display: block;

        flex: 0 0 auto;
    }

    /* Mobile navigation */

    .main-nav {
        position: absolute;
        z-index: 1500;

        top: calc(100% + 1px);
        left: 0;
        right: 0;

        display: none;

        flex-direction: column;
        align-items: stretch;

        gap: 3px;

        padding: 8px;

        background: var(--surface);

        border: 1px solid var(--line);
        border-top: 0;

        border-radius:
            0 0 var(--radius-md) var(--radius-md);

        box-shadow: var(--shadow);
    }

    .main-nav.mobile-open {
        display: flex;
    }

    .main-nav > a,
    .nav-dropdown-toggle {
        width: 100%;

        min-height: 44px;

        justify-content: flex-start;

        padding: 10px 12px;

        font-size: 14px;

        text-align: left;
    }

    .main-nav > a:hover,
    .nav-dropdown-toggle:hover {
        background: var(--surface-soft);
    }

    /* Finance */

    .nav-dropdown {
        width: 100%;
    }

    .nav-dropdown-toggle {
        justify-content: space-between;
    }

    /* Finance submenu */

    .nav-dropdown-menu {
        position: static;

        width: 100%;

        margin: 2px 0 5px;
        padding: 4px;

        background: var(--surface-soft);

        border: 0;
        border-radius: var(--radius-sm);

        box-shadow: none;
    }

    .nav-dropdown-menu a {
        display: flex;
        align-items: center;

        min-height: 40px;

        padding: 8px 12px;

        font-size: 13px;
    }


    /* Main page */

    .legal-page {
        padding: 28px 0 48px;
    }

    .legal-container {
        width: calc(100% - 24px);

        padding: 30px 24px;

        border-radius: 15px;
    }

    .legal-header {
        margin-bottom: 28px;
        padding-bottom: 24px;
    }

    .legal-header h1 {
        font-size: 34px;
    }

    .legal-section {
        margin-bottom: 30px;
    }

    .legal-section h2 {
        font-size: 19px;
    }

    .legal-section p,
    .legal-section ul {
        font-size: 14px;
    }
}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 480px) {

    .container {
        width: calc(100% - 20px);
    }

    .header-inner {
        min-height: 56px;
        padding: 7px 0;
    }

    .logo {
        font-size: 18px;
    }

    .mobile-menu-toggle {
        width: 40px;
        height: 40px;
    }

    .legal-page {
        padding: 18px 0 36px;
    }

    .legal-container {
        width: calc(100% - 20px);

        padding: 25px 18px 27px;

        border-radius: 13px;
    }

    .legal-header {
        margin-bottom: 25px;
        padding-bottom: 21px;
    }

    .eyebrow {
        margin-bottom: 8px;

        font-size: 10px;
    }

    .legal-header h1 {
        font-size: 29px;

        letter-spacing: -0.8px;
    }

    .updated {
        margin-top: 9px;

        font-size: 13px;

        line-height: 1.5;
    }

    .legal-section {
        margin-bottom: 27px;
    }

    .legal-section h2 {
        margin-bottom: 9px;

        font-size: 18px;
    }

    .legal-section p {
        margin-bottom: 11px;

        font-size: 14px;

        line-height: 1.65;
    }

    .legal-section ul {
        margin-top: 8px;

        padding-left: 19px;

        font-size: 14px;

        line-height: 1.6;
    }

    .legal-section li {
        margin-bottom: 5px;
    }

    .contact-box {
        margin-top: 17px;
        padding: 16px;

        border-radius: 11px;
    }

    .contact-box a {
        max-width: 100%;

        font-size: 15px;
    }

    .legal-note {
        margin-top: 32px;
        padding-top: 19px;
    }

    .site-footer {
        padding: 23px 0 28px;
    }

    .site-footer p {
        width: calc(100% - 24px);

        font-size: 12px;

        line-height: 1.5;
    }

    .footer-links {
        width: calc(100% - 24px);

        gap: 10px 15px;
    }

    .footer-links a {
        font-size: 12px;
    }
}


/* =========================================================
   VERY SMALL PHONES
========================================================= */

@media (max-width: 350px) {

    .container {
        width: calc(100% - 16px);
    }

    .header-inner {
        min-height: 54px;
    }

    .logo {
        font-size: 17px;
    }

    .mobile-menu-toggle {
        width: 38px;
        height: 38px;
    }

    .legal-page {
        padding: 14px 0 30px;
    }

    .legal-container {
        width: calc(100% - 16px);

        padding: 22px 15px 24px;

        border-radius: 12px;
    }

    .legal-header h1 {
        font-size: 27px;
    }

    .legal-section h2 {
        font-size: 17px;
    }

    .legal-section p,
    .legal-section ul {
        font-size: 13.5px;
    }

    .contact-box {
        padding: 14px;
    }

    .contact-box a {
        font-size: 14px;
    }
}