/* =========================================================================
   CA-Appraiser.com — Design System
   Distinct California identity: deep slate-green + gold + terracotta,
   Fraunces serif display, Inter body. Clean, professional, high-contrast.
   ========================================================================= */

:root {
    /* Brand */
    --slate: #1f3a34;          /* deep slate-green — primary brand */
    --slate-2: #2d4f47;        /* lighter slate for gradients */
    --slate-deep: #152b27;     /* near-black green for dark sections */
    --gold: #c8962a;           /* California gold — primary accent / CTA */
    --gold-deep: #a87a18;      /* gold hover */
    --terracotta: #b5532a;     /* warm secondary accent */
    --sand: #faf7f1;           /* warm off-white background */
    --sand-2: #f1ece1;         /* alt section background */
    --cream-border: #e4ddcd;   /* warm border */

    /* Neutrals */
    --ink: #1c2622;            /* primary text (warm near-black) */
    --ink-soft: #4a564f;       /* secondary text */
    --ink-mute: #76817a;       /* muted text */
    --white: #ffffff;

    /* Semantic */
    --up: #2e7d4f;
    --down: #b5532a;

    /* Type */
    --serif: "Fraunces", Georgia, "Times New Roman", serif;
    --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    --maxw: 1180px;
    --radius: 12px;
    --shadow-sm: 0 1px 2px rgba(28,38,34,.06), 0 4px 14px rgba(28,38,34,.05);
    --shadow-md: 0 2px 6px rgba(28,38,34,.07), 0 14px 40px rgba(28,38,34,.10);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.62;
    color: var(--ink);
    background: var(--sand);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
    font-family: var(--serif);
    font-weight: 600;
    color: var(--slate);
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 .6em;
}
h1 { font-size: 2.45rem; }
h2 { font-size: 1.95rem; }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.12rem; }

p { margin: 0 0 1.1em; }

a { color: var(--terracotta); text-decoration: none; }
a:hover { text-decoration: underline; }

strong { color: var(--ink); }

img { max-width: 100%; display: block; }

.skip-to-content {
    position: absolute; left: -9999px; top: 0;
    background: var(--slate); color: #fff; padding: 10px 16px; z-index: 1000;
}
.skip-to-content:focus { left: 8px; top: 8px; }

