/* Localization interaction fixtures and missions (localization_bare layout).
   Logical properties only, so the same rules lay out the RTL (ar) pages. */

.l10n-app { background: #f8fafc; margin: 0; font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Noto Sans Arabic", sans-serif; color: #111827; }
.l10n-app-main { max-width: 760px; margin: 0 auto; padding: 1.5rem 1rem 4rem; }
.l10n-page h1 { font-size: 1.5rem; margin: 0 0 0.5rem; }
.l10n-page h3 { margin-block: 0 0.75rem; }

.l10n-form .l10n-field { margin-block-end: 0.9rem; }
.l10n-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
.l10n-form label, .l10n-form .l10n-label { display: block; font-weight: 600; margin-block-end: 0.25rem; }
.l10n-form input:not([type=checkbox]):not([type=radio]) {
  width: 100%; box-sizing: border-box; padding: 0.5rem 0.6rem;
  border: 1px solid #cbd5e1; border-radius: 6px; font: inherit;
}
.l10n-checks label { font-weight: 400; }
.su-hint, .su-help, .mc-hint { margin: 0.25rem 0 0; font-size: 0.85rem; color: #4b5563; }
.su-error, .mb-error, .mc-error, .ca-promo-error { margin: 0.25rem 0 0; font-size: 0.85rem; color: #b91c1c; }
.su-strength { margin: 0.25rem 0 0; font-size: 0.85rem; }

.l10n-btn {
  display: inline-block; padding: 0.45rem 0.9rem; border: 1px solid #cbd5e1; border-radius: 6px;
  background: #fff; font: inherit; cursor: pointer;
}
.l10n-btn--primary { background: #2563eb; border-color: #2563eb; color: #fff; }
.l10n-btn--danger { background: #b91c1c; border-color: #b91c1c; color: #fff; }
.l10n-btn:disabled { opacity: 0.5; cursor: default; }
.l10n-link { background: none; border: none; padding: 0; color: #1d4ed8; text-decoration: underline; cursor: pointer; font: inherit; }
.controls { margin-block-start: 1rem; display: flex; gap: 0.5rem; flex-wrap: wrap; }

.l10n-toast, .l10n-snackbar {
  position: fixed; inset-block-end: 1.25rem; inset-inline-start: 50%; transform: translateX(-50%);
  background: #111827; color: #fff; padding: 0.7rem 1.1rem; border-radius: 8px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2); z-index: 20;
}
[dir=rtl] .l10n-toast, [dir=rtl] .l10n-snackbar { transform: translateX(50%); }
.l10n-snackbar { inset-block-end: 4.5rem; display: flex; gap: 1rem; align-items: center; }
.l10n-snackbar .l10n-link { color: #93c5fd; }
.l10n-toast[hidden], .l10n-snackbar[hidden] { display: none; }

/* Sign-up */
.su-tip-wrap { position: relative; display: inline-block; margin-inline-start: 0.35rem; }
.su-tip-button { inline-size: 1.4rem; block-size: 1.4rem; border-radius: 50%; border: 1px solid #94a3b8; background: #fff; cursor: help; font-size: 0.8rem; }
.su-tooltip {
  position: absolute; inset-block-start: 1.8rem; inset-inline-start: 0; inline-size: 18rem;
  background: #111827; color: #fff; font-weight: 400; font-size: 0.85rem; padding: 0.5rem 0.7rem; border-radius: 6px; z-index: 5;
}
.su-country { position: relative; }
.su-country-button { inline-size: 100%; text-align: start; padding: 0.5rem 0.6rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.su-country-list { position: absolute; inset-inline: 0; margin: 0.2rem 0 0; padding: 0.25rem 0; list-style: none; background: #fff; border: 1px solid #cbd5e1; border-radius: 6px; z-index: 5; }
.su-country-option { padding: 0.4rem 0.7rem; cursor: pointer; }
.su-country-option:hover, .su-country-option:focus { background: #eef2ff; }
.su-success { color: #166534; }

/* Cart */
.ca-item { display: grid; grid-template-columns: 1fr auto auto auto; gap: 0.75rem; align-items: center; padding-block: 0.6rem; border-block-end: 1px dashed #e5e7eb; }
.ca-item:last-child { border-block-end: none; }
.ca-item[hidden] { display: none; }
.ca-item-main { display: flex; flex-direction: column; gap: 0.15rem; }
.ca-sku, .ca-weight { font-size: 0.82rem; color: #4b5563; }
.ca-qty { display: flex; align-items: center; gap: 0.35rem; }
.ca-step { inline-size: 1.8rem; block-size: 1.8rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; cursor: pointer; }
.ca-promo { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.ca-promo input { padding: 0.45rem 0.6rem; border: 1px solid #cbd5e1; border-radius: 6px; font: inherit; }
.ca-promo .ca-promo-error { flex-basis: 100%; }
.ca-total { font-size: 1.05rem; }

/* Dashboard */
.db-header { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; }
.db-notif { position: relative; }
.db-notif-panel { position: absolute; inset-inline-end: 0; inline-size: 16rem; background: #fff; border: 1px solid #cbd5e1; border-radius: 8px; padding: 0.6rem 0.9rem; z-index: 5; }
.db-tabs { display: flex; gap: 0.25rem; border-block-end: 1px solid #e5e7eb; margin-block-end: 1rem; }
.db-tab { padding: 0.5rem 0.9rem; border: none; background: none; font: inherit; cursor: pointer; border-block-end: 3px solid transparent; }
.db-tab--active { border-block-end-color: #2563eb; font-weight: 600; }
.db-table { inline-size: 100%; border-collapse: collapse; }
.db-table th, .db-table td { text-align: start; padding: 0.4rem; border-block-end: 1px solid #e5e7eb; }
.db-faq-question { display: block; inline-size: 100%; text-align: start; padding: 0.5rem 0; border: none; background: none; font: inherit; font-weight: 600; cursor: pointer; }
.db-faq-answer { margin: 0 0 0.5rem; }
.db-dialog { border: 1px solid #cbd5e1; border-radius: 10px; padding: 1.25rem 1.5rem; max-inline-size: 26rem; }
.db-dialog::backdrop { background: rgba(15, 23, 42, 0.45); }

/* Address: the form card has a fixed size and both button rows are placed absolutely at the
   same offset, so the form's Cancel and the dialog's Cancel have the same box (text and
   position). The dialog covers the whole card and has no border, so both offsets are measured
   from the same padding box. */
.ad-card { position: relative; box-sizing: border-box; block-size: 30rem; padding: 1.5rem; }
.ad-btn { box-sizing: border-box; inline-size: 8rem; block-size: 2.5rem; padding: 0; text-align: center; }
.ad-row, .ad-submit-row { position: absolute; inset-inline-start: 1.5rem; display: flex; gap: 0.5rem; }
.ad-row { inset-block-start: 21rem; }
.ad-submit-row { inset-block-start: 25rem; }
.ad-dialog { position: absolute; inset: 0; margin: 0; box-sizing: border-box; inline-size: 100%; block-size: 100%; max-inline-size: none; max-block-size: none; border: 0; border-radius: 10px; padding: 1.5rem; background: #fff; color: inherit; }
.ad-dialog:not([open]) { display: none; }

/* Missions */
.mission-brief { background: #fefce8; border-color: #fde68a; }
.mb-calendar { max-inline-size: 22rem; }
.mb-calendar-head { display: flex; justify-content: space-between; align-items: center; margin-block-end: 0.5rem; }
.mb-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 0.25rem; text-align: center; }
.mb-weekday { font-size: 0.8rem; font-weight: 600; color: #4b5563; }
.mb-day { padding: 0.35rem 0; border: 1px solid #e5e7eb; border-radius: 6px; background: #fff; cursor: pointer; font: inherit; }
.mb-day[aria-pressed=true] { background: #2563eb; color: #fff; border-color: #2563eb; }
.mb-options, .mc-options { border: none; padding: 0; margin: 0 0 0.75rem; display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; }
.mb-options legend, .mc-options legend { font-weight: 600; margin-block-end: 0.35rem; }
.mc-options { flex-direction: column; }
.mb-done, .mc-done { font-weight: 600; color: #166534; }

/* Film page (media) */
.md-header { display: flex; justify-content: space-between; align-items: center; }
.md-header nav { display: flex; gap: 1rem; }
.md-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-block: 1rem; }
.md-tabs { display: flex; gap: 0.25rem; border-block-end: 1px solid #e5e7eb; margin-block-end: 1rem; }
.md-tab { padding: 0.5rem 0.9rem; border: none; background: none; font: inherit; cursor: pointer; border-block-end: 3px solid transparent; }
.md-tab--active { border-block-end-color: #2563eb; font-weight: 600; }
.md-credits dt { font-weight: 600; }
.md-credits dd { margin: 0 0 0.5rem; }

/* Shelf: a row of cards that scrolls sideways */
.l10n-app-main:has(> .sh), .l10n-app-main:has(> .bn) { max-width: none; }
.sh-carousel { position: relative; overflow: hidden; max-width: 1100px; margin: 0 auto; }
.sh-track { display: flex; gap: 16px; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none; list-style: none; margin: 0; padding: 0; }
.sh-track::-webkit-scrollbar { display: none; }
.sh-card { flex: 0 0 260px; box-sizing: border-box; padding: 1rem; background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; }
.sh-name { font-size: 1rem; margin: 0 0 0.5rem; }
.sh-note { margin: 0 0 0.5rem; color: #4b5563; font-size: 0.9rem; }
.sh-price { margin: 0; font-weight: 600; }
.sh-nav { position: absolute; top: 0.5rem; z-index: 1; padding: 0.35rem 0.8rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.sh-prev { left: 0.5rem; }
.sh-next { right: 0.5rem; }

/* Picker: a long list inside a panel */
.pk-field { position: relative; display: inline-block; }
.pk-panel { position: absolute; top: 100%; left: 0; z-index: 2; width: 18rem; background: #fff; border: 1px solid #cbd5e1; border-radius: 6px; }
.pk-list { height: 240px; overflow-y: auto; margin: 0; padding: 0; list-style: none; }
.pk-list li { height: 30px; }
.pk-list button { display: block; width: 100%; height: 30px; padding: 0 0.75rem; box-sizing: border-box; border: none; background: none; text-align: start; font: inherit; cursor: pointer; }
.pk-list button:hover { background: #eff6ff; }

/* Callback: a wizard whose steps are cut by a viewport */
.cb-overlay { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(15, 23, 42, 0.5); z-index: 10; }
.cb-overlay[hidden] { display: none; }
.cb-dialog { position: relative; box-sizing: border-box; width: 560px; padding: 20px; background: #fff; border-radius: 10px; }
.cb-close { position: absolute; top: 0.5rem; right: 0.5rem; }
.cb-stepper { display: flex; gap: 1rem; list-style: none; margin: 0 0 1rem; padding: 0; color: #6b7280; }
.cb-stepper-item--active { color: #1d4ed8; font-weight: 600; }
.cb-viewport { overflow: hidden; width: 520px; }
.cb-steps { display: flex; width: 1560px; }
.cb-step { flex: 0 0 520px; width: 520px; box-sizing: border-box; }
.cb-input { display: block; width: 100%; box-sizing: border-box; padding: 0.5rem 0.6rem; border: 1px solid #cbd5e1; border-radius: 6px; font: inherit; }
.cb-note, .cb-hint { margin: 0.25rem 0 0.75rem; font-size: 0.85rem; color: #4b5563; }
.cb-error { margin: 0 0 0.75rem; font-size: 0.85rem; color: #b91c1c; }

/* Banner: slides that change by themselves */
.bn-banner { position: relative; width: 1100px; max-width: 100%; height: 320px; margin: 0 auto; overflow: hidden; border-radius: 10px; }
.bn-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .6s; pointer-events: none; box-sizing: border-box; padding: 3rem; background: #dbeafe; }
.bn-slide:nth-child(2) { background: #dcfce7; }
.bn-slide:nth-child(3) { background: #fef3c7; }
.bn-slide--active { opacity: 1; pointer-events: auto; }
.bn-headline { font-size: 2rem; margin: 0 0 0.5rem; }
.bn-line { font-size: 1.1rem; margin: 0 0 1.5rem; }
.bn-controls { display: flex; align-items: center; gap: 0.5rem; width: 1100px; max-width: 100%; margin: 0.75rem auto; }
.bn-dot { width: 14px; height: 14px; padding: 0; border: 1px solid #1d4ed8; border-radius: 50%; background: #fff; cursor: pointer; }
.bn-reviews { width: 1100px; max-width: 100%; margin: 1.5rem auto 0; }

/* Skip link: off-screen until it has keyboard focus */
.sk-skip { position: absolute; left: -999px; top: 8px; padding: 0.5rem 1rem; background: #1d4ed8; color: #fff; border-radius: 6px; z-index: 20; }
.sk-skip:focus { left: 16px; }

/* Consent: a banner fixed to the bottom third of the window lies over the footer at the end of the page */
.cn-footer { height: 100px; margin-top: 2rem; padding-top: 1rem; border-top: 1px solid #e5e7eb; }
.cn-footer ul { display: flex; flex-wrap: wrap; gap: 1.5rem; margin: 0; padding: 0; list-style: none; }
.cn-banner { position: fixed; bottom: 0; left: 0; right: 0; z-index: 100; height: 33vh; box-sizing: border-box; padding: 1.5rem 2rem; background: #1f2937; color: #fff; }
.cn-banner[hidden] { display: none; }
.cn-close { position: absolute; top: 0.5rem; right: 0.75rem; border: none; background: none; color: #fff; font: inherit; text-decoration: underline; cursor: pointer; }
.cn-answers { display: flex; gap: 0.75rem; }

/* Menu: the panel is faded out and ignores the pointer until the button opens it; its links keep opacity 1 */
.mn-header { position: relative; display: flex; align-items: center; gap: 1rem; padding: 0.75rem 1.5rem; border-bottom: 1px solid #e5e7eb; }
.mn-panel { position: absolute; top: 100%; left: 1.5rem; z-index: 50; min-width: 220px; padding: 0.75rem 1rem; background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; opacity: 0; pointer-events: none; transition: opacity 0.2s ease; }
.mn-panel.is-open { opacity: 1; pointer-events: auto; }
.mn-panel ul { margin: 0; padding: 0; list-style: none; }
.mn-panel li { padding: 0.25rem 0; }

/* Tooltip: the bubble is faded out on its wrapper and ignores the pointer; hover or focus on the button's wrapper shows it; the hint keeps opacity 1 */
.tp-header { padding: 0.75rem 1.5rem; border-bottom: 1px solid #e5e7eb; }
.tp-wrap { position: relative; display: inline-block; }
.tp-bubble { position: absolute; top: 100%; left: 0; z-index: 50; width: 260px; margin-top: 0.5rem; padding: 0.5rem 0.75rem; background: #1f2937; color: #fff; border-radius: 8px; opacity: 0; pointer-events: none; transition: opacity 0.2s ease; }
.tp-wrap:hover .tp-bubble,
.tp-wrap:focus-within .tp-bubble { opacity: 1; }

/* Popup: a box fixed in the centre of the window lies over whatever text is scrolled to the centre; no backdrop */
.pu-box { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 100; width: 480px; height: 300px; box-sizing: border-box; padding: 2rem; background: #fff; border: 1px solid #d1d5db; border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }
.pu-box[hidden] { display: none; }
.pu-close { position: absolute; top: 0.5rem; right: 0.75rem; border: none; background: none; font-size: 1.5rem; line-height: 1; cursor: pointer; }

/* Trap: a settings popup open at load over a half-transparent mask; the header lies above the mask; the skip link is off-screen until it has focus */
.tr-header { position: relative; z-index: 100; display: flex; align-items: center; gap: 1.25rem; padding: 0.75rem 1rem; background: #fff; border-bottom: 1px solid #e5e7eb; }
.tr-skip { position: absolute; left: -999px; top: 8px; z-index: 1; padding: 0.5rem 1rem; background: #1d4ed8; color: #fff; border-radius: 6px; }
.tr-skip:focus { left: 8px; }
.tr-nav { display: flex; gap: 1rem; }
.tr-settings { margin-inline-start: auto; padding: 0.45rem 0.9rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.tr-popup { position: absolute; top: calc(100% + 0.5rem); inset-inline-end: 0; width: 260px; box-sizing: border-box; padding: 1rem; background: #fff; border-radius: 8px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }
.tr-popup button { display: block; width: 100%; margin-block: 0.25rem; text-align: start; }
.tr-mask { position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.5); }

/* Mask: a settings popup in the header, open at load, over a half-transparent mask on the whole page (its full height, not only the window); the header lies above the mask, the row of cards under it */
.l10n-app:has(#mk-shade) { position: relative; }
#mk-shade { position: absolute; inset: 0; z-index: 10; background: rgba(0, 0, 0, 0.5); }
.mk-header { position: relative; z-index: 20; display: flex; align-items: center; gap: 1.5rem; margin-block-end: 1.5rem; padding: 0.75rem 1.5rem; background: #fff; border-bottom: 1px solid #e5e7eb; }
.mk-nav { display: flex; gap: 1rem; }
.mk-settings { margin-inline-start: auto; padding: 0.45rem 0.9rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.mk-popup { position: absolute; top: calc(100% + 0.5rem); inset-inline-end: 1.5rem; width: 360px; box-sizing: border-box; padding: 1rem; background: #fff; border: 1px solid #d1d5db; border-radius: 10px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }
.mk-popup h2 { margin: 0 0 0.75rem; font-size: 1rem; }
.mk-popup button { margin-inline-end: 0.5rem; }

/* Chooser: a settings popup under the header button holds a language and a currency button and their lists; the currency list scrolls in its own 400 px box */
.ch-header { position: relative; display: flex; align-items: center; gap: 1.5rem; padding: 0.75rem 0; border-bottom: 1px solid #e5e7eb; }
.ch-brand { font-weight: 700; }
.ch-nav { display: flex; gap: 1rem; }
.ch-settings { margin-inline-start: auto; padding: 0.45rem 0.9rem; border: 1px solid #cbd5e1; border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.ch-popup { position: absolute; top: 100%; inset-inline-end: 0; z-index: 50; width: 360px; box-sizing: border-box; padding: 0.75rem; background: #fff; border: 1px solid #d1d5db; border-radius: 8px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); }
.ch-row { display: flex; gap: 0.5rem; }
.ch-row .l10n-btn { padding: 0.4rem 0.6rem; font-size: 0.875rem; white-space: nowrap; }
.ch-list { margin: 0.5rem 0 0; padding: 0; list-style: none; border: 1px solid #cbd5e1; border-radius: 6px; }
.ch-list li { height: 30px; }
.ch-list button { display: block; width: 100%; height: 30px; padding: 0 0.75rem; box-sizing: border-box; border: none; background: none; text-align: start; font: inherit; cursor: pointer; }
.ch-list button:hover { background: #eff6ff; }
.ch-currencies { height: 400px; overflow-y: auto; }
.ch-article { max-width: 340px; }
