:root {
    --primary: #1e293b;
    --accent: #d97706;
    --light-bg: #f7f0e3;
    --text-main: #334155;
    --text-muted: #64748b;
    --card-border: #ddcfb6;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    margin: 0;
    padding: 0;
    background-color: #f4ead8;
}

.container {
    max-width: 850px;
    margin: 0 auto;
    padding: 0 20px;
}

.skip {
    position: absolute;
    left: 12px;
    top: -48px;
    background: var(--accent);
    color: #fff;
    padding: 8px 12px;
    z-index: 40;
    text-decoration: none;
    font-weight: 700;
    border-radius: 4px;
}
.skip:focus { top: 12px; }

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid var(--card-border);
}
.logo {
    font-weight: bold;
    font-size: 1.1rem;
    color: var(--primary);
    text-decoration: none;
}
.nav-links a {
    margin-left: 20px;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] {
    color: var(--accent);
}
.nav-links a[aria-current="page"] {
    font-weight: 600;
}

header.hero,
header {
    background-color: var(--primary);
    color: white;
    padding: 60px 20px;
    text-align: center;
    border-radius: 8px;
    margin: 20px 0 40px 0;
}
header p.tagline {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    color: var(--accent);
    font-weight: bold;
    margin-bottom: 10px;
}
header h1 {
    font-size: 2.5rem;
    margin: 0 0 15px 0;
    font-weight: 800;
    line-height: 1.2;
    color: white;
}
header .subheadline {
    font-size: 1.2rem;
    color: #cbd5e1;
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.5;
}

section {
    padding: 40px 0;
    border-bottom: 1px solid var(--card-border);
}
section:last-of-type {
    border-bottom: none;
}
h2 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-top: 0;
    margin-bottom: 20px;
}

.catch-phrase {
    font-size: 1.4rem;
    font-weight: bold;
    color: var(--accent);
    text-align: center;
    margin: 30px 0;
    padding: 15px;
    border-top: 2px dashed var(--card-border);
    border-bottom: 2px dashed var(--card-border);
}

.math-grid,
.how {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 25px 0;
}
.how {
    grid-template-columns: 1fr 1fr 1fr;
}
.math-card,
.step {
    background: var(--light-bg);
    padding: 25px;
    border: 1px solid var(--card-border);
    border-radius: 8px;
}
.math-card h3,
.step h3 {
    margin-top: 0;
    color: var(--primary);
    font-size: 1.2rem;
}
.step .n {
    color: var(--accent);
    font-size: 0.8rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 700;
    margin: 0 0 8px;
}
.step p {
    margin: 0;
    color: var(--text-main);
}
.price-badge {
    font-size: 1.6rem;
    font-weight: bold;
    color: var(--accent);
    margin: 10px 0;
}
.highlight-box {
    background-color: #fffbeb;
    border-left: 5px solid var(--accent);
    padding: 20px;
    border-radius: 4px;
    margin: 25px 0;
}

.tab-container {
    display: flex;
    gap: 10px;
    margin: 0 0 24px;
}
.tab-btn {
    flex: 1;
    background: var(--light-bg);
    border: 1px solid var(--card-border);
    padding: 12px 14px;
    min-height: 44px;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-main);
    border-radius: 6px;
    cursor: pointer;
    font-family: inherit;
}
.tab-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}
.comparison-view {
    display: none;
}
.comparison-view.active {
    display: block;
}
.compare-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 24px;
}
.compare-card {
    padding: 25px;
    border: 2px solid var(--card-border);
    border-radius: 8px;
    background: #fffaf1;
}
.compare-card.shop {
    border-color: #c48a7a;
    background: #f8ece4;
}
.compare-card.diy {
    border-color: #7a9a72;
    background: #eef4e8;
}
.compare-card h3 {
    margin-top: 0;
    color: var(--primary);
    font-size: 1.2rem;
}
.price-tag {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 12px 0;
}
.shop .price-tag { color: #b45309; }
.diy .price-tag { color: #3f621a; }
.talking-points {
    background: var(--light-bg);
    border-left: 5px solid var(--primary);
    padding: 20px;
    border-radius: 4px;
}
.talking-points h4 {
    margin: 0 0 10px;
    color: var(--primary);
}
.talking-points ul {
    margin: 0;
    padding-left: 20px;
}
.talking-points li {
    margin-bottom: 8px;
}
.lifetime-savings {
    background: var(--primary);
    color: #fff;
    padding: 30px;
    border-radius: 8px;
    margin-top: 32px;
    text-align: center;
}
.lifetime-savings h3 {
    margin: 0 0 12px;
    color: #fbbf24;
}
.lifetime-savings p {
    margin: 0 auto 8px;
    max-width: 560px;
    color: #cbd5e1;
}
.lifetime-savings .btn {
    margin-top: 18px;
}

.package-list {
    margin-top: 30px;
}
.package-item {
    background: #fffaf1;
    border: 1px solid var(--card-border);
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 20px;
    position: relative;
}
.package-item.featured {
    border: 2px solid var(--accent);
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.1);
}
.package-badge {
    display: block;
    width: fit-content;
    margin: 0 0 12px auto;
    background: var(--accent);
    color: white;
    padding: 4px 10px;
    font-size: 0.8rem;
    font-weight: bold;
    border-radius: 4px;
    text-transform: uppercase;
}
.package-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 15px;
    gap: 12px;
}
.package-title {
    font-size: 1.4rem;
    font-weight: bold;
    color: var(--primary);
    margin: 0;
}
.package-price {
    font-size: 1.4rem;
    font-weight: bold;
    color: var(--text-main);
    white-space: nowrap;
}
.package-price .price-duration {
    font-size: 0.9rem;
    font-weight: normal;
    color: var(--text-muted);
}
.package-features {
    margin: 15px 0 0 0;
    padding-left: 20px;
}
.package-features li {
    margin-bottom: 8px;
}

