/* =================================================================
   Dubai Luxe — Professional PWA theme
   Design tokens first. Mobile-first. Gold = accent, not dominant.
   ================================================================= */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Fraunces:opsz,wght@9..144,500;9..144,600&display=swap");

:root {
    /* Surfaces */
    --bg: #0a0a0b;
    --surface: #131316;
    --surface-2: #1a1a1e;
    --surface-3: #232328;

    /* Borders */
    --border: rgba(255, 255, 255, 0.06);
    --border-strong: rgba(255, 255, 255, 0.1);

    /* Text */
    --text: #fafafa;
    --text-2: #a4a4ad;
    --text-3: #6b6b73;

    /* Gold accent (used sparingly) */
    --gold: #c9a55c;
    --gold-bright: #e8c878;
    --gold-soft: rgba(201, 165, 92, 0.08);
    --gold-line: rgba(201, 165, 92, 0.22);

    /* Status */
    --success: #4ade80;
    --warning: #fbbf24;
    --danger: #ef4444;
    --info: #60a5fa;

    /* Spacing — 4px base */
    --s-1: 4px;
    --s-2: 8px;
    --s-3: 12px;
    --s-4: 16px;
    --s-5: 20px;
    --s-6: 24px;
    --s-7: 32px;
    --s-8: 48px;

    /* Radius */
    --r-1: 6px;
    --r-2: 10px;
    --r-3: 14px;
    --r-4: 20px;
    --r-5: 28px;

    /* Shadows */
    --sh-1: 0 1px 2px rgba(0, 0, 0, 0.4);
    --sh-2: 0 4px 12px rgba(0, 0, 0, 0.35);
    --sh-3: 0 12px 32px rgba(0, 0, 0, 0.45);
    --sh-gold: 0 8px 24px rgba(201, 165, 92, 0.18);

    /* Type */
    --font-sans:
        "Inter", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    --font-serif: "Fraunces", Georgia, serif;

    /* Motion */
    --ease: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);

    /* Layout */
    --header-h: 60px;
    --search-h: 56px;
    --chips-h: 36px;
    --carousel-h: 240px;
}

/* =============================================================
       LIGHT THEME
       ============================================================= */
[data-theme="light"] {
    --bg: #fafaf9;
    --surface: #ffffff;
    --surface-2: #f3f3f1;
    --surface-3: #e8e8e5;
    --border: rgba(0, 0, 0, 0.07);
    --border-strong: rgba(0, 0, 0, 0.12);
    --text: #0a0a0b;
    --text-2: #54545a;
    --text-3: #8a8a90;
    --gold: #b08838;
    --gold-bright: #a07a2e;
    --gold-soft: rgba(176, 136, 56, 0.1);
    --gold-line: rgba(176, 136, 56, 0.28);
    --sh-1: 0 1px 2px rgba(0, 0, 0, 0.05);
    --sh-2: 0 2px 8px rgba(0, 0, 0, 0.06);
    --sh-3: 0 12px 28px rgba(0, 0, 0, 0.1);
    --sh-gold: 0 6px 20px rgba(176, 136, 56, 0.18);
    --topbar-grad-top: rgba(250, 250, 249, 0.9);
    --topbar-grad-bot: rgba(250, 250, 249, 0);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}
html,
body {
    height: 100%;
    min-height: 100dvh;
    overflow: hidden;
    overscroll-behavior: none;
}
body {
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.5;
    color: var(--text);
    background: var(--bg);
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}
input {
    font-family: inherit;
}
a {
    color: inherit;
    text-decoration: none;
}
img {
    display: block;
    max-width: 100%;
}
[hidden] {
    display: none !important;
}

/* hide native scrollbars inside the app */
.app *::-webkit-scrollbar {
    display: none;
}
.app * {
    scrollbar-width: none;
}

/* ---------- App shell ---------- */
.app {
    position: relative;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 100dvh;
    overflow: hidden;
    background: var(--bg);
    isolation: isolate;
}

/* =================================================================
   MAP
   ================================================================= */
.map {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: #0a0a0b;
}

/* ---------- Map Control Buttons ---------- */
.map-controls {
    display: none !important;
}

.control-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 40px;
    min-width: 40px;
    padding: 0 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--sh-2);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition:
        background 0.2s var(--ease),
        border-color 0.2s var(--ease),
        color 0.2s var(--ease),
        box-shadow 0.2s var(--ease),
        transform 0.16s var(--ease-out);
}

.control-btn:hover {
    background: var(--surface-2);
    border-color: var(--border-strong);
    color: var(--text);
}

.control-btn.active {
    background: var(--gold-soft);
    border-color: var(--gold);
    color: var(--gold-bright);
    box-shadow: var(--sh-gold);
}

.control-icon-3d {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    transition: background-color 0.2s var(--ease);
}

/* Override Mapbox controls to match theme */
.mapboxgl-ctrl-group {
    background: var(--surface) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--r-2) !important;
    box-shadow: var(--sh-2) !important;
}

.mapboxgl-ctrl-group button {
    width: 40px !important;
    height: 40px !important;
    border-bottom: 1px solid var(--border) !important;
}

.mapboxgl-ctrl-group button:last-child {
    border-bottom: none !important;
}

.mapboxgl-ctrl-group button span {
    filter: invert(1) !important; /* Invert mapbox icons for dark mode */
}

/* Hide the default Mapbox NavigationControl — the custom map-controls panel
   owns zoom and 3D toggles. */
.mapboxgl-ctrl-top-right .mapboxgl-ctrl-group:not(.mapboxgl-ctrl-attrib) {
    display: none !important;
}

/* Attributions */
.mapboxgl-ctrl-attrib {
    background: rgba(10, 10, 11, 0.7) !important;
    color: var(--text-3) !important;
    font-family: var(--font-sans) !important;
    font-size: 10px !important;
    border-radius: 4px !important;
    padding: 2px 6px !important;
    backdrop-filter: blur(8px);
}

.mapboxgl-ctrl-attrib a {
    color: var(--text-2) !important;
}

/* ---------- Pin marker ---------- */
.pin {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 22px;
    padding: 0 8px;
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1px;
    cursor: pointer;
    white-space: nowrap;
    transform: translateY(-5px);
    transition:
        transform 0.18s var(--ease),
        border-color 0.18s var(--ease),
        background 0.18s var(--ease);
    box-shadow: var(--sh-2);
}
.pin::before {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -5px;
    width: 8px;
    height: 8px;
    background: inherit;
    border-right: 1px solid var(--border-strong);
    border-bottom: 1px solid var(--border-strong);
    transform: translateX(-50%) rotate(45deg);
}
.pin:hover {
    transform: translateY(-9px) scale(1.05);
    border-color: var(--gold-line);
}
.pin.is-active {
    border-color: var(--gold);
    background: var(--gold-soft);
}
.pin .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 6px var(--success);
}
.pin[data-status="recent"] .dot {
    background: var(--info);
    box-shadow: 0 0 6px var(--info);
}
.pin[data-status="hot"] .dot {
    background: var(--warning);
    box-shadow: 0 0 6px var(--warning);
}
.pin[data-status="sold"] {
    opacity: 0.7;
    text-decoration: line-through;
}
.pin[data-status="sold"] .dot {
    background: var(--text-3);
    box-shadow: none;
}

/* Cluster — always shows count + price range (never a single fixed price) */
.cluster-pin-container {
    position: relative;
}
.cluster {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-width: 72px;
    max-width: 128px;
    padding: 7px 12px 8px;
    border-radius: 16px;
    background: rgba(19, 19, 22, 0.94);
    border: 1px solid var(--gold-line);
    color: var(--text);
    font-family: var(--font-sans);
    font-weight: 600;
    box-shadow: var(--sh-2);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    cursor: pointer;
    transform: translateY(-3px);
    transition:
        transform 0.18s var(--ease),
        border-color 0.18s var(--ease),
        box-shadow 0.18s var(--ease);
    animation: clusterEnter 0.24s var(--ease-out) both;
}
.cluster::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -5px;
    width: 9px;
    height: 9px;
    background: inherit;
    border-right: 1px solid var(--gold-line);
    border-bottom: 1px solid var(--gold-line);
    transform: translateX(-50%) rotate(45deg);
}
.cluster:hover {
    transform: translateY(-6px) scale(1.03);
    border-color: var(--gold);
    box-shadow: var(--sh-gold);
}
.cluster-sm { min-width: 68px; }
.cluster-md {
    min-width: 84px;
    padding: 8px 13px 9px;
}
.cluster-lg {
    min-width: 96px;
    padding: 9px 14px 10px;
    border-width: 1.5px;
    box-shadow: var(--sh-gold);
}
.cluster-count {
    font-size: 11px;
    font-weight: 700;
    color: var(--gold-bright);
    letter-spacing: 0.4px;
}
.cluster-lg .cluster-count { font-size: 12px; }
.cluster-range {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-2);
    white-space: nowrap;
}
.cluster-range.empty {
    color: var(--text-3);
}

.area-location-cluster {
    align-items: flex-start;
    min-width: 150px;
    border-style: dashed;
}

.area-location-cluster small {
    display: block;
    color: var(--text-3);
    font-size: 8px;
    line-height: 1.25;
    text-align: left;
}

@keyframes clusterEnter {
    from { opacity: 0; transform: translateY(2px) scale(0.95); }
    to { opacity: 1; transform: translateY(-3px) scale(1); }
}

/* =================================================================
   TOP BAR
   ================================================================= */
.topbar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 5;
    height: var(--header-h);
    padding: 0 var(--s-4);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-3);
    background: linear-gradient(
        180deg,
        var(--topbar-grad-top, rgba(10, 10, 11, 0.85)),
        var(--topbar-grad-bot, rgba(10, 10, 11, 0))
    );
    pointer-events: none;
}
.topbar > * {
    pointer-events: auto;
}

.brand {
    display: flex;
    align-items: center;
    gap: var(--s-3);
}
.brand-mark {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    font-family: var(--font-serif);
    font-weight: 600;
    font-size: 18px;
    color: var(--gold-bright);
    line-height: 1;
}
.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}
.brand-name {
    font-weight: 600;
    font-size: 14px;
    letter-spacing: -0.1px;
}
.brand-tag {
    font-size: 10px;
    color: var(--text-3);
    letter-spacing: 0.4px;
    text-transform: uppercase;
    margin-top: 1px;
}

.topbar-actions {
    display: flex;
    gap: var(--s-2);
}

.demo-status {
    align-self: center;
    padding: 5px 8px;
    border: 1px solid var(--gold-line);
    border-radius: 999px;
    color: var(--gold-bright);
    background: var(--gold-soft);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.8px;
}

.showcase-link {
    align-self: center;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 9px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    color: var(--text-2);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.3px;
    transition: border-color .2s var(--ease), color .2s var(--ease), background .2s var(--ease);
}
.showcase-link:hover { color: var(--gold-bright); border-color: var(--gold-line); background: var(--gold-soft); }

/* Theme icon: show sun in dark, moon in light */
.icon-sun,
.icon-moon {
    transition: opacity 0.2s var(--ease);
}
[data-theme="dark"] .icon-moon {
    display: none;
}
[data-theme="light"] .icon-sun {
    display: none;
}
.icon-btn {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-2);
    transition:
        background 0.15s var(--ease),
        color 0.15s var(--ease);
}
.icon-btn:hover {
    background: var(--surface-2);
    color: var(--text);
}
.boundary-toggle {
    position: relative;
}
.boundary-toggle.active,
.boundary-toggle[aria-pressed="true"] {
    background: var(--gold-soft);
    border-color: var(--gold-line);
    color: var(--gold-bright);
}
.assistant-trigger {
    position: relative;
}
.assistant-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 15px;
    height: 15px;
    padding: 0 4px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--gold);
    color: #0a0a0b;
    border: 2px solid var(--bg);
    font-size: 9px;
    font-weight: 700;
}

/* =================================================================
   SEARCH
   ================================================================= */
.search {
    position: absolute;
    top: auto;
    bottom: calc(var(--s-4) + env(safe-area-inset-bottom));
    left: var(--s-4);
    right: var(--s-4);
    z-index: 7;
    height: var(--search-h);
    display: flex;
    align-items: center;
    gap: var(--s-3);
    padding: 0 var(--s-4);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 60%),
        var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    box-shadow:
        0 16px 44px rgba(0, 0, 0, 0.36),
        0 0 0 1px rgba(201, 165, 92, 0.04) inset;
    transition:
        opacity 0.22s var(--ease),
        transform 0.28s var(--ease-out);
}
.app.results-open .search {
    opacity: 0;
    pointer-events: none;
    transform: translateY(calc(100% + var(--s-5)));
}
.search-icon {
    color: var(--text-3);
    flex-shrink: 0;
}
.search input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    color: var(--text);
    font-size: 14px;
}
.search input::placeholder {
    color: var(--text-3);
}
.search-voice {
    position: relative;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(201, 165, 92, 0.08);
    border: 1px solid rgba(201, 165, 92, 0.22);
    color: var(--gold-bright);
    flex-shrink: 0;
    transition: background 0.15s var(--ease), color 0.15s var(--ease), transform 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.search-voice:hover {
    background: var(--gold-soft);
    color: var(--gold-bright);
    transform: scale(1.05);
    box-shadow: 0 0 0 4px rgba(201, 165, 92, 0.10);
}
.search-voice.is-active {
    color: var(--gold-bright);
    background: var(--gold-soft);
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(201, 165, 92, 0.14);
    animation: voiceBtnPulse 1.6s ease-in-out infinite;
}
@keyframes voiceBtnPulse {
    0%, 100% { box-shadow: 0 0 0 4px rgba(201, 165, 92, 0.14); }
    50% { box-shadow: 0 0 0 10px rgba(201, 165, 92, 0.04); }
}
.search-submit {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--gold);
    color: #0a0a0b;
    flex-shrink: 0;
    transition: background 0.15s var(--ease), transform 0.15s var(--ease);
}
.search-submit:hover {
    background: var(--gold-bright);
    transform: translateX(1px);
}
.search-filter {
    height: 36px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0 10px;
    border-radius: 999px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text-3);
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
    transition:
        color 0.15s,
        background 0.15s,
        border-color 0.15s;
}
.search-filter:hover {
    color: var(--gold-bright);
    background: var(--gold-soft);
    border-color: var(--gold-line);
}
.search-filter b {
    min-width: 18px;
    height: 18px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--gold);
    color: #0a0a0b;
    font-size: 10px;
    line-height: 1;
}

