/* Agency public site. Each agency's brand colour arrives as --agency-color (PreviewBanner's head block); until it sets
   one the fallback is a neutral slate, never our own brand (white label). */
:root {
    --agency-color: #2F4858;
    --agency-text: #FFFFFF;
    --text: #1F2933;
    --bg: #F3F5F8;
    --card: #fff;
    --muted: #6B7785;
    --line: #E3E8EF;
    --radius: 14px;
    --shadow: 0 6px 24px rgba(15, 30, 50, .08);
    --shadow-lg: 0 18px 50px rgba(15, 30, 50, .18);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: "Montserrat", "Segoe UI", Arial, sans-serif;
    line-height: 1.5;
}

a { color: var(--agency-color); }
.site { min-height: 100vh; display: flex; flex-direction: column; }

/* Icons (inline SVG) */
.icon { width: 1.15em; height: 1.15em; fill: currentColor; vertical-align: -.2em; flex: none; }
.icon.big { width: 48px; height: 48px; }

/* ---- Top bar ---- */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar-inner { max-width: 1200px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 700; font-size: 1.1rem; min-width: 0; }
.brand span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 320px; }
.brand .agency-logo { max-height: 40px; max-width: 140px; margin: 0; padding: 0; background: none; border-radius: 0; }
.topnav { display: flex; gap: 2px; margin-left: auto; flex-wrap: nowrap; }
.topnav a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: .9rem; font-weight: 600; }
.topnav a .icon { color: var(--agency-color); }
.topnav a:hover, .topnav a.active { background: color-mix(in srgb, var(--agency-color) 10%, #fff); }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.call { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); font-weight: 600; font-size: .9rem; }
.call .icon { color: var(--agency-color); width: 22px; height: 22px; }
.call small { display: block; color: var(--muted); font-weight: 500; font-size: .72rem; line-height: 1; }
.btn-outline { display: inline-flex; align-items: center; gap: 6px; border: 1.5px solid var(--agency-color); color: var(--agency-color); padding: 7px 12px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: .85rem; white-space: nowrap; }
.btn-outline:hover { background: var(--agency-color); color: var(--agency-text); }
@media (max-width: 1180px) { .topnav { display: none; } .topbar-actions { margin-left: auto; } }
@media (max-width: 640px) { .call span { display: none; } }

/* ---- Hero (banner) with the search panel ---- */
.hero {
    position: relative;
    background: radial-gradient(1200px 400px at 85% -10%, color-mix(in srgb, var(--agency-color) 55%, #fff) 0%, transparent 60%),
                linear-gradient(135deg, var(--agency-color), color-mix(in srgb, var(--agency-color) 55%, #000));
    background-size: cover; background-position: center;
    color: #fff;
    padding: 56px 16px 72px;
}
.hero.has-image { background-size: cover; background-position: center; }
.hero.compact { padding: 24px 16px 40px; }
.hero.thin { padding: 0; height: 90px; }
.hero-inner { max-width: 1100px; margin: 0 auto; }
.hero h1 { margin: 0 0 6px; font-size: clamp(1.8rem, 4.5vw, 3rem); font-weight: 700; text-shadow: 0 2px 16px rgba(0,0,0,.25); }
.hero-sub { margin: 0 0 24px; font-size: 1.05rem; opacity: .95; max-width: 640px; }

.search-panel { background: #fff; color: var(--text); border-radius: var(--radius); box-shadow: var(--shadow-lg); overflow: hidden; }
.search-tabs { display: flex; overflow-x: auto; border-bottom: 1px solid var(--line); background: #FAFBFC; }
.search-tabs a { flex: 1; min-width: 92px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 8px 12px; color: var(--muted); text-decoration: none; font-weight: 600; font-size: .85rem; border-bottom: 3px solid transparent; }
.search-tabs a .icon { width: 26px; height: 26px; }
.search-tabs a:hover { color: var(--agency-color); background: #fff; }
.search-tabs a.active { color: var(--agency-color); border-bottom-color: var(--agency-color); background: #fff; }
.search-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; padding: 18px; align-items: end; }
.search-fields .field { display: flex; flex-direction: column; gap: 6px; margin: 0; font-size: .8rem; font-weight: 600; color: var(--muted); }
.search-fields .field span { display: flex; align-items: center; gap: 6px; text-transform: uppercase; letter-spacing: .03em; }
.search-fields .field .icon { color: var(--agency-color); }
.search-fields select, .search-fields input { margin: 0; height: 48px; font-size: 1rem; }
.search-btn { height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 10px; background: var(--agency-color); color: var(--agency-text); font: inherit; font-weight: 700; font-size: 1rem; cursor: pointer; padding: 0 22px; }
.search-btn:hover { filter: brightness(1.08); }

/* ---- Page sections ---- */
.page { width: 100%; max-width: 1200px; margin: 0 auto; padding: 28px 16px 40px; flex: 1; }
.section { margin: 8px 0 36px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.section-head h2 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 1.4rem; }
.section-head h2 .icon { color: var(--agency-color); }
.section-head a { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; text-decoration: none; }

.offer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 16px; }
.offer-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; display: flex; flex-direction: column; gap: 6px; border: 1px solid transparent; transition: transform .15s, box-shadow .15s, border-color .15s; }
.offer-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--agency-color) 30%, #fff); }
.offer-card-top { display: flex; justify-content: space-between; align-items: center; }
.kind-badge { display: inline-flex; align-items: center; gap: 6px; background: color-mix(in srgb, var(--agency-color) 10%, #fff); color: var(--agency-color); font-weight: 700; font-size: .78rem; padding: 4px 10px; border-radius: 999px; }
.sample-pill { background: #FFF4D6; color: #7a5b00; font-weight: 700; font-size: .7rem; padding: 3px 8px; border-radius: 999px; letter-spacing: .04em; }
.offer-card h3 { margin: 6px 0 2px; font-size: 1.05rem; line-height: 1.3; }
.offer-card p { margin: 0; display: flex; align-items: center; gap: 6px; }
.offer-card .route .icon, .offer-card .when .icon { color: var(--muted); }
.offer-card-foot { margin-top: auto; padding-top: 12px; border-top: 1px dashed var(--line); display: flex; justify-content: space-between; align-items: center; }
.offer-card-foot strong { display: block; font-size: 1.3rem; color: var(--text); }
.offer-card-foot small { color: var(--muted); font-size: .78rem; }

.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.tile { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px 16px; text-decoration: none; color: var(--text); display: flex; flex-direction: column; gap: 6px; transition: transform .15s, box-shadow .15s; }
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.tile-icon, .step-icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in srgb, var(--agency-color) 12%, #fff); color: var(--agency-color); margin-bottom: 6px; }
.tile-icon .icon, .step-icon .icon { width: 28px; height: 28px; }
.tile span:last-child { color: var(--muted); font-size: .85rem; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }
.step { display: flex; flex-direction: column; gap: 4px; }
.step span:last-child { color: var(--muted); font-size: .9rem; }

.request { display: grid; grid-template-columns: 1fr 1.2fr; gap: 24px; align-items: start; }
.request-intro h2 { display: flex; align-items: center; gap: 10px; margin-top: 0; }
.request-intro h2 .icon { color: var(--agency-color); }
.checks { list-style: none; padding: 0; }
.checks li { display: flex; align-items: center; gap: 8px; margin: 6px 0; }
.checks .icon { color: #1A7F37; }
@media (max-width: 800px) { .request { grid-template-columns: 1fr; } }

/* ---- Cards and forms (also offer, quote and sign-in pages) ---- */
.card { background: var(--card); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.card h2 { margin-top: 0; font-size: 1.3rem; }
.card.empty, .card.thanks { text-align: center; }
.card.empty .icon.big { color: var(--muted); }
.ok-icon { color: #1A7F37; }
.site-main { width: 100%; max-width: 680px; margin: -60px auto 32px; padding: 0 16px; flex: 1; position: relative; }
.site-main.narrow { max-width: 420px; margin-top: 48px; }
.site-main .card + .card { margin-top: 12px; }
label { display: block; font-weight: 600; margin: 14px 0 4px; font-size: .92rem; }
input, select, textarea {
    width: 100%; padding: 11px 12px; border: 1px solid #D5DCE4; border-radius: 10px;
    font: inherit; font-size: 1rem; background: #fff; color: var(--text);
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--agency-color); outline-offset: 1px; border-color: transparent; }
button[type=submit] {
    margin-top: 20px; width: 100%; padding: 13px; border: 0; border-radius: 10px;
    background: var(--agency-color); color: var(--agency-text); font: inherit; font-weight: 700; cursor: pointer;
}
button[type=submit]:hover { filter: brightness(1.08); }
.search-fields button[type=submit] { margin-top: 0; width: auto; }
.errors, .validation-message { color: #C62828; font-size: .9rem; }
.btn { display: inline-flex; align-items: center; gap: 6px; background: var(--agency-color); color: var(--agency-text); text-decoration: none; padding: 9px 16px; border-radius: 10px; font-weight: 700; }
.btn:hover { filter: brightness(1.08); }
.muted { color: var(--muted); font-size: .9rem; }
.small { font-size: .82rem; }
.center { text-align: center; }
.ok { color: #1A7F37; font-weight: 600; }
.sample-flag { background: #FFF4D6; color: #7a5b00; padding: 8px 12px; border-radius: 8px; font-weight: 600; font-size: .9rem; }
.preview-banner { background: #FFF4D6; color: #7a5b00; text-align: center; padding: 8px 16px; font-weight: 600; font-size: .9rem; }
.quote-lines { width: 100%; border-collapse: collapse; margin: 12px 0; }
.quote-lines td { padding: 8px 0; border-bottom: 1px solid #eee; }
.quote-lines td:last-child { text-align: right; white-space: nowrap; }
.quote-lines tr.total td { font-weight: 700; border-bottom: 0; font-size: 1.1rem; }
.agency-logo { max-height: 72px; max-width: 220px; display: block; margin: 0 auto 12px; background: #fff; padding: 6px 10px; border-radius: 8px; }

/* ---- Footer ---- */
.site-foot { background: #111A24; color: #C9D2DC; margin-top: auto; }
.site-foot-inner { max-width: 1200px; margin: 0 auto; padding: 36px 16px; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 24px; font-size: .9rem; }
.site-foot strong { color: #fff; display: block; margin-bottom: 8px; }
.site-foot ul { list-style: none; padding: 0; margin: 0; }
.site-foot li { margin: 6px 0; }
.site-foot a { color: #C9D2DC; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.site-foot a:hover { color: #fff; }
.site-foot .agency-details { text-align: left; color: #9AA6B2; margin-top: 8px; }
.site-foot .agency-details p { margin: 4px 0; }
.licence { font-size: .8rem; }
@media (max-width: 800px) { .site-foot-inner { grid-template-columns: 1fr; } }
.wa-fab { position: fixed; right: 18px; bottom: 18px; width: 56px; height: 56px; border-radius: 50%; background: #25D366; color: #fff; display: grid; place-items: center; box-shadow: var(--shadow-lg); z-index: 30; }
.wa-fab .icon { width: 30px; height: 30px; }

/* Legacy pieces still used by some pages */
.contact-buttons { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }
.btn-light { display: inline-block; padding: 8px 14px; border-radius: 999px; background: rgba(255,255,255,.15); color: inherit; text-decoration: none; font-weight: 600; font-size: .9rem; border: 1px solid rgba(255,255,255,.4); }
.agency-details { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 20px; }