/* ---------- Header / Nav ---------- */
.header {
    background: var(--white);
    border-bottom: 1px solid var(--cream-border);
    position: sticky; top: 0; z-index: 100;
}
.header-content {
    max-width: var(--maxw); margin: 0 auto; padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
    min-height: 68px; flex-wrap: wrap;
}
.logo-title {
    font-family: var(--serif); font-weight: 600; font-size: 1.4rem;
    color: var(--slate); margin: 0; letter-spacing: -.02em;
}
.logo-title .dot { color: var(--gold); }
.logo-sub {
    display: block; font-family: var(--sans); font-size: .68rem; font-weight: 600;
    letter-spacing: .14em; text-transform: uppercase; color: var(--ink-mute); margin-top: 2px;
}
.top-nav-inner { display: flex; gap: 4px; align-items: center; }
.top-nav a {
    color: var(--ink-soft); font-size: .94rem; font-weight: 600;
    padding: 8px 12px; border-radius: 6px; letter-spacing: -.01em;
}
.top-nav a:hover { color: var(--slate); background: var(--sand-2); text-decoration: none; }
.top-nav a.active { color: var(--gold-deep); }
.top-nav a.nav-cta {
    background: var(--gold); color: #fff; padding: 9px 18px; border-radius: 8px;
}
.top-nav a.nav-cta:hover { background: var(--gold-deep); color: #fff; }
.mobile-nav-toggle {
    display: none; background: none; border: 1px solid var(--cream-border);
    border-radius: 8px; padding: 8px 12px; font-size: .9rem; font-weight: 600;
    color: var(--slate); cursor: pointer;
}

/* ---------- Hero ---------- */
.hero-banner { position: relative; overflow: hidden; background: var(--slate-deep); }
.hero-image { width: 100%; height: 440px; object-fit: cover; opacity: .55; }
.hero-overlay {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    justify-content: center; align-items: flex-start;
    max-width: var(--maxw); margin: 0 auto; padding: 0 24px;
    background: linear-gradient(90deg, rgba(21,43,39,.82) 0%, rgba(21,43,39,.45) 55%, rgba(21,43,39,.15) 100%);
}
.hero-overlay::after { content: ""; }
.hero-headline {
    color: #fff; font-size: 2.9rem; max-width: 760px; margin: 0 0 .35em;
    text-shadow: 0 2px 18px rgba(0,0,0,.35);
}
.hero-sub {
    color: #f4eede; font-size: 1.18rem; max-width: 640px; margin: 0 0 1.4em; font-weight: 400;
    text-shadow: 0 1px 10px rgba(0,0,0,.4);
}
.cta-button {
    display: inline-block; background: var(--gold); color: #fff !important;
    font-weight: 700; font-size: 1rem; padding: 13px 28px; border-radius: 9px;
    box-shadow: var(--shadow-sm); transition: background .15s, transform .1s;
}
.cta-button:hover { background: var(--gold-deep); text-decoration: none; transform: translateY(-1px); }
.cta-button.alt { background: var(--white); color: var(--slate) !important; }
.cta-button.alt:hover { background: var(--sand-2); }

/* ---------- Layout ---------- */
.page-wrapper { max-width: var(--maxw); margin: 0 auto; padding: 52px 24px 24px; }
.main-content { background: transparent; }
.narrow { max-width: 820px; margin-left: auto; margin-right: auto; }

section + section { margin-top: 8px; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: .85rem; margin-bottom: 24px; }
.breadcrumb ul { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; }
.breadcrumb li::after { content: "›"; margin-left: 8px; color: var(--ink-mute); }
.breadcrumb li:last-child::after { content: ""; }
.breadcrumb a { color: var(--ink-mute); }
.breadcrumb span { color: var(--ink-soft); }

/* ---------- Stats bar ---------- */
.stats-bar {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
    background: var(--slate); border-radius: var(--radius); padding: 30px 24px;
    margin-bottom: 56px; box-shadow: var(--shadow-md);
}
.stat-item { text-align: center; color: #fff; }
.stat-number { display: block; font-family: var(--serif); font-size: 2.3rem; font-weight: 600; color: var(--gold); }
.stat-label { display: block; font-size: .9rem; color: #d8e0dc; letter-spacing: .02em; }

/* ---------- Services grid ---------- */
.services-section { margin-bottom: 60px; text-align: center; }
.services-section > h2 { margin-bottom: 36px; }
.services-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; text-align: left;
}
.service-card {
    background: var(--white); border: 1px solid var(--cream-border); border-radius: var(--radius);
    padding: 26px 24px; box-shadow: var(--shadow-sm); transition: transform .12s, box-shadow .12s;
    display: flex; flex-direction: column;
}
.service-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.service-card-icon {
    width: 46px; height: 46px; border-radius: 10px; background: var(--sand-2);
    color: var(--gold-deep); font-size: 1.5rem; display: flex; align-items: center;
    justify-content: center; margin-bottom: 16px;
}
.service-card h3 { font-size: 1.22rem; margin-bottom: .4em; }
.service-card p { color: var(--ink-soft); font-size: .97rem; margin-bottom: 1em; }
.learn-more { font-weight: 700; font-size: .92rem; color: var(--terracotta); margin-top: auto; }
.learn-more::after { content: " →"; }

/* ---------- CTA banners ---------- */
.cta-banner {
    background: linear-gradient(135deg, var(--slate) 0%, var(--slate-2) 100%);
    border-radius: var(--radius); padding: 46px 40px; text-align: center; margin: 56px 0;
    box-shadow: var(--shadow-md);
}
.cta-banner h2 { color: #fff; }
.cta-banner p { color: #e8ede9; max-width: 680px; margin: 0 auto 1.5em; }
.cta-banner .cta-phone { display: block; margin-top: 16px; font-size: .92rem; color: #cfd8d3; }
.cta-banner .cta-phone a { color: var(--gold); }

/* ---------- Why section ---------- */
.why-section { margin: 60px 0; }
.why-section > h2 { text-align: center; margin-bottom: 36px; }
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.why-item {
    background: var(--white); border: 1px solid var(--cream-border); border-left: 4px solid var(--gold);
    border-radius: 10px; padding: 22px 22px;
}
.why-item strong { display: block; font-family: var(--serif); font-size: 1.12rem; color: var(--slate); margin-bottom: .4em; }
.why-item p { color: var(--ink-soft); font-size: .95rem; margin: 0; }

/* ---------- Generic prose blocks ---------- */
.main-content ul:not(.appraisal-types-list):not(.reset) { padding-left: 1.2em; }
.main-content li { margin-bottom: .4em; }

/* ---------- Pricing (services & fees) ---------- */
.price-tier-group { margin: 14px 0 40px; }
.price-tier-group > h2 { border-bottom: 2px solid var(--cream-border); padding-bottom: 10px; }
.pricing-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 24px; }
.price-card {
    background: var(--white); border: 1px solid var(--cream-border); border-radius: var(--radius);
    padding: 24px 20px; box-shadow: var(--shadow-sm); position: relative; display: flex; flex-direction: column;
}
.price-card.featured { border: 2px solid var(--gold); box-shadow: var(--shadow-md); }
.price-badge {
    position: absolute; top: -12px; left: 20px; background: var(--gold); color: #fff;
    font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
    padding: 4px 12px; border-radius: 999px;
}
.price-amount { font-family: var(--serif); font-size: 2.1rem; font-weight: 600; color: var(--slate); }
.price-card h3 { font-size: 1.2rem; margin: 6px 0 4px; }
.price-degree { font-size: .82rem; color: var(--ink-mute); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 12px; }
.price-card p { font-size: .94rem; color: var(--ink-soft); }
.price-card ul { padding-left: 1.1em; font-size: .9rem; color: var(--ink-soft); margin: 4px 0 0; }
.price-card li { margin-bottom: .3em; }

/* compact pricing summary (area pages) */
.pricing-summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 20px 0; }
.pricing-summary-card {
    background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px; padding: 18px 16px;
    position: relative; box-shadow: var(--shadow-sm);
}
.pricing-summary-card.pricing-summary-featured { border: 2px solid var(--gold); }
.pricing-summary-price { font-family: var(--serif); font-size: 1.7rem; font-weight: 600; color: var(--slate); display: block; }
.pricing-summary-card strong { display: block; margin: 2px 0 6px; color: var(--slate); }
.pricing-summary-card p { font-size: .87rem; color: var(--ink-soft); margin: 0; }
.pricing-summary-badge {
    position: absolute; top: -10px; right: 12px; background: var(--gold); color: #fff;
    font-size: .66rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
    padding: 3px 10px; border-radius: 999px;
}
.pricing-summary-extras { background: var(--sand-2); border-radius: 10px; padding: 14px 20px; margin: 8px 0; }
.pricing-summary-extras p { margin: 4px 0; font-size: .92rem; }

/* add-ons row */
.addon-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 18px; }
.addon-card { background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px; padding: 18px; }
.addon-card .price-amount { font-size: 1.5rem; }

/* ---------- Appraisal types list ---------- */
.appraisal-types-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 24px; }
.appraisal-types-list li { padding-left: 18px; position: relative; }
.appraisal-types-list li::before { content: "▪"; color: var(--gold); position: absolute; left: 0; }

/* ---------- Article section spacing ---------- */
.city-intro-section, .appraisal-types-section, .market-snapshot-section,
.services-pricing-section, .contact-cta-section, .service-detail-section { margin-bottom: 44px; }

/* ---------- Market snapshot ---------- */
.market-metrics-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 18px 0; }
.market-metric {
    background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px;
    padding: 16px; text-align: center;
}
.metric-value { display: block; font-family: var(--serif); font-size: 1.45rem; font-weight: 600; color: var(--slate); }
.metric-value-sm { display: block; font-family: var(--serif); font-size: 1.2rem; font-weight: 600; color: var(--slate); }
.metric-label { display: block; font-size: .8rem; color: var(--ink-mute); margin-top: 2px; }
.trend-up { color: var(--up); font-size: .8rem; font-weight: 600; }
.trend-down { color: var(--down); font-size: .8rem; font-weight: 600; }
.market-metrics-secondary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 16px 0; }
.market-metric-sm { padding: 12px; }
.market-source { font-size: .8rem; color: var(--ink-mute); font-style: italic; }
.chart-explainer { font-size: .9rem; color: var(--ink-soft); }
.market-news-section { background: var(--sand-2); border-radius: 10px; padding: 18px 22px; margin: 18px 0; }
.market-news-section h4 { margin-bottom: 10px; }
.market-news-section ul { padding-left: 1.1em; }
.market-news-section li { font-size: .92rem; color: var(--ink-soft); margin-bottom: 10px; }