/* Persistent AI conversation — the same thread controls map + filters. */
.ai-chat-panel {
    position: fixed;
    top: calc(var(--header-h) + 14px);
    right: 16px;
    z-index: 24;
    display: flex;
    flex-direction: column;
    width: min(390px, calc(100vw - 32px));
    max-height: min(650px, calc(100vh - var(--header-h) - 110px));
    overflow: hidden;
    border: 1px solid rgba(201,165,92,.24);
    border-radius: 20px;
    background: linear-gradient(155deg, rgba(24,24,27,.98), rgba(10,10,12,.98));
    box-shadow: 0 24px 70px rgba(0,0,0,.48);
    backdrop-filter: blur(22px);
}
.ai-chat-panel[hidden] { display: none; }
.app.chat-open .search { border-color: var(--gold-line); }
.ai-chat-head { display: flex; align-items: center; justify-content: space-between; padding: 15px 16px 12px; border-bottom: 1px solid rgba(255,255,255,.07); }
.ai-chat-identity { display: flex; align-items: center; gap: 10px; }
.ai-chat-identity > span { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 50%; background: var(--gold); color: #17130c; font-size: 13px; }
.ai-chat-identity div { display: flex; flex-direction: column; gap: 2px; }
.ai-chat-identity b { color: var(--text); font-size: 12px; }
.ai-chat-identity small { color: var(--text-3); font-size: 9px; }
.ai-chat-close { width: 28px; height: 28px; border: 0; border-radius: 50%; background: rgba(255,255,255,.06); color: var(--text-2); cursor: pointer; }
.ai-chat-context { display: flex; align-items: center; gap: 8px; padding: 9px 16px; border-bottom: 1px solid rgba(255,255,255,.06); background: rgba(201,165,92,.055); }
.ai-chat-context span { padding: 3px 6px; border-radius: 999px; background: rgba(201,165,92,.13); color: var(--gold-bright); font-size: 8px; font-weight: 800; letter-spacing: .08em; }
.ai-chat-context b { overflow: hidden; color: var(--text-2); font-size: 9px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.ai-chat-messages { min-height: 180px; overflow-y: auto; padding: 15px 14px; display: flex; flex-direction: column; gap: 12px; scrollbar-width: thin; }
.ai-chat-message { display: flex; align-items: flex-end; gap: 8px; max-width: 92%; }
.ai-chat-message.user { align-self: flex-end; flex-direction: row-reverse; }
.ai-chat-message > div { padding: 10px 12px; border: 1px solid rgba(255,255,255,.075); border-radius: 14px 14px 14px 4px; background: rgba(255,255,255,.045); }
.ai-chat-message.user > div { border-color: rgba(201,165,92,.22); border-radius: 14px 14px 4px 14px; background: rgba(201,165,92,.13); }
.ai-chat-message p { color: #e9e5dd; font-size: 12px; line-height: 1.5; white-space: pre-line; }
.ai-chat-message small { display: block; margin-top: 6px; color: #77736c; font-size: 8px; }
.ai-chat-avatar { width: 23px; height: 23px; flex: 0 0 23px; display: grid; place-items: center; border-radius: 50%; background: rgba(201,165,92,.15); color: var(--gold-bright); font-size: 9px; }
.ai-chat-message.user .ai-chat-avatar { background: rgba(255,255,255,.08); color: var(--text-2); }
.ai-chat-message.is-thinking p { color: var(--text-3); }
.ai-chat-message.is-thinking p::after { content: ""; display: inline-block; width: 16px; height: 4px; margin-left: 7px; background: radial-gradient(circle, var(--gold) 2px, transparent 3px) 0 0/8px 4px; animation: aiThinking .8s linear infinite; }
@keyframes aiThinking { to { background-position: 8px 0; } }
.ai-chat-actions { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.ai-chat-actions span, .ai-chat-actions button { padding: 4px 7px; border: 1px solid rgba(201,165,92,.18); border-radius: 999px; background: rgba(201,165,92,.07); color: #d5c092; font-size: 8px; }
.ai-chat-actions button { cursor: pointer; }
.ai-chat-suggestions { display: flex; gap: 6px; overflow-x: auto; padding: 0 14px 10px; scrollbar-width: none; }
.ai-chat-suggestions button { flex: 0 0 auto; padding: 6px 9px; border: 1px solid rgba(255,255,255,.08); border-radius: 999px; background: rgba(255,255,255,.035); color: var(--text-3); font-size: 9px; cursor: pointer; }
.ai-chat-composer { display: flex; align-items: center; gap: 7px; margin: 0 12px 10px; padding: 7px 7px 7px 11px; border: 1px solid rgba(255,255,255,.10); border-radius: 14px; background: rgba(255,255,255,.045); }
.ai-chat-composer:focus-within { border-color: var(--gold-line); }
.ai-chat-composer input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 12px; }
.ai-chat-mic, .ai-chat-send { width: 28px; height: 28px; flex: 0 0 28px; border: 0; border-radius: 50%; cursor: pointer; }
.ai-chat-mic { background: rgba(255,255,255,.06); color: var(--gold-bright); }
.ai-chat-send { background: var(--gold); color: #17130c; font-size: 15px; font-weight: 800; }
.ai-chat-foot { padding: 0 14px 11px; color: #66625d; font-size: 8px; text-align: center; }
@media (max-width: 700px) {
    .ai-chat-panel { top: auto; right: 8px; bottom: 76px; width: calc(100vw - 16px); max-height: 64vh; border-radius: 18px; }
    .ai-chat-messages { min-height: 150px; }
}

/* =================================================================
   MAP FILTER CONTEXT
   ================================================================= */
.filter-chips {
    position: absolute;
    top: calc(var(--header-h) + var(--s-2));
    left: var(--s-4);
    right: var(--s-4);
    z-index: 6;
    display: flex;
    align-items: center;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 2px;
    scrollbar-width: none;
    transition:
        opacity 0.18s var(--ease),
        transform 0.24s var(--ease-out);
}
.filter-chips[hidden] {
    display: none;
}

.building-demo-hint {
    display: none !important;
    position: absolute;
    right: clamp(16px, 4vw, 56px);
    bottom: 86px;
    z-index: 7;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    max-width: calc(100% - 32px);
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: rgba(16, 17, 20, 0.9);
    color: var(--text-2);
    box-shadow: var(--sh-2);
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.18s ease-out, transform 0.18s ease-out, border-color 0.18s ease-out;
    pointer-events: none;
}

.map-ready .building-demo-hint {
    opacity: 1;
    transform: translateY(0);
}

.building-demo-hint.ready,
.building-demo-hint.selected {
    border-color: var(--gold-line);
}

.building-demo-hint span {
    padding: 3px 6px;
    border-radius: 999px;
    background: var(--gold-soft);
    color: var(--gold-bright);
    font-size: 8px;
    font-weight: 800;
}

.building-demo-hint b {
    flex: 1 1 160px;
    min-width: 0;
    overflow: hidden;
    font-size: 10px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.building-coverage {
    flex: 0 0 100%;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.building-coverage b,
.building-coverage small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.building-coverage b {
    color: var(--text-2);
    font-size: 9px;
    font-weight: 700;
}

.building-coverage small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 8px;
}

.building-marker-container {
    pointer-events: auto;
}

.building-marker,
.building-cluster {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 44px;
    max-width: 190px;
    padding: 6px 8px;
    border: 1px solid rgba(201, 165, 92, 0.42);
    border-radius: 10px;
    background: rgba(14, 15, 18, 0.92);
    color: var(--text);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(12px);
    cursor: pointer;
    transform: translateY(-5px);
    transition: transform var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease), background var(--motion-fast) var(--ease);
}

.building-marker::after,
.building-cluster::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 18px;
    width: 8px;
    height: 8px;
    border-right: 1px solid rgba(201, 165, 92, 0.42);
    border-bottom: 1px solid rgba(201, 165, 92, 0.42);
    background: inherit;
    transform: rotate(45deg);
}

.building-marker:hover,
.building-cluster:hover {
    border-color: var(--gold-bright);
    background: rgba(35, 31, 22, 0.96);
    transform: translateY(-8px) scale(1.02);
}

.building-marker b,
.building-marker small,
.building-cluster span,
.building-cluster small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.building-marker b {
    max-width: 150px;
    color: var(--text);
    font-size: 9px;
    font-weight: 800;
}

.building-marker small {
    max-width: 150px;
    margin-top: 2px;
    color: var(--text-3);
    font-size: 8px;
}

.building-marker-dot {
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    border: 2px solid var(--gold-bright);
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.13), 0 0 12px rgba(201, 165, 92, 0.5);
}

.building-marker-area {
    align-items: flex-start;
    border-style: dashed;
    border-color: rgba(165, 174, 196, 0.55);
}

.building-marker-area .building-marker-dot {
    border-color: var(--text-3);
    background: transparent;
    box-shadow: none;
}

.building-marker-approximate {
    border-color: rgba(120, 186, 224, 0.7);
}

.building-marker-approximate .building-marker-dot {
    border-color: var(--info);
    background: var(--info);
    box-shadow: 0 0 0 3px rgba(120, 186, 224, 0.12), 0 0 12px rgba(120, 186, 224, 0.45);
}

.building-marker-precise {
    border-color: var(--gold-bright);
}

.building-cluster {
    flex-direction: column;
    justify-content: center;
    gap: 1px;
    min-width: 58px;
    padding: 8px 10px;
    border-radius: 999px;
}

.building-cluster span {
    color: var(--gold-bright);
    font-size: 13px;
    font-weight: 800;
}

.building-cluster small {
    color: var(--text-2);
    font-size: 8px;
}

.building-cluster-md {
    min-width: 72px;
}

.building-cluster-lg {
    min-width: 86px;
    padding-block: 10px;
}

.building-context-list {
    display: grid;
    gap: 5px;
    max-height: 132px;
    overflow: auto;
}

.building-context-list span {
    display: block;
    padding: 7px 8px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}

.building-context-list b,
.building-context-list small,
.building-context-more {
    display: block;
}

.building-context-list b {
    overflow: hidden;
    color: var(--text-2);
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.building-context-list small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 8px;
}

.building-context-more {
    padding: 4px 2px;
    color: var(--gold-bright);
    font-size: 8px;
}
.filter-chips::-webkit-scrollbar {
    display: none;
}
.filter-source {
    display: inline-flex;
    align-items: center;
    height: var(--chips-h);
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(10, 10, 11, 0.72);
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2px;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: var(--sh-1);
    backdrop-filter: blur(12px);
}
.filter-source.source-search {
    color: var(--info);
    border-color: rgba(96, 165, 250, 0.3);
}
.filter-source.source-ai {
    color: var(--success);
    border-color: rgba(74, 222, 128, 0.32);
}
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: var(--chips-h);
    padding: 0 12px;
    background: rgba(19, 19, 22, 0.82);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text);
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: var(--sh-1);
    backdrop-filter: blur(12px);
    transition:
        background 0.15s var(--ease),
        border-color 0.15s var(--ease),
        color 0.15s var(--ease);
}
.filter-chip:hover {
    background: var(--surface-2);
}
.filter-chip svg {
    color: var(--text-2);
    flex-shrink: 0;
}
.filter-chip .fcount {
    background: var(--gold);
    color: #0a0a0b;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 999px;
    min-width: 16px;
    text-align: center;
    line-height: 1.4;
}
.filter-chip.active {
    background: var(--gold-soft);
    border-color: var(--gold-line);
    color: var(--gold-bright);
}
.filter-chip.active svg {
    color: var(--gold-bright);
}
.filter-chip .chip-x {
    color: var(--text-3);
    margin-left: 2px;
}
.filter-chip.active .chip-x {
    color: var(--gold-bright);
}

/* =================================================================
   FABs
   ================================================================= */
.fab {
    position: absolute;
    z-index: 5;
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border-strong);
    color: var(--text);
    box-shadow: var(--sh-2);
    transition:
        transform 0.15s var(--ease),
        background 0.15s var(--ease);
}
.fab:hover {
    transform: translateY(-1px);
    background: var(--surface-2);
}
.fab:active {
    transform: scale(0.96);
}
.fab-chat {
    right: var(--s-4);
    bottom: calc(var(--carousel-h) + var(--s-5));
}
.fab-filter {
    right: var(--s-4);
    bottom: calc(var(--carousel-h) + var(--s-5) + 60px);
}

/* =================================================================
   TOAST / SNACKBAR
   ================================================================= */
.toast {
    position: absolute;
    top: calc(var(--header-h) + var(--search-h) + var(--chips-h) + var(--s-5));
    left: 50%;
    transform: translate(-50%, -8px);
    z-index: 6;
    padding: 8px 14px;
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text);
    font-size: 12px;
    font-weight: 500;
    box-shadow: var(--sh-2);
    opacity: 0;
    transition:
        opacity 0.22s var(--ease),
        transform 0.22s var(--ease);
    white-space: nowrap;
}
.toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
}

.snackbar {
    position: absolute;
    top: calc(var(--header-h) + var(--search-h) + var(--chips-h) + var(--s-5));
    left: 50%;
    transform: translate(-50%, -8px);
    z-index: 7;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    box-shadow: var(--sh-2);
    opacity: 0;
    transition:
        opacity 0.22s var(--ease),
        transform 0.22s var(--ease);
}
.snackbar.show {
    opacity: 1;
    transform: translate(-50%, 0);
}
.snackbar-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
}

/* =================================================================
   SMART BAR
   ================================================================= */
.smart-bar {
    position: absolute;
    left: var(--s-4);
    right: calc(
        48px + var(--s-4) + 60px + var(--s-3)
    ); /* leave room for FABs */
    bottom: calc(var(--carousel-h) + var(--s-5));
    z-index: 6;
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-3);
    height: 48px;
    padding: 0 6px 0 var(--s-4);
    background: var(--gold);
    border: 1px solid var(--gold);
    color: #0a0a0b;
    border-radius: 999px;
    box-shadow: var(--sh-gold);
    font-weight: 500;
    animation: smartIn 0.32s var(--ease-out);
}
.smart-bar.show {
    display: flex;
}
@keyframes smartIn {
    from {
        transform: translateY(8px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}
.smart-bar-text b {
    font-weight: 700;
}
.smart-bar-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 36px;
    padding: 0 14px;
    background: #0a0a0b;
    color: var(--gold-bright);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    transition: background 0.15s var(--ease);
}
.smart-bar-cta:hover {
    background: #1a1a1e;
}

/* =================================================================
   AI RESPONSE
   ============================================================= */
.ai-response {
    position: absolute;
    top: auto;
    bottom: calc(var(--s-4) + var(--search-h) + var(--s-3) + env(safe-area-inset-bottom));
    left: var(--s-4);
    right: var(--s-4);
    z-index: 8;
    display: flex;
    gap: var(--s-3);
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: 16px;
    padding: 12px 36px 12px 14px;
    box-shadow: var(--sh-2);
    animation: aiIn 0.3s var(--ease-out);
    transition:
        bottom 0.28s var(--ease-out),
        opacity 0.18s var(--ease),
        transform 0.22s var(--ease-out);
}
.app.results-open .ai-response {
    bottom: calc(var(--carousel-h) + var(--s-3) + env(safe-area-inset-bottom));
}
@keyframes aiIn {
    from {
        transform: translateY(8px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}
.ai-response-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.ai-response-body {
    flex: 1;
    min-width: 0;
}
.ai-response-text {
    font-size: 13px;
    line-height: 1.45;
    color: var(--text);
}
.ai-response-text b {
    color: var(--gold-bright);
    font-weight: 600;
}
.ai-response-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
}
.ai-response-chips .rc {
    font-size: 10px;
    padding: 3px 9px;
    border-radius: 999px;
    background: var(--gold-soft);
    color: var(--gold-bright);
    border: 1px solid var(--gold-line);
    font-weight: 500;
}
.ai-response-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    color: var(--text-3);
    display: grid;
    place-items: center;
    transition:
        background 0.15s,
        color 0.15s;
}
.ai-response-close:hover {
    background: var(--surface-2);
    color: var(--text);
}

/* =================================================================
   USER PROPERTY ASSISTANT
   ================================================================= */
.assistant-drawer {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 12;
    width: min(100%, 410px);
    display: flex;
    flex-direction: column;
    gap: var(--s-4);
    padding: var(--s-5) var(--s-4) var(--s-4);
    background: var(--surface);
    border-left: 1px solid var(--border-strong);
    box-shadow: -20px 0 60px rgba(0, 0, 0, 0.35);
    transform: translateX(102%);
    transition: transform 0.34s var(--ease-out);
    overflow-y: auto;
}
.assistant-drawer.show {
    transform: translateX(0);
}
.assistant-head,
.assistant-title-wrap,
.assistant-request-actions,
.assistant-section-head,
.assistant-chat-head {
    display: flex;
    align-items: center;
}
.assistant-head,
.assistant-section-head,
.assistant-chat-head {
    justify-content: space-between;
    gap: var(--s-3);
}
.assistant-title-wrap {
    gap: var(--s-3);
}
.assistant-orb {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    box-shadow: var(--sh-gold);
}
.assistant-kicker,
.assistant-card-label {
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.8px;
}
.assistant-head h2 {
    margin-top: 2px;
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 500;
}
.assistant-status {
    padding: 9px 12px;
    border-radius: var(--r-2);
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--text-2);
    font-size: 11px;
}
.assistant-status b {
    color: var(--text-3);
    padding: 0 3px;
}
.offline-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-right: 5px;
    border-radius: 50%;
    background: var(--text-3);
}
.online-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-right: 5px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
}
.assistant-request-card {
    padding: var(--s-4);
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-3);
}
.assistant-empty {
    display: grid;
    gap: 5px;
    padding: 24px 16px;
    border: 1px dashed var(--border-strong);
    border-radius: var(--r-3);
    color: var(--text-2);
    text-align: center;
}
.assistant-empty > span {
    color: var(--gold-bright);
    font-size: 20px;
}
.assistant-empty b {
    color: var(--text);
    font-size: 12px;
}
.assistant-empty small {
    color: var(--text-3);
    font-size: 10px;
    line-height: 1.5;
}
.assistant-request-title {
    margin-top: 5px;
    font-size: 17px;
    font-weight: 600;
}
.assistant-request-meta {
    margin-top: 3px;
    color: var(--text-2);
    font-size: 12px;
}
.assistant-request-actions {
    gap: var(--s-4);
    margin-top: var(--s-3);
}
.assistant-link {
    color: var(--gold-bright);
    font-size: 12px;
    font-weight: 600;
}
.assistant-link:hover {
    color: var(--text);
}
.assistant-section-head {
    padding-top: var(--s-1);
    color: var(--text-2);
    font-size: 12px;
    font-weight: 600;
}
.assistant-unread {
    color: var(--success);
    font-size: 11px;
}
.assistant-feed {
    display: flex;
    flex-direction: column;
    gap: var(--s-2);
}
.assistant-update {
    width: 100%;
    display: flex;
    align-items: flex-start;
    gap: var(--s-3);
    padding: var(--s-3);
    text-align: left;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    transition: background 0.15s, border-color 0.15s;
}
.assistant-update:hover {
    background: var(--surface-3);
    border-color: var(--border-strong);
}
.assistant-avatar {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--gold-soft);
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
}
.assistant-avatar.blue {
    background: rgba(96, 165, 250, 0.12);
    color: var(--info);
}
.assistant-update-copy {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.assistant-update-copy b {
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
}
.assistant-update-copy span {
    color: var(--text-2);
    font-size: 11px;
    line-height: 1.4;
}
.assistant-update-copy small,
.assistant-bubble small {
    color: var(--text-3);
    font-size: 10px;
}
.assistant-chevron {
    color: var(--text-3);
    font-size: 21px;
    line-height: 1;
}
.assistant-note {
    padding: var(--s-3);
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.45;
}
.assistant-note span {
    color: var(--gold-bright);
    margin-right: 4px;
}
.assistant-chat {
    min-height: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--s-3);
}
.assistant-chat-head {
    padding-bottom: var(--s-3);
    border-bottom: 1px solid var(--border);
    color: var(--text-2);
    font-size: 12px;
}
.assistant-chat-head b {
    color: var(--text);
    font-weight: 600;
}
.assistant-messages {
    min-height: 160px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--s-2);
    overflow-y: auto;
}
.assistant-bubble {
    max-width: 88%;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 10px 12px;
    border-radius: 14px;
    font-size: 12px;
    line-height: 1.45;
}
.assistant-bubble-agent {
    align-self: flex-start;
    background: var(--surface-2);
    border: 1px solid var(--border);
}
.assistant-bubble-user {
    align-self: flex-end;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--text);
}
.assistant-bubble-system {
    max-width: 100%;
    color: var(--text-3);
    font-size: 10px;
    text-align: center;
}
.assistant-quick-replies {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.assistant-quick-replies button {
    padding: 7px 10px;
    border-radius: 999px;
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    font-size: 11px;
}
.assistant-quick-replies button:hover {
    background: var(--gold-soft);
}
.assistant-composer {
    display: flex;
    gap: var(--s-2);
    padding: 6px 6px 6px 12px;
    background: var(--surface-2);
    border: 1px solid var(--border-strong);
    border-radius: 999px;
}
.assistant-composer input {
    min-width: 0;
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text);
    font-size: 12px;
}
.assistant-composer input::placeholder {
    color: var(--text-3);
}
.assistant-composer button {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--gold);
    color: #0a0a0b;
    font-weight: 700;
}
.assistant-footnote {
    color: var(--text-3);
    font-size: 10px;
    text-align: center;
}

