/* ============================================================
   AEVIA — Medical Doctor Premium vCard (clinic-vcard)
   Calm clinical light · porcelain + deep teal + sage + warm sand
   Fraunces (display serif) + Inter (body) + IBM Plex Sans Arabic
   Mobile-first · RTL-safe (logical properties) · reduced-motion aware
   ============================================================ */

:root {
    --accent: var(--teal);
    --bg: var(--tk-bg, #F4F7F5);
    --surface: #FFFFFF;
    --surface-2: color-mix(in srgb, var(--tk-bg, #F4F7F5) 30%, #fff);
    --sage: color-mix(in srgb, var(--tk-primary, #0C6157) 10%, #fff);
    --sage-2: color-mix(in srgb, var(--tk-primary, #0C6157) 16%, #fff);
    --ink: var(--tk-text, #122420);
    --muted: color-mix(in srgb, var(--tk-text, #122420) 70%, #fff);
    --dim: color-mix(in srgb, var(--tk-text, #122420) 46%, #fff);
    --teal: var(--tk-primary, #0C6157);
    --teal-bright: color-mix(in srgb, var(--tk-primary, #0C6157) 82%, #fff);
    --teal-deep: var(--tk-secondary, #07433C);
    --teal-soft: rgb(from var(--tk-primary, #0C6157) r g b / .08);
    --teal-line: rgb(from var(--tk-primary, #0C6157) r g b / .28);
    /* sand demoted to a single quiet metallic detail (ticks / brackets only) */
    --sand: var(--tk-accent2, #B8985F);
    --sand-deep: color-mix(in srgb, var(--tk-accent2, #B8985F) 74%, #000);
    --sand-soft: color-mix(in srgb, var(--tk-accent2, #B8985F) 16%, #fff);
    --line: color-mix(in srgb, var(--tk-primary, #0C6157) 12%, #fff);
    --line-2: color-mix(in srgb, var(--tk-primary, #0C6157) 22%, #fff);
    --shadow-1: 0 1px 2px rgba(10, 40, 36, .05), 0 12px 30px -18px rgba(10, 40, 36, .16);
    --shadow-2: 0 3px 8px rgba(10, 40, 36, .06), 0 34px 70px -30px rgba(10, 40, 36, .30);
    --shadow-teal: 0 14px 34px -14px rgb(from var(--tk-primary, #0C6157) r g b / .42);
    --ring: 0 0 0 3px rgb(from var(--tk-primary, #0C6157) r g b / .16);
    --r-lg: 20px;
    --r-md: 14px;
    --r-sm: 10px;
    --font-d: var(--tk-font-header, 'Fraunces'), 'IBM Plex Sans Arabic', Georgia, serif;
    --font-b: var(--tk-font-content, 'Inter'), 'IBM Plex Sans Arabic', system-ui, sans-serif;
    --ease: cubic-bezier(.22, 1, .36, 1);
    --dock-h: 72px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html:focus-within { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-b);
    font-size: 16px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    min-height: 100vh;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
.hidden { display: none !important; }

::selection { background: var(--teal); color: #fff; }

/* ---------- Background system: daylight mesh + topographic contour field ---------- */
.fx { position: fixed; inset: 0; z-index: -2; pointer-events: none; overflow: hidden; }
.fx::before { /* layered daylight mesh — deeper teal anchor top + base wash */
    content: ""; position: absolute; inset: 0;
    background:
        radial-gradient(760px 520px at 88% -10%, rgb(from var(--tk-primary, #0C6157) r g b / .16), transparent 58%),
        radial-gradient(680px 520px at -14% 8%, color-mix(in srgb, var(--tk-primary, #0C6157) 16%, #fff), transparent 60%),
        radial-gradient(900px 560px at 50% -4%, color-mix(in srgb, var(--tk-primary, #0C6157) 10%, #fff), transparent 64%),
        radial-gradient(1100px 800px at 50% 116%, rgb(from var(--tk-primary, #0C6157) r g b / .08), transparent 62%),
        linear-gradient(180deg, color-mix(in srgb, var(--tk-primary, #0C6157) 9%, #fff) 0%, var(--bg) 30%);
}
.fx::after { /* topographic contour field — present at top, fades down */
    content: ""; position: absolute; inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='480' height='480' viewBox='0 0 480 480'%3E%3Cg fill='none' stroke='%230C6157' stroke-opacity='.07' stroke-width='1'%3E%3Cpath d='M0 36q120-30 240 0t240 0'/%3E%3Cpath d='M0 96q120-46 240 0t240 0'/%3E%3Cpath d='M0 156q120-26 240 0t240 0'/%3E%3Cpath d='M0 216q120-50 240 0t240 0'/%3E%3Cpath d='M0 276q120-32 240 0t240 0'/%3E%3Cpath d='M0 336q120-52 240 0t240 0'/%3E%3Cpath d='M0 396q120-26 240 0t240 0'/%3E%3Cpath d='M0 456q120-44 240 0t240 0'/%3E%3C/g%3E%3C/svg%3E");
    background-size: 480px 480px;
    -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0,0,0,.55) 36%, rgba(0,0,0,.18) 78%, transparent 100%);
            mask-image: linear-gradient(180deg, #000 0%, rgba(0,0,0,.55) 36%, rgba(0,0,0,.18) 78%, transparent 100%);
}

/* ---------- Layout ---------- */
.aev-wrap { max-width: 720px; margin-inline: auto; padding-inline: 20px; padding-block-end: calc(var(--dock-h) + 30px); }
.sec { padding-block: 46px; }
.sec-head { margin-block-end: 26px; }
.kicker {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-b); font-size: 11px; font-weight: 700;
    letter-spacing: .22em; text-transform: uppercase; color: var(--teal-bright);
}
/* signature: a measured tick + dash (clinical chart vernacular) */
.kicker::before { content: ""; width: 26px; height: 0; border-block-start: 1.5px solid var(--sand); position: relative; }
.kicker::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--teal-bright); }
.sec-title {
    font-family: var(--font-d); font-size: clamp(1.85rem, 6.4vw, 2.5rem);
    font-weight: 600; letter-spacing: -.018em; line-height: 1.08;
    margin-block-start: 12px; color: var(--ink);
    position: relative; padding-block-end: 14px;
}
/* signature: hairline baseline rule with a measured tick under every section title */
.sec-title::after {
    content: ""; position: absolute; inset-block-end: 0; inset-inline-start: 0;
    width: 44px; height: 2px; background: var(--teal);
    box-shadow: 7px 0 0 -.5px var(--sand);
}
.sec-sub { color: var(--muted); font-size: 15px; line-height: 1.6; margin-block-start: 4px; max-width: 56ch; }

/* ---------- Reveal: composed fade + 14px rise, signature easing ---------- */
.rv { opacity: 0; transform: translateY(14px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.rv.in { opacity: 1; transform: none; }
.rv-d1 { transition-delay: .09s; } .rv-d2 { transition-delay: .18s; } .rv-d3 { transition-delay: .27s; } .rv-d4 { transition-delay: .36s; }

/* ---------- Hero load choreography (runs once on paint) ---------- */
@keyframes aevRise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes aevPortrait { from { opacity: 0; transform: translateY(14px) scale(.94); } to { opacity: 1; transform: none; } }
.hero .portrait, .hero-chip, .hero-name, .hero-role, .hero-desc, .hero-cta, .hero-book {
    opacity: 0; animation: aevRise .8s var(--ease) forwards;
}
.hero .portrait { animation-name: aevPortrait; animation-delay: .05s; }
.hero-chip { animation-delay: .18s; }
.hero-name { animation-delay: .26s; }
.hero-role { animation-delay: .36s; }
.hero-desc { animation-delay: .44s; }
.hero-cta { animation-delay: .52s; }
.hero-book { animation-delay: .40s; }
.cover-band.rv { transition-delay: 0s; }

/* ---------- Topbar ---------- */
.topbar {
    position: sticky; inset-block-start: 0; z-index: 60;
    display: flex; align-items: center; gap: 12px;
    margin-inline: -20px; padding: 11px 20px;
    background: rgb(from var(--tk-bg, #F4F7F5) r g b / .72);
    backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4);
    border-block-end: 1px solid var(--line);
}
.topbar-avatar { width: 36px; height: 36px; border-radius: 11px; object-fit: cover; border: 1px solid var(--line-2); box-shadow: 0 0 0 3px rgba(255,255,255,.6); }
.topbar-name { font-family: var(--font-d); font-weight: 600; font-size: 15px; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-spacer { flex: 1; }

/* ---------- Hero ---------- */
.hero-zone { padding-block-start: 22px; }
.cover-band {
    position: relative;
    border-radius: var(--r-lg); overflow: hidden;
    border: 1px solid var(--line); box-shadow: var(--shadow-2);
    background: linear-gradient(135deg, var(--sage), var(--sage-2));
}
.cover-band img { width: 100%; height: 168px; object-fit: cover; }
/* warm-light wash so pale covers still read as a finished frame */
.cover-band::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(180deg, rgb(from var(--tk-secondary, #07433C) r g b / .04) 0%, transparent 34%, rgb(from var(--tk-secondary, #07433C) r g b / .16) 100%);
}

.hero { padding-block: 0 8px; }

/* the hero "chart card" — the signature lockup that frames the doctor */
.hero-card {
    position: relative;
    margin-block-start: -42px;
    padding: 56px 22px 24px;
    border-radius: var(--r-lg);
    background:
        linear-gradient(180deg, rgba(255,255,255,.96), var(--surface) 60%);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-2);
}
.cover-band + .hero .hero-card { margin-block-start: -48px; }
.hero:not(.cover-after) .hero-card { margin-block-start: 0; padding-block-start: 24px; }
/* signature corner brackets (clinical focus frame) */
.hero-card::before, .hero-card::after {
    content: ""; position: absolute; width: 22px; height: 22px; pointer-events: none;
}
.hero-card::before { inset-block-start: 12px; inset-inline-end: 12px; border-block-start: 2px solid var(--teal-line); border-inline-end: 2px solid var(--teal-line); border-start-end-radius: 6px; }
.hero-card::after { inset-block-end: 12px; inset-inline-start: 12px; border-block-end: 2px solid var(--sand); border-inline-start: 2px solid var(--sand); border-end-start-radius: 6px; opacity: .7; }

.portrait {
    position: absolute; inset-block-start: -46px; inset-inline-start: 22px;
    width: 88px; height: 88px; border-radius: 24px; overflow: hidden;
    border: 4px solid var(--surface);
    box-shadow: var(--shadow-2), 0 0 0 1px var(--line);
    background: var(--sage);
}
.hero:not(.cover-after) .portrait { position: static; margin-block-end: 16px; }
.portrait img { width: 100%; height: 100%; object-fit: cover; }

.hero-chip {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 13px; border-radius: 999px;
    background: rgb(from var(--teal-bright) r g b / .1); border: 1px solid rgb(from var(--teal-bright) r g b / .22);
    font-size: 12px; font-weight: 600; letter-spacing: .01em; color: var(--teal);
}
.hero-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal-bright); box-shadow: 0 0 0 0 rgb(from var(--teal-bright) r g b / .4); animation: calm-dot 2.8s ease-out infinite; }
@keyframes calm-dot { 60% { box-shadow: 0 0 0 8px rgb(from var(--teal-bright) r g b / 0); } 100% { box-shadow: 0 0 0 0 rgb(from var(--teal-bright) r g b / 0); } }

.hero-name {
    font-family: var(--font-d);
    font-size: clamp(2.5rem, 10vw, 3.9rem);
    font-weight: 600; letter-spacing: -.028em; line-height: .98;
    margin-block-start: 14px; color: var(--ink);
}
.hero-role {
    font-family: var(--font-d); font-style: italic; font-weight: 400;
    font-size: clamp(1.15rem, 4.6vw, 1.5rem); color: var(--teal-bright);
    margin-block-start: 10px; letter-spacing: -.01em;
}
.hero-desc { margin-block-start: 16px; color: var(--muted); font-size: 15px; line-height: 1.62; max-width: 56ch; }
.hero-desc p { margin-block-end: .6em; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 11px; margin-block-start: 22px; }

.btn-primary {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 15px 26px; border: 0; border-radius: var(--r-md);
    background: linear-gradient(180deg, var(--teal-bright), var(--teal) 58%, var(--teal-deep));
    color: #fff;
    font-family: var(--font-b); font-weight: 600; font-size: 14.5px; letter-spacing: .01em;
    box-shadow: var(--shadow-teal), inset 0 1px 0 rgba(255,255,255,.18);
    transition: transform .25s var(--ease), box-shadow .25s var(--ease), filter .25s ease;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 20px 40px -14px rgb(from var(--tk-primary, #0C6157) r g b / .52), inset 0 1px 0 rgba(255,255,255,.22); filter: brightness(1.04); }
.btn-primary:active { transform: translateY(0); }
.btn-block { width: 100%; justify-content: center; }

.btn-ghost {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 14px 22px; border-radius: var(--r-md);
    background: var(--surface); border: 1px solid var(--line-2);
    color: var(--ink); font-family: var(--font-b); font-weight: 600; font-size: 14.5px;
    transition: background .25s ease, border-color .25s ease, transform .25s ease;
}
.btn-ghost:hover { background: var(--sage); border-color: var(--sage-2); transform: translateY(-1px); }

.btn-mini {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 0; border: 0; background: transparent;
    font-family: var(--font-b); font-size: 13.5px; font-weight: 600; color: var(--teal);
    transition: gap .2s ease, color .2s ease;
}
.btn-mini i { font-size: 12.5px; }
.btn-mini:hover { gap: 12px; color: var(--teal-deep); }
/* trailing directional arrow points the reading-forward way in RTL (leading brand icon untouched) */
[dir="rtl"] .btn-mini i.fa-arrow-right,
[dir="rtl"] .btn-mini i.fa-arrow-up-right-from-square,
[dir="rtl"] .care-cta .btn-mini i:last-child { transform: scaleX(-1); }

/* ---------- Instant appointment card (hero sidekick — the "intake card") ---------- */
.hero-book {
    position: relative;
    margin-block-start: 24px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 24px 22px 22px;
    box-shadow: var(--shadow-2);
    overflow: hidden;
}
/* signature top accent band + faint contour echo */
.hero-book::before {
    content: ""; position: absolute; inset-block-start: 0; inset-inline: 0; height: 4px;
    background: linear-gradient(90deg, var(--teal-bright), var(--teal) 60%, var(--sand));
}
.hb-kicker {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 13px; border-radius: 999px;
    background: var(--teal-soft); color: var(--teal); border: 1px solid rgb(from var(--tk-primary, #0C6157) r g b / .16);
    font-size: 10.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
}
.hb-title { font-family: var(--font-d); font-size: 23px; font-weight: 600; letter-spacing: -.02em; margin-block-start: 13px; line-height: 1.1; }
.hb-sub { color: var(--muted); font-size: 13.5px; line-height: 1.55; margin-block-start: 6px; margin-block-end: 4px; }
.hb-note { display: flex; align-items: center; gap: 8px; color: var(--dim); font-size: 12px; margin-block-start: 14px; }
.hb-note i { color: var(--teal-bright); font-size: 13px; }

/* ---------- Vitals bar (one connected instrument, not floating pills) ---------- */
.trust-strip {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
    align-items: stretch; margin-block-start: 24px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); border-radius: var(--r-lg);
    box-shadow: var(--shadow-1); overflow: hidden;
}
@media (max-width: 539px) {
    .trust-strip { grid-template-columns: 1fr 1fr; grid-auto-flow: row; }
}
.trust-chip {
    display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
    padding: 16px 16px 15px; position: relative;
    border-inline-start: 1px solid var(--line);
}
.trust-chip:first-child { border-inline-start: 0; }
@media (max-width: 539px) {
    .trust-chip:nth-child(odd) { border-inline-start: 0; }
    .trust-chip:nth-child(n+3) { border-block-start: 1px solid var(--line); }
}
.trust-ic {
    width: 30px; height: 30px; border-radius: 9px; flex-shrink: 0;
    display: grid; place-items: center; font-size: 13px;
    background: var(--teal-soft); color: var(--teal);
}
.trust-val { font-family: var(--font-d); font-weight: 600; font-size: 1.6rem; color: var(--ink); line-height: 1; letter-spacing: -.02em; }
.trust-label { color: var(--muted); font-size: 11.5px; line-height: 1.25; font-weight: 500; }

/* ---------- Quick actions (centered flex — rows balance at any count) ---------- */
.qa-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-block-start: 22px; }
.qa-item {
    display: flex; flex-direction: column; align-items: center; gap: 9px;
    flex: 0 1 116px; min-width: 96px;
    padding: 16px 14px; border-radius: var(--r-md);
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line);
    color: var(--muted); font-size: 12px; font-weight: 600;
    box-shadow: var(--shadow-1);
    transition: transform .22s var(--ease), border-color .22s ease, box-shadow .22s ease;
}
/* labels (esp. longer Arabic words) stay clear of the tile edge */
.qa-item, .soc-item { text-align: center; line-height: 1.25; overflow-wrap: anywhere; word-break: break-word; }
.qa-item i { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; font-size: 15px; background: var(--teal-soft); color: var(--teal); transition: background .22s ease, color .22s ease; }
.qa-item:hover { transform: translateY(-3px); border-color: var(--line-2); box-shadow: var(--shadow-2); }
.qa-item:hover i { background: var(--teal); color: #fff; }

/* ---------- Video band (cover video + reel share geometry) ---------- */
.video-band { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: #0b1413; box-shadow: var(--shadow-1); margin-block-start: 22px; }
.video-band iframe { width: 100%; aspect-ratio: 16/9; border: 0; display: block; }

/* ---------- Expertise pills (checkmark micro-animation) ---------- */
.xp-list { display: grid; gap: 10px; }
.xp-pill {
    display: flex; align-items: center; flex-wrap: wrap; gap: 6px 13px;
    padding: 15px 18px; border-radius: 16px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1);
    transition: border-color .22s ease, transform .22s var(--ease), box-shadow .22s ease;
}
.xp-pill:hover { border-color: var(--teal-line); transform: translateX(3px); box-shadow: var(--shadow-2); }
[dir="rtl"] .xp-pill:hover { transform: translateX(-3px); }
.xp-check {
    width: 30px; height: 30px; border-radius: 10px; flex-shrink: 0;
    display: grid; place-items: center;
    background: var(--teal-soft); color: var(--teal); border: 1px solid rgb(from var(--tk-primary, #0C6157) r g b / .16);
}
.xp-check svg { width: 14px; height: 14px; }
.xp-check svg path { stroke-dasharray: 20; stroke-dashoffset: 20; transition: stroke-dashoffset .55s var(--ease) .25s; }
.rv.in .xp-check svg path { stroke-dashoffset: 0; }
.xp-main { font-weight: 600; font-size: 15px; color: var(--ink); letter-spacing: -.005em; }
.xp-detail { color: var(--muted); font-size: 13px; flex: 1 1 100%; padding-inline-start: 43px; }

/* ---------- Services (soft cards, icon in tinted tile) ---------- */
.care-grid { display: grid; gap: 14px; }
.care-card {
    position: relative; border-radius: var(--r-lg); padding: 24px 22px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1); overflow: hidden;
    transition: transform .3s var(--ease), border-color .3s ease, box-shadow .3s ease;
}
.care-card::before { /* ghost contour echo, top corner */
    content: ""; position: absolute; inset-block-start: -40px; inset-inline-end: -40px;
    width: 130px; height: 130px; border-radius: 50%;
    background: radial-gradient(circle, var(--teal-soft), transparent 70%);
    opacity: 0; transition: opacity .3s ease;
}
.care-card:hover { transform: translateY(-3px); border-color: var(--teal-line); box-shadow: var(--shadow-2); }
.care-card:hover::before { opacity: 1; }
.care-ic {
    position: relative; width: 52px; height: 52px; border-radius: 15px; overflow: hidden;
    display: grid; place-items: center; font-size: 20px;
    background: linear-gradient(140deg, var(--teal-soft), rgb(from var(--teal-bright) r g b / .04));
    color: var(--teal); border: 1px solid rgb(from var(--tk-primary, #0C6157) r g b / .14);
    margin-block-end: 15px;
}
.care-ic img { width: 100%; height: 100%; object-fit: cover; }
.care-name { position: relative; font-family: var(--font-d); font-size: 20px; font-weight: 600; letter-spacing: -.02em; line-height: 1.22; }
.care-desc { position: relative; color: var(--muted); font-size: 14px; line-height: 1.6; margin-block-start: 8px; }
.care-cta { position: relative; display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-block-start: 16px; padding-block-start: 15px; border-block-start: 1px solid var(--line); }

/* ---------- Care plans (products) ---------- */
.plan-grid { display: grid; gap: 16px; }
.plan-card {
    position: relative; border-radius: var(--r-lg); padding: 22px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1);
    display: flex; flex-direction: column;
    transition: transform .3s var(--ease), box-shadow .3s ease, border-color .3s ease;
}
.plan-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: var(--teal-line); }
.plan-badge {
    position: absolute; inset-block-start: -11px; inset-inline-start: 20px; z-index: 2;
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 13px; border-radius: 999px;
    font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
    background: linear-gradient(180deg, var(--teal-bright), var(--teal));
    color: #fff; box-shadow: var(--shadow-teal);
}
.plan-img {
    width: 100%; height: 152px; object-fit: cover;
    border-radius: var(--r-md); margin-block-end: 16px;
    border: 1px solid var(--line);
    background: linear-gradient(140deg, var(--sage), var(--sage-2)); /* mat behind pale images */
}
.plan-name { font-family: var(--font-d); font-size: 19px; font-weight: 600; letter-spacing: -.018em; line-height: 1.2; }
.plan-desc { color: var(--muted); font-size: 13.5px; line-height: 1.55; margin-block-start: 6px; }
.plan-price-row { display: flex; align-items: baseline; gap: 10px; margin-block-start: 16px; }
.plan-price { font-family: var(--font-d); font-size: 1.85rem; font-weight: 600; letter-spacing: -.02em; color: var(--ink); }
.plan-price-old { color: var(--dim); font-size: 14px; text-decoration: line-through; }
.plan-stock { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; margin-block-start: 6px; }
.plan-stock::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 18%, transparent); }
.plan-stock.ok { color: var(--teal-bright); }
.plan-stock.out { color: var(--sand-deep); }
.plan-card .btn-primary { width: 100%; justify-content: center; margin-block-start: auto; padding-block: 13px; }
.plan-card .plan-stock { margin-block-end: 16px; }

/* ---------- Gallery (slow-drift carousel) ---------- */
.gal { position: relative; }
.gal-track {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x proximity;
    margin-inline: -20px; padding-inline: 20px; padding-block-end: 8px;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.gal-track::-webkit-scrollbar { display: none; }
.gal-item {
    flex: 0 0 74%; max-width: 330px; scroll-snap-align: center;
    position: relative; border-radius: var(--r-lg); overflow: hidden;
    border: 1px solid var(--line); aspect-ratio: 4/3;
    background: linear-gradient(140deg, var(--sage), var(--sage-2));
    box-shadow: var(--shadow-1);
}
.gal-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.gal-item:hover img { transform: scale(1.05); }
.gal-cap {
    position: absolute; inset-block-end: 0; inset-inline: 0;
    padding: 34px 16px 13px; font-size: 13px; font-weight: 500; color: #fff;
    letter-spacing: .005em;
    background: linear-gradient(transparent, rgba(7, 30, 27, .82));
}
.gal-nav {
    position: absolute; inset-block-start: 50%; transform: translateY(-50%);
    width: 40px; height: 40px; border-radius: 50%;
    border: 1px solid var(--line-2); background: rgba(255, 255, 255, .92);
    color: var(--teal); backdrop-filter: blur(8px);
    display: grid; place-items: center; font-size: 13px; z-index: 5;
    box-shadow: var(--shadow-1);
    transition: background .2s ease;
}
.gal-nav:hover { background: #fff; }
.gal-nav.prev { inset-inline-start: -6px; }
.gal-nav.next { inset-inline-end: -6px; }
[dir="rtl"] .gal-nav i { transform: scaleX(-1); }
@media (max-width: 759px) { .gal-nav { display: none; } } /* touch swipes on mobile */

/* ---------- Videos reel ---------- */
.reel { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; margin-inline: -20px; padding-inline: 20px; padding-block-end: 8px; scrollbar-width: none; }
.reel::-webkit-scrollbar { display: none; }
.reel-item { flex: 0 0 86%; scroll-snap-align: center; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: #0b1413; box-shadow: var(--shadow-1); }
.reel-item:only-child { margin-inline: auto; }
.reel-item iframe { width: 100%; aspect-ratio: 16/9; border: 0; display: block; }
.reel-label { padding: 11px 14px; font-size: 13px; color: var(--muted); background: var(--surface); border-block-start: 1px solid var(--line); }

/* ---------- Testimonials (horizontal snap bar) ---------- */
.tm-track {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x proximity;
    margin-inline: -20px; padding-inline: 20px; padding-block-end: 8px;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.tm-track::-webkit-scrollbar { display: none; }
.tm-card {
    flex: 0 0 84%; max-width: 370px; scroll-snap-align: center;
    position: relative; padding: 26px 22px 22px; border-radius: var(--r-lg);
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1); overflow: hidden;
}
.tm-card::before { content: ""; position: absolute; inset-block-start: 0; inset-inline-start: 0; width: 3px; height: 100%; background: linear-gradient(180deg, var(--teal-bright), var(--teal)); opacity: .5; }
.tm-card:only-child { margin-inline: auto; }
/* decorative quote sits opposite the accent bar (logical property mirrors for RTL automatically) */
.tm-mark { position: absolute; inset-block-start: 6px; inset-inline-end: 18px; font-family: var(--font-d); font-style: italic; font-size: 72px; line-height: 1; color: var(--teal-soft); pointer-events: none; }
.tm-stars { display: flex; gap: 3px; color: var(--sand); font-size: 13px; margin-block-end: 12px; }
.tm-text { font-family: var(--font-d); font-size: 16px; font-weight: 400; line-height: 1.5; color: var(--ink); position: relative; }
.tm-who { display: flex; align-items: center; gap: 12px; margin-block-start: 15px; }
.tm-who img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-2); }
.tm-name { font-weight: 600; font-size: 13.5px; }
.tm-sub { color: var(--dim); font-size: 12px; }

/* ---------- Links / iframes ---------- */
.link-grid { display: grid; gap: 10px; }
.link-card {
    display: flex; align-items: center; gap: 14px;
    padding: 16px 18px; border-radius: var(--r-md);
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1);
    transition: transform .22s var(--ease), border-color .22s ease, box-shadow .22s ease;
}
.link-card:hover { transform: translateX(4px); border-color: var(--teal-line); box-shadow: var(--shadow-2); }
[dir="rtl"] .link-card:hover { transform: translateX(-4px); }
.link-ic { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; background: var(--teal-soft); color: var(--teal); font-size: 15px; flex-shrink: 0; }
.link-label { font-weight: 600; font-size: 14px; }
.link-val { color: var(--muted); font-size: 12.5px; word-break: break-word; }
.link-arrow { margin-inline-start: auto; color: var(--dim); font-size: 13px; }
[dir="rtl"] .link-arrow i { transform: scaleX(-1); }
.iframe-wrap { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); margin-block-end: 12px; background: var(--surface); }
.iframe-wrap iframe { width: 100%; min-height: 320px; border: 0; display: block; }

/* ---------- Panels & forms ---------- */
.panel { border-radius: var(--r-lg); padding: 26px 22px; background: linear-gradient(180deg, var(--surface), var(--surface-2)); border: 1px solid var(--line); box-shadow: var(--shadow-2); }
.f-label { display: block; font-size: 13px; font-weight: 600; color: var(--ink); margin-block: 14px 6px; }
.f-input, select.f-input, textarea.f-input {
    width: 100%; padding: 13px 15px; border-radius: 12px;
    background: color-mix(in srgb, var(--tk-primary, #0C6157) 4%, #fff); border: 1px solid var(--line-2);
    color: var(--ink); font-family: var(--font-b); font-size: 15px;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
    appearance: none; -webkit-appearance: none;
}
.f-input:focus { outline: none; border-color: var(--teal); background: #fff; box-shadow: var(--ring); }
.f-input::placeholder { color: var(--dim); }
select.f-input { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235C6F6A' stroke-width='1.6' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: calc(100% - 15px) center; }
[dir="rtl"] select.f-input { background-position: 15px center; }
select.f-input option { background: #fff; color: var(--ink); }
.grid-2f { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.alert-box { display: flex; align-items: center; gap: 10px; padding: 12px 15px; border-radius: 12px; font-size: 13.5px; margin-block-end: 14px; }
.alert-error { background: color-mix(in srgb, var(--tk-danger, #A23E33) 8%, #fff); border: 1px solid color-mix(in srgb, var(--tk-danger, #A23E33) 24%, #fff); color: var(--tk-danger, #A23E33); }
.alert-success { background: color-mix(in srgb, var(--tk-primary, #0C6157) 8%, #fff); border: 1px solid color-mix(in srgb, var(--tk-primary, #0C6157) 22%, #fff); color: var(--teal); }

/* flatpickr — porcelain skin */
.flatpickr-calendar { background: #fff !important; border: 1px solid var(--line-2) !important; border-radius: 16px !important; box-shadow: var(--shadow-2) !important; font-family: var(--font-b) !important; }
.flatpickr-day { color: var(--ink) !important; border-radius: 10px !important; }
.flatpickr-day:hover { background: var(--sage) !important; border-color: transparent !important; }
.flatpickr-day.today { border-color: var(--sand) !important; }
.flatpickr-day.selected { background: var(--teal) !important; border-color: var(--teal) !important; color: #fff !important; }
.flatpickr-day.flatpickr-disabled { color: var(--dim) !important; opacity: .45; }
.flatpickr-month, .flatpickr-current-month .flatpickr-monthDropdown-months, .flatpickr-current-month input.cur-year, .flatpickr-weekday { color: var(--ink) !important; fill: var(--ink) !important; }
.flatpickr-prev-month svg, .flatpickr-next-month svg { fill: var(--muted) !important; }

/* ---------- Hours ---------- */
.hour-row { display: flex; justify-content: space-between; align-items: center; padding-block: 11px; border-block-end: 1px solid var(--line); font-size: 14px; }
.hour-row:last-child { border-block-end: 0; }
.hour-day { color: var(--muted); font-weight: 500; }
.hour-time { color: var(--ink); }
.hour-row.today .hour-day, .hour-row.today .hour-time { color: var(--teal); font-weight: 600; }
.hour-row.today .hour-day::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--sand); margin-inline-start: 8px; vertical-align: middle; }
.hour-24 { display: flex; align-items: center; gap: 10px; color: var(--teal); font-weight: 600; font-size: 15px; }

/* ---------- Map ---------- */
.map-wrap { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.map-wrap iframe { width: 100%; height: 280px; border: 0; display: block; }

/* ---------- Payments ---------- */
.pay-grid { display: grid; gap: 12px; }
.pay-card { padding: 17px 18px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); }
.pay-label { font-weight: 600; font-size: 14px; margin-block-end: 5px; color: var(--ink); }
.pay-label i { color: var(--teal); }
.pay-val { color: var(--muted); font-size: 13.5px; word-break: break-all; }
.pay-img { border-radius: var(--r-sm); max-height: 220px; margin-inline: auto; border: 1px solid var(--line); }

/* ---------- Socials (centered flex — rows balance at any count) ---------- */
.soc-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.soc-item {
    display: flex; flex-direction: column; align-items: center; gap: 10px;
    flex: 0 1 112px; min-width: 98px;
    padding: 18px 14px; border-radius: var(--r-md);
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--line); box-shadow: var(--shadow-1);
    font-size: 12px; color: var(--muted); font-weight: 600;
    transition: transform .22s var(--ease), border-color .22s ease, box-shadow .22s ease;
}
.soc-item i { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-size: 17px; background: var(--teal-soft); color: var(--teal); transition: background .22s ease, color .22s ease; }
.soc-item:hover { transform: translateY(-3px); border-color: var(--teal-line); color: var(--ink); box-shadow: var(--shadow-2); }
.soc-item:hover i { background: var(--teal); color: #fff; }
.footer { text-align: center; padding-block: 32px 8px; color: var(--dim); font-size: 12.5px; border-block-start: 1px solid var(--line); margin-block-start: 20px; }
.footer a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Action dock ---------- */
.dock {
    position: fixed; inset-block-end: 0; inset-inline: 0; z-index: 70;
    display: flex; justify-content: center;
    padding-block-end: calc(10px + env(safe-area-inset-bottom));
    pointer-events: none;
    transition: transform .35s ease;
}
.dock.dock-hide { transform: translateY(130%); }
.dock-inner {
    pointer-events: auto;
    display: flex; align-items: center; gap: 4px;
    padding: 8px 12px; border-radius: 24px;
    background: rgba(255, 255, 255, .82);
    border: 1px solid rgba(255,255,255,.7);
    backdrop-filter: blur(22px) saturate(1.5); -webkit-backdrop-filter: blur(22px) saturate(1.5);
    box-shadow: var(--shadow-2), inset 0 1px 0 rgba(255,255,255,.7);
}
.dock-btn {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    min-width: 56px; padding: 8px 6px; border: 0; background: transparent;
    color: var(--muted); font-size: 10.5px; font-weight: 600; border-radius: 14px;
    transition: color .2s ease, background .2s ease;
}
.dock-btn i { font-size: 16px; color: var(--teal); }
.dock-btn:hover, .dock-btn:focus-visible { color: var(--ink); background: var(--sage); }
.dock-btn.dock-main {
    background: linear-gradient(180deg, var(--teal-bright), var(--teal) 60%, var(--teal-deep));
    color: #fff; border-radius: 18px;
    min-width: 64px; padding-block: 11px;
    box-shadow: var(--shadow-teal), inset 0 1px 0 rgba(255,255,255,.2);
    transform: translateY(-10px);
}
.dock-btn.dock-main i { color: #fff; }
.dock-btn.dock-main:hover { filter: brightness(1.06); }

/* ---------- Modals ---------- */
.pm-overlay {
    position: fixed; inset: 0; z-index: 90;
    display: flex; align-items: flex-end; justify-content: center;
    background: rgba(23, 37, 34, .42); backdrop-filter: blur(6px);
    opacity: 0; transition: opacity .3s ease; padding: 16px;
}
.pm-overlay.show { opacity: 1; }
.pm-box {
    position: relative; /* anchors .pm-close inside the box */
    width: 100%; max-width: 470px; max-height: 86vh; overflow-y: auto;
    border-radius: 24px; padding: 26px 22px;
    background: linear-gradient(180deg, var(--surface), var(--surface-2)); border: 1px solid var(--line);
    box-shadow: var(--shadow-2);
    transform: translateY(26px) scale(.98); transition: transform .4s var(--ease);
}
.pm-overlay.show .pm-box { transform: none; }
.pm-title { font-family: var(--font-d); font-size: 23px; font-weight: 600; letter-spacing: -.02em; color: var(--ink); }
.pm-sub { color: var(--muted); font-size: 13.5px; margin-block-start: 4px; }
.pm-close { position: absolute; inset-block-start: 16px; inset-inline-end: 16px; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--surface); color: var(--muted); display: grid; place-items: center; transition: background .2s ease; }
.pm-close:hover { background: var(--sage); color: var(--ink); }
.pm-head { position: relative; margin-block-end: 8px; padding-inline-end: 40px; }
.pm-actions { display: flex; gap: 10px; margin-block-start: 20px; }
.pm-actions .btn-ghost, .pm-actions .btn-primary { flex: 1; justify-content: center; }
.qr-wrap { display: grid; place-items: center; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); width: fit-content; margin: 18px auto; }
.share-row { display: flex; justify-content: center; gap: 11px; margin-block: 14px; }
.share-row a { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--sage); border: 1px solid var(--sage-2); font-size: 16px; color: var(--teal); transition: transform .2s ease, background .2s ease; }
.share-row a:hover { transform: translateY(-2px); background: var(--sage-2); }

@media (min-width: 480px) {
    .pm-overlay { align-items: center; }
}

/* ---------- Language switcher ---------- */
.lang-wrap { position: relative; }
.lang-btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 14px; border-radius: 999px;
    background: var(--surface); border: 1px solid var(--line-2);
    color: var(--ink); font-size: 12.5px; font-weight: 600;
    transition: background .2s ease;
}
.lang-btn:hover { background: var(--sage); }
.lang-btn i { color: var(--teal); font-size: 13px; }
.lang-menu {
    position: absolute; inset-inline-end: 0; inset-block-start: calc(100% + 8px);
    min-width: 160px; max-height: 280px; overflow-y: auto;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 6px; z-index: 80;
    box-shadow: var(--shadow-2);
}
.lang-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 9px; font-size: 13.5px; color: var(--muted); transition: background .15s ease, color .15s ease; }
.lang-item:hover { background: var(--sage); color: var(--ink); }
.lang-item.active { color: var(--teal); font-weight: 600; }

/* ---------- Desktop ---------- */
@media (min-width: 760px) {
    .aev-wrap { max-width: 1040px; }
    .sec { padding-block: 62px; }
    .hero-zone { padding-block-start: 34px; }
    .cover-band img { height: 248px; }
    .hero { padding-block: 0 10px; }
    .hero.has-side { display: grid; grid-template-columns: 1.1fr .9fr; gap: 30px; align-items: start; }
    .hero.has-side .hero-book { margin-block-start: 0; }
    .hero.has-side.cover-after .hero-book { margin-block-start: -48px; } /* align top with hero-card under cover */
    .hero:not(.has-side) .hero-card { max-width: 720px; }
    .hero-card { padding: 60px 30px 30px; }
    .hero:not(.cover-after) .hero-card { padding-block-start: 30px; }
    .portrait { width: 96px; height: 96px; inset-block-start: -50px; inset-inline-start: 30px; }
    .hero-book { padding: 28px; }
    .qa-item { flex-basis: 168px; }
    .xp-list { grid-template-columns: 1fr 1fr; }
    .care-grid { grid-template-columns: repeat(2, 1fr); }
    .plan-grid { grid-template-columns: repeat(3, 1fr); }
    .gal-item { flex-basis: 34%; }
    .reel-item { flex-basis: 56%; }
    .tm-card { flex-basis: 42%; }
    .soc-item { flex-basis: 132px; }
    .map-wrap iframe { height: 360px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .hero-chip .dot { animation: none !important; }
    .rv { opacity: 1; transform: none; transition: none; }
    .hero .portrait, .hero-chip, .hero-name, .hero-role, .hero-desc, .hero-cta, .hero-book {
        animation: none !important; opacity: 1 !important;
    }
    .xp-check svg path { stroke-dashoffset: 0; transition: none; }
    .gal-item img, .btn-primary, .btn-ghost, .care-card, .plan-card, .qa-item, .soc-item, .link-card, .xp-pill { transition: none; }
}


/* ============================================================
   GLOBAL CONTAINMENT BASELINE (founder remark: diagonal-scroll
   drift / horizontal "wiggle" on mobile + zoom-out).
   overflow-x:clip on html is sticky-safe (unlike hidden) and
   stops the horizontal pan; overscroll-behavior-x:none kills the
   rubber-band; max-width:100% + min-width:0 prevent any child
   from forcing the document wider than the viewport.
   ============================================================ */
html { overflow-x: clip; }
body { overflow-x: clip; overscroll-behavior-x: none; max-width: 100%; }
/* horizontal scrollers keep their swipe to themselves */
.car-track, .reel, .film-reel, .tm-track, .letters, .marquee, .marquee-track,
[class*="-track"], [class*="-rail"], [class*="-carousel"], [class*="-scroll"] {
    overscroll-behavior-x: contain;
    max-width: 100vw;
}