/* ---------- Contact / forms ---------- */
.contact-cta-section {
    background: var(--white); border: 1px solid var(--cream-border); border-left: 5px solid var(--gold);
    border-radius: 10px; padding: 26px 28px;
}
.contact-info p { margin: 4px 0; }
.contact-form { max-width: 640px; }
.contact-form label { display: block; font-weight: 600; font-size: .92rem; color: var(--slate); margin: 14px 0 5px; }
.contact-form input, .contact-form select, .contact-form textarea {
    width: 100%; padding: 11px 13px; border: 1px solid #cfd3cb; border-radius: 8px;
    font-family: var(--sans); font-size: 1rem; background: var(--white); color: var(--ink);
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
    outline: 2px solid var(--gold); border-color: var(--gold);
}
.contact-form button {
    margin-top: 20px; background: var(--gold); color: #fff; border: none; border-radius: 9px;
    padding: 13px 34px; font-size: 1.02rem; font-weight: 700; cursor: pointer; transition: background .15s;
}
.contact-form button:hover { background: var(--gold-deep); }
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: start; }
.contact-aside { background: var(--white); border: 1px solid var(--cream-border); border-radius: var(--radius); padding: 24px; }

/* ---------- Service area page ---------- */
.county-block { margin-bottom: 40px; }
.county-block h2 { border-bottom: 2px solid var(--cream-border); padding-bottom: 8px; }
.county-meta { font-size: .9rem; color: var(--ink-mute); font-weight: 600; }
.area-links { list-style: none; padding: 0; columns: 4; column-gap: 24px; margin-top: 14px; }
.area-links li { margin-bottom: 7px; break-inside: avoid; }
.area-links a { color: var(--terracotta); font-weight: 500; font-size: .96rem; }