/* =================================================================
   CAROUSEL
   ============================================================= */
.carousel {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 5;
    min-height: 0;
    height: auto;
    max-height: min(var(--carousel-h), 38dvh);
    display: flex;
    flex-direction: column;
    padding-bottom: env(safe-area-inset-bottom);
    background: linear-gradient(180deg, rgba(10, 10, 11, 0) 0%, var(--bg) 28%),
        var(--bg);
    border-top: 1px solid var(--border);
    box-shadow: 0 -18px 44px rgba(0, 0, 0, 0.28);
    transition:
        max-height 0.4s var(--ease),
        transform 0.4s var(--ease-out);
}
.carousel-handle {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: var(--border-strong);
}
.carousel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--s-4) var(--s-4) var(--s-2);
}
.carousel-count {
    font-size: 12px;
    color: var(--text-2);
    font-weight: 500;
}
.carousel-count b {
    color: var(--text);
    font-weight: 600;
}
.carousel-hide {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    color: var(--text-2);
    transition:
        background 0.15s,
        color 0.15s;
}
.carousel-hide:hover {
    background: var(--surface);
    color: var(--text);
}
.carousel-hide svg {
    transition: transform 0.3s var(--ease);
}
.carousel.is-collapsed .carousel-hide svg {
    transform: rotate(180deg);
}
.carousel.is-collapsed {
    transform: translateY(calc(100% + 8px));
}
.carousel.is-collapsed .carousel-track,
.carousel.is-collapsed .carousel-handle {
    opacity: 0;
    pointer-events: none;
}
.carousel.is-collapsed .carousel-head {
    border-bottom: none;
}

.carousel-track {
    display: flex;
    gap: var(--s-3);
    padding: var(--s-2) var(--s-4) var(--s-4);
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-padding-left: var(--s-4);
}

/* Results entry point when search/filter is active but the list is collapsed */
.results-pill {
    position: absolute;
    left: var(--s-4);
    right: var(--s-4);
    bottom: calc(var(--s-4) + var(--search-h) + var(--s-3) + env(safe-area-inset-bottom));
    z-index: 6;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--border-strong);
    color: var(--text);
    box-shadow: var(--sh-2);
    font-size: 13px;
    font-weight: 600;
    animation: pillIn 0.24s var(--ease-out);
}
.results-pill[hidden] {
    display: none;
}
.results-pill-dot {
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: var(--gold-bright);
    box-shadow: 0 0 10px rgba(232, 200, 120, 0.55);
}
.results-pill b {
    color: var(--text);
}
.results-pill-action {
    color: var(--gold-bright);
}
@keyframes pillIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Property card */
.card {
    flex: 0 0 260px;
    scroll-snap-align: start;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition:
        transform 0.18s var(--ease),
        border-color 0.18s var(--ease);
    cursor: pointer;
}
.card:hover {
    transform: translateY(-2px);
    border-color: var(--border-strong);
}
.card.is-focused {
    border-color: var(--gold);
    box-shadow:
        0 0 0 1px var(--gold-line) inset,
        0 12px 34px rgba(201, 165, 92, 0.16);
}
.card:active {
    transform: scale(0.99);
}

.card-media {
    position: relative;
    aspect-ratio: 16 / 10;
    background: var(--surface-2);
    overflow: hidden;
}
.card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.card-media-fallback {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    color: rgba(201, 165, 92, 0.35);
    letter-spacing: 1px;
    background: linear-gradient(135deg, var(--surface-2), var(--surface));
}

.card-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    gap: 4px;
}
.badge {
    font-size: 10px;
    font-weight: 600;
    padding: 3px 7px;
    border-radius: 6px;
    background: rgba(10, 10, 11, 0.65);
    backdrop-filter: blur(8px);
    color: var(--text);
    letter-spacing: 0.2px;
    border: 1px solid var(--border);
}
.badge.match {
    background: var(--gold);
    color: #0a0a0b;
    border-color: transparent;
}
.badge.verified {
    color: var(--gold-bright);
    border-color: var(--gold-line);
}
.badge.new {
    color: var(--success);
    border-color: rgba(74, 222, 128, 0.3);
}
.badge.hot {
    color: var(--warning);
    border-color: rgba(251, 191, 36, 0.3);
}

.card-like {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(10, 10, 11, 0.65);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border);
    color: var(--text-2);
    transition:
        color 0.15s,
        background 0.15s;
}
.card-like:hover {
    color: var(--text);
}
.card-like.on {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.3);
}
.card-like.on svg {
    fill: var(--danger);
}

.card-body {
    padding: 14px 14px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.card-area {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}
.card-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    line-height: 1.35;
    min-height: 38px;
}
.card-price {
    font-family: var(--font-serif);
    font-size: 20px;
    font-weight: 600;
    color: var(--gold-bright);
    letter-spacing: -0.3px;
    margin-top: 2px;
}
.card-price small {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 500;
    color: var(--text-3);
    margin-left: 4px;
}
.card-specs {
    display: flex;
    gap: 14px;
    margin-top: 4px;
    font-size: 11px;
    color: var(--text-2);
}
.card-specs b {
    color: var(--text);
    font-weight: 600;
}

/* Drop-in highlight for fresh proposals */
.card.fresh {
    animation: cardDrop 0.28s var(--ease-out);
    border-color: var(--gold-line);
}
@keyframes cardDrop {
    from {
        transform: translateY(12px) scale(0.98);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Empty state */
.empty {
    flex: 1;
    display: grid;
    place-items: center;
    text-align: center;
    padding: var(--s-7);
    color: var(--text-2);
}
.empty-title {
    font-family: var(--font-serif);
    font-size: 18px;
    color: var(--text);
    margin-bottom: 4px;
}
.empty-sub {
    font-size: 12px;
    color: var(--text-3);
}

/* =================================================================
   SCRIM
   ================================================================= */
.scrim {
    position: absolute;
    inset: 0;
    z-index: 9;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s var(--ease);
}
.scrim.show {
    opacity: 1;
    pointer-events: auto;
}

/* =================================================================
   INSTALL HELP
   ================================================================= */
.install-help {
    position: absolute;
    left: var(--s-4);
    right: var(--s-4);
    bottom: calc(var(--s-4) + env(safe-area-inset-bottom));
    z-index: 11;
    padding: var(--s-5);
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-4);
    box-shadow: var(--sh-3);
}
.install-help[hidden] {
    display: none;
}
.install-help-close {
    position: absolute;
    top: var(--s-3);
    right: var(--s-3);
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: var(--text-2);
    background: var(--surface-2);
}
.install-help-kicker {
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    margin-bottom: var(--s-2);
}
.install-help h2 {
    font-family: var(--font-serif);
    font-size: 22px;
    line-height: 1.2;
    margin: 0 36px var(--s-3) 0;
}
.install-help p {
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.55;
}
.install-help b {
    color: var(--text);
}

/* =================================================================
   BOTTOM SHEET
   ================================================================= */
.sheet {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-5) var(--r-5) 0 0;
    padding: 8px var(--s-5) var(--s-6);
    transform: translateY(100%);
    visibility: hidden;
    pointer-events: none;
    transition:
        transform 0.3s var(--ease-out),
        visibility 0s linear 0.3s;
    max-height: 85%;
    overflow-y: auto;
}
.sheet.show {
    transform: translateY(0);
    visibility: visible;
    pointer-events: auto;
    transition:
        transform 0.3s var(--ease-out),
        visibility 0s;
}
.sheet-grip {
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: var(--border-strong);
    margin: 8px auto var(--s-4);
}
.sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--s-5);
    gap: var(--s-3);
}
.sheet-head h2 {
    flex: 1;
    text-align: center;
    font-family: var(--font-serif);
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.2px;
}
.sheet-close {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    color: var(--text-2);
    transition:
        background 0.15s,
        color 0.15s;
}
.sheet-close:hover {
    background: var(--surface-2);
    color: var(--text);
}

.field {
    margin-bottom: var(--s-5);
}
.field-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: var(--s-3);
}

/* Segmented control */
.segmented {
    display: flex;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    padding: 3px;
    gap: 3px;
}
.segmented button {
    flex: 1;
    height: 36px;
    border-radius: 8px;
    color: var(--text-2);
    font-size: 13px;
    font-weight: 500;
    transition:
        color 0.15s var(--ease),
        background 0.15s var(--ease),
        box-shadow 0.15s var(--ease);
}
.segmented button:hover {
    color: var(--text);
}
.segmented button.on {
    background: var(--surface-3);
    color: var(--text);
    box-shadow: var(--sh-1);
}

/* Range slider */
.range-value {
    display: block;
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    color: var(--gold-bright);
    letter-spacing: -0.3px;
    margin-bottom: var(--s-3);
}
.range-input {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 999px;
    background: linear-gradient(
        to right,
        var(--gold) 0%,
        var(--gold) var(--p, 30%),
        var(--surface-3) var(--p, 30%)
    );
    outline: none;
    margin: var(--s-3) 0;
}
.range-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gold-bright);
    border: 3px solid var(--bg);
    cursor: pointer;
    box-shadow:
        0 0 0 1px var(--gold),
        var(--sh-2);
}
.range-input::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gold-bright);
    border: 3px solid var(--bg);
    cursor: pointer;
    box-shadow: 0 0 0 1px var(--gold);
}
.range-scale {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: var(--text-3);
    margin-top: 2px;
}

/* Chips */
.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.chip {
    height: 32px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text-2);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    transition:
        color 0.15s var(--ease),
        background 0.15s var(--ease),
        border-color 0.15s var(--ease);
}
.chip:hover {
    color: var(--text);
    border-color: var(--border-strong);
}
.chip.on {
    background: var(--gold-soft);
    border-color: var(--gold-line);
    color: var(--gold-bright);
}
.chip-count {
    margin-left: 6px;
    font-size: 10px;
    font-weight: 600;
    opacity: 0.65;
}

/* Toggle */
.toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-4);
}
.toggle-label {
    font-size: 14px;
    font-weight: 500;
}
.toggle-help {
    font-size: 12px;
    color: var(--text-3);
    margin-top: 2px;
}
.switch {
    position: relative;
    width: 42px;
    height: 24px;
    flex-shrink: 0;
}
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.switch-track {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: var(--surface-3);
    border: 1px solid var(--border);
    transition: background 0.2s var(--ease);
}
.switch-track::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--text-3);
    transition:
        transform 0.22s var(--ease-out),
        background 0.2s;
}
.switch input:checked + .switch-track {
    background: var(--gold);
    border-color: var(--gold);
}
.switch input:checked + .switch-track::before {
    transform: translate(18px, -50%);
    background: var(--bg);
}

/* Sheet footer */
.sheet-foot {
    display: flex;
    gap: var(--s-3);
    margin-top: var(--s-6);
    padding-top: var(--s-4);
    border-top: 1px solid var(--border);
}
.btn {
    flex: 1;
    height: 44px;
    border-radius: var(--r-2);
    font-size: 13px;
    font-weight: 600;
    transition:
        background 0.15s,
        transform 0.1s;
}
.btn:active {
    transform: scale(0.99);
}
.btn-ghost {
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text);
}
.btn-ghost:hover {
    background: var(--surface-3);
}
.btn-primary {
    background: var(--gold);
    color: #0a0a0b;
}
.btn-primary:hover {
    background: var(--gold-bright);
}

/* =================================================================
   LISTING DETAIL MODAL
   ================================================================= */
.modal {
    position: absolute;
    left: var(--s-3);
    right: var(--s-3);
    bottom: calc(var(--s-3) + env(safe-area-inset-bottom));
    z-index: 14;
    display: flex;
    flex-direction: column;
    max-height: min(78dvh, 720px);
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-5);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
    transform: translateY(calc(100% + var(--s-5)));
    transition: transform 0.2s var(--ease-out);
    overflow-y: auto;
    pointer-events: none;
}
.modal.show {
    transform: translateY(0);
    pointer-events: auto;
}

.modal-hero {
    position: relative;
    height: 0;
    background: var(--surface-2);
    overflow: hidden;
    border-radius: var(--r-5) var(--r-5) var(--r-3) var(--r-3);
    display: none;
}
.modal-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.modal-hero-fallback {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-family: var(--font-serif);
    font-size: 36px;
    color: rgba(201, 165, 92, 0.3);
    background: linear-gradient(135deg, var(--surface-2), var(--surface));
}
.modal-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(10, 10, 11, 0.4) 0%,
        transparent 30%,
        transparent 70%,
        rgba(19, 19, 22, 0.95) 100%
    );
}
.modal-hero-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    padding: var(--s-4);
}
.modal-hero-dots {
    position: absolute;
    bottom: var(--s-4);
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    gap: 5px;
}
.modal-hero-dots span {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.4);
}
.modal-hero-dots span.on {
    background: var(--gold-bright);
    width: 18px;
}

.modal-content {
    padding: var(--s-5) var(--s-5) calc(var(--s-8) + var(--s-6));
    margin-top: 0;
    position: relative;
    z-index: 2;
}
.modal-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-3);
    margin-bottom: var(--s-4);
}
.modal-toolbar span {
    color: var(--text-3);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}
.modal-toolbar .icon-btn.like.on {
    color: var(--danger);
}
.modal-toolbar .icon-btn.like.on svg {
    fill: var(--danger);
}
.modal-price-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--s-4);
}
.modal-price {
    font-family: var(--font-serif);
    font-size: 28px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.1;
}
.modal-price-sub {
    display: block;
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-3);
    margin-top: 4px;
}
.modal-match {
    text-align: right;
    min-width: 58px;
    padding: 8px 10px;
    border-radius: 14px;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
}
.modal-match-v {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    color: var(--gold-bright);
    line-height: 1;
}
.modal-match-l {
    font-size: 10px;
    color: var(--text-3);
    text-transform: uppercase;
    margin-top: 2px;
}

.modal-title {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    margin-top: var(--s-3);
    line-height: 1.25;
}
.modal-loc {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-3);
    font-size: 12px;
    margin-top: var(--s-2);
}
.modal-loc svg {
    color: var(--gold-bright);
}

.spec-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--s-2);
    margin: var(--s-5) 0 var(--s-5);
}
.spec {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    padding: 14px 10px;
    text-align: center;
}
.spec-n {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    color: var(--text);
    line-height: 1;
}
.spec-t {
    font-size: 10px;
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-top: 4px;
}

.section-label {
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-3);
    font-weight: 600;
    margin: var(--s-6) 0 var(--s-3);
}
.modal-desc {
    font-size: 13px;
    color: var(--text-2);
    line-height: 1.6;
}

.insight {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-3);
    overflow: hidden;
}
.insight-row {
    display: flex;
    justify-content: space-between;
    padding: 12px var(--s-4);
    font-size: 12px;
}
.insight-row + .insight-row {
    border-top: 1px solid var(--border);
}
.insight-row span {
    color: var(--text-3);
}
.insight-row b {
    font-family: var(--font-serif);
    font-weight: 600;
    color: var(--text);
}

.agent-card {
    display: flex;
    align-items: center;
    gap: var(--s-3);
    padding: var(--s-3);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-3);
}
.agent-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gold-soft);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
    font-weight: 600;
    font-size: 13px;
}
.agent-info {
    flex: 1;
    line-height: 1.3;
}
.agent-info .n {
    font-size: 13px;
    font-weight: 500;
}
.agent-info .a {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 2px;
}
.agent-verify {
    font-size: 10px;
    color: var(--gold-bright);
    background: var(--gold-soft);
    padding: 3px 7px;
    border-radius: 999px;
    font-weight: 600;
}

