/* ============================================================================
   components.css — the reusable pieces that sit inside the sections: the data
   cards, the step and feature cards, the comparison panels and the WhatsApp
   conversation mock.

   ========================================================================== */

/* ─────────────────────  hero data cards (shared)  ─────────────────── */
.hero__card {
    position: absolute;
    /* Vertically centred on the screen while the hero is at rest. */
    top: 50vh;
    translate: 0 -50%;
    width: 300px;
    border-radius: 14px;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.hero__card--passport { right: 88px; }
.hero__card--voucher  { left: 88px; }

.card__title { font-size: 15px; font-weight: 700; margin: 0 0 12px; }

/* Title and status on one line: the badge sits at the far end, and the head keeps the title's own
   bottom margin so both hero cards stay the height they were. */
.card__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; margin: 0 0 12px; }
.card__head .card__title { margin: 0; }
/* The page's own green (the chat's send disc, the online dot), as a tint rather than a fill. */
.card__badge {
    font-size: 11px;
    font-weight: 500;
    line-height: 16px;
    padding: 2px 8px;
    border-radius: 6px;
    color: #25d367;
    background: rgba(37, 211, 103, 0.14);
    box-shadow: inset 0 0 0 1px rgba(37, 211, 103, 0.22);
    white-space: nowrap;
}

.card__row {
    display: flex;
    gap: 8px;
    justify-content: flex-start;
    width: 100%;
    font-size: 12px;
    margin: 0 0 6px;
    perspective: 320px;   /* gives the nationality flip its depth */
}
.card__row dt { opacity: 0.45; order: 1; }
.card__row dd { opacity: 0.8; font-weight: 500; order: 2; }

.card__note { font-size: 11px; font-weight: 500; opacity: 0.6; margin: 16px 0 0; }

/* ───────────────────────  approval voucher card  ──────────────────── */
.voucher__body { display: flex; align-items: center; gap: 14px; width: 100%; justify-content: flex-start; }
/* Label over value, three high: the stack is no taller than the passport card's three rows and
   note, so the pair shares a height without either card carrying empty space. */
.voucher__facts { display: flex; flex-direction: column; gap: 5px; margin: 0; min-width: 0; text-align: start; }
.voucher__fact { perspective: 320px; }   /* gives the authority flip its depth */
.voucher__fact dt { font-size: 11px; line-height: 13px; opacity: 0.45; }
.voucher__fact dd { margin: 0; font-size: 12px; line-height: 15px; font-weight: 500; opacity: 0.8; white-space: nowrap; }
/* Codes and dates are Latin and read left to right inside the Arabic card; inline-block so the
   row's own alignment still places them at the start. */
.voucher__code { display: inline-block; direction: ltr; unicode-bidi: isolate; font-variant-numeric: tabular-nums; }
/* The flip reserves the widest number as a min-width, and a left-to-right box would park a short
   number at its left. The number keeps its own order but sits on the page's reading edge. */
[dir="rtl"] .voucher__code { text-align: right; }
[dir="ltr"] .voucher__code { text-align: left; }

.qr {
    width: 72px;
    height: 72px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #d5d7da;
    padding: 12px;
    flex-shrink: 0;
}
.qr svg { display: block; width: 100%; height: 100%; }

/* ───────────────────  split-flap rotating fields  ─────────────────── */
.flap, .flap-code { display: inline-block; }
.flap { transform-origin: center bottom; backface-visibility: hidden; }

/* ────────────────────  02 — authority cells  ──────────────────────── */
.authorities__cell {
    flex: 1 0 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 26px 24px;
    text-align: center;
    border-inline-start: 1px solid var(--hairline);
}
.authorities__cell:first-child { border-inline-start: 0; }
.authorities__cell b { font-size: 19px; font-weight: 700; opacity: 0.9; }
.authorities__cell span { font-size: 13px; opacity: 0.4; }

/* ──────────────────────  03 — step cards  ─────────────────────────── */
.step {
    flex: 1 0 0;
    min-width: 0;
    border-radius: 14px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: start;
}
.step__num {
    width: 38px;
    height: 38px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    opacity: 0.6;
    margin-bottom: 16px;
}
.step:first-child .step__num { background: var(--red); opacity: 1; }
.step h3 { font-size: 17px; font-weight: 700; margin: 0 0 8px; }
.step p { font-size: 13px; line-height: 20px; opacity: 0.5; margin: 0; }

/* ──────────────────────  04 — why cards  ──────────────────────────── */
.why__card {
    flex: 1 0 0;
    min-width: 0;
    border-radius: 18px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 42px;
    min-height: 392px;
}
.why__card:nth-child(even) { margin-top: 52px; min-height: 340px; }
.why__card-body { width: 100%; text-align: start; }
/* inline-end is the physical left in RTL, so this pins the mark right. */
.why__card-body img { width: 32px; height: 32px; border-radius: 8px; display: block; margin-inline-end: auto; }
.why__card-body h3 {
    font-size: 36px;
    line-height: 44px;
    font-weight: 700;
    letter-spacing: -0.72px;
    margin: 14px 0 8px;
}
.why__card-body p { font-size: 14px; line-height: 20px; opacity: 0.45; margin: 0; }