/* ---------- FAQ ---------- */
.faq-item { background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px; padding: 20px 24px; margin-bottom: 14px; }
.faq-item h3 { font-size: 1.15rem; margin-bottom: .4em; }
.faq-item p { color: var(--ink-soft); margin: 0; }

/* ---------- Reviews ---------- */
.reviews-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.review-card { background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px; padding: 22px 24px; box-shadow: var(--shadow-sm); }
.review-stars { color: var(--gold); letter-spacing: 2px; margin-bottom: 8px; }
.review-card p { font-style: italic; color: var(--ink-soft); }
.review-author { font-weight: 700; color: var(--slate); font-style: normal; font-size: .92rem; }

/* ---------- Blog ---------- */
.blog-list { display: grid; gap: 18px; }
.blog-entry { background: var(--white); border: 1px solid var(--cream-border); border-radius: 10px; padding: 22px 26px; box-shadow: var(--shadow-sm); }
.blog-entry h3 { margin-bottom: .3em; }
.blog-meta { font-size: .82rem; color: var(--ink-mute); margin-bottom: 10px; }

/* ---------- Callout ---------- */
.callout { background: var(--sand-2); border-left: 4px solid var(--terracotta); border-radius: 8px; padding: 16px 20px; margin: 18px 0; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Footer ---------- */
.footer { background: var(--slate-deep); color: #cdd6d1; margin-top: 64px; }
.footer-content {
    max-width: var(--maxw); margin: 0 auto; padding: 46px 24px 26px;
    display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px;
}
.footer h4 { color: #fff; font-size: 1.15rem; margin-bottom: 12px; }
.footer p { font-size: .92rem; color: #aebbb4; margin: 4px 0; }
.footer a { color: #e6c98a; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer ul li { margin-bottom: 8px; }
.footer ul a { color: #cdd6d1; font-size: .92rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); }
.footer-bottom p { max-width: var(--maxw); margin: 0 auto; padding: 18px 24px; font-size: .82rem; color: #8b988f; }

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
    .services-grid, .why-grid { grid-template-columns: repeat(2, 1fr); }
    .pricing-cards, .pricing-summary-grid, .market-metrics-grid, .market-metrics-secondary { grid-template-columns: repeat(2, 1fr); }
    .area-links { columns: 2; }
    .contact-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
    body { font-size: 16px; }
    h1 { font-size: 1.95rem; }
    h2 { font-size: 1.6rem; }
    .hero-headline { font-size: 1.95rem; }
    .hero-image { height: 360px; }
    .mobile-nav-toggle { display: block; }
    .top-nav { display: none; width: 100%; }
    .top-nav.open { display: block; }
    .top-nav-inner { flex-direction: column; align-items: stretch; padding: 10px 0; }
    .top-nav a { padding: 11px 8px; }
    .stats-bar { grid-template-columns: 1fr; gap: 22px; }
    .services-grid, .why-grid, .pricing-cards, .pricing-summary-grid,
    .addon-grid, .market-metrics-grid, .market-metrics-secondary, .reviews-grid { grid-template-columns: 1fr; }
    .area-links { columns: 1; }
    .appraisal-types-list { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; }
    .page-wrapper { padding-top: 36px; }
}