.modal-cta {
    position: sticky;
    bottom: 0;
    display: flex;
    gap: var(--s-2);
    margin-top: var(--s-6);
    padding-top: var(--s-3);
    background: linear-gradient(180deg, rgba(19, 19, 22, 0), var(--surface) 32%);
}
.modal-cta .btn {
    flex: 1;
}
.modal-cta .btn-secondary {
    padding: 0 16px;
    flex: 0 0 auto;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text);
}
.modal-cta .btn-secondary:hover {
    background: var(--surface-3);
}

/* =================================================================
   MATCHING SCENE
   ================================================================= */
.match-overlay {
    position: absolute;
    inset: 0;
    z-index: 8;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s var(--ease);
}
.match-overlay.show {
    opacity: 1;
    pointer-events: auto;
}
.match-dim {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 11, 0.55);
}

.radar {
    position: absolute;
    left: 50%;
    top: 46%;
    width: 0;
    height: 0;
    pointer-events: none;
}
.radar span {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 60px;
    height: 60px;
    margin: -30px;
    border-radius: 50%;
    border: 1px solid var(--gold);
    opacity: 0;
    animation: radar 2.4s linear infinite;
}
.radar span:nth-child(2) {
    animation-delay: 0.8s;
}
.radar span:nth-child(3) {
    animation-delay: 1.6s;
}
@keyframes radar {
    0% {
        transform: scale(0.4);
        opacity: 0.7;
    }
    100% {
        transform: scale(5);
        opacity: 0;
    }
}

.match-panel {
    position: absolute;
    left: var(--s-4);
    right: var(--s-4);
    bottom: var(--s-4);
    z-index: 9;
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-4);
    padding: var(--s-5);
    box-shadow: var(--sh-3);
}

.match-status {
    display: flex;
    align-items: center;
    gap: var(--s-3);
    margin-bottom: var(--s-4);
}
.match-spinner {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
}
.match-spinner svg {
    animation: spin 2s linear infinite;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
.match-panel.idle .match-spinner {
    background: rgba(74, 222, 128, 0.12);
    border-color: rgba(74, 222, 128, 0.3);
    color: var(--success);
}
.match-panel.idle .match-spinner svg {
    animation: none;
}
.match-status-text {
    flex: 1;
}
.match-status-title {
    font-size: 14px;
    font-weight: 600;
}
.match-status-sub {
    font-size: 12px;
    color: var(--text-3);
    margin-top: 2px;
}
.match-cancel {
    font-size: 12px;
    color: var(--text-3);
    padding: 4px 8px;
    border-radius: 6px;
    transition:
        background 0.15s,
        color 0.15s;
}
.match-cancel:hover {
    color: var(--text);
    background: var(--surface-2);
}

.progress-segs {
    display: flex;
    gap: 6px;
    margin-top: var(--s-3);
}
.progress-segs .seg {
    flex: 1;
    height: 4px;
    border-radius: 999px;
    background: var(--surface-3);
    overflow: hidden;
    position: relative;
}
.progress-segs .seg-fill {
    position: absolute;
    inset: 0;
    width: 0;
    background: linear-gradient(90deg, var(--gold), var(--gold-bright));
    transition: width 0.6s var(--ease);
}
.seg-labels {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}
.seg-labels .lbl {
    flex: 1;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-3);
}
.seg-labels .lbl b {
    color: var(--text-2);
    font-weight: 600;
}
.seg-labels .lbl.active b {
    color: var(--gold-bright);
}

.proposals {
    margin-top: var(--s-4);
    display: flex;
    flex-direction: column;
    gap: var(--s-2);
}

.proposal {
    display: flex;
    align-items: center;
    gap: var(--s-3);
    padding: var(--s-3);
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--r-3);
    animation: cardDrop 0.28s var(--ease-out);
}
.proposal-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gold-soft);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}
.proposal-info {
    flex: 1;
    min-width: 0;
}
.proposal-name {
    font-size: 13px;
    font-weight: 500;
}
.proposal-ag {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 1px;
}
.proposal-score {
    font-size: 10px;
    color: var(--success);
    margin-top: 3px;
    font-weight: 600;
}
.proposal-cta {
    height: 32px;
    padding: 0 12px;
    border-radius: 8px;
    background: var(--gold);
    color: #0a0a0b;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}
.proposal-cta:hover {
    background: var(--gold-bright);
}

/* =================================================================
   UTILITIES
   ================================================================= */
.hidden {
    display: none !important;
}
.no-select {
    user-select: none;
    -webkit-user-select: none;
}

/* =================================================================
   RESPONSIVE — desktop / large screens
   ================================================================= */
@media (min-width: 768px) {
    :root {
        --header-h: 64px;
        --carousel-h: 260px;
    }
    .topbar {
        padding: 0 var(--s-6);
    }
    .search {
        left: var(--s-6);
        right: var(--s-6);
    }
    .filter-chips,
    .ai-response {
        left: var(--s-6);
        right: var(--s-6);
    }
}

@media (min-width: 1024px) {
    .app {
        width: min(100%, 1440px);
        max-width: 1440px;
        margin: 0 auto;
        border-left: 1px solid var(--border);
        border-right: 1px solid var(--border);
    }
}

/* =============================================================
   INTRO OVERLAY & LOGIN SCREEN
   ============================================================= */
.intro-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #050507;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.intro-overlay.fade-out {
    opacity: 0;
    transform: scale(1.05);
    pointer-events: none;
}

.intro-bg {
    position: absolute;
    inset: 0;
    background-image: url('https://images.unsplash.com/photo-1582672060674-bc2bd808a8b5?auto=format&fit=crop&w=1800&q=80');
    background-size: cover;
    background-position: center;
    filter: brightness(0.2) saturate(0.8);
    z-index: -1;
    animation: kenBurns 40s infinite alternate var(--ease);
}

@keyframes kenBurns {
    0% { transform: scale(1); }
    100% { transform: scale(1.15) translate(-1%, -1%); }
}

.intro-card-wrap {
    padding: 24px;
    width: 100%;
    max-width: 420px;
    z-index: 10;
}

.intro-card {
    background: rgba(19, 19, 22, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--r-4);
    padding: 36px var(--s-6);
    box-shadow: var(--sh-3), 0 0 40px rgba(0,0,0,0.5);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    animation: cardSlideUp 1s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cardSlideUp {
    0% { opacity: 0; transform: translateY(30px); }
    100% { opacity: 1; transform: translateY(0); }
}

.intro-header {
    text-align: center;
    margin-bottom: 32px;
}

.intro-brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--gold-bright), var(--gold));
    color: #0a0a0b;
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 600;
    border-radius: var(--r-2);
    margin-bottom: 12px;
    box-shadow: var(--sh-gold);
}

.intro-header h1 {
    font-family: var(--font-serif);
    font-size: 28px;
    font-weight: 600;
    color: var(--text);
    letter-spacing: -0.5px;
}

.intro-header p {
    font-family: var(--font-sans);
    font-size: 10px;
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 2px;
    margin-top: 4px;
    text-transform: uppercase;
}

.login-form {
    display: flex;
    flex-direction: column;
}

.login-form .input-group {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: var(--s-2);
}

.login-form label {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-2);
    letter-spacing: 0.2px;
    text-align: left;
}

.login-form input {
    height: 48px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-2);
    color: var(--text);
    padding: 0 var(--s-4);
    font-family: var(--font-sans);
    font-size: 14px;
    transition:
        background 0.2s var(--ease),
        border-color 0.2s var(--ease),
        box-shadow 0.2s var(--ease);
    outline: none;
}

.login-form input:focus {
    border-color: var(--gold);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.15);
}

.btn-login {
    height: 48px;
    background: var(--gold);
    border: none;
    border-radius: var(--r-2);
    color: #0a0a0b;
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition:
        background 0.2s var(--ease),
        color 0.2s var(--ease),
        border-color 0.2s var(--ease),
        box-shadow 0.2s var(--ease),
        transform 0.16s var(--ease-out);
    margin-top: 8px;
    box-shadow: var(--sh-gold);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-login:hover {
    background: var(--gold-bright);
    transform: translateY(-1px);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login.loading {
    background: var(--gold-soft);
    color: var(--gold-bright);
    border: 1px solid var(--gold-line);
    box-shadow: none;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-login.loading::after {
    content: "";
    width: 16px;
    height: 16px;
    border: 2px solid rgba(201, 165, 92, 0.2);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin-left: 8px;
}

.login-divider {
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--text-3);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 20px 0;
}

.login-divider::before,
.login-divider::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid var(--border);
}

.login-divider::before {
    margin-right: 12px;
}

.login-divider::after {
    margin-left: 12px;
}

.btn-guest {
    height: 44px;
    background: transparent;
    border: 1px solid var(--gold-line);
    border-radius: var(--r-2);
    color: var(--gold-bright);
    font-family: var(--font-sans);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition:
        background 0.2s var(--ease),
        border-color 0.2s var(--ease),
        color 0.2s var(--ease);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-guest:hover {
    background: var(--gold-soft);
    border-color: var(--gold);
}

.intro-footer {
    font-size: 10px;
    color: var(--text-3);
    text-align: center;
    margin-top: 24px;
    letter-spacing: 0.1px;
}

/* =============================================================
   INTRO PRODUCT REVEAL
   ============================================================= */
.intro-overlay {
    overflow: auto;
    overflow-x: hidden;
    padding: 32px 24px;
    background: #050507;
    align-items: flex-start;
}

.intro-bg {
    filter: brightness(0.13) saturate(0.75);
}

.intro-glow {
    position: absolute;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(80px);
    opacity: 0.18;
}

.intro-glow-one {
    top: -240px;
    right: 12%;
    background: #c9a55c;
}

.intro-glow-two {
    bottom: -300px;
    left: 8%;
    background: #415d86;
    opacity: 0.2;
}

.intro-layout {
    display: grid;
    grid-template-columns: minmax(360px, 0.86fr) minmax(460px, 1.14fr);
    align-items: center;
    gap: clamp(48px, 8vw, 112px);
    width: min(1180px, 100%);
    max-width: 1180px;
    min-height: calc(100% - 64px);
    margin: 0 auto;
}

.intro-layout .intro-card {
    padding: 20px 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    align-items: flex-start;
    animation: introRevealLeft 0.9s var(--ease-out) both;
}

@keyframes introRevealLeft {
    from { opacity: 0; transform: translateX(-24px); }
    to { opacity: 1; transform: translateX(0); }
}

.intro-header {
    text-align: left;
    margin-bottom: 28px;
}

.intro-brand-line {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.75);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.7px;
}

.intro-brand-line i {
    width: 24px;
    height: 1px;
    background: var(--gold);
    opacity: 0.75;
}

.intro-brand-mark {
    width: 34px;
    height: 34px;
    margin: 0 2px 0 0;
    border-radius: 9px;
    font-size: 18px;
}

.intro-eyebrow {
    margin-top: 42px;
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2.4px;
}

.intro-header h1 {
    margin-top: 14px;
    font-family: var(--font-serif);
    font-size: clamp(46px, 5.5vw, 76px);
    line-height: 0.98;
    letter-spacing: -2.8px;
    text-align: left;
}

.intro-header h1 em {
    color: var(--gold-bright);
    font-style: normal;
}

.intro-header .intro-lede {
    max-width: 470px;
    margin-top: 22px;
    color: rgba(255, 255, 255, 0.66);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.7;
    letter-spacing: 0;
    text-transform: none;
}

.intro-benefits {
    display: grid;
    gap: 12px;
    width: 100%;
    max-width: 470px;
    margin-bottom: 28px;
}

.intro-benefit {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.8);
}

.intro-benefit-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
    background: rgba(201, 165, 92, 0.06);
    font-size: 16px;
}

.intro-benefit b,
.intro-benefit small {
    display: block;
}

.intro-benefit b {
    font-size: 12px;
    font-weight: 600;
}

.intro-benefit small {
    margin-top: 1px;
    color: var(--text-3);
    font-size: 11px;
}

.intro-primary-cta {
    justify-content: space-between;
    width: 100%;
    max-width: 310px;
    height: 52px;
    padding: 0 18px 0 20px;
    background: var(--gold);
    color: #0a0a0b;
    border-color: transparent;
    box-shadow: 0 10px 30px rgba(201, 165, 92, 0.2);
    font-size: 13px;
    font-weight: 700;
}

.intro-primary-cta:hover {
    color: #0a0a0b;
    background: var(--gold-bright);
    border-color: transparent;
    transform: translateY(-2px);
}

.intro-walkthrough-cta {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 310px;
    min-height: 40px;
    margin-top: 8px;
    padding: 0 2px;
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
    text-align: left;
}

.intro-walkthrough-cta:hover {
    color: var(--text);
}

.intro-demo-note {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    color: var(--text-3);
    font-size: 10px;
}

.intro-demo-dot,
.preview-live {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.08);
}

.intro-signin {
    width: 100%;
    max-width: 310px;
    margin-top: 26px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 14px;
}

.intro-signin summary {
    color: var(--text-3);
    cursor: pointer;
    font-size: 11px;
    list-style: none;
}

.intro-signin summary::-webkit-details-marker {
    display: none;
}

.intro-signin summary::after {
    content: " +";
    color: var(--gold);
}

.intro-signin[open] summary::after {
    content: " −";
}

.intro-signin .login-form {
    margin-top: 16px;
    gap: 12px;
}

.intro-signin .login-form .input-group {
    margin-bottom: 0;
}

.intro-signin .btn-login {
    margin-top: 4px;
}

.intro-footer {
    margin-top: 26px;
    text-align: left;
}

.intro-product-preview {
    position: relative;
    width: 100%;
    max-width: 590px;
    justify-self: end;
    transform: rotate(1.5deg);
    animation: introRevealRight 1s 0.12s var(--ease-out) both;
}

@keyframes introRevealRight {
    from { opacity: 0; transform: translateX(28px) rotate(1.5deg); }
    to { opacity: 1; transform: translateX(0) rotate(1.5deg); }
}

.preview-topline,
.preview-window-head,
.preview-bottom,
.preview-agent-update,
.preview-caption {
    display: flex;
    align-items: center;
}

.preview-topline {
    justify-content: space-between;
    margin: 0 14px 10px;
    color: rgba(255, 255, 255, 0.45);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.2px;
}

.preview-topline span:first-child {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gold-bright);
}

.preview-window {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 20px;
    background: rgba(16, 18, 23, 0.9);
    box-shadow: 0 26px 90px rgba(0, 0, 0, 0.58), 0 0 0 8px rgba(255,255,255,0.025);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
}

.preview-window-head {
    justify-content: space-between;
    height: 46px;
    padding: 0 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.58);
    font-size: 10px;
}

.preview-dots {
    display: flex;
    gap: 5px;
}

.preview-dots i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.24);
}

.preview-window-title {
    color: rgba(255, 255, 255, 0.82);
    font-weight: 600;
}

.preview-lock {
    color: var(--gold);
    font-size: 15px;
}

.preview-search {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 48px;
    margin: 18px 18px 0;
    padding: 0 14px;
    border: 1px solid rgba(201, 165, 92, 0.38);
    border-radius: 10px;
    background: rgba(201, 165, 92, 0.08);
    color: var(--gold-bright);
    font-size: 11px;
}

.preview-search b {
    overflow: hidden;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-search em {
    margin-left: auto;
    font-style: normal;
}

.preview-map {
    position: relative;
    overflow: hidden;
    height: 238px;
    margin-top: 14px;
    background: #17212b;
    background-image: linear-gradient(135deg, rgba(255,255,255,0.025) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.025) 50%, rgba(255,255,255,0.025) 75%, transparent 75%);
    background-size: 54px 54px;
}

.preview-water {
    position: absolute;
    top: -20%;
    right: -16%;
    width: 43%;
    height: 145%;
    border-left: 2px solid rgba(71, 145, 171, 0.35);
    border-radius: 50%;
    background: rgba(33, 101, 128, 0.25);
    transform: rotate(18deg);
}

.preview-road {
    position: absolute;
    display: block;
    height: 1px;
    background: rgba(255, 255, 255, 0.14);
    transform-origin: left center;
}

.road-one { top: 58%; left: -5%; width: 115%; transform: rotate(-16deg); }
.road-two { top: 20%; left: 18%; width: 95%; transform: rotate(43deg); opacity: 0.7; }

.preview-pin {
    position: absolute;
    z-index: 2;
    padding: 5px 8px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    background: #d2aa5c;
    color: #12100b;
    box-shadow: 0 6px 16px rgba(0,0,0,0.3);
    font-size: 10px;
    font-weight: 800;
}

.pin-one { top: 32%; left: 44%; }
.pin-two { top: 58%; left: 24%; background: rgba(255,255,255,0.9); }
.pin-three { top: 18%; left: 68%; background: rgba(255,255,255,0.9); }