/* ─────────────────  05 — documents list + passport  ───────────────── */
/* Same card treatment as the passport card beside it. */
.docs__list {
    width: 400px;
    flex-shrink: 0;
    border-radius: 16px;
    padding: 22px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
}
.docs__list li {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    font-size: 14px;
    opacity: 0.6;
}
.docs__list img { width: 6px; height: 6px; display: block; flex-shrink: 0; }

.passport {
    width: 420px;
    flex-shrink: 0;
    border-radius: 16px;
    padding: 22px 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.passport__head {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
    width: 100%;
    margin-bottom: 16px;
}
/* order 1 lands on the right in RTL: logomark first, then the title. */
.passport__head img { width: 26px; height: 14.37px; display: block; order: 1; }
.passport__head h3 { font-size: 16px; font-weight: 700; margin: 0; order: 2; }
.passport .card__row { font-size: 13px; margin: 0 0 8px; perspective: 320px; }
/* Tabular figures + nowrap keep the rotating fields from reflowing. */
.passport .card__row dd { font-variant-numeric: tabular-nums; white-space: nowrap; }
.passport .card__row dt { opacity: 0.42; }
.passport__note { font-size: 12px; font-weight: 500; opacity: 0.55; margin: 4px 0 0; }

/* ────────────────────  06 — WhatsApp button  ──────────────────────── */
.btn--whatsapp {
    gap: 12px;
    padding-block: 9px;
    padding-inline-start: 9px;    /* the icon side */
    padding-inline-end: 26px;
    font-size: 15px;
    font-weight: 700;
    background: var(--glass-bg);
    border-color: var(--glass-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
.btn--whatsapp:hover {
    background: rgba(255, 255, 255, 0.13);
    border-color: rgba(255, 255, 255, 0.32);
}
.btn__icon {
    width: 36px;
    height: 36px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.14);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background-color 0.3s ease;
}
.btn--whatsapp:hover .btn__icon { background: rgba(255, 255, 255, 0.22); }
.btn__icon svg { width: 19px; height: 19px; display: block; fill: #fff; }

/* ────────────────────  06 — conversation mock  ────────────────────── */
.chat {
    flex: 0 0 500px;
    width: 500px;
    margin: 0;
    border-radius: 20px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.chat__head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid var(--hairline);
}
.chat__avatar {
    width: 38px;
    height: 38px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    order: 1;
}
.chat__avatar img { width: 22px; height: 12.16px; display: block; }
.chat__id { flex: 1 0 0; min-width: 0; display: flex; flex-direction: column; gap: 3px; align-items: flex-start; order: 2; }
.chat__id b { font-size: 15px; font-weight: 700; }
.chat__status { display: flex; align-items: center; gap: 6px; font-size: 11px; opacity: 0.45; }
.chat__status img { width: 6px; height: 6px; display: block; }

.chat__body { display: flex; flex-direction: column; gap: 10px; padding: 18px; }
.chat__row { display: flex; }
/* RTL thread: your own messages sit left, the account's replies right. */
.chat__row--out { justify-content: flex-end; }
.chat__row--in  { justify-content: flex-start; }

.bubble {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
    padding: 10px 14px 8px;
    border-radius: 16px;
    max-width: 318px;
}
.bubble p { font-size: 13px; line-height: 21px; opacity: 0.9; margin: 0; width: 290px; }
.bubble__meta { display: flex; align-items: center; gap: 5px; width: 100%; font-size: 10px; justify-content: flex-end; }
.bubble__meta time { order: 2; opacity: 0.35; }
.bubble__ticks { order: 1; color: #25d367; opacity: 0.9; }

.bubble--out {
    background: rgba(37, 211, 103, 0.16);
    border: 1px solid rgba(37, 211, 103, 0.24);
    border-start-end-radius: 6px;   /* notch on the top-left in RTL */
}
.bubble--in {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--hairline);
    border-start-start-radius: 6px; /* notch on the top-right in RTL */
}

.chat__foot {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px 14px;
    border-top: 1px solid var(--hairline);
}
/* The send button carries the glyph the product itself sends with — a green disc with nothing on
   it reads as a status dot rather than as a control. */
.chat__send {
    width: 34px;
    height: 34px;
    border-radius: 99px;
    background: rgba(37, 211, 103, 0.9);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.chat__send img { width: 17px; height: 17px; display: block; }
.chat__input {
    flex: 1 0 0;
    min-width: 0;
    padding: 9px 14px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.06);
    font-size: 12px;
    opacity: 0.35;
    text-align: start;
}

/* ────────────────────  07 — comparison panels  ────────────────────── */
.panel {
    flex: 1 0 0;
    min-width: 0;
    border-radius: 18px;
    padding: 26px 28px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.panel--good { border-color: rgba(229, 29, 40, 0.5); }
.panel__badge { margin-bottom: 20px; font-size: 12px; font-weight: 700; }
.panel--good .panel__badge { background: var(--red); border-color: transparent; opacity: 1; }
.panel li {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    padding: 8px 0;
    font-size: 16px;
    font-weight: 500;
}
.panel img { width: 6px; height: 6px; display: block; flex-shrink: 0; }
.panel--good li { opacity: 0.92; }
.panel--bad li { opacity: 0.4; }