.form-group {
    margin-bottom: 15px;
}
label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}
input, select, textarea {
    width: 100%;
    padding: 12px 10px;
    border: 1px solid var(--card-border);
    border-radius: 4px;
    box-sizing: border-box;
    font-family: inherit;
    font-size: 1rem;
    background: #fffaf1;
    color: var(--text-main);
}
textarea {
    min-height: 120px;
    resize: vertical;
}
.row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.row-3 {
    grid-template-columns: 1fr 1fr 1fr;
}
.vehicle-picker,
.choice-or {
    border: 1px solid var(--card-border);
    background: #fffaf1;
    border-radius: 8px;
    padding: 20px;
    margin: 8px 0 20px;
}
.vehicle-picker legend,
.choice-or legend {
    font-weight: 700;
    color: var(--primary);
    padding: 0 6px;
}
.or-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 14px;
    align-items: end;
}
.or-divider {
    margin: 0 0 15px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    text-align: center;
    font-size: 0.85rem;
}
.choice-or .form-group.is-idle {
    opacity: 0.5;
}
.optional {
    font-weight: 400;
    color: var(--text-muted);
    font-size: 0.9rem;
}
.vin-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: start;
}
.btn-secondary {
    background: var(--primary);
    color: #fff;
    padding: 12px 16px;
    white-space: nowrap;
}
.btn-secondary:hover {
    background: #0f172a;
    color: #fff;
}
.note-muted {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 10px;
}
.form-status {
    margin: 8px 0 0;
    color: var(--accent);
    min-height: 1.2em;
}

.btn {
    display: inline-block;
    background-color: var(--accent);
    color: white;
    padding: 12px 30px;
    text-decoration: none;
    font-weight: bold;
    border-radius: 4px;
    text-align: center;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    min-height: 44px;
}
.btn:hover {
    background-color: #b45309;
    color: white;
}
.btn-center {
    display: block;
    max-width: 220px;
    margin: 30px auto 0 auto;
}
.package-item .btn {
    margin-top: 18px;
}

.section-link {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}
.section-link:hover {
    text-decoration: underline;
}

.posts {
    display: grid;
    gap: 16px;
    margin-top: 20px;
}
.post {
    background: #fffaf1;
    border: 1px solid var(--card-border);
    border-radius: 8px;
    padding: 22px;
}
.post .tag {
    color: var(--accent);
    font-size: 0.8rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin: 0 0 10px;
    font-weight: 700;
}
.post p {
    color: var(--text-main);
    line-height: 1.6;
    margin: 0;
    white-space: pre-wrap;
}

.faq {
    display: grid;
    gap: 0;
    border: 1px solid var(--card-border);
    background: #fffaf1;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 20px;
}
.faq details {
    border-top: 1px solid var(--card-border);
}
.faq details:first-child { border-top: 0; }
.faq summary {
    cursor: pointer;
    list-style: none;
    padding: 16px 18px;
    min-height: 48px;
    display: flex;
    align-items: center;
    font-weight: 650;
    color: var(--primary);
}
.faq summary::-webkit-details-marker { display: none; }
.faq details p {
    margin: 0;
    padding: 0 18px 16px;
    color: var(--text-main);
    line-height: 1.6;
}

.offerings-status {
    margin: 16px 0 0;
    padding: 12px 14px;
    border: 1px solid #a33b22;
    color: var(--accent);
    background: #fffaf1;
    font-size: 14px;
    line-height: 1.5;
    border-radius: 4px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
}

footer {
    text-align: center;
    padding: 40px 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    border-top: 1px solid var(--card-border);
}
footer a {
    color: var(--text-muted);
    text-decoration: none;
}
footer a:hover {
    color: var(--accent);
}

@media (max-width: 600px) {
    nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .nav-links {
        display: flex;
        flex-wrap: wrap;
        row-gap: 8px;
    }
    .nav-links a {
        margin-left: 0;
        margin-right: 16px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }
    header,
    header.hero {
        padding: 40px 16px;
    }
    header h1 {
        font-size: 1.8rem;
    }
    .math-grid,
    .how,
    .row,
    .row-3,
    .compare-grid,
    .vin-row,
    .or-grid {
        grid-template-columns: 1fr;
    }
    .or-divider {
        margin: 0 0 4px;
    }
    .tab-container {
        flex-direction: column;
    }
    .package-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
}