.preview-map-label {
    position: absolute;
    color: rgba(255, 255, 255, 0.55);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.label-one { bottom: 24%; left: 40%; }
.label-two { top: 25%; left: 20%; }

.preview-bottom {
    justify-content: space-between;
    gap: 18px;
    padding: 16px 18px 18px;
}

.preview-bottom > div:first-child {
    flex: 0 0 auto;
}

.preview-bottom small,
.preview-bottom strong {
    display: block;
}

.preview-bottom small {
    color: var(--text-3);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1px;
}

.preview-bottom strong {
    margin-top: 4px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
}

.preview-agent-update {
    min-width: 225px;
    gap: 9px;
    padding: 9px 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
}

.preview-agent-update > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 26px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(201,165,92,0.18);
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
}

.preview-agent-update p {
    min-width: 0;
}

.preview-agent-update p b,
.preview-agent-update p small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-agent-update p b {
    color: rgba(255, 255, 255, 0.82);
    font-size: 10px;
}

.preview-agent-update p small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 9px;
    font-weight: 400;
    letter-spacing: 0;
}

.preview-agent-update > i {
    margin-left: auto;
    color: var(--gold);
    font-size: 18px;
    font-style: normal;
}

.preview-caption {
    gap: 10px;
    margin: 20px 14px 0;
}

.preview-orb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
    background: rgba(201,165,92,0.09);
}

.preview-caption b,
.preview-caption small {
    display: block;
}

.preview-caption b {
    color: rgba(255, 255, 255, 0.78);
    font-size: 11px;
}

.preview-caption small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 10px;
}

@media (max-width: 900px) {
    .intro-layout {
        grid-template-columns: minmax(320px, 0.9fr) minmax(350px, 1.1fr);
        gap: 34px;
    }

    .intro-header h1 {
        font-size: clamp(42px, 6vw, 58px);
    }

    .preview-map {
        height: 200px;
    }

    .preview-agent-update {
        min-width: 0;
    }
}

@media (max-width: 700px) {
    .intro-overlay {
        align-items: flex-start;
        padding: 22px 18px 34px;
    }

    .intro-layout {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 28px;
        margin: 0 auto;
    }

    .intro-layout .intro-card {
        padding: 10px 0 0;
    }

    .intro-eyebrow {
        margin-top: 30px;
    }

    .intro-header h1 {
        font-size: clamp(42px, 13vw, 60px);
        letter-spacing: -1.8px;
    }

    .intro-header .intro-lede {
        font-size: 13px;
    }

    .intro-product-preview {
        max-width: none;
        transform: none;
    }

    @keyframes introRevealRight {
        from { opacity: 0; transform: translateY(18px); }
        to { opacity: 1; transform: translateY(0); }
    }

    .preview-map {
        height: 180px;
    }

    .preview-bottom {
        align-items: flex-start;
        flex-direction: column;
    }

    .preview-agent-update {
        width: 100%;
    }
}

@media (min-width: 768px) and (max-height: 760px) {
    .intro-overlay {
        padding: 16px 24px;
    }

    .intro-layout {
        min-height: auto;
        gap: 40px;
    }

    .intro-layout .intro-card {
        padding: 8px 0;
    }

    .intro-eyebrow {
        margin-top: 24px;
    }

    .intro-header {
        margin-bottom: 16px;
    }

    .intro-header h1 {
        font-size: clamp(42px, 5vw, 60px);
    }

    .intro-header .intro-lede {
        margin-top: 14px;
        font-size: 13px;
        line-height: 1.45;
    }

    .intro-benefits {
        gap: 7px;
        margin-bottom: 14px;
    }

    .intro-benefit-icon {
        width: 28px;
        height: 28px;
        flex-basis: 28px;
    }

    .intro-signin {
        margin-top: 12px;
        padding-top: 9px;
    }

    .preview-map {
        height: 170px;
    }

    .preview-caption {
        margin-top: 12px;
    }
}

/* =============================================================
   GUIDED PRESENTER PATH
   ============================================================= */
.presenter-fab {
    position: fixed;
    right: 18px;
    bottom: 20px;
    z-index: 905;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 10px 14px;
    border: 1px solid var(--gold-line);
    border-radius: 999px;
    background: rgba(12, 12, 14, .92);
    color: var(--gold-bright);
    box-shadow: 0 12px 36px rgba(0,0,0,.28);
    backdrop-filter: blur(14px);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: .05em;
    cursor: pointer;
}
.presenter-fab span { font-size: 9px; }
.presenter-rail {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 9999;
    width: min(370px, calc(100vw - 28px));
    overflow: hidden;
    border: 1px solid rgba(217, 184, 112, .28);
    border-radius: 22px;
    background: linear-gradient(155deg, rgba(24,24,27,.98), rgba(10,10,12,.98));
    color: #f6f2e9;
    box-shadow: 0 30px 80px rgba(0,0,0,.52);
    backdrop-filter: blur(22px);
}
.presenter-head,
.presenter-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.presenter-head { padding: 15px 16px 12px; }
.presenter-head > div { display: flex; align-items: center; gap: 10px; }
.presenter-head-actions { display: flex; align-items: center; gap: 6px; }
.presenter-head small { color: #d8bb7a; font-size: 9px; font-weight: 800; letter-spacing: .16em; }
.presenter-head b { color: #8f8b84; font-size: 9px; }
.presenter-head button {
    width: 28px; height: 28px; border: 0; border-radius: 50%;
    background: rgba(255,255,255,.06); color: #d6d1c8; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 14px; line-height: 1; transition: background 0.15s ease, color 0.15s ease;
}
.presenter-head button:hover {
    background: rgba(255,255,255,.14); color: #fff;
}
.presenter-progress { height: 2px; background: rgba(255,255,255,.07); }
.presenter-progress span { display: block; width: 14.28%; height: 100%; background: #c9a55c; transition: width .3s ease; }
.presenter-body { padding: 18px 18px 14px; }
.presenter-claim { color: #c9a55c; font-size: 9px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.presenter-body h2 { margin: 7px 0 9px; color: #fff; font-family: var(--font-display); font-size: 25px; line-height: 1.08; font-weight: 600; }
.presenter-body > p { color: #aaa6a0; font-size: 12px; line-height: 1.55; }
.presenter-say { margin-top: 14px; padding: 12px 13px; border-left: 2px solid #c9a55c; border-radius: 0 10px 10px 0; background: rgba(201,165,92,.07); }
.presenter-say small { display: block; margin-bottom: 4px; color: #8e8677; font-size: 8px; font-weight: 800; letter-spacing: .14em; }
.presenter-say p { color: #e8e2d8; font-family: var(--font-display); font-size: 13px; font-style: italic; line-height: 1.45; }
.presenter-evidence { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 13px; }
.presenter-evidence span { padding: 5px 8px; border: 1px solid rgba(255,255,255,.09); border-radius: 999px; color: #b9b3aa; font-size: 9px; }
.presenter-controls { padding: 11px 12px; border-top: 1px solid rgba(255,255,255,.07); }
.presenter-controls button { padding: 9px 10px; border: 0; border-radius: 9px; background: rgba(255,255,255,.055); color: #c9c4bb; font-size: 10px; font-weight: 700; cursor: pointer; }
.presenter-controls .presenter-run { flex: 1; background: #c9a55c; color: #16130e; }
.presenter-controls button:disabled { opacity: .3; cursor: default; }
.presenter-showcase { display: block; padding: 10px 16px 13px; color: #d8bb7a; text-align: center; font-size: 9px; text-decoration: none; letter-spacing: .04em; }
.presenter-highlight { animation: presenterProofPulse 1.25s ease 2; outline: 2px solid rgba(201,165,92,.75) !important; outline-offset: 4px; }
@keyframes presenterProofPulse { 50% { box-shadow: 0 0 0 10px rgba(201,165,92,.10); } }
@media (max-width: 640px) {
    .presenter-fab { right: 12px; bottom: 12px; }
    .presenter-rail { right: 10px; bottom: 10px; }
    .presenter-body h2 { font-size: 22px; }
}

@media (max-width: 767px) {
    .demo-status {
        display: none;
    }
}

@media (min-width: 768px) and (max-height: 760px) {
    .request-submit {
        position: static;
        box-shadow: none;
    }
}

/* =============================================================
   PROFILE POPOVER
   ============================================================= */
.profile-popover {
    position: absolute;
    top: calc(var(--header-h) - 10px);
    right: 0;
    z-index: 100;
    width: 240px;
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-3);
    box-shadow: var(--sh-3);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 16px;
    transform-origin: top right;
    animation: popoverFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes popoverFadeIn {
    from { opacity: 0; transform: scale(0.95) translateY(-5px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.popover-arrow {
    position: absolute;
    top: -6px;
    right: 16px;
    width: 10px;
    height: 10px;
    background: var(--surface);
    border-left: 1px solid var(--border-strong);
    border-top: 1px solid var(--border-strong);
    transform: rotate(45deg);
}

.profile-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.profile-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gold-soft);
    border: 1px solid var(--gold-line);
    color: var(--gold-bright);
    font-weight: 600;
    font-size: 13px;
}

.profile-details {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    text-align: left;
}

.profile-details strong {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.profile-details span {
    font-size: 11px;
    color: var(--text-3);
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.popover-divider {
    height: 1px;
    background: var(--border);
    margin: 12px 0;
}

.popover-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    height: 36px;
    padding: 0 var(--s-3);
    background: transparent;
    border: none;
    border-radius: var(--r-1);
    color: var(--text-2);
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition:
        background 0.15s var(--ease),
        color 0.15s var(--ease);
}

.popover-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
}

.popover-item.btn-signout {
    color: var(--danger);
}

.popover-item.btn-signout:hover {
    background: rgba(239, 68, 68, 0.08);
    color: #fca5a5;
}

/* =============================================================
   MOTION PASS — calm, intentional, feedback-first interaction
   ============================================================= */
:root {
    --motion-fast: 160ms;
    --motion-base: 260ms;
    --motion-smooth: 300ms;
}

button,
a,
input,
.card,
.pin,
.chip,
.filter-chip,
.assistant-update,
.preview-pin {
    -webkit-tap-highlight-color: transparent;
}

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

.map {
    transition: filter 0.72s var(--ease-out), opacity 0.72s var(--ease-out);
}

.app:not(.map-ready) .map {
    filter: saturate(0.72) brightness(0.82);
}

.app.map-ready .map {
    filter: none;
}

.search {
    will-change: transform, opacity, border-color;
}

.search.is-processing {
    border-color: var(--gold-line);
    box-shadow: 0 16px 44px rgba(0, 0, 0, 0.36), 0 0 0 3px rgba(201, 165, 92, 0.08);
}

.search-submit {
    position: relative;
    will-change: transform;
}

.search-submit svg {
    transition: opacity var(--motion-fast) var(--ease), transform var(--motion-fast) var(--ease);
}

.search.is-processing .search-submit svg {
    opacity: 0;
    transform: translateX(3px);
}

.search.is-processing .search-submit::after {
    content: "";
    position: absolute;
    width: 12px;
    height: 12px;
    border: 1.5px solid rgba(10, 10, 11, 0.25);
    border-top-color: #0a0a0b;
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
}

.carousel-track {
    scroll-behavior: smooth;
}

.card {
    animation: cardEnter 0.42s var(--ease-out) both;
    animation-delay: calc(min(var(--card-index, 0), 7) * 42ms);
    will-change: transform, opacity;
}

@keyframes cardEnter {
    from {
        opacity: 0;
        transform: translateY(14px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.filter-chip,
.filter-source {
    animation: chipEnter 0.28s var(--ease-out) both;
}

.filter-chip {
    animation-delay: 35ms;
}

@keyframes chipEnter {
    from { opacity: 0; transform: translateY(-5px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.pin {
    animation: pinEnter 0.34s var(--ease-out) both;
}

@keyframes pinEnter {
    from { opacity: 0; transform: translateY(1px) scale(0.86); }
    to { opacity: 1; transform: translateY(-5px) scale(1); }
}

.pin:hover {
    animation: none;
}

.assistant-drawer {
    will-change: transform;
    transition: transform var(--motion-smooth) var(--ease-out);
}

.assistant-update {
    will-change: transform, background, border-color;
}

.assistant-update:hover {
    transform: translateX(-3px);
}

.assistant-bubble {
    animation: bubbleEnter 0.3s var(--ease-out) both;
}

@keyframes bubbleEnter {
    from { opacity: 0; transform: translateY(7px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.preview-pin {
    animation: previewPinFloat 3.4s ease-in-out infinite;
}

.pin-two { animation-delay: -1.1s; }
.pin-three { animation-delay: -2.2s; }

@keyframes previewPinFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

.preview-agent-update {
    animation: previewUpdatePulse 4s 1.4s ease-in-out infinite;
}

@keyframes previewUpdatePulse {
    0%, 78%, 100% { border-color: rgba(255, 255, 255, 0.08); background: rgba(255, 255, 255, 0.04); }
    86% { border-color: rgba(201, 165, 92, 0.32); background: rgba(201, 165, 92, 0.08); }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

/* =============================================================
   RESPONSIVE APP SHELL
   ============================================================= */
@media (min-width: 1024px) {
    .app {
        width: min(100%, 1440px);
        max-width: 1440px;
        margin: 0 auto;
        border-left: 1px solid var(--border);
        border-right: 1px solid var(--border);
    }

    .topbar {
        padding-left: clamp(24px, 5vw, 72px);
        padding-right: clamp(24px, 5vw, 72px);
    }

    .search {
        left: 50%;
        right: auto;
        width: min(calc(100% - 96px), 720px);
        transform: translateX(-50%);
    }

    .app.results-open .search {
        transform: translate(-50%, calc(100% + var(--s-5)));
    }

    .filter-chips,
    .ai-response {
        left: clamp(24px, 5vw, 72px);
        right: clamp(24px, 5vw, 72px);
    }

    .filter-chips {
        justify-content: center;
    }

    .ai-response {
        width: min(calc(100% - 96px), 720px);
        left: 50%;
        right: auto;
        transform: translateX(-50%);
    }

    .app.results-open .ai-response {
        transform: translateX(-50%);
    }

    .carousel-track {
        padding-left: clamp(24px, 5vw, 72px);
        padding-right: clamp(24px, 5vw, 72px);
    }

    .smart-bar {
        left: 50%;
        right: auto;
        width: min(calc(100% - 96px), 720px);
        transform: translateX(-50%);
        animation-name: smartInDesktop;
    }

    @keyframes smartInDesktop {
        from { opacity: 0; transform: translate(-50%, 8px); }
        to { opacity: 1; transform: translate(-50%, 0); }
    }

    .assistant-drawer {
        width: min(430px, 38vw);
        padding-left: 24px;
        padding-right: 24px;
    }
}

@media (max-width: 767px) {
    .topbar {
        padding-left: 12px;
        padding-right: 12px;
        gap: 8px;
    }

    .brand-text {
        min-width: 0;
    }

    .brand-name {
        font-size: 13px;
    }

    .brand-tag {
        display: none;
    }

    .topbar-actions {
        gap: 4px;
    }

    .topbar-actions .icon-btn {
        width: 34px;
        height: 34px;
    }

    .showcase-link { padding: 6px 8px; font-size: 9px; }

    .search {
        left: 10px;
        right: 10px;
        gap: 8px;
        padding-left: 12px;
        padding-right: 8px;
    }

    .search input {
        min-width: 0;
        font-size: 13px;
    }

    .search-filter {
        width: 36px;
        justify-content: center;
        padding: 0;
    }

    .search-filter span {
        display: none;
    }

    .filter-chips,
    .ai-response {
        left: 10px;
        right: 10px;
    }

    .carousel-track {
        padding-left: 12px;
        padding-right: 12px;
    }

    .card {
        flex-basis: min(260px, calc(100vw - 48px));
    }

    .assistant-drawer {
        width: 100%;
        padding-left: 16px;
        padding-right: 16px;
    }
}

/* =============================================================
   REQUEST REGISTRATION SURFACE
   ============================================================= */
.request-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--gold-line);
    border-radius: 10px;
    background: var(--gold-soft);
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
    transition: background var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease), transform var(--motion-fast) var(--ease);
}

.request-trigger:hover {
    background: rgba(201, 165, 92, 0.16);
    border-color: var(--gold);
    transform: translateY(-1px);
}

.request-trigger:active {
    transform: scale(0.98);
}

.request-sheet {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 13;
    width: min(760px, calc(100% - 48px));
    max-height: min(90dvh, 760px);
    overflow-y: auto;
    padding: 26px 28px 22px;
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-5);
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.58);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translate(-50%, -45%) scale(0.96);
    transition: opacity var(--motion-base) var(--ease), transform var(--motion-smooth) var(--ease-out), visibility 0s linear var(--motion-smooth);
}

.request-sheet.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
    transition: opacity var(--motion-base) var(--ease), transform var(--motion-smooth) var(--ease-out), visibility 0s;
}

.request-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--s-4);
}

.request-kicker,
.request-label,
.request-context-head span,
.request-developers > small {
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.request-head h2 {
    margin-top: 6px;
    font-family: var(--font-serif);
    font-size: clamp(24px, 4vw, 34px);
    line-height: 1.1;
    letter-spacing: -0.5px;
}

.request-intro {
    max-width: 620px;
    margin: 12px 0 22px;
    color: var(--text-2);
    font-size: 13px;
    line-height: 1.6;
}

.request-form {
    display: flex;
    flex-direction: column;
    gap: 17px;
}

.request-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.request-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.request-label {
    color: var(--text-3);
    letter-spacing: 0.7px;
}

.request-label output {
    float: right;
    color: var(--gold-bright);
    font-size: 11px;
    letter-spacing: 0;
    text-transform: none;
}

.request-segmented {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.request-segmented button,
.request-form select,
.request-form textarea {
    min-height: 44px;
    border: 1px solid var(--border-strong);
    border-radius: var(--r-2);
    background: var(--surface-2);
    color: var(--text);
    font: inherit;
    outline: none;
    transition: border-color var(--motion-fast) var(--ease), background var(--motion-fast) var(--ease), color var(--motion-fast) var(--ease);
}

.request-segmented button {
    color: var(--text-2);
    font-size: 13px;
    font-weight: 600;
}

.request-segmented button:hover,
.request-segmented button.on {
    border-color: var(--gold-line);
    background: var(--gold-soft);
    color: var(--gold-bright);
}

.request-form select {
    width: 100%;
    padding: 0 12px;
}

.request-form textarea {
    width: 100%;
    min-height: 70px;
    padding: 11px 12px;
    resize: vertical;
}

.request-form select:focus,
.request-form textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.1);
}

.request-form input[type="range"] {
    width: 100%;
    height: 5px;
    appearance: none;
    border-radius: 999px;
    outline: none;
    background: linear-gradient(90deg, var(--gold) var(--p, 12%), var(--surface-3) var(--p, 12%));
}

.request-form input[type="range"]::-webkit-slider-thumb {
    width: 18px;
    height: 18px;
    appearance: none;
    border: 3px solid var(--bg);
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 0 1px var(--gold);
    cursor: pointer;
}

.request-form input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border: 3px solid var(--bg);
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 0 1px var(--gold);
    cursor: pointer;
}

.request-range-scale {
    display: flex;
    justify-content: space-between;
    color: var(--text-3);
    font-size: 10px;
}

.request-context {
    padding: 14px;
    border: 1px solid var(--gold-line);
    border-radius: var(--r-3);
    background: linear-gradient(135deg, rgba(201, 165, 92, 0.09), rgba(255, 255, 255, 0.025));
}

.request-context-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.request-context-head b {
    color: var(--text);
    font-size: 11px;
    font-weight: 600;
    text-align: right;
}

.request-context p {
    margin-top: 7px;
    color: var(--text-2);
    font-size: 11px;
    line-height: 1.5;
}

.request-context-stats {
    display: flex;
    gap: 28px;
    margin-top: 12px;
}

.request-context-stats b,
.request-context-stats small {
    display: block;
}

.request-context-stats b {
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 18px;
}

.request-context-stats small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 10px;
}

.request-developers {
    margin-top: 12px;
}

.request-developers > small {
    color: var(--text-3);
    font-size: 9px;
    letter-spacing: 0.5px;
}

.request-developers > div {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 7px;
}

.request-developers span {
    padding: 4px 8px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text-2);
    font-size: 10px;
}

.request-submit {
    position: sticky;
    bottom: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    flex: none;
    box-shadow: 0 -14px 22px var(--surface);
}

.request-privacy {
    color: var(--text-3);
    font-size: 10px;
    text-align: center;
}

.request-privacy span {
    color: var(--gold-bright);
}

@media (max-width: 767px) {
    .request-trigger {
        width: 34px;
        padding: 0;
    }

    .request-trigger span {
        display: none;
    }

    .request-sheet {
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        width: 100%;
        max-height: 92dvh;
        padding: 22px 16px calc(18px + env(safe-area-inset-bottom));
        border-radius: var(--r-5) var(--r-5) 0 0;
        transform: translateY(102%);
    }

    .request-sheet.show {
        transform: translateY(0);
    }

    .request-form-grid {
        grid-template-columns: 1fr;
    }
}

/* =============================================================
   LOCATION INTELLIGENCE DRAWER
   ============================================================= */
.request-context-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 13px;
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
}

.request-context-link:hover {
    color: var(--text);
}

.request-context-link span {
    font-size: 15px;
    transition: transform var(--motion-fast) var(--ease);
}

.request-context-link:hover span {
    transform: translate(2px, -2px);
}

.location-drawer {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 13;
    display: flex;
    flex-direction: column;
    gap: 18px;
    width: min(440px, 40vw);
    overflow-y: auto;
    padding: 24px;
    background: var(--surface);
    border-left: 1px solid var(--border-strong);
    box-shadow: -20px 0 60px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(102%);
    transition: opacity var(--motion-base) var(--ease), transform var(--motion-smooth) var(--ease-out), visibility 0s linear var(--motion-smooth);
}

.location-drawer.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(0);
    transition: opacity var(--motion-base) var(--ease), transform var(--motion-smooth) var(--ease-out), visibility 0s;
}

.location-head,
.location-summary,
.location-section-title,
.route-preview-top {
    display: flex;
    align-items: center;
}

.location-head,
.location-section-title,
.route-preview-top {
    justify-content: space-between;
    gap: 12px;
}

.location-kicker {
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.2px;
}

.location-head h2 {
    margin-top: 5px;
    font-family: var(--font-serif);
    font-size: 27px;
    line-height: 1.1;
}

.location-summary {
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--border-strong);
    border-radius: var(--r-3);
    background: linear-gradient(135deg, var(--gold-soft), rgba(255, 255, 255, 0.025));
}

.location-score {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 22px;
}

.location-summary b,
.location-summary small {
    display: block;
}

.location-summary b {
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
}

.location-summary small {
    margin-top: 4px;
    color: var(--text-3);
    font-size: 10px;
}

.location-section-title {
    margin-top: 2px;
}

.location-section-title span {
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
}

.location-section-title small {
    color: var(--text-3);
    font-size: 10px;
}

.access-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.access-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 70px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    background: var(--surface-2);
    text-align: left;
    transition: background var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease), transform var(--motion-fast) var(--ease);
}

.access-card:hover,
.access-card.selected {
    border-color: var(--gold-line);
    background: var(--gold-soft);
    transform: translateY(-2px);
}

.access-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
}
.access-icon svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.access-card b,
.access-card strong,
.access-card small {
    display: block;
}

.access-card b {
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 16px;
}

.access-card strong {
    margin-top: 1px;
    color: var(--text);
    font-size: 10px;
    font-weight: 600;
}

.access-card small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 9px;
    white-space: nowrap;
}

.access-card i {
    position: absolute;
    top: 9px;
    right: 9px;
    color: var(--text-3);
    font-size: 13px;
    font-style: normal;
}

.area-catalog {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.catalog-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 11px;
    border: 1px solid var(--border);
    border-radius: var(--r-2);
    background: rgba(255, 255, 255, 0.025);
    transition: background var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease);
}

.catalog-item.saved {
    border-color: var(--gold-line);
    background: var(--gold-soft);
}

.catalog-item > div {
    min-width: 0;
}

.catalog-item small,
.catalog-item b,
.catalog-item span {
    display: block;
}

.catalog-item small {
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.7px;
    text-transform: uppercase;
}

.catalog-item b {
    margin-top: 2px;
    color: var(--text);
    font-size: 11px;
    font-weight: 600;
}

.catalog-item span {
    overflow: hidden;
    margin-top: 2px;
    color: var(--text-3);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.catalog-item button {
    flex: 0 0 auto;
    padding: 6px 8px;
    border: 1px solid var(--border-strong);
    border-radius: 7px;
    color: var(--text-2);
    font-size: 10px;
    font-weight: 700;
    transition: background var(--motion-fast) var(--ease), color var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease);
}

.catalog-item button:hover,
.catalog-item.saved button {
    border-color: var(--gold-line);
    background: var(--gold-soft);
    color: var(--gold-bright);
}

.route-preview {
    padding: 13px;
    border: 1px solid var(--gold-line);
    border-radius: var(--r-3);
    background: linear-gradient(135deg, rgba(201, 165, 92, 0.1), rgba(255, 255, 255, 0.025));
}

.route-preview-top span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1px;
}

.route-preview-top b {
    color: var(--text-2);
    font-size: 10px;
    font-weight: 500;
    text-align: right;
}

.route-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.08);
}

.route-preview p {
    margin: 9px 0 12px;
    color: var(--text-2);
    font-size: 11px;
    line-height: 1.5;
}

.route-3d-btn {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    flex: none;
}

.route-3d-btn:disabled {
    cursor: default;
    opacity: 0.45;
}

.route-3d-btn span {
    font-size: 16px;
}

.location-source-note {
    padding-bottom: 2px;
    color: var(--text-3);
    font-size: 9px;
    line-height: 1.5;
    text-align: center;
}

@media (max-width: 767px) {
    .location-drawer {
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        width: 100%;
        max-height: 92dvh;
        padding: 20px 16px calc(18px + env(safe-area-inset-bottom));
        border-radius: var(--r-5) var(--r-5) 0 0;
        transform: translateY(102%);
    }

    .location-drawer.show {
        transform: translateY(0);
    }
}

/* =============================================================
   CINEMATIC AREA STORY / PERSONALIZED LOCATION CATALOGUE
   ============================================================= */
.story-launch {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px;
    border: 1px solid var(--gold-line);
    border-radius: var(--r-3);
    background: linear-gradient(135deg, rgba(201, 165, 92, 0.13), rgba(255, 255, 255, 0.035));
    text-align: left;
    transition: border-color var(--motion-fast) var(--ease), background var(--motion-fast) var(--ease), transform var(--motion-fast) var(--ease);
}

.story-launch:hover {
    border-color: var(--gold);
    background: rgba(201, 165, 92, 0.18);
    transform: translateY(-2px);
}

.story-launch-play {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    padding-left: 2px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
    font-size: 10px;
}

.story-launch b,
.story-launch small {
    display: block;
}

.story-launch b {
    color: var(--text);
    font-size: 11px;
    font-weight: 700;
}

.story-launch small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 10px;
}

