/* =====================================================================
   APROAPE — styles
   Keeps the original identity: Quicksand, the green / purple / blue / coral
   palette, soft rounded cards and gradient action tiles. Text colours were
   darkened where needed to reach WCAG AA contrast.
   ===================================================================== */
:root {
    --primary-green: #6BCB77;
    --empathy-purple: #8A7CFF;
    --trust-blue: #4D96FF;
    --help-accent: #FF6B6B;

    /* Accessible text variants of the brand colours (≥ 4.5:1 on light backgrounds) */
    --purple-text: #4C3CC4;
    --purple-strong: #5B4BD6; /* background for white text, both themes */
    --green-text: #166127;
    --blue-text: #1A52A8;
    --red-text: #A3241F;

    --bg-main: #E2E8F0;
    --bg-app: #F7F8FC;
    --bg-card: rgba(255, 255, 255, 0.94);
    --bg-input: #FFFFFF;
    --border: #CBD5E1;
    --text-main: #1F2937;
    --text-muted: #4B5563;
    --nav-bg: #FFFFFF;
    --shadow-color: rgba(138, 124, 255, 0.15);
    --focus: #1F5FC2;

    --radius-lg: 32px;
    --radius-md: 24px;
    --radius-sm: 16px;
    --nav-h: 76px;
    --fs: 16px;
}

body.dark-mode {
    --bg-main: #05080f;
    --bg-app: #0B1220;
    --bg-card: rgba(30, 41, 59, 0.92);
    --bg-input: #111A2E;
    --border: #334155;
    --text-main: #F8FAFC;
    --text-muted: #CBD5E1;
    --nav-bg: #1E293B;
    --shadow-color: rgba(0, 0, 0, 0.4);
    --purple-text: #B4ABFF;
    --green-text: #8FE09B;
    --blue-text: #9CC3FF;
    --red-text: #FF9C9C;
    --focus: #9CC3FF;
}

body.high-contrast {
    --bg-card: #FFFFFF;
    --text-main: #000000;
    --text-muted: #1F2937;
    --border: #000000;
    --purple-text: #3B2DB0;
    --blue-text: #0B3F91;
}
body.high-contrast.dark-mode {
    --bg-card: #000000;
    --bg-app: #000000;
    --text-main: #FFFFFF;
    --text-muted: #E5E7EB;
    --border: #FFFFFF;
    --purple-text: #D6D0FF;
    --blue-text: #C7DDFF;
}
body.high-contrast .card, body.high-contrast .donation-card, body.high-contrast .question-card { border: 2px solid var(--border); }

body.large-text { --fs: 19px; }

/* ---------- base ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { font-size: var(--fs); }
body {
    font-family: 'Quicksand', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    font-size: 1rem; line-height: 1.5; font-weight: 600;
    background: var(--bg-main); color: var(--text-main);
    min-height: 100vh; transition: background 0.4s ease;
}
img { max-width: 100%; display: block; }
a { color: var(--blue-text); font-weight: 700; }
ul[role="list"], .plain-list { list-style: none; }
h1 { font-size: 1.75rem; font-weight: 800; line-height: 1.2; margin-bottom: 8px; color: var(--text-main); }
h2, .h2 { font-size: 1.4rem; font-weight: 700; margin-bottom: 8px; }
h3, .h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 4px; }
.h4 { font-size: 1rem; font-weight: 800; margin-bottom: 4px; }
p { color: var(--text-muted); }
.prewrap { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text-main); }
.meta { font-size: 0.875rem; color: var(--text-muted); }
.muted { color: var(--text-muted); }
.hint { font-size: 0.875rem; color: var(--text-muted); }
.center { text-align: center; }
.grow { flex: 1; min-width: 0; }
.emoji { font-family: 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', sans-serif; font-weight: 400; }

.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 8px; top: -60px; z-index: 2000; background: var(--purple-strong); color: #fff; padding: 12px 20px; border-radius: 100px; }
.skip-link:focus { top: 8px; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 8px; }
/* Page titles receive focus only so screen readers announce the new page. */
h1[tabindex="-1"]:focus { outline: none; }
[hidden] { display: none !important; }