.story-launch i {
    margin-left: auto;
    color: var(--gold-bright);
    font-size: 17px;
    font-style: normal;
}

.area-story {
    position: absolute;
    inset: 0;
    z-index: 16;
    overflow: hidden;
    background: rgba(3, 5, 8, 0.18);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.55s var(--ease), visibility 0s linear 0.55s;
}

.app.story-mode {
    overflow: hidden;
}

.app.story-mode .topbar,
.app.story-mode .map-controls,
.app.story-mode .search,
.app.story-mode .filter-chips,
.app.story-mode .ai-response,
.app.story-mode .smart-bar,
.app.story-mode .carousel,
.app.story-mode .results-pill {
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--motion-base) var(--ease);
}

.area-story.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.55s var(--ease), visibility 0s;
}

.area-story-vignette {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(4, 6, 9, 0.84) 0%, rgba(4, 6, 9, 0.44) 38%, rgba(4, 6, 9, 0.04) 74%),
        linear-gradient(0deg, rgba(4, 6, 9, 0.9) 0%, transparent 31%, rgba(4, 6, 9, 0.35) 100%);
    pointer-events: none;
}

.area-story-vignette {
    background:
        linear-gradient(90deg, rgba(4, 6, 9, 0.62) 0%, rgba(4, 6, 9, 0.16) 42%, rgba(4, 6, 9, 0.02) 82%),
        linear-gradient(0deg, rgba(4, 6, 9, 0.62) 0%, transparent 34%, rgba(4, 6, 9, 0.14) 100%);
}

.area-story-head {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: 68px;
    padding: 0 clamp(18px, 5vw, 72px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
    background: linear-gradient(180deg, rgba(4, 6, 9, 0.55), transparent);
}

.area-story-brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.4px;
}

.area-story-brand .brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--gold-bright), var(--gold));
    color: #0a0a0b;
    font-family: var(--font-serif);
    font-size: 17px;
}

.area-story-brand i {
    width: 20px;
    height: 1px;
    background: var(--gold);
}

.area-story-brand b {
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
}

.area-story-live {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-left: auto;
    color: rgba(255, 255, 255, 0.5);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.area-story-live span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.08);
}

.area-story-copy {
    position: absolute;
    top: clamp(130px, 24vh, 220px);
    left: clamp(22px, 8vw, 120px);
    z-index: 2;
    width: min(480px, calc(100% - 44px));
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.4);
}

.area-story-copy.reveal {
    animation: storyCopyIn 0.7s var(--ease-out) both;
}

@keyframes storyCopyIn {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

.area-story-chapter {
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.8px;
}

.area-story-copy h2 {
    max-width: 470px;
    margin-top: 14px;
    color: var(--text);
    font-family: var(--font-serif);
    font-size: clamp(38px, 5.3vw, 74px);
    line-height: 0.98;
    letter-spacing: -2px;
}

.area-story-copy p {
    max-width: 405px;
    margin-top: 19px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 14px;
    line-height: 1.7;
}

.area-story-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 22px;
}

.area-story-fact {
    padding: 6px 9px;
    border: 1px solid rgba(201, 165, 92, 0.35);
    border-radius: 999px;
    background: rgba(201, 165, 92, 0.09);
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
}

.area-story-points {
    position: absolute;
    right: clamp(20px, 6vw, 88px);
    bottom: 135px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 7px;
}

.story-point {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    background: rgba(10, 12, 16, 0.58);
    color: rgba(255, 255, 255, 0.78);
    font-size: 10px;
    backdrop-filter: blur(12px);
    animation: storyPointIn 0.45s var(--ease-out) both;
}

.story-point:nth-child(2) { animation-delay: 80ms; }
.story-point:nth-child(3) { animation-delay: 160ms; }
.story-point:nth-child(4) { animation-delay: 240ms; }

@keyframes storyPointIn {
    from { opacity: 0; transform: translateX(12px); }
    to { opacity: 1; transform: translateX(0); }
}

.story-point i {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 10px var(--gold);
}

.story-map-marker {
    display: flex;
    align-items: center;
    gap: 5px;
    transform: translateY(-5px);
    animation: storyMarkerIn 0.55s var(--ease-out) both;
}

.story-map-marker span {
    display: inline-block;
    width: 9px;
    height: 9px;
    border: 2px solid #0a0a0b;
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 0 5px rgba(232, 200, 120, 0.18), 0 0 20px rgba(232, 200, 120, 0.7);
}

.story-map-marker b {
    padding: 5px 8px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    background: rgba(10, 12, 16, 0.76);
    color: rgba(255, 255, 255, 0.88);
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
    backdrop-filter: blur(10px);
}

.location-map-marker { transform: translateY(-5px); }
.location-map-marker button {
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--info);
}
.location-map-marker svg,
.custom-destination-marker svg {
    width: 29px;
    height: 29px;
    padding: 6px;
    border: 2px solid #0a0a0b;
    border-radius: 50% 50% 50% 4px;
    background: var(--info);
    fill: #101217;
    stroke: #101217;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    box-shadow: 0 0 0 5px rgba(96, 165, 250, 0.16), 0 0 16px rgba(96, 165, 250, 0.7);
    transform: rotate(-45deg);
}
.location-map-marker svg > *,
.custom-destination-marker svg > * { transform: rotate(45deg); transform-origin: center; }
.location-map-marker b {
    padding: 4px 7px;
    border: 1px solid rgba(96, 165, 250, 0.3);
    border-radius: 999px;
    background: rgba(10, 12, 16, 0.72);
    color: rgba(255, 255, 255, 0.78);
    font-size: 9px;
    font-weight: 700;
    white-space: nowrap;
    backdrop-filter: blur(10px);
}
.custom-destination-marker svg { background: var(--gold-bright); box-shadow: 0 0 0 5px rgba(232, 200, 120, 0.18), 0 0 16px rgba(232, 200, 120, 0.72); }
.route-pick-btn {
    width: 100%;
    margin: 9px 0 7px;
    padding: 9px 10px;
    border: 1px dashed var(--border-strong);
    border-radius: var(--r-2);
    color: var(--text-2);
    font-size: 10px;
    font-weight: 700;
    text-align: left;
}
.route-pick-btn:hover, .route-pick-btn.is-picking { border-color: var(--gold); color: var(--gold-bright); background: var(--gold-soft); }

@keyframes storyMarkerIn {
    from { opacity: 0; transform: translateY(4px) scale(0.9); }
    to { opacity: 1; transform: translateY(-5px) scale(1); }
}

.area-story-player {
    position: absolute;
    right: clamp(18px, 5vw, 72px);
    bottom: 24px;
    left: clamp(18px, 5vw, 72px);
    z-index: 3;
    display: flex;
    align-items: center;
    gap: 14px;
    height: 52px;
    padding: 0 14px;
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 14px;
    background: rgba(10, 12, 16, 0.72);
    box-shadow: 0 14px 38px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
}

.story-player-btn {
    display: grid;
    place-items: center;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
}

.story-play-triangle {
    margin-left: 2px;
    font-size: 10px;
}

.story-pause-bars {
    display: none;
    gap: 3px;
}

.story-pause-bars i {
    width: 2px;
    height: 11px;
    background: currentColor;
}

.area-story.is-playing .story-play-triangle {
    display: none;
}

.area-story.is-playing .story-pause-bars {
    display: inline-flex;
}

.story-time {
    display: inline-flex;
    gap: 5px;
    color: rgba(255, 255, 255, 0.48);
    font-size: 10px;
    white-space: nowrap;
}

.story-time b {
    color: var(--text);
}

.story-progress {
    position: relative;
    flex: 1;
    height: 3px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.15);
}

.story-progress span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--gold), var(--gold-bright));
}

.story-chapters {
    display: flex;
    gap: 4px;
}

.story-chapters button {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    color: var(--text-3);
    font-size: 9px;
    transition: background var(--motion-fast) var(--ease), color var(--motion-fast) var(--ease);
}

.story-chapters button:hover,
.story-chapters button.on {
    background: var(--gold-soft);
    color: var(--gold-bright);
}

.story-next {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--gold-bright);
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.story-next span {
    font-size: 16px;
}

@media (max-width: 767px) {
    .area-story-vignette {
        background:
            linear-gradient(180deg, rgba(4, 6, 9, 0.8) 0%, rgba(4, 6, 9, 0.25) 48%, rgba(4, 6, 9, 0.92) 100%),
            linear-gradient(90deg, rgba(4, 6, 9, 0.55), transparent);
    }

    .area-story-head {
        height: 58px;
        padding: 0 14px;
    }

    .area-story-brand {
        gap: 6px;
        font-size: 9px;
    }

    .area-story-brand i,
    .area-story-brand b,
    .area-story-live {
        display: none;
    }

    .area-story-copy {
        top: 105px;
        left: 18px;
        width: calc(100% - 36px);
    }

    .area-story-copy h2 {
        font-size: clamp(37px, 12vw, 56px);
        letter-spacing: -1.4px;
    }

    .area-story-copy p {
        max-width: 330px;
        font-size: 12px;
    }

    .area-story-points {
        right: 18px;
        bottom: 116px;
        left: 18px;
        align-items: flex-start;
    }

    .area-story-player {
        right: 12px;
        bottom: calc(12px + env(safe-area-inset-bottom));
        left: 12px;
        gap: 9px;
        padding: 0 9px;
    }

    .story-chapters {
        display: none;
    }

    .story-next {
        font-size: 10px;
    }
}

/* =============================================================
   MAP-FIRST DISCOVERY AND REQUEST CONTEXT
   ============================================================= */
.area-pin-container {
    pointer-events: auto;
}

.area-pin {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 138px;
    max-width: 188px;
    padding: 8px 11px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 11px;
    background: rgba(15, 17, 21, 0.86);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.38);
    backdrop-filter: blur(16px);
    transform: translateY(-5px);
    transition: transform var(--motion-fast) var(--ease), border-color var(--motion-fast) var(--ease), background var(--motion-fast) var(--ease);
}

.area-pin::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 18px;
    width: 9px;
    height: 9px;
    border-right: 1px solid rgba(255, 255, 255, 0.16);
    border-bottom: 1px solid rgba(255, 255, 255, 0.16);
    background: inherit;
    transform: rotate(45deg);
}

.area-pin:hover,
.area-pin.is-active {
    border-color: var(--gold);
    background: rgba(35, 31, 22, 0.92);
    transform: translateY(-8px) scale(1.02);
}

.area-pin span,
.area-pin b,
.area-pin small {
    display: block;
}

.area-pin span {
    color: var(--text);
    font-size: 10px;
    font-weight: 700;
}

.area-pin b {
    margin-top: 2px;
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 14px;
    line-height: 1.25;
    white-space: nowrap;
}

.area-pin small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 9px;
    line-height: 1.3;
}

.area-pin.attention {
    animation: areaPinAttention 0.65s ease-in-out 2;
}

@keyframes areaPinAttention {
    50% { border-color: var(--gold-bright); box-shadow: 0 0 0 7px rgba(201, 165, 92, 0.12), 0 12px 30px rgba(0,0,0,.4); }
}

.map-context-card {
    position: absolute;
    top: calc(var(--header-h) + 18px);
    left: clamp(16px, 4vw, 56px);
    z-index: 8;
    width: min(370px, calc(100% - 32px));
    max-height: calc(100dvh - var(--header-h) - 112px);
    overflow-y: auto;
    padding: 16px;
    border: 1px solid var(--border-strong);
    border-radius: 18px;
    background: rgba(16, 17, 20, 0.9);
    box-shadow: 0 18px 58px rgba(0, 0, 0, 0.44);
    backdrop-filter: blur(24px);
    opacity: 0;
    pointer-events: none;
    transform: translateX(-12px) scale(0.98);
    transition: opacity var(--motion-base) var(--ease), transform var(--motion-smooth) var(--ease-out);
}

.map-context-card.show {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0) scale(1);
}

.app.has-filters .map-context-card {
    top: calc(var(--header-h) + var(--chips-h) + 24px);
}

.map-context-head,
.map-context-section,
.map-route-status,
.map-context-actions {
    display: flex;
    align-items: center;
}

.map-context-head,
.map-context-section {
    justify-content: space-between;
    gap: 12px;
}

.map-context-kicker {
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.2px;
}

.map-context-head h2 {
    margin-top: 3px;
    font-family: var(--font-serif);
    font-size: 25px;
    line-height: 1.1;
}

.map-context-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--surface-2);
    color: var(--text-3);
    font-size: 18px;
}

.map-context-summary {
    margin-top: 9px;
    color: var(--text-2);
    font-size: 11px;
    line-height: 1.5;
}

.map-context-stats {
    display: grid;
    grid-template-columns: 0.85fr 0.85fr 1.3fr;
    gap: 6px;
    margin-top: 12px;
}

.map-context-stats span {
    min-width: 0;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.025);
}

.map-context-stats b,
.map-context-stats small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
}

.map-context-stats b {
    color: var(--text);
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}

.map-context-stats .profit-metric {
    background: rgba(16, 185, 129, 0.05);
    border-color: rgba(16, 185, 129, 0.15);
}

.map-context-stats .profit-metric b {
    color: #10b981;
}

.map-context-stats small {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 8px;
    white-space: nowrap;
}

.map-context-section {
    margin-top: 13px;
}

.map-context-section span {
    color: var(--text);
    font-size: 10px;
    font-weight: 700;
}

.map-context-section small {
    color: var(--gold-bright);
    font-size: 9px;
}

.map-context-access {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 7px;
}

.map-access-empty {
    grid-column: 1 / -1;
    padding: 10px;
    border: 1px dashed var(--border-strong);
    border-radius: 9px;
    color: var(--text-2);
}

.map-access-empty b,
.map-access-empty small {
    display: block;
}

.map-access-empty b { font-size: 10px; }
.map-access-empty small { margin-top: 3px; color: var(--text-3); font-size: 9px; line-height: 1.4; }

.location-empty {
    grid-column: 1 / -1;
    padding: 14px;
    border: 1px dashed var(--border-strong);
    border-radius: var(--r-2);
}

.location-empty b,
.location-empty small { display: block; }
.location-empty b { color: var(--text-2); font-size: 12px; }
.location-empty small { margin-top: 4px; color: var(--text-3); font-size: 10px; line-height: 1.45; }

.offplan-pin {
    border-color: var(--gold-line);
}

.project-location-pin {
    min-width: 156px;
    max-width: 222px;
}

.project-location-pin b {
    font-family: var(--font-sans);
    font-size: 10px;
}

.project-developer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 10px;
    padding-top: 9px;
    border-top: 1px solid var(--border);
}

.project-developer b {
    overflow: hidden;
    color: var(--text-2);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.project-developer span,
.project-disclaimer {
    color: var(--text-3);
    font-size: 8px;
}

.project-developer span { flex-shrink: 0; }
.project-disclaimer { margin-top: 7px; line-height: 1.35; }

.map-access-item {
    display: grid;
    grid-template-columns: 1fr 27px;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface-2);
    transition: border-color var(--motion-fast) var(--ease), background var(--motion-fast) var(--ease);
}

.map-access-item:hover,
.map-access-item.selected,
.map-access-item.saved {
    border-color: var(--gold-line);
    background: var(--gold-soft);
}

.map-access-item > button:first-child {
    display: grid;
    grid-template-columns: 22px 1fr auto;
    align-items: center;
    gap: 5px;
    min-width: 0;
    padding: 7px;
    text-align: left;
}

.map-access-item > button:first-child span {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border: 1px solid var(--gold-line);
    border-radius: 50%;
    color: var(--gold-bright);
    font-size: 8px;
    font-weight: 800;
}

.map-access-item b {
    overflow: hidden;
    color: var(--text-2);
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map-access-item small {
    color: var(--gold-bright);
    font-size: 9px;
    white-space: nowrap;
}

.map-access-save {
    border-left: 1px solid var(--border);
    color: var(--gold-bright);
    font-size: 13px;
    font-weight: 800;
}

.map-route-status {
    gap: 7px;
    margin-top: 9px;
    padding: 7px 9px;
    border: 1px solid var(--gold-line);
    border-radius: 9px;
    background: var(--gold-soft);
}

.map-route-status b {
    overflow: hidden;
    color: var(--text-2);
    font-size: 9px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map-route-status button {
    margin-left: auto;
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
}

.map-context-actions {
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 13px;
}

.map-context-secondary,
.map-context-primary {
    min-height: 34px;
    border-radius: 9px;
    font-size: 9px;
    font-weight: 700;
}

.map-context-secondary {
    flex: 1;
    padding: 0 9px;
    border: 1px solid var(--border-strong);
    color: var(--text-2);
}

.map-context-primary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 0 0 100%;
    padding: 0 11px;
    background: var(--gold);
    color: #0a0a0b;
}

.request-map-summary {
    margin: -6px 0 3px;
    padding: 12px;
    border: 1px solid var(--gold-line);
    border-radius: var(--r-3);
    background: linear-gradient(135deg, rgba(201, 165, 92, 0.1), rgba(255,255,255,0.025));
}

.request-map-summary-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.request-map-summary-head span {
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1px;
}

.request-map-summary-head b {
    color: var(--text);
    font-size: 11px;
}

.request-map-summary-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 9px;
}

.request-map-summary-chips span {
    padding: 4px 7px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text-2);
    font-size: 9px;
}

.request-map-summary > small {
    display: block;
    margin-top: 8px;
    color: var(--text-3);
    font-size: 9px;
    line-height: 1.45;
}

@media (max-width: 767px) {
    .area-pin {
        min-width: 112px;
        padding: 7px 9px;
    }

    .map-context-card {
        top: calc(var(--header-h) + 10px);
        right: 10px;
        left: 10px;
        width: auto;
        max-height: min(52dvh, 390px);
        padding: 13px;
    }

    .app.has-filters .map-context-card {
        top: calc(var(--header-h) + var(--chips-h) + 14px);
    }

    .map-context-head h2 {
        font-size: 21px;
    }

    .map-context-summary {
        display: none;
    }

    .map-context-stats {
        margin-top: 9px;
    }
}

/* =============================================================
   VOICE MODE — transparent gradient wash on the map (~1/5 viewport)
   Not a modal/card: a soft bottom sheet that keeps the map visible.
   ============================================================= */
.voice-mode {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(var(--search-h) + env(safe-area-inset-bottom));
    z-index: 12;
    height: 20vh;
    min-height: 140px;
    max-height: 180px;
    pointer-events: none;
    opacity: 0;
    transform: translateY(18px);
    transition:
        opacity 0.28s var(--ease),
        transform 0.34s var(--ease-out);
}
.voice-mode[hidden] { display: none !important; }
.voice-mode.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: none;
}
.voice-mode.show .voice-mode-sheet,
.voice-mode.show .voice-mode-orb,
.voice-mode.show .voice-mode-close {
    pointer-events: auto;
}
.app.results-open .voice-mode {
    bottom: calc(var(--carousel-h) + env(safe-area-inset-bottom));
}

.voice-mode-sheet {
    position: relative;
    height: 100%;
    overflow: hidden;
    border: none;
    border-radius: 0;
    background:
        linear-gradient(
            180deg,
            rgba(10, 10, 11, 0) 0%,
            rgba(10, 10, 11, 0.18) 24%,
            rgba(12, 12, 14, 0.42) 58%,
            rgba(10, 10, 11, 0.58) 100%
        );
    backdrop-filter: blur(8px) saturate(125%);
    -webkit-backdrop-filter: blur(8px) saturate(125%);
    mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 100%);
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 100%);
    color: var(--text);
    font-family: var(--font-sans);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 18px 20px 14px;
    box-shadow: none;
}
.voice-mode-glow {
    position: absolute;
    left: 8%;
    right: 8%;
    bottom: 8%;
    height: 70%;
    background:
        radial-gradient(ellipse at 28% 70%, rgba(201, 165, 92, 0.18), transparent 55%),
        radial-gradient(ellipse at 72% 80%, rgba(96, 165, 250, 0.08), transparent 50%);
    pointer-events: none;
    filter: blur(2px);
    animation: voiceGlowDrift 8s ease-in-out infinite alternate;
}
@keyframes voiceGlowDrift {
    from { opacity: 0.55; transform: translateY(4px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1.04); }
}

.voice-mode-head {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}
.voice-mode-live {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--gold-bright);
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.45);
}
.voice-mode-live span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 10px var(--gold-bright);
    animation: voiceStateDot 1.3s ease-in-out infinite;
}
.voice-mode.is-speaking .voice-mode-live { color: var(--info); }
.voice-mode.is-speaking .voice-mode-live span {
    background: var(--info);
    box-shadow: 0 0 10px var(--info);
}
.voice-mode.is-processing .voice-mode-live span { animation-duration: 0.7s; }
@keyframes voiceStateDot {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

.voice-mode-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(10, 10, 11, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-2);
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: background 0.15s var(--ease), color 0.15s var(--ease);
}
.voice-mode-close:hover {
    background: rgba(10, 10, 11, 0.55);
    color: var(--text);
}

.voice-mode-body {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 0;
}