/* ---------- layout ---------- */
.app-container {
    position: relative; min-height: 100vh; background: var(--bg-app);
    max-width: 1200px; margin: 0 auto; box-shadow: 0 25px 50px -12px var(--shadow-color);
}
/* Soft, calm background: pastel brand colours in large blurred glows. */
.global-background-layer {
    position: fixed; inset: 0; pointer-events: none; z-index: 0;
    background:
        radial-gradient(60% 50% at 0% 0%, rgba(167, 157, 255, 0.28), transparent 70%),
        radial-gradient(50% 45% at 100% 10%, rgba(143, 217, 154, 0.25), transparent 70%),
        radial-gradient(55% 50% at 80% 100%, rgba(140, 187, 255, 0.22), transparent 70%),
        radial-gradient(45% 40% at 10% 90%, rgba(255, 180, 180, 0.18), transparent 70%),
        linear-gradient(180deg, #F7F6FD 0%, #F3F8F6 100%);
}
body.dark-mode .global-background-layer {
    background:
        radial-gradient(60% 50% at 0% 0%, rgba(138, 124, 255, 0.18), transparent 70%),
        radial-gradient(50% 45% at 100% 10%, rgba(107, 203, 119, 0.10), transparent 70%),
        radial-gradient(55% 50% at 80% 100%, rgba(77, 150, 255, 0.12), transparent 70%),
        linear-gradient(180deg, #0B1220 0%, #0E1526 100%);
}
/* Quiet pattern of thin-line symbols (wheelchair, person with cane, ear, signing hand, infinity for
   neurodiversity, heart, leaf). Plain background images (one per theme) so it shows in every browser. */
.global-background-layer::before {
    content: ''; position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='360' viewBox='0 0 360 360' fill='none' stroke='%235B4BD6' stroke-opacity='0.16' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg transform='translate(28 30) rotate(-6 24 24)'%3E%3Ccircle cx='20' cy='6' r='3.5'/%3E%3Cpath d='M20 11v13h12l5 11M20 17h9M15 19a11 11 0 1 0 15 13'/%3E%3C/g%3E%3Cg transform='translate(200 18) rotate(8 24 24)'%3E%3Cpath d='M24 38S8 28 8 17a8 8 0 0 1 16-3 8 8 0 0 1 16 3c0 11-16 21-16 21z'/%3E%3C/g%3E%3Cg transform='translate(118 112) rotate(-4 24 24)'%3E%3Ccircle cx='22' cy='6' r='3.5'/%3E%3Cpath d='M22 11l-3 12 6 6 2 11M19 23l-5 17M22 14l8 6M30 20l6 22'/%3E%3C/g%3E%3Cg transform='translate(282 104) rotate(10 24 24)'%3E%3Cpath d='M14 30c-2 6 6 8 8 2 2-5 8-7 8-15a10 10 0 0 0-20 0M16 17a4 4 0 0 1 8 0c0 3-4 4-4 7M36 9a12 12 0 0 1 0 16'/%3E%3C/g%3E%3Cg transform='translate(30 206) rotate(6 24 24)'%3E%3Cpath d='M24 20c-4-6-14-6-14 0s10 6 14 0 14-6 14 0-10 6-14 0z'/%3E%3C/g%3E%3Cg transform='translate(196 196) rotate(-8 24 24)'%3E%3Cpath d='M16 42c-5-3-9-9-11-14-1-3 2-5 4-3l5 5V10a2.5 2.5 0 0 1 5 0v12V7a2.5 2.5 0 0 1 5 0v15V9a2.5 2.5 0 0 1 5 0v14V13a2.5 2.5 0 0 1 5 0v17c0 7-5 12-12 12z'/%3E%3C/g%3E%3Cg transform='translate(110 290) rotate(4 24 24)'%3E%3Cpath d='M10 38C10 20 22 10 40 10c0 18-12 28-30 28zM10 38l18-18'/%3E%3C/g%3E%3Cg transform='translate(296 286) rotate(-10 24 24)'%3E%3Cpath d='M24 38S8 28 8 17a8 8 0 0 1 16-3 8 8 0 0 1 16 3c0 11-16 21-16 21z'/%3E%3C/g%3E%3C/svg%3E") 0 0 / 360px 360px repeat;
}
body.dark-mode .global-background-layer::before {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='360' viewBox='0 0 360 360' fill='none' stroke='%23C9C2FF' stroke-opacity='0.13' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg transform='translate(28 30) rotate(-6 24 24)'%3E%3Ccircle cx='20' cy='6' r='3.5'/%3E%3Cpath d='M20 11v13h12l5 11M20 17h9M15 19a11 11 0 1 0 15 13'/%3E%3C/g%3E%3Cg transform='translate(200 18) rotate(8 24 24)'%3E%3Cpath d='M24 38S8 28 8 17a8 8 0 0 1 16-3 8 8 0 0 1 16 3c0 11-16 21-16 21z'/%3E%3C/g%3E%3Cg transform='translate(118 112) rotate(-4 24 24)'%3E%3Ccircle cx='22' cy='6' r='3.5'/%3E%3Cpath d='M22 11l-3 12 6 6 2 11M19 23l-5 17M22 14l8 6M30 20l6 22'/%3E%3C/g%3E%3Cg transform='translate(282 104) rotate(10 24 24)'%3E%3Cpath d='M14 30c-2 6 6 8 8 2 2-5 8-7 8-15a10 10 0 0 0-20 0M16 17a4 4 0 0 1 8 0c0 3-4 4-4 7M36 9a12 12 0 0 1 0 16'/%3E%3C/g%3E%3Cg transform='translate(30 206) rotate(6 24 24)'%3E%3Cpath d='M24 20c-4-6-14-6-14 0s10 6 14 0 14-6 14 0-10 6-14 0z'/%3E%3C/g%3E%3Cg transform='translate(196 196) rotate(-8 24 24)'%3E%3Cpath d='M16 42c-5-3-9-9-11-14-1-3 2-5 4-3l5 5V10a2.5 2.5 0 0 1 5 0v12V7a2.5 2.5 0 0 1 5 0v15V9a2.5 2.5 0 0 1 5 0v14V13a2.5 2.5 0 0 1 5 0v17c0 7-5 12-12 12z'/%3E%3C/g%3E%3Cg transform='translate(110 290) rotate(4 24 24)'%3E%3Cpath d='M10 38C10 20 22 10 40 10c0 18-12 28-30 28zM10 38l18-18'/%3E%3C/g%3E%3Cg transform='translate(296 286) rotate(-10 24 24)'%3E%3Cpath d='M24 38S8 28 8 17a8 8 0 0 1 16-3 8 8 0 0 1 16 3c0 11-16 21-16 21z'/%3E%3C/g%3E%3C/svg%3E") 0 0 / 360px 360px repeat;
}
body.high-contrast .global-background-layer::before { display: none; }
.app-container { background: transparent; }

/* Accent colour per section: title badge and a soft glow at the top of the page */
.screen-host { --accent: #8A7CFF; --accent-2: #B4ABFF; }
.route-harta { --accent: #FF6B6B; --accent-2: #FFA3A3; }
.route-echipamente { --accent: #3FAE5A; --accent-2: #8FD99A; }
.route-comunitate { --accent: #8A7CFF; --accent-2: #C3BBFF; }
.route-drepturi { --accent: #4D96FF; --accent-2: #9CC3FF; }
.route-mesaje { --accent: #B565D0; --accent-2: #DDA8EC; }
.route-profil, .route-cont { --accent: #2BA5A5; --accent-2: #8ADADA; }
.route-transport, .route-curse { --accent: #2E9E4A; --accent-2: #8FD99A; }
.route-moderare { --accent: #D99A00; --accent-2: #FFD66B; }
.screen-host::before {
    content: ''; position: absolute; left: 0; right: 0; top: 0; height: 260px; pointer-events: none; z-index: -1;
    background: radial-gradient(70% 100% at 50% 0%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 75%);
}
.section-icon {
    display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; margin-right: 10px; vertical-align: middle;
    border-radius: 15px; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2));
    box-shadow: 0 6px 16px color-mix(in srgb, var(--accent) 35%, transparent);
}
.section-icon .ico { width: 26px; height: 26px; }
.map-title-row h1 .section-icon { width: 38px; height: 38px; border-radius: 12px; }
.ico { display: block; }
.nav-item .icon .ico { width: 26px; height: 26px; }
.nav-item[aria-current="page"] .icon { color: var(--purple-text); }
.tile .card-icon { color: #3B3363; }
.tile .card-icon .ico { width: 30px; height: 30px; }
.ride-banner-icon .ico { width: 40px; height: 40px; color: #fff; }
.screen-host { position: relative; z-index: 1; min-width: 0; min-height: 100vh; padding-bottom: calc(var(--nav-h) + 24px + env(safe-area-inset-bottom)); outline: none; }
body.no-nav .screen-host { padding-bottom: 32px; }
.screen-pad { padding: 24px 20px; animation: fadeIn 0.35s ease; }
.screen-pad.narrow { max-width: 760px; margin: 0 auto; }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 12px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.row-2 { display: grid; grid-template-columns: 1fr; gap: 0 16px; }
@media (min-width: 600px) { .row-2 { grid-template-columns: 1fr 1fr; } }

@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }

.demo-banner {
    position: relative; z-index: 5; background: #FFF4CC; color: #4A3B00; font-size: 0.875rem;
    padding: 8px 16px; text-align: center; border-bottom: 1px solid #F0D98A;
}
.demo-banner a { color: #4A3B00; }
body.dark-mode .demo-banner { background: #3A3110; color: #FFE9A3; border-color: #5C4E1B; }
body.dark-mode .demo-banner a { color: #FFE9A3; }

/* ---------- navigation (bottom on phones, side rail on desktop) ---------- */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
    height: calc(var(--nav-h) + env(safe-area-inset-bottom)); padding: 0 6px env(safe-area-inset-bottom);
    background: var(--nav-bg); border-top-left-radius: 32px; border-top-right-radius: 32px;
    display: flex; justify-content: space-around; align-items: center;
    box-shadow: 0 -10px 30px var(--shadow-color);
}
.nav-item {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    min-width: 64px; min-height: 56px; padding: 6px 4px; border-radius: 20px;
    color: var(--text-muted); font-size: 0.75rem; font-weight: 800; text-decoration: none;
    transition: color 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.nav-item .icon { font-size: 1.5rem; line-height: 1; transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.nav-item[aria-current="page"] { color: var(--purple-text); background: rgba(138, 124, 255, 0.12); }
.nav-item[aria-current="page"] .icon { transform: translateY(-2px) scale(1.1); }

@media (min-width: 1000px) {
    :root { --nav-h: 0px; }
    /* Desktop: use the whole screen width (menu on the left, content fills the rest). */
    .app-container { display: grid; grid-template-columns: 240px minmax(0, 1fr); max-width: none; box-shadow: none; }
    .screen-pad { padding: 32px clamp(24px, 3vw, 56px); max-width: 1560px; margin: 0 auto; }
    .screen-pad.narrow { max-width: 880px; }
    .app-container > .demo-banner { grid-column: 1 / -1; }
    .bottom-nav {
        position: sticky; top: 0; bottom: auto; grid-column: 1; grid-row: 2; height: 100vh; border-radius: 0;
        flex-direction: column; justify-content: flex-start; gap: 8px; padding: 32px 16px;
        box-shadow: 4px 0 30px var(--shadow-color);
    }
    .nav-item { flex-direction: row; justify-content: flex-start; gap: 12px; width: 100%; font-size: 1rem; padding: 12px 16px; }
    .screen-host { grid-column: 2; grid-row: 2; padding-bottom: 40px; }
    body.no-nav .screen-host { grid-column: 1 / -1; }
}

/* ---------- buttons & inputs ---------- */
.btn-primary, .btn-secondary, .btn-danger {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 48px; padding: 12px 22px; border-radius: 100px; border: none; cursor: pointer;
    font: inherit; font-weight: 800; text-decoration: none; text-align: center; line-height: 1.2;
}
.btn-primary { background: var(--purple-strong); color: #fff; box-shadow: 0 4px 15px rgba(138, 124, 255, 0.4); }
.btn-secondary { background: rgba(138, 124, 255, 0.12); color: var(--purple-text); }
.btn-danger { background: rgba(255, 107, 107, 0.15); color: var(--red-text); }
.btn-primary:hover, .btn-secondary:hover, .btn-danger:hover { filter: brightness(1.05); transform: translateY(-1px); }
.full-btn { width: 100%; }
.small-btn { min-height: 44px; padding: 8px 16px; font-size: 0.875rem; }
button:disabled { opacity: 0.55; cursor: not-allowed; }
.back-btn {
    display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin-bottom: 12px;
    background: none; border: none; font: inherit; font-weight: 700; color: var(--text-main); cursor: pointer; text-decoration: none;
}
.close-btn { background: none; border: none; min-width: 44px; min-height: 44px; font-size: 1.1rem; cursor: pointer; color: var(--text-main); border-radius: 50%; }

.field { display: flex; flex-direction: column; gap: 6px; border: none; margin-bottom: 4px; }
.field label, .field legend { font-weight: 700; color: var(--text-main); }
fieldset.field { padding: 0; }
fieldset.field legend { margin-bottom: 8px; }
.form-input {
    width: 100%; min-height: 48px; padding: 12px 16px; font: inherit; font-weight: 600;
    background: var(--bg-input); color: var(--text-main);
    border: 2px solid var(--border); border-radius: var(--radius-sm);
}
.form-input:focus { border-color: var(--empathy-purple); outline: none; box-shadow: 0 0 0 3px rgba(138, 124, 255, 0.35); }
textarea.form-input { min-height: 120px; resize: vertical; }
[aria-invalid="true"] { border-color: var(--red-text) !important; }
.field-error { color: var(--red-text); font-size: 0.875rem; font-weight: 700; }
.field-error::before { content: '⚠ '; }
.form-message { color: var(--red-text); font-weight: 700; }
.inline-field { flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; }
.inline-field label { flex: 1; }
.inline-field select { width: auto; min-width: 140px; }

.consent-item, .radio-item, .switch {
    display: flex; align-items: flex-start; gap: 12px; padding: 8px 0; cursor: pointer; color: var(--text-main);
}
.consent-item input, .radio-item input, .switch input { width: 24px; height: 24px; flex-shrink: 0; margin-top: 2px; accent-color: var(--empathy-purple); }

.choice-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; }
.choice > span {
    display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 14px; border-radius: var(--radius-sm);
    border: 2px solid var(--border); background: var(--bg-input); color: var(--text-main);
}
.choice small { color: var(--text-muted); font-size: 0.8rem; }
.choice input:checked + span { border-color: var(--empathy-purple); background: rgba(138, 124, 255, 0.1); }
.choice input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }

.seg { display: inline-flex; background: rgba(138, 124, 255, 0.1); border-radius: 100px; padding: 4px; gap: 4px; flex-wrap: wrap; }
.seg-btn {
    min-height: 40px; padding: 8px 16px; border-radius: 100px; border: none; background: transparent;
    font: inherit; font-weight: 800; color: var(--purple-text); cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
}
.seg-btn[aria-pressed="true"], .seg-btn:has(input:checked) { background: var(--bg-card); box-shadow: 0 2px 8px var(--shadow-color); }
.seg-btn input { accent-color: var(--empathy-purple); }

.chip-row { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 10px; margin: 12px 0; scrollbar-width: thin; }
.chip {
    white-space: nowrap; min-height: 44px; padding: 8px 16px; border-radius: 100px; cursor: pointer;
    background: var(--bg-card); border: 2px solid transparent; color: var(--text-main);
    font: inherit; font-size: 0.9rem; font-weight: 700; box-shadow: 0 4px 15px var(--shadow-color);
}
.chip[aria-pressed="true"] { border-color: var(--empathy-purple); background: rgba(138, 124, 255, 0.14); color: var(--purple-text); }

.search-bar {
    display: flex; align-items: center; gap: 10px; background: var(--bg-card); padding: 6px 6px 6px 18px;
    border-radius: 100px; box-shadow: 0 4px 15px var(--shadow-color); border: 2px solid var(--border);
}
.search-bar input { border: none; outline: none; flex: 1; min-width: 0; min-height: 40px; background: transparent; color: var(--text-main); font: inherit; }
.search-bar:focus-within { border-color: var(--empathy-purple); }

.filter-row { display: grid; grid-template-columns: 1fr; gap: 8px; align-items: end; margin-bottom: 12px; }
@media (min-width: 700px) { .filter-row { grid-template-columns: 2fr 1.5fr 1.5fr auto; } }

/* ---------- cards ---------- */
.card {
    background: var(--bg-card); border-radius: var(--radius-md); padding: 20px;
    box-shadow: 0 8px 25px var(--shadow-color); margin-bottom: 16px;
}
.card-list { display: flex; flex-direction: column; gap: 14px; margin-top: 12px; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; margin-top: 12px; }
.stretched::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.stretched { text-decoration: none; color: var(--text-main); }
.stretched:hover { text-decoration: underline; }

.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 0.78rem; font-weight: 800; padding: 4px 10px; border-radius: 100px; margin: 2px 4px 2px 0; }
.badge-verified { background: rgba(107, 203, 119, 0.2); color: var(--green-text); }
.badge-unverified { background: rgba(100, 116, 139, 0.15); color: var(--text-muted); }
.badge-pending { background: rgba(255, 193, 7, 0.22); color: #7A5600; }
.badge-danger { background: rgba(255, 107, 107, 0.18); color: var(--red-text); }
body.dark-mode .badge-danger { color: #FFA3A3; }
.law-list { display: flex; flex-direction: column; gap: 10px; }
.law-item { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 10px 12px; border-radius: 12px; background: rgba(138, 124, 255, 0.07); }
.law-item a { font-weight: 800; color: var(--blue-text); }
body.dark-mode .badge-pending { color: #FFD66B; }
.badge-demo { background: #FFF4CC; color: #5C4A00; }
body.dark-mode .badge-demo { background: #3A3110; color: #FFE9A3; }

.type-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 0.8rem; font-weight: 800; padding: 5px 12px; border-radius: 12px; }
.type-donez, .type-gratuit { background: rgba(107, 203, 119, 0.2); color: var(--green-text); }
.type-imprumut { background: rgba(77, 150, 255, 0.18); color: var(--blue-text); }
.type-caut { background: rgba(138, 124, 255, 0.18); color: var(--purple-text); }
.type-vand { background: rgba(255, 159, 67, 0.22); color: #8A4A00; }
body.dark-mode .type-vand { color: #FFC28A; }
.type-voluntariat, .type-initiativa { background: rgba(107, 203, 119, 0.2); color: var(--green-text); }
.type-cerere { background: rgba(255, 107, 107, 0.16); color: var(--red-text); }
.type-eveniment { background: rgba(77, 150, 255, 0.18); color: var(--blue-text); }

.status-tag { display: inline-block; font-size: 0.8rem; font-weight: 800; padding: 4px 10px; border-radius: 10px; background: rgba(100, 116, 139, 0.15); color: var(--text-muted); }
.status-activ { background: rgba(107, 203, 119, 0.2); color: var(--green-text); }
.status-rezervat { background: rgba(255, 193, 7, 0.22); color: #7A5600; }
body.dark-mode .status-rezervat { color: #FFD66B; }

.notice {
    display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; margin: 12px 0;
    border-radius: var(--radius-sm); background: rgba(77, 150, 255, 0.1); color: var(--text-main); font-weight: 600;
}
.notice p, .notice li { color: var(--text-main); }
.notice ul { padding-left: 18px; margin-top: 6px; }
.notice > .emoji { font-size: 1.4rem; line-height: 1.2; }
.notice-warn { background: rgba(255, 193, 7, 0.16); }
.notice-emergency { background: rgba(255, 107, 107, 0.12); margin-top: 24px; }
.notice-safety { background: rgba(107, 203, 119, 0.13); }

.empty-state, .error-state, .loading-state { text-align: center; padding: 40px 16px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.empty-state > .emoji, .error-state > .emoji { font-size: 2.6rem; }
.loading-state { flex-direction: row; justify-content: center; color: var(--text-muted); }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 3px solid rgba(138, 124, 255, 0.3); border-top-color: var(--empathy-purple); animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.skeleton { background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-main) 50%, var(--bg-card) 75%); background-size: 400px 100%; animation: shimmer 1.5s infinite linear; border-radius: var(--radius-md); }
.skeleton-card { height: 140px; margin-top: 14px; }
@keyframes shimmer { 0% { background-position: -400px 0; } 100% { background-position: 400px 0; } }

/* ---------- home ---------- */
.hero-area { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 28px; }
.hero-illustration { position: relative; width: 96px; height: 96px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.breathing-circle { position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle, rgba(107, 203, 119, 0.35), rgba(138, 124, 255, 0.15)); animation: breathe 4s ease-in-out infinite; }
.hero-emoji { position: relative; font-size: 3rem; }
@keyframes breathe { 0%, 100% { transform: scale(0.92); } 50% { transform: scale(1.06); } }
.action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (min-width: 760px) { .action-grid { grid-template-columns: repeat(3, 1fr); } }
.action-card {
    display: flex; flex-direction: column; justify-content: center; gap: 4px; min-height: 160px; height: 100%; padding: 20px;
    border-radius: var(--radius-lg); background: var(--gradient); text-decoration: none;
    box-shadow: 0 8px 25px var(--shadow-color);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}
.action-card:hover { transform: translateY(-6px) scale(1.02); box-shadow: 0 15px 35px var(--shadow-color); }
.card-icon { position: relative; font-size: 2rem; margin-bottom: 10px; width: 54px; height: 54px; display: flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, 0.65); border-radius: 20px; }
.card-title { font-size: 1.05rem; font-weight: 800; color: #1F2937; }
.card-text { font-size: 0.875rem; font-weight: 600; color: #374151; }
.notification-badge {
    position: absolute; top: -6px; right: -6px; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 100px;
    background: #D93636; color: #fff; font-size: 0.75rem; font-weight: 800; display: flex; align-items: center; justify-content: center;
    border: 2px solid #fff;
}
.notification-badge.inline { position: static; border: none; }

/* ---------- equipment ---------- */
.donations-banner {
    display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px; margin-bottom: 16px;
    border-radius: var(--radius-md); border: 2px dashed var(--trust-blue); text-decoration: none; color: var(--text-main);
    background: linear-gradient(135deg, #FDF2F8, #EBF8FF); box-shadow: 0 8px 25px var(--shadow-color);
}
body.dark-mode .donations-banner { background: linear-gradient(135deg, #1E293B, #0F172A); border-color: rgba(77, 150, 255, 0.5); }
.banner-content { display: flex; flex-direction: column; gap: 4px; }
.banner-text { color: var(--text-muted); font-size: 0.9rem; }
.donation-card { position: relative; background: var(--bg-card); border-radius: var(--radius-lg); overflow: hidden; box-shadow: 0 8px 25px var(--shadow-color); }
.donation-card:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.donation-img { height: 170px; background: #E2E8F0 center / cover no-repeat; display: flex; align-items: center; justify-content: center; font-size: 3.5rem; }
body.dark-mode .donation-img { background-color: #1E293B; }
.detail-img { border-radius: var(--radius-md); }
.donation-info { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.price { font-weight: 800; color: var(--text-main); font-size: 1.05rem; }
.details { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.details dt { font-size: 0.8rem; color: var(--text-muted); font-weight: 700; }
.details dd { color: var(--text-main); font-weight: 700; }
.photo-gallery { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; }
.photo-gallery li { flex: 0 0 85%; max-width: 480px; scroll-snap-align: start; }
.photo-gallery img { width: 100%; height: 260px; object-fit: cover; border-radius: var(--radius-sm); }
.photo-previews { display: flex; gap: 10px; flex-wrap: wrap; list-style: none; }
.photo-thumb { position: relative; }
.photo-thumb img { width: 88px; height: 88px; object-fit: cover; border-radius: 14px; }
.thumb-remove { position: absolute; top: -8px; right: -8px; width: 32px; height: 32px; border-radius: 50%; border: 2px solid #fff; background: #D93636; color: #fff; cursor: pointer; font-weight: 800; }

/* ---------- community ---------- */
.question-card { position: relative; background: var(--bg-card); border-radius: var(--radius-lg); padding: 20px; box-shadow: 0 8px 25px var(--shadow-color); display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.question-card:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.q-excerpt { color: var(--text-main); }
.author { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; font-weight: 700; color: var(--text-main); font-size: 0.9rem; position: relative; z-index: 1; }

/* ---------- map ---------- */
.map-page { display: flex; flex-direction: column; height: calc(100vh - var(--nav-h) - env(safe-area-inset-bottom)); }
.route-harta { padding-bottom: 0 !important; }
.map-toolbar { padding: 16px 16px 4px; background: var(--bg-app); z-index: 3; box-shadow: 0 6px 20px var(--shadow-color); }
.map-title-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.map-title-row h1 { font-size: 1.35rem; margin: 0; }
.map-toolbar .chip-row { margin: 8px 0 0; }
.map-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.map-status { font-size: 0.85rem; min-height: 1.4em; margin-top: 4px; color: var(--text-muted); }
/* Calmer map toolbar: search + location + "Filtre" in one row, the rest folded away */
.map-searchrow { display: flex; gap: 8px; align-items: center; }
.map-searchrow .search-bar { flex: 1; min-width: 0; margin: 0; }
.icon-btn {
    flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 48px; min-height: 48px; padding: 0 12px;
    border: 2px solid transparent; border-radius: 16px; background: var(--bg-card); color: var(--text-main); font: inherit; font-weight: 800; cursor: pointer;
    box-shadow: 0 4px 12px var(--shadow-color);
}
.icon-btn:hover { border-color: var(--empathy-purple); }
.filters-btn.active, .filters-btn[aria-expanded="true"] { border-color: var(--purple-strong); color: var(--purple-text); }
.filters-count:not(:empty) { display: inline-flex; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--purple-strong); color: #fff; font-size: 0.8rem; align-items: center; justify-content: center; }
@media (max-width: 480px) { .filters-btn span:not(.filters-count):not(.emoji) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } }
.more-filters { margin-top: 8px; padding: 10px 12px; border-radius: 16px; background: color-mix(in srgb, var(--bg-card) 70%, transparent); }
.chip-row.wrap-chips { flex-wrap: wrap; overflow: visible; margin: 0 0 8px; padding: 0; }
.map-toolbar .category-row { margin-top: 10px; }
.map-suggest { position: absolute; left: 12px; bottom: 16px; z-index: 600; min-height: 48px; box-shadow: 0 8px 22px rgba(76, 60, 196, 0.35); }
.map-page.routing .map-suggest, .map-page.routing .map-searchrow, #map[hidden] ~ .map-suggest { display: none; }
.map-body { position: relative; flex: 1; min-height: 320px; }
.map-canvas { position: absolute; inset: 0; z-index: 1; background: #e0e5ec; }
body.dark-mode .map-canvas { background: #0B1220; }
/* Calmer map: softer colours and a little lighter, so the markers stand out (dark theme: inverted, also soft). */
.calm-tiles { filter: saturate(0.45) brightness(1.06) contrast(0.9); }
body.dark-mode .calm-tiles { filter: invert(1) hue-rotate(180deg) saturate(0.35) brightness(0.85) contrast(0.85); }
.place-list { position: absolute; inset: 0; overflow-y: auto; z-index: 2; background: var(--bg-app); }
.map-crosshair { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 500; font-size: 2.5rem; color: #D93636; pointer-events: none; text-shadow: 0 0 4px #fff; }
.pick-bar { position: absolute; left: 12px; right: 12px; bottom: 16px; z-index: 600; background: var(--bg-card); border-radius: var(--radius-md); padding: 16px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }
.pick-bar p { color: var(--text-main); margin-bottom: 10px; }
/* Place card on the map: photo and the accessibility verdict */
.sheet-photo { margin: 10px 0; border-radius: 16px; overflow: hidden; background: var(--bg-input); }
.sheet-photo img { display: block; width: 100%; max-height: 220px; object-fit: cover; }
.access-verdict { display: flex; align-items: center; gap: 8px; margin: 10px 0 6px; padding: 10px 14px; border-radius: 14px; font-size: 1.05rem; }
.verdict-ok { background: rgba(107, 203, 119, 0.2); color: var(--green-text); }
.verdict-partial { background: rgba(255, 214, 107, 0.25); color: #6B4E00; }
.verdict-nu { background: rgba(255, 107, 107, 0.16); color: var(--red-text); }
.verdict-necunoscut { background: rgba(100, 116, 139, 0.14); color: var(--text-main); }
body.dark-mode .verdict-partial { color: #FFD66B; }
/* Route inside the app */
.sheet-handle-btn { display: flex; justify-content: center; width: 100%; min-height: 32px; margin: -6px 0 4px; padding: 10px 0; border: none; background: none; cursor: pointer; border-radius: 12px; }
.sheet-handle-btn .sheet-handle { margin: 0; width: 56px; height: 6px; opacity: 0.7; }
.sheet-handle-btn:hover .sheet-handle, .sheet-handle-btn:focus-visible .sheet-handle { opacity: 1; background: var(--purple-text); }
.route-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.route-big { display: flex; flex-direction: column; }
.route-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.route-time { font-size: 1.8rem; font-weight: 800; line-height: 1.1; color: var(--purple-text); }
.route-dist { font-size: 1rem; font-weight: 700; color: var(--text-main); }
.route-to { margin: 8px 0 10px; font-size: 1.05rem; font-weight: 800; color: var(--text-main); }
.route-steps { list-style: none; margin: 12px 0 6px; padding: 0; display: flex; flex-direction: column; gap: 4px; max-height: 34vh; overflow-y: auto; color: var(--text-main); }
.route-steps li { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; font-size: 1.02rem; font-weight: 700; background: rgba(138, 124, 255, 0.08); }
.route-steps li:first-child { background: rgba(138, 124, 255, 0.2); }
.step-arrow { flex: none; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--bg-card); font-size: 1.2rem; box-shadow: 0 2px 6px var(--shadow-color); }
.route-sheet { max-height: 50%; }
.map-page.routing .map-toolbar .chip-row, .map-page.routing .map-toolbar .map-actions, .map-page.routing .map-toolbar .search-bar { display: none; }
.route-sheet.collapsed .route-details, .route-sheet.collapsed .route-to { display: none; }
.route-sheet.collapsed { max-height: none; }
.route-flag { font-size: 2rem; line-height: 1; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.35)); background: none; border: none; }
/* "Ce cauți?" category row */
.chip-label { align-self: center; flex-shrink: 0; font-weight: 800; font-size: 0.85rem; color: var(--text-muted); padding-right: 2px; }
.chip-category[aria-pressed="true"] { background: var(--purple-strong); color: #fff; border-color: var(--purple-strong); }
/* The draggable character on the map (same drawing as on the home page) */
.map-buddy { --tire: #3B3363; --rim: #A79DFF; --frame: #3B3363; --skin: #F3C29E; --body: #8A7CFF; --leg: #4D96FF; background: none; border: none; cursor: grab; }
body.dark-mode .map-buddy { --tire: #E2E8F0; --frame: #CBD5E1; --rim: #B4ABFF; }
.map-buddy .buddy-art { position: relative; display: block; width: 64px; height: 64px; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.3)); }
.map-buddy .buddy-art::before { content: ''; position: absolute; left: 14px; right: 14px; bottom: 0; height: 10px; border-radius: 50%; background: rgba(59, 51, 99, 0.25); z-index: -1; }
.map-buddy .chair-svg { width: 100%; height: 100%; }
.map-buddy .buddy-bubble {
    position: absolute; bottom: 68px; left: 50%; transform: translateX(-50%); white-space: nowrap;
    padding: 6px 12px; border-radius: 14px; background: #fff; color: #2E2566; font-size: 0.8rem; font-weight: 800;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}
.map-buddy .buddy-bubble::after { content: ''; position: absolute; left: 50%; bottom: -6px; width: 12px; height: 12px; margin-left: -6px; background: inherit; transform: rotate(45deg); }
.map-buddy.leaflet-drag-target, .map-buddy:active { cursor: grabbing; }
.map-marker { display: flex !important; align-items: center; justify-content: center; border-radius: 50%; font-size: 1.15rem; border: 3px solid #fff; box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35); background: #64748B; }
.marker-verificat { background: var(--primary-green); }
.marker-neverificat { background: var(--trust-blue); }
/* Hospitals and recovery centres stand out: bigger, own colour, thick white ring */
.map-marker.marker-type-spital { background: #D32F2F !important; font-size: 1.45rem; border-width: 4px; box-shadow: 0 0 0 4px rgba(211, 47, 47, 0.35), 0 6px 14px rgba(0, 0, 0, 0.4); }
.map-marker.marker-type-recuperare { background: #0F8A7E !important; font-size: 1.45rem; border-width: 4px; box-shadow: 0 0 0 4px rgba(15, 138, 126, 0.35), 0 6px 14px rgba(0, 0, 0, 0.4); }
/* After choosing a filter, the matching places pulse for a moment (a ring stays when animations are off) */
.map-page.pulse-markers .map-marker { animation: markerPulse 0.8s ease-in-out 4; outline: 3px solid #FFD66B; outline-offset: 2px; }
@keyframes markerPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.35); } }
/* Map legend (top right of the map) */
.map-legend { position: absolute; top: 12px; right: 12px; z-index: 650; max-width: min(300px, calc(100% - 80px)); background: var(--bg-card); border-radius: 16px; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25); padding: 6px 12px; }
.map-legend summary { cursor: pointer; font-weight: 800; min-height: 40px; display: flex; align-items: center; gap: 6px; color: var(--text-main); }
.map-legend[open] { padding-bottom: 12px; max-height: 60%; overflow-y: auto; }
.legend-list { list-style: none; margin: 6px 0; padding: 0; display: flex; flex-direction: column; gap: 8px; color: var(--text-main); font-size: 0.9rem; font-weight: 700; }
.legend-list li { display: flex; align-items: center; gap: 10px; }
.legend-dot { flex: none; width: 26px; height: 26px; border-radius: 50%; border: 3px solid #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 0.8rem; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3); }
.legend-dot.marker-type-spital { background: #D32F2F; }
.legend-dot.marker-type-recuperare { background: #0F8A7E; }
.legend-verified { background: var(--primary-green); }
.legend-community { background: var(--trust-blue); }
.legend-osm { background: #8A7CFF; }
.legend-pending { background: #F59E0B; }
.legend-emoji { flex: none; width: 26px; text-align: center; font-size: 1.2rem; }
.map-page.routing .map-legend { display: none; }
.marker-osm { background: #8A7CFF; }
.marker-in_asteptare { background: #F59E0B; }
.bottom-preview-card {
    position: absolute; bottom: 0; left: 0; right: 0; z-index: 700; max-height: 70%; overflow-y: auto;
    background: var(--bg-card); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border-top-left-radius: 32px; border-top-right-radius: 32px; padding: 12px 20px 20px;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.18);
    transform: translateY(110%); transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.bottom-preview-card.show { transform: translateY(0); }
.sheet-handle { width: 40px; height: 5px; background: var(--text-muted); border-radius: 10px; margin: 0 auto 14px; opacity: 0.5; }
.sheet-header { display: flex; align-items: center; gap: 14px; margin-bottom: 8px; }
.feature-list { list-style: none; display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.feature-list.compact { flex-direction: row; flex-wrap: wrap; gap: 6px; }
.feature { display: flex; align-items: center; gap: 6px; color: var(--text-main); font-size: 0.9rem; }
.feature-list.compact .feature { background: rgba(100, 116, 139, 0.1); padding: 4px 10px; border-radius: 100px; font-size: 0.8rem; }
.feature-da strong { color: var(--green-text); }
.feature-partial strong { color: #8A5A00; }
body.dark-mode .feature-partial strong { color: #FFD66B; }
.feature-nu strong { color: var(--red-text); }
.feature-necunoscut strong { color: var(--text-muted); font-weight: 600; }
.leaflet-container { font-family: inherit; }
.leaflet-container a { color: var(--blue-text); }
.leaflet-container .leaflet-control-attribution { background: rgba(255, 255, 255, 0.9); color: #1F2937; }
.leaflet-container .leaflet-control-attribution a { color: #1F5FC2; }
.leaflet-bar a { width: 40px !important; height: 40px !important; line-height: 40px !important; }

/* ---------- avatars & profile ---------- */
.avatar { width: 50px; height: 50px; flex-shrink: 0; border-radius: 50%; background: var(--trust-blue); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; font-weight: 800; }
.avatar.small { width: 40px; height: 40px; font-size: 1.05rem; }
.profile-header { text-align: center; margin-bottom: 20px; }
.profile-avatar { width: 110px; height: 110px; border-radius: 36px; margin: 0 auto 14px; background: linear-gradient(135deg, var(--primary-green), var(--trust-blue)); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 2.8rem; font-weight: 800; }
.status-badge { display: inline-block; background: rgba(107, 203, 119, 0.2); color: var(--green-text); padding: 8px 18px; border-radius: 100px; font-weight: 800; }
.link-list li { padding: 8px 0; border-bottom: 1px solid var(--border); display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: baseline; }
.check-list li { display: flex; gap: 10px; padding: 6px 0; color: var(--text-main); }

/* ---------- messages ---------- */
.conversation-item { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: var(--radius-md); background: var(--bg-card); box-shadow: 0 4px 15px var(--shadow-color); text-decoration: none; color: var(--text-main); }
.conv-details { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.conv-name { font-weight: 800; }
.conv-context { font-size: 0.8rem; color: var(--text-muted); }
.last-msg { font-size: 0.9rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conversation-item.unread .last-msg { color: var(--text-main); font-weight: 800; }
.conv-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.time { font-size: 0.75rem; color: var(--text-muted); }
.unread-dot { width: 12px; height: 12px; background: #D93636; border-radius: 50%; }
.chat-layout { display: flex; flex-direction: column; height: calc(100vh - var(--nav-h) - env(safe-area-inset-bottom)); max-width: 820px; margin: 0 auto; }
.route-mesaje:has(.chat-layout) { padding-bottom: 0 !important; }
.chat-header { display: flex; align-items: center; gap: 10px; padding: 12px 16px; background: var(--bg-card); box-shadow: 0 4px 15px var(--shadow-color); z-index: 2; }
.chat-header .back-btn { margin: 0; }
.chat-title { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.chat-title h1 { margin: 0; }
.chat-messages { flex: 1; overflow-y: auto; list-style: none; padding: 20px 16px; display: flex; flex-direction: column; gap: 12px; }
.msg { max-width: 80%; padding: 12px 16px; border-radius: 22px; font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
.msg.received { align-self: flex-start; background: var(--bg-card); color: var(--text-main); border-bottom-left-radius: 4px; box-shadow: 0 4px 15px var(--shadow-color); }
.msg.sent { align-self: flex-end; background: var(--purple-strong); color: #fff; border-bottom-right-radius: 4px; }
.msg.sent .prewrap { color: #fff; }
.msg-time { font-size: 0.7rem; opacity: 0.8; align-self: flex-end; }
.chat-input-bar { display: flex; align-items: flex-end; gap: 8px; padding: 10px 12px; background: var(--bg-card); border-top-left-radius: 24px; border-top-right-radius: 24px; box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.06); }
.chat-input-bar textarea { flex: 1; min-height: 48px; max-height: 140px; resize: none; padding: 12px 16px; border-radius: 24px; border: 2px solid var(--border); background: var(--bg-input); color: var(--text-main); font: inherit; }
.send-btn { width: 48px; height: 48px; flex-shrink: 0; border-radius: 50%; border: none; background: var(--purple-strong); color: #fff; font-size: 1.1rem; cursor: pointer; }
.chat-hint { padding: 4px 16px 10px; background: var(--bg-card); }
.chat-blocked { margin: 0 12px; }
.menu { position: relative; }
.menu summary { list-style: none; cursor: pointer; }
.menu summary::-webkit-details-marker { display: none; }
.menu-list { position: absolute; right: 0; top: 52px; z-index: 10; background: var(--bg-card); border-radius: var(--radius-sm); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); padding: 8px; display: flex; flex-direction: column; min-width: 230px; }
.menu-list button { min-height: 44px; padding: 8px 12px; border: none; background: none; text-align: left; font: inherit; font-weight: 700; color: var(--text-main); cursor: pointer; border-radius: 10px; }
.menu-list button:hover { background: rgba(138, 124, 255, 0.1); }

/* ---------- rights & legal ---------- */
.rights-card p + p { margin-top: 8px; }
.rights-card p { color: var(--text-main); }
.sources { margin-top: 12px; }
.sources summary { cursor: pointer; font-weight: 800; color: var(--blue-text); min-height: 32px; }
.sources ul { padding-left: 20px; margin-top: 6px; }
.legal h2 { margin-top: 20px; }
.legal ul { padding-left: 20px; color: var(--text-main); }
.legal li { margin-bottom: 6px; }
.legal p { color: var(--text-main); }

/* ---------- welcome ---------- */
.welcome-header { text-align: center; margin: 16px 0 20px; }
.welcome-logo { display: block; width: 128px; height: 128px; margin: 0 auto 14px; border-radius: 28px; box-shadow: 0 12px 30px rgba(91, 75, 214, 0.25); }

/* ---------- dialogs ---------- */
.sheet-dialog { border: none; padding: 0; background: transparent; width: 100%; max-width: 560px; max-height: 92vh; margin: auto auto 0; color: var(--text-main); }
.sheet-dialog.wide { max-width: 720px; }
.sheet-dialog::backdrop { background: rgba(0, 0, 0, 0.5); backdrop-filter: blur(4px); }
.sheet-dialog .modal-content { background: var(--bg-app); border-top-left-radius: 32px; border-top-right-radius: 32px; padding: 20px 20px calc(24px + env(safe-area-inset-bottom)); max-height: 92vh; overflow-y: auto; animation: slideUp 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }
@media (min-width: 700px) { .sheet-dialog { margin: auto; } .sheet-dialog .modal-content { border-radius: 32px; } }
.modal-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.modal-header h2 { margin: 0; font-size: 1.3rem; }
.modal-body p { color: var(--text-main); }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; margin-top: 20px; }

/* ---------- toasts ---------- */
.toast-host { position: fixed; z-index: 3000; left: 50%; transform: translateX(-50%); bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 8px; width: min(92vw, 480px); pointer-events: none; }
.toast { pointer-events: auto; padding: 14px 18px; border-radius: 18px; font-weight: 700; color: #fff; background: #334155; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); animation: fadeIn 0.3s ease; transition: opacity 0.4s; }
.toast-success { background: #1E7B32; }
.toast-error { background: #B42318; }
.toast.hide { opacity: 0; }
.noscript { padding: 24px; text-align: center; }

/* ---------- friendly home: interactive wheelchair character ---------- */
.home { position: relative; overflow: hidden; }
.home > * { position: relative; z-index: 1; }
.home-blobs { position: absolute !important; inset: 0; z-index: 0 !important; pointer-events: none; }
.home-blobs span { position: absolute; border-radius: 50%; filter: blur(40px); opacity: 0.35; animation: float 14s ease-in-out infinite alternate; }
.home-blobs span:nth-child(1) { width: 260px; height: 260px; background: #A79DFF; top: -60px; right: -40px; }
.home-blobs span:nth-child(2) { width: 220px; height: 220px; background: #8FD99A; top: 340px; left: -80px; animation-delay: -5s; }
.home-blobs span:nth-child(3) { width: 200px; height: 200px; background: #FFB4B4; bottom: 40px; right: 10%; animation-delay: -9s; }
body.dark-mode .home-blobs span { opacity: 0.16; }
@keyframes float { from { transform: translate(0, 0) scale(1); } to { transform: translate(30px, 24px) scale(1.12); } }

.home > .hero-friendly { align-items: center; overflow: visible; padding-top: 8px; z-index: 5; }
.wave-emoji { display: inline-block; transform-origin: 70% 80%; animation: handWave 2.4s ease-in-out 0.6s 2; }
@keyframes handWave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(16deg); } 20%, 40% { transform: rotate(-8deg); } }

.hero-chair { position: relative; width: 116px; flex-shrink: 0; --tire: #3B3363; --rim: #A79DFF; --frame: #3B3363; --skin: #F3C29E; --body: #8A7CFF; --leg: #4D96FF; }
body.dark-mode .hero-chair { --tire: #E2E8F0; --frame: #CBD5E1; --rim: #B4ABFF; }
@media (max-width: 420px) { .hero-chair { width: 96px; } }
/* Soft circular halo so the character sits inside the app's visual language */
.hero-chair::before { content: ''; position: absolute; inset: 4% 2% 0; border-radius: 50%; z-index: 0;
    background: radial-gradient(circle at 40% 35%, rgba(255, 255, 255, 0.9), rgba(167, 157, 255, 0.35) 60%, rgba(107, 203, 119, 0.2)); box-shadow: 0 10px 30px var(--shadow-color); }
body.dark-mode .hero-chair::before { background: radial-gradient(circle at 40% 35%, rgba(138, 124, 255, 0.35), rgba(30, 41, 59, 0.6) 70%); }
.chair-body { position: relative; z-index: 1; display: block; width: 100%; padding: 6px; border: none; background: none; cursor: pointer; border-radius: 50%; }
.chair-svg { width: 100%; height: auto; display: block; overflow: visible; animation: bob 3.2s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.chair-svg .tire { fill: none; stroke: var(--tire); stroke-width: 4.5; }
.chair-svg .tire.small { stroke-width: 3.5; }
.chair-svg .spokes { fill: none; stroke: var(--rim); stroke-width: 2; stroke-linecap: round; }
.chair-svg .hub { fill: var(--tire); }
.chair-svg .frame { fill: none; stroke: var(--frame); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.chair-svg .body { fill: var(--body); }
.chair-svg .leg { fill: none; stroke: var(--leg); stroke-width: 6.5; stroke-linecap: round; stroke-linejoin: round; }
.chair-svg .arm { fill: none; stroke: var(--body); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.chair-svg .skin { fill: var(--skin); }
.chair-svg .eye { fill: #1F2937; }
.chair-svg .smile { fill: none; stroke: #1F2937; stroke-width: 1.4; stroke-linecap: round; }
.chair-svg .wheel, .chair-svg .arm-wave { transform-box: view-box; }
.chair-svg .wheel-big { transform-origin: 46px 82px; }
.chair-svg .wheel-small { transform-origin: 92px 101px; }
.chair-svg .arm-wave { transform-origin: 64px 44px; animation: armWave 3.6s ease-in-out infinite; }
@keyframes armWave { 0%, 55%, 100% { transform: rotate(0); } 65%, 85% { transform: rotate(-14deg); } 75%, 95% { transform: rotate(10deg); } }
.hero-chair:hover .wheel, .hero-chair.wiggle .wheel { animation: spin 1.6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.hero-chair.wiggle .chair-svg { animation: wiggle 0.6s ease; }
@keyframes wiggle { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-4deg) translateX(-4px); } 75% { transform: rotate(4deg) translateX(4px); } }

.chair-bubble {
    position: absolute; top: 2%; right: 88%; width: max-content; max-width: 170px; padding: 8px 12px; border-radius: 16px 16px 4px 16px; z-index: 4;
    background: var(--bg-card); color: var(--text-main); font-size: 0.82rem; font-weight: 700; box-shadow: 0 6px 18px var(--shadow-color);
    opacity: 0; transform: translateY(6px) scale(0.95); transition: opacity 0.3s, transform 0.3s; pointer-events: none; white-space: normal;
}
.hero-chair.talk .chair-bubble { opacity: 1; transform: none; }
@media (max-width: 520px) {
    .home > .hero-friendly { padding-top: 46px; }
    .chair-bubble { top: auto; bottom: 100%; right: 0; max-width: 150px; margin-bottom: 2px; border-radius: 16px 16px 4px 16px; }
}

.hotspot {
    position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; border: 2px solid #fff; cursor: pointer;
    display: flex; align-items: center; justify-content: center; font: inherit; font-weight: 800; z-index: 3;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25); transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hotspot::after { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 3px solid currentColor; opacity: 0; animation: ping 2.4s ease-out infinite; }
@keyframes ping { 0% { transform: scale(0.8); opacity: 0.7; } 80%, 100% { transform: scale(1.5); opacity: 0; } }
.hotspot:hover, .hotspot[aria-expanded="true"] { transform: scale(1.15); }
.hotspot-sos { left: 40%; top: 69%; background: #C0322F; color: #fff; font-size: 0.62rem; letter-spacing: 0.3px; }
.hotspot-sos::after { border-color: #FF6B6B; }
.hotspot-heart { left: 90%; top: 10%; background: #fff; color: #C0322F; font-size: 0.95rem; }
.hotspot-heart::after { border-color: #A79DFF; animation-delay: 1.2s; }

.chair-pop {
    position: absolute; top: calc(100% + 8px); right: 0; z-index: 60; width: min(320px, calc(100vw - 40px));
    padding: 18px 18px 16px; border-radius: 22px; background: var(--bg-card); color: var(--text-main);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25); border: 2px solid transparent; animation: popIn 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}
body.dark-mode .chair-pop { background: #1E293B; }
.chair-pop::before { content: ''; position: absolute; top: -9px; width: 18px; height: 18px; background: inherit; transform: rotate(45deg); border-radius: 4px; }
.pop-sos { border-color: #FF9C9C; }
.pop-sos::before { right: 42%; }
.pop-vol { border-color: #A79DFF; }
.pop-vol::before { right: 12%; }
@keyframes popIn { from { opacity: 0; transform: translateY(-8px) scale(0.92); } to { opacity: 1; transform: none; } }
.chair-pop p { color: var(--text-main); margin-top: 8px; font-size: 0.92rem; }
.pop-title { font-size: 1.1rem; font-weight: 800; margin-top: 0 !important; padding-right: 36px; }
.pop-close { position: absolute; top: 8px; right: 8px; width: 40px; height: 40px; border: none; border-radius: 50%; background: rgba(100, 116, 139, 0.12); color: var(--text-main); cursor: pointer; font-size: 0.9rem; }
.pop-112 { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; min-height: 52px; border-radius: 14px; background: #C0322F; color: #fff; font-size: 1.15rem; font-weight: 800; text-decoration: none; }
.pop-112::before { content: '📞'; }
.pop-small { font-size: 0.8rem !important; color: var(--text-muted) !important; }
.pop-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.pop-link { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 14px; border-radius: 14px; background: rgba(138, 124, 255, 0.12); color: var(--purple-text); font-weight: 800; text-decoration: none; transition: transform 0.2s; }
.pop-link:hover { transform: translateX(4px); background: rgba(138, 124, 255, 0.2); }

.section-kicker { font-size: 1.2rem; margin: 6px 0 12px; }
.action-grid > li { animation: cardIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes cardIn { from { opacity: 0; transform: translateY(16px) scale(0.96); } to { opacity: 1; transform: none; } }
@media (max-width: 759px) { .action-grid > li:last-child:nth-child(odd) { grid-column: 1 / -1; } .action-grid > li:last-child:nth-child(odd) .action-card { min-height: 110px; } }
.action-card { position: relative; }
.action-card .card-icon { transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }
.action-card:hover .card-icon { transform: rotate(-8deg) scale(1.12); }
.card-arrow { position: absolute; right: 18px; bottom: 16px; font-weight: 800; color: #1F2937; opacity: 0; transform: translateX(-6px); transition: opacity 0.25s, transform 0.25s; }
.action-card:hover .card-arrow, .action-card:focus-visible .card-arrow { opacity: 1; transform: none; }

/* Bento grid of home sections */
.bento { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; list-style: none; grid-auto-flow: dense; }
.tile { position: relative; display: flex; flex-direction: column; border-radius: var(--radius-lg); background: var(--gradient); overflow: hidden;
    box-shadow: 0 8px 25px var(--shadow-color); transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
    transition: transform 0.25s ease, box-shadow 0.3s ease; animation: tileIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both; animation-delay: calc(var(--i, 0) * 80ms); }
/* Uses translate/scale (not transform) so the mouse tilt keeps working after the entrance. */
@keyframes tileIn { from { opacity: 0; translate: 0 16px; scale: 0.96; } to { opacity: 1; translate: 0 0; scale: 1; } }
.tile::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s;
    background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.55), transparent 55%); }
.tile:hover { box-shadow: 0 18px 40px var(--shadow-color); }
.tile:hover::after { opacity: 1; }
.tile:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.tile-big, .tile-wide { grid-column: span 2; }
.tile-main { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 20px; min-height: 150px; text-decoration: none; }
.tile-main:focus-visible { outline: none; }
.tile-main .card-title { font-size: 1.1rem; }
.tile-big .tile-main { min-height: 230px; justify-content: flex-end; }
.tile-big .card-title { font-size: 1.35rem; }
.tile-main:hover .card-icon { transform: rotate(-8deg) scale(1.12); }
.tile-main:hover .card-arrow, .tile-main:focus-visible .card-arrow { opacity: 1; transform: none; }
.tile .card-icon { transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); }

.tile-quick { position: relative; z-index: 2; list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 16px; }
.tile-quick a { display: inline-flex; align-items: center; gap: 4px; min-height: 40px; padding: 6px 12px; border-radius: 100px;
    background: rgba(255, 255, 255, 0.78); color: #1F2937; font-size: 0.82rem; font-weight: 800; text-decoration: none;
    transition: transform 0.2s, background 0.2s; }
.tile-quick a:hover, .tile-quick a:focus-visible { background: #fff; transform: translateY(-2px); }
/* With a mouse, shortcuts slide in on hover or keyboard focus; on touch screens they stay visible. */
@media (hover: hover) and (pointer: fine) {
    .tile-quick { position: absolute; left: 0; right: 0; bottom: 0; padding-top: 30px; opacity: 0; transform: translateY(12px); pointer-events: none;
        transition: opacity 0.25s, transform 0.25s; background: linear-gradient(to top, rgba(255, 255, 255, 0.55), transparent); }
    .tile:hover .tile-quick, .tile:focus-within .tile-quick { opacity: 1; transform: none; pointer-events: auto; }
    .tile:hover .card-text, .tile:focus-within .card-text { opacity: 0.25; }
}

.tile-art { position: absolute; pointer-events: none; z-index: 0; }
.art-map { inset: 0; }
.art-map svg { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.55; }
.art-map .street { fill: none; stroke: #fff; stroke-width: 9; stroke-linecap: round; }
.art-map .street.thin { stroke-width: 5; }
.art-map .pin { position: absolute; width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 50%;
    background: #fff; box-shadow: 0 6px 14px rgba(0, 0, 0, 0.2); font-size: 1.15rem; line-height: 1; animation: pinDrop 2.8s ease-in-out infinite; }
.art-map .pin::after { content: ''; position: absolute; bottom: -6px; left: 50%; margin-left: -6px; border: 6px solid transparent; border-top-color: #fff; border-bottom: 0; }
.art-map .pin-1 { top: 18%; right: 14%; }
.art-map .pin-2 { top: 40%; right: 38%; animation-delay: 0.5s; }
.art-map .pin-3 { top: 12%; right: 58%; animation-delay: 1s; }
@keyframes pinDrop { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }
.art-map .me-dot { position: absolute; top: 55%; right: 20%; width: 16px; height: 16px; border-radius: 50%; background: #4D96FF; border: 3px solid #fff; box-shadow: 0 0 0 0 rgba(77, 150, 255, 0.6); animation: meping 2s infinite; }
@keyframes meping { 0% { box-shadow: 0 0 0 0 rgba(77, 150, 255, 0.6); } 100% { box-shadow: 0 0 0 18px rgba(77, 150, 255, 0); } }
.art-carousel { top: 14px; right: 18px; width: 64px; height: 64px; }
.art-carousel span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 2.6rem; opacity: 0;
    animation: carousel 10s infinite; animation-delay: calc(var(--k) * 2s); }
@keyframes carousel { 0% { opacity: 0; transform: translateY(14px) scale(0.8); } 4%, 16% { opacity: 1; transform: none; } 20%, 100% { opacity: 0; transform: translateY(-14px) scale(0.8); } }
.art-typing { top: 22px; right: 22px; display: flex; gap: 5px; padding: 10px 14px; border-radius: 18px 18px 4px 18px; background: rgba(255, 255, 255, 0.8); }
.art-typing span { width: 8px; height: 8px; border-radius: 50%; background: #8A7CFF; animation: typing 1.2s infinite; }
.art-typing span:nth-child(2) { animation-delay: 0.2s; }
.art-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing { 0%, 60%, 100% { transform: translateY(0); opacity: 0.5; } 30% { transform: translateY(-6px); opacity: 1; } }

@media (min-width: 760px) {
    .bento { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .tile-big { grid-row: span 2; }
    .tile-big .tile-main { min-height: 100%; }
    .tile-msg { grid-column: 1 / -1; }
    .tile-msg .tile-main { min-height: 110px; }
}

.tip-card { display: flex; gap: 14px; align-items: center; margin-top: 20px; padding: 16px 18px; border-radius: var(--radius-md); background: var(--bg-card); box-shadow: 0 6px 20px var(--shadow-color); border-left: 6px solid var(--primary-green); }
.tip-card p { color: var(--text-main); }
/* "Gândul zilei" — motivational thought on Home */
.quote-card { flex-wrap: wrap; border-left-color: var(--empathy-purple); background: linear-gradient(135deg, var(--bg-card), color-mix(in srgb, var(--empathy-purple) 10%, var(--bg-card))); }
.quote-label { font-size: 0.85rem; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase; color: var(--purple-text); margin: 0 0 4px; }
.quote-text { margin: 0; font-size: 1.15rem; font-weight: 700; line-height: 1.45; color: var(--text-main); font-style: italic; }
.quote-text.quote-in { animation: fadeIn 0.5s ease; }
.quote-card #next-quote { margin-left: auto; }
.tip-emoji { font-size: 2rem; animation: bob 3s ease-in-out infinite; }

/* ---------- transport & volunteer rides ---------- */
:root { --ride-green: #1E7B32; --ride-green-hover: #17662A; }
.btn-ride {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; padding: 14px 26px;
    border: none; border-radius: 16px; background: var(--ride-green); color: #fff; font: inherit; font-size: 1.05rem;
    font-weight: 800; text-decoration: none; cursor: pointer; box-shadow: 0 6px 18px rgba(30, 123, 50, 0.35);
}
.btn-ride:hover { background: var(--ride-green-hover); }
.btn-ride:disabled { opacity: 0.6; }
/* Language switch (beta banner, welcome screen, Profile) */
.lang-switch {
    display: inline-flex; align-items: center; gap: 6px; margin-left: 10px; min-height: 36px; padding: 4px 14px;
    border: 2px solid currentColor; border-radius: 100px; background: transparent; color: inherit; font: inherit; font-weight: 800; cursor: pointer;
}
.lang-switch.suggest { background: var(--purple-strong); border-color: var(--purple-strong); color: #fff; }
.demo-banner.lang-only { text-align: right; }
.welcome-lang { display: flex; width: max-content; margin: 0 0 8px auto; }
.label-like { display: block; font-weight: 800; margin-bottom: 6px; }
/* Voice reading: floating "Ascultă pagina" button, only when the setting is on. */
.speak-fab {
    display: none; position: fixed; z-index: 900; right: 16px; bottom: calc(var(--nav-h) + 20px + env(safe-area-inset-bottom));
    align-items: center; gap: 8px; min-height: 56px; padding: 12px 22px; border: none; border-radius: 100px;
    background: var(--purple-strong); color: #fff; font: inherit; font-size: 1.05rem; font-weight: 800; cursor: pointer;
    box-shadow: 0 10px 28px rgba(76, 60, 196, 0.4);
}
body.voice-on .speak-fab { display: inline-flex; }
.speak-fab[aria-pressed="true"] { background: #A3241F; box-shadow: 0 10px 28px rgba(163, 36, 31, 0.4); }
.speak-fab:focus-visible { outline: 3px solid #FFD66B; outline-offset: 3px; }
@media (min-width: 1000px) { .speak-fab { right: 32px; bottom: 32px; } }
.welcome-header #welcome-listen { margin-top: 14px; }
.welcome-name { margin: -4px 0 8px; font-size: 1.25rem; font-weight: 800; color: var(--purple-text); }
.btn-google {
    display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 52px; padding: 10px 20px;
    border: 2px solid var(--border); border-radius: 100px; background: #fff; color: #1F1F1F; font: inherit; font-weight: 800; cursor: pointer;
}
.btn-google:hover { border-color: var(--purple-strong); }
.btn-google .g-logo { width: 22px; height: 22px; flex: none; }
.link-btn { background: none; border: none; padding: 8px 4px; min-height: 40px; font: inherit; font-weight: 700; color: var(--blue-text); cursor: pointer; }

.ride-banner {
    display: flex; align-items: center; gap: 14px; padding: 18px 20px; margin-bottom: 18px; border-radius: var(--radius-md);
    background: linear-gradient(135deg, #1E7B32, #2E9E4A); color: #fff; text-decoration: none; box-shadow: 0 10px 28px rgba(30, 123, 50, 0.3);
}
.ride-banner-icon { font-size: 2.2rem; }
.ride-banner-title { display: block; font-size: 1.15rem; font-weight: 800; }
.ride-banner-text { display: block; font-size: 0.9rem; opacity: 0.95; }
.ride-banner-cta { white-space: nowrap; font-weight: 800; background: rgba(255, 255, 255, 0.2); padding: 10px 14px; border-radius: 12px; }
@media (max-width: 520px) { .ride-banner { flex-wrap: wrap; } .ride-banner-cta { width: 100%; text-align: center; } }

.ride-hero { padding: 20px; border-radius: var(--radius-md); background: rgba(107, 203, 119, 0.14); margin-bottom: 16px; display: flex; flex-direction: column; gap: 14px; }
.ride-hero p { color: var(--text-main); }
.link-card { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--text-main); }
.travel-card summary { cursor: pointer; min-height: 32px; list-style-position: outside; }
.travel-card p { color: var(--text-main); margin-top: 10px; }
.source-list { padding-left: 20px; }
.contact-lines li { padding: 4px 0; }

.route-curse { padding-bottom: 0 !important; }
.ride-page { position: relative; display: flex; flex-direction: column; min-height: calc(100vh - var(--nav-h) - env(safe-area-inset-bottom)); }
.ride-map { height: 42vh; min-height: 240px; background: #e0e5ec; z-index: 1; }
body.dark-mode .ride-map { background: #0B1220; }
.ride-page.picking .ride-map { height: calc(100vh - var(--nav-h) - 140px); }
.ride-page.picking .ride-sheet { display: none; }
.ride-page .map-crosshair { top: 21vh; }
.ride-page.picking .map-crosshair { top: calc((100vh - var(--nav-h) - 140px) / 2); }
.ride-back {
    position: absolute; top: 14px; left: 14px; z-index: 600; width: 48px; height: 48px; border-radius: 50%;
    background: var(--bg-card); display: flex; align-items: center; justify-content: center; text-decoration: none; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}
.ride-sheet {
    position: relative; z-index: 5; margin-top: -28px; padding: 10px 20px 28px; background: var(--bg-app);
    border-top-left-radius: 28px; border-top-right-radius: 28px; box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.12);
    display: flex; flex-direction: column; gap: 12px; max-width: 760px; width: 100%; margin-left: auto; margin-right: auto;
}
.ride-sheet h1 { margin-bottom: 0; }
.ride-sheet .pick-bar, .ride-page > .pick-bar { position: fixed; }
.dot { display: inline-block; width: 12px; height: 12px; margin-right: 8px; vertical-align: middle; }
.dot-pickup { background: var(--ride-green); border-radius: 50%; }
.dot-dest { background: var(--red-text); border-radius: 2px; }
.place-field { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--bg-card); box-shadow: 0 4px 14px var(--shadow-color); }
.place-input { display: flex; gap: 8px; }
.place-input input { flex: 1; min-width: 0; }
.place-tools { gap: 4px 16px; }
.suggestions { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.suggestion { width: 100%; text-align: left; display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; min-height: 44px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-input); color: var(--text-main); font: inherit; cursor: pointer; }
.suggestion:hover { border-color: var(--empathy-purple); }
.chosen { color: var(--green-text); font-weight: 700; font-size: 0.9rem; }
.vehicle-list { display: flex; flex-direction: column; gap: 8px; }
.vehicle-option { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 2px solid var(--border); border-radius: 16px; background: var(--bg-input); cursor: pointer; }
.vehicle-option input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.vehicle-option:has(input:checked) { border-color: var(--ride-green); background: rgba(107, 203, 119, 0.14); }
.vehicle-option:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.vehicle-icon { font-size: 1.8rem; width: 44px; text-align: center; }
.vehicle-text { flex: 1; display: flex; flex-direction: column; color: var(--text-main); }
.vehicle-text small { color: var(--text-muted); font-size: 0.82rem; }
.vehicle-meta { font-weight: 800; color: var(--text-main); white-space: nowrap; }
.more-options summary { cursor: pointer; font-weight: 800; color: var(--purple-text); min-height: 40px; display: flex; align-items: center; }
.active-rides { display: flex; flex-direction: column; gap: 8px; }
.active-ride { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 14px; background: rgba(107, 203, 119, 0.16); color: var(--text-main); text-decoration: none; border-left: 5px solid var(--ride-green); }
.stepper { list-style: none; display: flex; gap: 6px; flex-wrap: wrap; counter-reset: step; }
.stepper li { flex: 1 1 120px; padding: 8px 10px; border-radius: 10px; background: rgba(100, 116, 139, 0.12); color: var(--text-muted); font-size: 0.8rem; font-weight: 700; }
.stepper li.done { background: rgba(107, 203, 119, 0.22); color: var(--green-text); }
.stepper li[aria-current="step"] { outline: 2px solid var(--ride-green); }
.searching { display: flex; gap: 10px; align-items: center; color: var(--text-main); }
.driver-card { display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 18px; background: var(--bg-card); box-shadow: 0 6px 18px var(--shadow-color); }
.driver-name { color: var(--text-main); font-weight: 800; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.plate { display: inline-block; margin-top: 4px; padding: 4px 10px; border: 2px solid #1F2937; border-radius: 6px; background: #fff; color: #1F2937; font-weight: 800; letter-spacing: 1px; font-family: ui-monospace, Consolas, monospace; }
.ride-details { display: grid; gap: 10px; }
.ride-details dt { font-size: 0.8rem; color: var(--text-muted); font-weight: 700; }
.ride-details dd { color: var(--text-main); font-weight: 700; }
.ride-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-list { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; }
.tag-list li { padding: 4px 10px; border-radius: 100px; background: rgba(77, 150, 255, 0.14); color: var(--text-main); font-size: 0.8rem; }
.note-box { padding: 12px; border-radius: 12px; background: var(--bg-card); }
.request-card { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.request-card p { color: var(--text-main); }
.request-card.unfit { opacity: 0.75; }
@media (min-width: 1000px) {
    .ride-page { flex-direction: row; min-height: 100vh; }
    .ride-map { position: sticky; top: 0; height: 100vh; flex: 1.2; }
    .ride-sheet { flex: 1; margin: 0; border-radius: 0; max-height: 100vh; overflow-y: auto; box-shadow: -10px 0 30px rgba(0, 0, 0, 0.08); }
    .ride-page .map-crosshair { top: 50vh; left: calc(1.2 / 2.2 * 100%); }
    .ride-page.picking .ride-map { height: 100vh; }
}

/* ---------- beta ---------- */
.demo-banner.beta-banner { background: linear-gradient(90deg, #EEEAFF, #E6F6EA); color: #2E2566; border-bottom-color: #D8D1FF; }
.demo-banner.beta-banner a { color: #3B2DB0; font-weight: 800; }
body.dark-mode .demo-banner.beta-banner { background: linear-gradient(90deg, #241E4A, #13301D); color: #E6E1FF; border-bottom-color: #3B3363; }
body.dark-mode .demo-banner.beta-banner a { color: #D6D0FF; }
.beta-pill { display: inline-block; margin-right: 6px; padding: 2px 8px; border-radius: 100px; background: #5B4BD6; color: #fff; font-size: 0.7rem; font-weight: 800; letter-spacing: 1px; }
.face-row { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.face { position: relative; cursor: pointer; }
.face input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.face > span { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; min-height: 84px; border-radius: 16px; border: 2px solid var(--border); background: var(--bg-input); text-align: center; transition: transform 0.2s; }
.face small { font-size: 0.72rem; color: var(--text-muted); line-height: 1.2; }
.face-emoji { font-size: 1.8rem; line-height: 1; }
.face input:checked + span { border-color: var(--accent, #8A7CFF); background: rgba(138, 124, 255, 0.14); transform: scale(1.05); }
.face input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.route-parere { --accent: #E0527A; --accent-2: #FF9CB6; }
.thanks .emoji { font-size: 3rem; }
.feedback-item p { color: var(--text-main); }

/* ---------- motion preferences ---------- */
body.reduced-motion *, body.reduced-motion *::before, body.reduced-motion *::after {
    animation: none !important; transition: none !important; scroll-behavior: auto !important;
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