.voice-mode-orb {
    position: relative;
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid rgba(201, 165, 92, 0.5);
    background: radial-gradient(circle at 35% 30%, rgba(255, 230, 170, 0.2), rgba(201, 165, 92, 0.08) 62%, rgba(10, 10, 11, 0.35) 78%);
    color: var(--gold-bright);
    display: grid;
    place-items: center;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(201, 165, 92, 0.14);
    backdrop-filter: blur(8px);
    transition: transform 0.18s var(--ease), border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.voice-mode-orb:hover { transform: scale(1.04); }
.voice-mode-orb-ring {
    position: absolute;
    inset: -7px;
    border-radius: 50%;
    border: 1px solid rgba(201, 165, 92, 0.28);
    opacity: 0;
    pointer-events: none;
}
.voice-mode.is-listening .voice-mode-orb-ring {
    animation: voiceOrbRing 1.8s ease-out infinite;
}
.voice-mode.is-listening .voice-mode-orb {
    animation: orbBreath 2.2s ease-in-out infinite;
}
.voice-mode.is-speaking .voice-mode-orb {
    border-color: rgba(96, 165, 250, 0.65);
    color: var(--info);
    box-shadow: 0 0 22px rgba(96, 165, 250, 0.2);
    animation: orbSpeak 1.1s ease-in-out infinite;
}
.voice-mode.is-processing .voice-mode-orb {
    animation: orbProcess 1s ease-in-out infinite;
}
.voice-mode-orb-core {
    position: absolute;
    inset: 10px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, rgba(255, 220, 160, 0.32), transparent 72%);
    pointer-events: none;
}
.voice-stop-icon { display: none; }
.voice-mode.is-listening .voice-mic-icon { display: none; }
.voice-mode.is-listening .voice-stop-icon { display: block; }
@keyframes voiceOrbRing {
    0% { transform: scale(0.86); opacity: 0.55; }
    100% { transform: scale(1.28); opacity: 0; }
}
@keyframes orbBreath {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}
@keyframes orbSpeak {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.07); }
}
@keyframes orbProcess {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

.voice-mode-copy {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.voice-mode-transcript {
    font-family: var(--font-display, "Fraunces", serif);
    font-size: 18px;
    line-height: 1.28;
    font-weight: 500;
    color: var(--text);
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.45);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.5em;
}
.voice-mode-hint {
    font-size: 11px;
    color: rgba(164, 164, 173, 0.9);
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.voice-mode.is-listening .voice-mode-hint,
.voice-mode.is-speaking .voice-mode-hint,
.voice-mode.is-processing .voice-mode-hint {
    opacity: 0.7;
}

.voice-mode-wave {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 3px;
    height: 16px;
    margin-top: 10px;
    margin-left: 66px;
}
.voice-mode-wave span {
    display: block;
    width: 2.5px;
    height: 5px;
    border-radius: 2px;
    background: var(--gold-bright);
    opacity: 0.35;
}
.voice-mode.is-listening .voice-mode-wave span {
    animation: voiceBar 0.85s ease-in-out infinite;
}
.voice-mode.is-speaking .voice-mode-wave span {
    background: var(--info);
    animation: voiceBarSpeak 0.6s ease-in-out infinite;
}
.voice-mode.is-processing .voice-mode-wave span {
    animation: voiceBar 1.1s ease-in-out infinite;
    opacity: 0.55;
}
.voice-mode-wave span:nth-child(odd) { animation-delay: 0.08s; }
.voice-mode-wave span:nth-child(3n) { animation-delay: 0.16s; }
.voice-mode-wave span:nth-child(5n) { animation-delay: 0.24s; }
@keyframes voiceBar {
    0%, 100% { height: 5px; opacity: 0.35; }
    50% { height: 15px; opacity: 1; }
}
@keyframes voiceBarSpeak {
    0%, 100% { height: 7px; opacity: 0.5; }
    50% { height: 15px; opacity: 1; }
}

@media (max-width: 600px) {
    .voice-mode {
        height: 22vh;
        min-height: 132px;
        max-height: 168px;
    }
    .voice-mode-sheet { padding: 16px 16px 12px; }
    .voice-mode-transcript { font-size: 16px; }
    .voice-mode-orb { width: 48px; height: 48px; }
    .voice-mode-wave { margin-left: 62px; }
}

@media (prefers-reduced-motion: reduce) {
    .sheet,
    .modal,
    .assistant-drawer,
    .location-drawer,
    .voice-mode,
    .search,
    .toast,
    .snackbar {
        transition-duration: 160ms !important;
    }
    .sheet,
    .modal,
    .assistant-drawer,
    .location-drawer,
    .voice-mode,
    .search {
        transform: none !important;
    }
    .voice-mode-glow,
    .voice-mode-orb,
    .voice-mode-orb-ring,
    .voice-mode-wave span,
    .voice-mode-live span {
        animation: none !important;
    }
    .voice-mode-orb { transform: scale(1); }
}

/* =============================================================
   LOCATION FILM VISUALS — data, imagery and route evidence
   ============================================================= */
.area-story-visual {
    position: absolute;
    top: clamp(112px, 16vh, 150px);
    right: clamp(20px, 7vw, 96px);
    z-index: 2;
    width: min(430px, 38vw);
    color: var(--text);
}

.area-story-visual.reveal {
    animation: storyVisualIn 0.65s var(--ease-out) both;
}

@keyframes storyVisualIn {
    from { opacity: 0; transform: translateY(18px) scale(0.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.story-visual-eyebrow {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 10px 10px;
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.2px;
}

.story-visual-eyebrow span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 0 4px rgba(201, 165, 92, 0.12);
}

.story-visual-photo,
.story-visual-panel {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
    background: rgba(12, 14, 18, 0.86);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.story-visual-photo {
    position: relative;
    height: 264px;
}

.story-visual-photo img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    filter: saturate(0.85) contrast(1.06);
}

.story-photo-shade {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 36%;
    background: rgba(5, 7, 10, 0.76);
}

.story-visual-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    padding: 6px 8px;
    border: 1px solid var(--gold-line);
    border-radius: 999px;
    background: rgba(10, 12, 16, 0.74);
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
}

.story-photo-thumbs {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    display: flex;
    gap: 5px;
}

.story-photo-thumbs img {
    width: 38px;
    height: 28px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 5px;
    object-fit: cover;
    opacity: 0.7;
}

.story-photo-thumbs img.is-selected {
    border-color: var(--gold-bright);
    opacity: 1;
}

.story-photo-caption {
    position: absolute;
    right: 16px;
    bottom: 14px;
    left: 16px;
}

.story-photo-caption b,
.story-photo-caption small {
    display: block;
}

.story-photo-caption b {
    font-size: 18px;
    font-weight: 600;
}

.story-photo-caption small {
    margin-top: 4px;
    color: rgba(255, 255, 255, 0.68);
    font-size: 10px;
}

.story-visual-strip {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-top: 0;
    border-radius: 0 0 14px 14px;
    background: rgba(12, 14, 18, 0.94);
}

.story-visual-strip span {
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 20px;
}

.story-visual-strip small {
    color: var(--text-2);
    font-size: 10px;
}

.story-visual-panel {
    padding: 18px;
}

.story-visual-panel-title small,
.story-visual-panel-title strong {
    display: block;
}

.story-visual-panel-title small {
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.1px;
}

.story-visual-panel-title strong {
    margin-top: 7px;
    color: var(--text);
    font-family: var(--font-serif);
    font-size: 27px;
    font-weight: 500;
}

.story-market-bars {
    display: flex;
    align-items: end;
    gap: 8px;
    height: 86px;
    margin: 20px 0 16px;
    padding: 0 8px 0 0;
    border-bottom: 1px solid var(--border-strong);
}

.story-market-bars i {
    display: block;
    flex: 1;
    height: var(--bar);
    min-height: 18px;
    border-radius: 5px 5px 0 0;
    background: var(--gold);
    opacity: 0.82;
    transform-origin: bottom;
    animation: storyBarIn 0.55s var(--ease-out) both;
}

.story-market-bars i:nth-child(2) { background: var(--gold-bright); animation-delay: 70ms; }
.story-market-bars i:nth-child(3) { animation-delay: 140ms; }
.story-market-bars i:nth-child(4) { animation-delay: 210ms; }
.story-market-bars i:nth-child(5) { background: var(--gold-bright); animation-delay: 280ms; }
.story-market-bars i:nth-child(6) { animation-delay: 350ms; }

@keyframes storyBarIn {
    from { opacity: 0; transform: scaleY(0.15); }
    to { opacity: 0.82; transform: scaleY(1); }
}

.story-stat-grid,
.story-opportunity-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.story-stat-grid span,
.story-opportunity-stats span {
    min-width: 0;
}

.story-stat-grid b,
.story-stat-grid small,
.story-opportunity-stats b,
.story-opportunity-stats small {
    display: block;
}

.story-stat-grid b,
.story-opportunity-stats b {
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.story-stat-grid small,
.story-opportunity-stats small {
    margin-top: 4px;
    color: var(--text-3);
    font-size: 8px;
    line-height: 1.3;
}

.story-developer-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 18px;
}

.story-developer-row span {
    padding: 5px 8px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    color: var(--text-2);
    font-size: 9px;
}

.story-route-panel {
    display: grid;
    grid-template-columns: 104px 1fr;
    align-items: center;
    gap: 18px;
}

.story-route-orbit {
    position: relative;
    display: grid;
    place-items: center;
    width: 104px;
    height: 104px;
    border: 1px solid rgba(201, 165, 92, 0.38);
    border-radius: 50%;
}

.story-route-orbit::before,
.story-route-orbit::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(201, 165, 92, 0.22);
    border-radius: 50%;
}

.story-route-orbit::before { inset: 14px; }
.story-route-orbit::after { inset: 29px; }

.story-route-orbit span,
.story-route-orbit i {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.story-route-orbit span { top: 17px; right: 18px; background: var(--info); box-shadow: 0 0 14px var(--info); }
.story-route-orbit i { bottom: 20px; left: 20px; background: var(--gold-bright); box-shadow: 0 0 14px var(--gold); }

.story-route-orbit b {
    color: var(--gold-bright);
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 500;
}

.story-route-panel > div:nth-child(2) small,
.story-route-panel > div:nth-child(2) strong,
.story-route-panel > div:nth-child(2) p {
    display: block;
}

.story-route-panel > div:nth-child(2) small {
    color: var(--gold-bright);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 1px;
}

.story-route-panel > div:nth-child(2) strong {
    margin-top: 7px;
    font-size: 18px;
}

.story-route-panel > div:nth-child(2) p {
    margin-top: 5px;
    color: var(--text-2);
    font-size: 10px;
}

.story-route-foot {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    padding-top: 13px;
    border-top: 1px solid var(--border);
    color: var(--text-3);
    font-size: 9px;
}

.story-service-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 18px;
}

.story-service-grid div {
    min-height: 74px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.025);
}

.story-service-grid span,
.story-service-grid b,
.story-service-grid small {
    display: block;
}

.story-service-grid span {
    color: var(--gold-bright);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.story-service-grid b {
    margin-top: 5px;
    color: var(--text);
    font-size: 10px;
}

.story-service-grid small {
    margin-top: 3px;
    overflow: hidden;
    color: var(--text-3);
    font-size: 9px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.story-opportunity-panel > p {
    margin-top: 18px;
    color: var(--text-2);
    font-size: 11px;
    line-height: 1.55;
}

.story-opportunity-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 18px;
    padding: 11px 12px;
    border: 1px solid var(--gold-line);
    border-radius: 10px;
    background: var(--gold-soft);
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 800;
}

.story-opportunity-cta span {
    font-size: 16px;
}

@media (max-width: 900px) {
    .area-story-visual {
        right: 28px;
        width: min(390px, 42vw);
    }

    .story-visual-photo {
        height: 224px;
    }
}

@media (max-width: 767px) {
    .area-story-visual {
        top: 302px;
        right: 18px;
        left: 18px;
        width: auto;
    }

    .area-story-points {
        display: none;
    }

    .story-visual-photo {
        height: 168px;
    }

    .story-visual-panel {
        padding: 14px;
    }

    .story-visual-panel-title strong {
        font-size: 21px;
    }

    .story-market-bars {
        height: 54px;
        margin: 12px 0;
    }

    .story-service-grid {
        margin-top: 12px;
    }

    .story-route-panel {
        grid-template-columns: 78px 1fr;
        gap: 12px;
    }

    .story-route-orbit {
        width: 78px;
        height: 78px;
    }

    .story-route-orbit b {
        font-size: 19px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .area-story-visual.reveal,
    .story-market-bars i {
        animation: none !important;
    }
}

/* =============================================================
   INVESTOR INTRO — product story surface
   ============================================================= */
.intro-audience {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.2px;
}

.intro-audience span {
    width: 22px;
    height: 1px;
    background: var(--gold);
}

.intro-secondary-cta {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 310px;
    min-height: 40px;
    margin-top: 8px;
    padding: 0 2px;
    color: var(--text-2);
    font-size: 11px;
    font-weight: 600;
    text-align: left;
}

.intro-secondary-cta:hover {
    color: var(--text);
}

.intro-product-preview {
    transform: none;
    animation: introRevealRightClean 0.8s 0.12s var(--ease-out) both;
}

@keyframes introRevealRightClean {
    from { opacity: 0; transform: translateX(28px); }
    to { opacity: 1; transform: translateX(0); }
}

.preview-flow {
    overflow: hidden;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 22px;
    background: #111217;
    box-shadow: 0 26px 90px rgba(0, 0, 0, 0.58), 0 0 0 8px rgba(255, 255, 255, 0.025);
}

.preview-flow-head,
.preview-flow-foot {
    display: flex;
    align-items: center;
}

.preview-flow-head {
    justify-content: space-between;
    padding-bottom: 14px;
    color: var(--gold-bright);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.2px;
}

.preview-flow-head b {
    color: var(--text-3);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
}

.preview-flow-card {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    min-height: 86px;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    background: #17181e;
}

.preview-flow-card.is-active {
    border-color: rgba(201, 165, 92, 0.5);
    background: #1b1a17;
}

.preview-flow-card.is-response {
    border-color: rgba(201, 165, 92, 0.22);
}

.preview-flow-index {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border: 1px solid rgba(201, 165, 92, 0.35);
    border-radius: 50%;
    color: var(--gold-bright);
    font-size: 10px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.preview-flow-copy {
    min-width: 0;
}

.preview-flow-copy small,
.preview-flow-copy strong,
.preview-flow-copy p {
    display: block;
}

.preview-flow-copy small {
    color: var(--gold-bright);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1px;
}

.preview-flow-copy strong {
    margin-top: 5px;
    overflow: hidden;
    color: rgba(255, 255, 255, 0.92);
    font-size: 15px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-flow-copy p {
    margin-top: 4px;
    overflow: hidden;
    color: var(--text-3);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-flow-copy p b {
    color: var(--text-2);
    font-variant-numeric: tabular-nums;
}

.preview-flow-status {
    align-self: start;
    padding: 5px 7px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    color: var(--text-3);
    font-size: 8px;
    font-weight: 700;
    white-space: nowrap;
}

.preview-flow-card.is-active .preview-flow-status,
.preview-flow-card.is-response .preview-flow-status {
    border-color: var(--gold-line);
    color: var(--gold-bright);
}

.preview-flow-line {
    position: relative;
    height: 18px;
    margin-left: 29px;
    border-left: 1px solid rgba(201, 165, 92, 0.35);
}

.preview-flow-line i {
    position: absolute;
    bottom: -2px;
    left: -3px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--gold);
}

.preview-flow-foot {
    justify-content: center;
    gap: 9px;
    padding-top: 16px;
    color: var(--text-3);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1px;
}

.preview-flow-foot i {
    color: var(--gold);
    font-style: normal;
}

.preview-flow-foot b {
    color: var(--gold-bright);
}

@media (max-width: 700px) {
    .preview-flow {
        padding: 12px;
        border-radius: 18px;
    }

    .preview-flow-card {
        grid-template-columns: 30px minmax(0, 1fr);
        gap: 9px;
        min-height: 74px;
        padding: 11px;
    }

    .preview-flow-status {
        display: none;
    }

    .preview-flow-copy strong {
        font-size: 13px;
    }

    .preview-flow-foot {
        gap: 6px;
        font-size: 7px;
    }
}

@media (min-width: 768px) and (max-height: 760px) {
    .preview-flow {
        padding: 14px;
    }

    .preview-flow-card {
        min-height: 68px;
        padding: 10px;
    }

    .preview-flow-copy strong {
        font-size: 13px;
    }

    .preview-flow-copy p {
        font-size: 9px;
    }

    .preview-flow-line {
        height: 11px;
    }

    .preview-flow-foot {
        padding-top: 11px;
    }
}

/* Showcase Accessibility Links & Popover */
.intro-showcases-section {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed var(--border-soft);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.intro-showcases-title {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: var(--gold-bright);
    display: flex;
    align-items: center;
    gap: 4px;
    text-transform: uppercase;
}

.intro-showcases-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.showcase-card-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: var(--r-2);
    border: 1px solid var(--border-soft);
    background: color-mix(in srgb, var(--surface-low) 40%, transparent);
    color: var(--text-1);
    text-decoration: none;
    transition: all 0.2s var(--ease);
}

.showcase-card-link:hover {
    border-color: var(--gold-line);
    background: var(--gold-soft);
    transform: translateY(-1px);
}

.showcase-card-icon {
    font-size: 14px;
}

.showcase-card-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.showcase-card-info strong {
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.showcase-card-info small {
    font-size: 9px;
    color: var(--text-3);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.showcase-card-arrow {
    margin-left: auto;
    font-size: 11px;
    color: var(--text-3);
}

.showcase-popover {
    width: 260px;
    padding: 12px;
}

.popover-header-title {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: var(--gold-bright);
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-soft);
}

.showcase-popover-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.showcase-popover-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: var(--r-1);
    text-decoration: none;
    color: var(--text-1);
    transition: background 0.15s var(--ease);
}

.showcase-popover-item:hover {
    background: var(--surface-low);
    color: var(--gold-bright);
}

.showcase-popover-item strong {
    display: block;
    font-size: 11px;
    font-weight: 600;
}

.showcase-popover-item small {
    display: block;
    font-size: 9.5px;
    color: var(--text-3);
}

.showcase-item-icon {
    font-size: 15px;
}

/* Database Scale & Power UI Components */
.intro-pulse-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 8px;
    background: color-mix(in srgb, var(--gold-bright) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--gold-bright) 30%, transparent);
    border-radius: 999px;
    color: var(--gold-bright);
    font-size: 8.5px;
    font-weight: 800;
    letter-spacing: 0.8px;
    margin-right: 8px;
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background: var(--gold-bright);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--gold-bright);
    animation: pulseGlow 1.8s infinite ease-in-out;
}

@keyframes pulseGlow {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.4); opacity: 1; box-shadow: 0 0 12px var(--gold-bright); }
}

.intro-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 16px 0;
    padding: 12px 14px;
    background: color-mix(in srgb, var(--surface) 60%, transparent);
    border: 1px solid var(--border-soft);
    border-radius: var(--r-3);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.intro-stat-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.intro-stat-num {
    font-family: var(--font-serif);
    font-size: 17px;
    font-weight: 700;
    color: var(--gold-bright);
    line-height: 1.1;
    letter-spacing: -0.3px;
}

.intro-stat-label {
    font-size: 9px;
    color: var(--text-2);
    font-weight: 500;
    margin-top: 2px;
    white-space: nowrap;
}

.preview-data-banner {
    background: color-mix(in srgb, var(--surface) 75%, transparent);
    border: 1px solid var(--border-soft);
    border-radius: var(--r-3);
    padding: 12px 14px;
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.preview-data-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: var(--text-2);
}

.badge-dld {
    font-size: 8px;
    font-weight: 800;
    padding: 2px 6px;
    background: var(--gold-bright);
    color: #0a0a0b;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.preview-data-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.chip {
    font-size: 9px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface-low) 80%, transparent);
    border: 1px solid var(--border-soft);
    color: var(--text-1);
    transition: border-color 0.2s var(--ease);
}

.chip:hover {
    border-color: var(--gold-line);
    color: var(--gold-bright);
}
