/* EJA Services · licence server pages (landing, account, admin). Every colour, radius and shadow comes from
   eja/eja-tokens.css and the shared pieces from eja/eja-components.css; this file is layout only. */

html { -webkit-text-size-adjust: 100%; }
* { box-sizing: border-box; }
body { min-height: 100vh; line-height: 1.5; overflow-x: hidden; }
/* The footer sits at the bottom of the window even when the page is short (sign in, account). */
body:not(.admin) { display: flex; flex-direction: column; min-height: 100dvh; }
body:not(.admin) > main { flex: 1 0 auto; width: 100%; }
body:not(.admin) > .foot { flex: none; }
html[lang="ar"] body { line-height: 1.7; }
h1, h2, h3, p, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
button, input, select, textarea { font-family: inherit; color: inherit; }
[hidden] { display: none !important; }
img { display: block; max-width: 100%; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.eja-input:focus-visible { outline: none; }
.eja-ic { flex: 0 0 auto; }
.offscreen { position: fixed; left: -9999px; top: 0; opacity: 0; }

/* ------------------------------------------------------------ head: logo on its plate, one gold line */
.top { position: sticky; top: 0; z-index: 30; padding: max(10px, env(safe-area-inset-top, 0px)) 16px 10px; }
.top-in { display: flex; align-items: center; gap: var(--space-12); width: 100%; max-width: 1120px; margin: 0 auto; min-width: 0; }
.brand { display: flex; align-items: center; gap: var(--space-12); color: inherit; min-width: 0; flex: 1 1 auto; }
.brand:hover { text-decoration: none; }
.plate { display: grid; place-items: center; width: 72px; height: 48px; flex: 0 0 auto; border-radius: var(--radius-12); background: #ffffff; border: 1px solid var(--line); overflow: hidden; }
.plate img { display: block; width: 100%; height: 100%; object-fit: contain; border-radius: 0; background: #ffffff; }
.eja-head .plate img { width: 100%; height: 100%; }
.brand-text { min-width: 0; }
.brand-text b { display: block; font-size: 16px; font-weight: 700; color: var(--text); overflow-wrap: anywhere; }
.brand-text span { display: block; font-size: 12px; color: var(--muted2); overflow-wrap: anywhere; }
.top-tools { display: flex; align-items: center; gap: var(--space-2); flex: 0 0 auto; }
.top-tools .eja-btn { margin-inline-end: 6px; }

/* the top bar's buttons: solid light teal squares, the icon in EJA's teal (the owner, 09/11) */
.icon-btn {
  display: inline-grid; place-items: center; width: var(--tap-min); height: var(--tap-min); flex: 0 0 auto; padding: 0;
  border: 0; border-radius: var(--radius-12); background: var(--brand-soft); color: var(--brand); cursor: pointer;
}
.icon-btn:hover { background: color-mix(in srgb, var(--brand) 18%, var(--brand-soft)); color: var(--brand); }
.icon-btn .eja-ic { width: 20px; height: 20px; }
.eja-btn .eja-ic { width: 18px; height: 18px; }
.eja-btn:not(:disabled):hover { background-color: var(--bg2); text-decoration: none; }
.eja-btn-primary:not(:disabled):hover, .eja-btn-new:not(:disabled):hover { background-color: var(--brand-fill); filter: brightness(1.08); }
.eja-btn-wa:not(:disabled):hover { background-color: var(--whatsapp); filter: brightness(1.05); }
.eja-btn-danger:not(:disabled):hover { background-color: var(--bad-fill); filter: brightness(1.08); }
.eja-btn-sm { min-height: 36px; padding: 0 12px; font-size: 13.5px; border-radius: var(--radius-10); gap: 6px; }
.eja-btn-sm .eja-ic { width: 16px; height: 16px; }
.eja-btn-quiet { color: var(--brand); }
.eja-btn-bad { color: var(--bad); }
.pill { border-radius: var(--radius-pill); }
a.eja-btn { text-decoration: none; }
.eja-btn[aria-disabled="true"] { opacity: .6; pointer-events: none; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.ic-plate { display: grid; place-items: center; width: 42px; height: 42px; flex: 0 0 auto; border-radius: var(--radius-12); background: var(--brand-soft); color: var(--brand); }
.ic-plate .eja-ic { width: 22px; height: 22px; }
.muted { color: var(--muted); }
.quiet { font-size: 12.5px; color: var(--muted2); }
.mono { font-family: var(--font-mono); }
.eja-num { white-space: normal; overflow-wrap: anywhere; }  /* long emails wrap instead of pushing the page sideways */
.key { font-family: var(--font-mono); font-weight: 700; letter-spacing: .02em; direction: ltr; unicode-bidi: isolate; overflow-wrap: anywhere; }
.section-t { font-size: 22px; font-weight: 800; line-height: 1.25; }
.section-sub { color: var(--muted); margin-top: 4px; }

/* ------------------------------------------------------------ landing */
.hero { display: grid; gap: 28px; padding: 32px 0 12px; align-items: center; }
.hero h1 { font-size: clamp(27px, 6vw, 42px); line-height: 1.15; font-weight: 800; letter-spacing: -.01em; }
html[lang="ar"] .hero h1 { letter-spacing: 0; line-height: 1.35; }
.hero .lead { font-size: 17px; color: var(--muted); margin-top: 14px; max-width: 36em; }
.cta { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 12px 16px; margin-top: 24px; }
.btn-xl { min-height: 56px; padding: 0 28px; font-size: 17px; border-radius: var(--radius-pill); box-shadow: var(--shadow-fill); }
.btn-xl .eja-ic { width: 22px; height: 22px; }
/* The Windows version and size sit with the Download button (I153), so they don't read as the Android version. */
.dl-block { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; min-width: 0; }
.dl-meta { font-size: 13.5px; color: var(--muted2); max-width: 100%; }
/* I188: the other two installers of the version, under the main button */
.dl-kinds { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; max-width: 100%; }
.dl-kinds[hidden] { display: none; }
.dl-kinds-t { font-size: 13px; color: var(--muted2); }
.dl-kind { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 14px; font-weight: 600; color: var(--brand);
  text-decoration: none; overflow-wrap: anywhere; }
.dl-kind:hover { text-decoration: underline; }
.dl-kind .eja-icon, .dl-kind svg { width: 16px; height: 16px; flex: 0 0 auto; }
.dl-kind-size { font-weight: 400; color: var(--muted2); }
/* A short "Requirements" box next to the download button (I153). */
.reqs { margin-top: 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-16); background: var(--card); max-width: 34em; }
.reqs-t { display: block; font-size: 14px; font-weight: 800; margin-bottom: 8px; }
.reqs-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.reqs-list li { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; color: var(--muted); }
.reqs-list .eja-ic { width: 17px; height: 17px; flex: 0 0 auto; color: var(--brand); margin-top: 1px; }
.trial-pill { display: inline-flex; align-items: center; gap: 8px; margin-top: 18px; padding: 6px 14px; border-radius: var(--radius-pill);
  background: var(--brand-soft); color: var(--brand); font-weight: 700; font-size: 14px; }
.trial-pill .eja-ic { width: 18px; height: 18px; }
.shot { border-radius: var(--radius-16); border: 1px solid var(--line); box-shadow: var(--shadow-pop); overflow: hidden; background: var(--card); }
.shot img { width: 100%; height: auto; }
/* I182: the app's pictures, one after the other. The frame keeps their shape (nothing below moves while they load);
   they fade from one to the next (at once with "reduce motion"); the caption wraps, never cut. */
.shots { display: grid; gap: 10px; min-width: 0; }
.shots-frame { position: relative; aspect-ratio: 1440 / 900; touch-action: pan-y; }
.shots-frame > .shots-first { display: block; width: 100%; height: 100%; object-fit: cover; }
.shots-slide { position: absolute; inset: 0; margin: 0; opacity: 0; visibility: hidden; transition: opacity .6s ease, visibility 0s linear .6s; }
.shots-slide.on { opacity: 1; visibility: visible; transition: opacity .6s ease, visibility 0s; }
.shots-slide img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; -webkit-user-drag: none; user-select: none; }
.shots-caption { margin: 0; text-align: center; color: var(--muted); font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.shots-dots { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px; }
.shots-dot { display: inline-grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: transparent; cursor: pointer; }
.shots-dot-in { width: 10px; height: 10px; border-radius: 50%; background: var(--line); border: 1px solid var(--muted); transition: transform .2s ease, background-color .2s ease; }
.shots-dot[aria-current="true"] .shots-dot-in { background: var(--brand); border-color: var(--brand); transform: scale(1.3); }
.shots-dot:hover .shots-dot-in { background: var(--muted); }
.shots-dot:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
@media (prefers-reduced-motion: reduce) { .shots-slide, .shots-slide.on, .shots-dot-in { transition: none; } }
@media (min-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 48px; padding: 56px 0 24px; }
}

.block { padding: 36px 0 8px; display: grid; gap: 18px; }
.grid-cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }
.feature { display: flex; gap: 12px; align-items: flex-start; }
.feature b { display: block; font-size: 15.5px; }
.feature p { font-size: 13.5px; color: var(--muted); margin-top: 2px; }

.steps { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); counter-reset: step; }
.step { display: flex; gap: 12px; align-items: flex-start; }
.step::before { counter-increment: step; content: counter(step); display: grid; place-items: center; flex: 0 0 auto; width: 34px; height: 34px;
  border-radius: 50%; background: var(--brand-fill); color: var(--on-brand); font-weight: 800; }
.step b { display: block; }
.step p { font-size: 13.5px; color: var(--muted); margin-top: 2px; }

.plans { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); align-items: stretch; }
.plan { display: flex; flex-direction: column; gap: 12px; padding: 20px; }
.plan-name { font-size: 17px; font-weight: 800; }
.price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; }
.price b { font-size: 34px; font-weight: 800; line-height: 1.1; color: var(--brand); direction: ltr; unicode-bidi: isolate; }
.price span { color: var(--muted); font-weight: 600; }
.plan-price { color: var(--brand); font-weight: 800; font-size: 20px; direction: ltr; unicode-bidi: isolate; }
.plan-desc { color: var(--muted); font-size: 14px; }
.ticks { display: grid; gap: 6px; font-size: 14px; }
.ticks li { display: flex; gap: 8px; align-items: flex-start; }
.ticks .eja-ic { width: 18px; height: 18px; color: var(--brand); margin-top: 3px; }
.plan .eja-btn { margin-top: auto; width: 100%; border-radius: var(--radius-pill); }
.contact-line { color: var(--muted); font-size: 14px; }
.subscribe-cta { display: flex; justify-content: center; }
.subscribe-cta .eja-btn { min-height: 52px; padding: 0 24px; border-radius: var(--radius-pill); font-size: 16px; }
.note-line { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: 14px; }
.note-line .eja-ic { width: 20px; height: 20px; color: var(--brand); margin-top: 1px; }

.foot { margin-top: 48px; border-top: 1px solid var(--line); background: var(--card); }
.foot-in { max-width: 1120px; margin: 0 auto; padding: 22px 16px calc(22px + env(safe-area-inset-bottom, 0px)); display: flex; flex-wrap: wrap; gap: 10px 24px;
  align-items: center; justify-content: space-between; font-size: 13.5px; color: var(--muted2); }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }

/* ------------------------------------------------------------ forms */
.form { display: grid; gap: 14px; }
.eja-field { align-content: start; }
input[type="file"].eja-input { padding: 8px 10px; }
input[type="file"]::file-selector-button { margin-inline-end: 12px; padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-10);
  background: var(--card); color: var(--text); font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; }
.form-row { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
textarea.eja-input { min-height: 84px; resize: vertical; line-height: 1.45; }
select.eja-input { appearance: auto; }
.eja-input[type="date"] { min-height: var(--field-min); }
.check { display: flex; align-items: center; gap: 10px; min-height: 36px; font-size: 14.5px; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 0; accent-color: var(--brand-fill); flex: 0 0 auto; }
.checks { display: grid; gap: 2px 14px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.inline-input { display: flex; gap: 8px; }
.inline-input .eja-input { flex: 1 1 auto; min-width: 0; }
.form-error { color: var(--bad); font-size: 14px; font-weight: 600; }
.form-error:empty { display: none; }
.hint { font-size: 12.5px; color: var(--muted2); }
.secret { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--radius-12); background: var(--brand-soft); }
.secret { container-type: inline-size; flex-wrap: wrap; }
.secret .key { flex: 1 1 auto; min-width: 0; font-size: 17px; }
.secret .key:not(.small) { font-size: min(17px, 6cqi); white-space: nowrap; overflow-wrap: normal; }  /* a licence key: one line */

/* ------------------------------------------------------------ cards, rows, badges */
.card-head { display: flex; align-items: center; gap: var(--space-12); margin-bottom: var(--space-12); }
.card-head > div { min-width: 0; flex: 1 1 auto; }
.eja-card-t { font-size: 15.5px; font-weight: 700; margin: 0; }
.eja-card-m { font-size: 12.5px; color: var(--muted); }
.stack { display: grid; gap: 16px; align-content: start; min-width: 0; }
.list { display: grid; gap: 10px; }
.item { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-14); box-shadow: var(--shadow-card); padding: 12px 14px;
  display: grid; gap: 8px; min-width: 0; }
.item-top { display: flex; align-items: flex-start; gap: 8px 12px; flex-wrap: wrap; }
.item-main { flex: 1 1 220px; min-width: 0; }
.item-title { font-weight: 700; overflow-wrap: anywhere; display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; }
.item-sub { font-size: 13.5px; color: var(--muted); overflow-wrap: anywhere; }
.item-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: var(--muted2); }
.item-meta b { color: var(--muted); font-weight: 600; }
.item-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.item.clickable { cursor: pointer; color: inherit; text-decoration: none; }
.item.clickable:hover { border-color: var(--brand); text-decoration: none; }
.item.clickable .item-title { color: var(--text); }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 1px 10px; border-radius: var(--radius-pill); font-size: 12.5px; font-weight: 700;
  white-space: nowrap; line-height: 1.6; }
.badge.ok { background: var(--brand-soft); color: var(--brand); }
.badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.wait { background: rgba(224, 161, 30, .16); color: var(--wait); }
.badge.off { background: var(--bg2); color: var(--muted); border: 1px solid var(--line); }
.empty { text-align: center; padding: 28px 16px; color: var(--muted2); font-size: 14.5px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.toolbar .search { flex: 1 1 240px; min-width: 0; position: relative; display: flex; align-items: center; }
.toolbar .search .eja-ic { position: absolute; inset-inline-start: 14px; width: 18px; height: 18px; color: var(--muted2); pointer-events: none; }
.toolbar .search .eja-input { padding-inline-start: 42px; min-height: 44px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips .eja-chip { min-height: 36px; padding: 0 12px; }
.progress { height: 10px; border-radius: var(--radius-pill); background: var(--bg2); overflow: hidden; border: 1px solid var(--line); }
.progress > i { display: block; height: 100%; width: 0; background: var(--brand-fill); transition: width .2s; }
.events { display: grid; }
.events li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.events li:last-child { border-bottom: 0; }
.events time { color: var(--muted2); font-size: 12.5px; white-space: nowrap; }
.events .kind { font-weight: 700; color: var(--brand); margin-inline-end: 6px; }
.events .kind.refused { color: var(--bad); }
.events span { overflow-wrap: anywhere; }
.devices { display: grid; gap: 8px; }
.device { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-12); background: var(--bg2); flex-wrap: wrap; }
.device > div { flex: 1 1 160px; min-width: 0; }
.device b { display: block; overflow-wrap: anywhere; }
.device span { font-size: 12.5px; color: var(--muted2); }
/* The key stays on one line: it gets the card's whole width and its letters shrink on a narrow phone
   (24 monospace characters take about 15em, so 6% of the box's width per em always fits). */
.kv dd.lic-key { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px;
  padding: 8px 10px; border-radius: var(--radius-12); background: var(--brand-soft); container-type: inline-size; }
.lic-key .key { flex: 1 1 auto; white-space: nowrap; overflow-wrap: normal; font-size: min(16px, 6cqi); }
.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 14px; font-size: 14px; }
.kv dt { color: var(--muted2); }
.kv dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

.grow { flex: 1 1 auto; min-width: 0; }
.pre { white-space: pre-wrap; }
.spacer { height: 4px; }
.sub-t { margin: 16px 0 8px; font-size: 14px; }
.kv + .sub-t { margin-top: 18px; }
.hint { margin-top: 10px; }
.form .hint { margin-top: 0; }
.stat-link { display: block; color: inherit; text-decoration: none; border: 1px solid transparent; }
.stat-link:hover { text-decoration: none; border-color: var(--brand); }
.key.small { font-size: 13px; font-weight: 600; }

/* ------------------------------------------------------------ popups and toast */
.pop-dialog { padding: 0; border: 0; background: transparent; width: min(560px, calc(100vw - 20px)); max-width: none; max-height: calc(100dvh - 20px);
  overflow: visible; color: var(--text); }
.pop-dialog.wide { width: min(760px, calc(100vw - 20px)); }
.pop-dialog::backdrop { background: var(--scrim); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.pop-dialog .eja-pop { display: flex; flex-direction: column; max-height: calc(100dvh - 20px); }
.eja-pop-hd { display: flex; align-items: center; gap: var(--space-10); padding-inline-end: 12px; }
.eja-pop-hd > span { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.pop-x { margin: -8px 0; width: 40px; height: 40px; }
.eja-pop-bd.form-bd { white-space: normal; overflow-y: auto; display: grid; gap: var(--space-12); font-size: 15px; padding-bottom: var(--space-12); }
.eja-pop-ft { align-items: center; flex-wrap: wrap; }
.eja-pop-b:disabled { opacity: .6; cursor: default; }
.confirm-text { color: var(--muted); }
.toast { position: fixed; z-index: 60; left: 50%; transform: translateX(-50%); bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  max-width: min(520px, calc(100vw - 32px)); padding: 12px 16px; border-radius: var(--radius-14); background: var(--card); color: var(--text);
  border: 1px solid var(--line); box-shadow: var(--shadow-pop); font-size: 14px; font-weight: 600; }
.toast.bad { color: var(--bad); }

/* ------------------------------------------------------------ account */
.narrow { max-width: 460px; margin: 32px auto 0; }
.signin-card { padding: 24px; }
.signin-logo { display: block; width: min(220px, 70%); height: auto; margin: 4px auto 18px; border-radius: 16px; background: #ffffff; }
.signin-card h1 { font-size: 22px; font-weight: 800; }
.signin-card .section-sub { margin-bottom: 18px; }
.acc { display: grid; gap: 16px; padding-top: 24px; }
.acc-hello { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; justify-content: space-between; }
.acc-hello h1 { font-size: 22px; font-weight: 800; }
@media (min-width: 900px) {
  .acc-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 16px; align-items: start; }
}
.acc-grid { display: grid; gap: 16px; }

/* ------------------------------------------------------------ admin */
.admin-shell { min-height: 100vh; }
.side { display: none; }
.side-brand { display: flex; align-items: center; gap: var(--space-12); padding: var(--space-16); position: relative; color: inherit; }
.side-brand:hover { text-decoration: none; }
.side-brand::after { content: ""; position: absolute; inset-inline: var(--space-16); bottom: 0; height: 2px; background: var(--gold); }
.side-brand b { display: block; font-size: 16px; font-weight: 700; }
.side-brand span span { display: block; font-size: 12px; color: var(--muted2); }
.side-foot { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); padding: var(--space-12) var(--space-16) var(--space-16); border-top: 1px solid var(--line); }
.side-foot .eja-btn { padding: 0 10px; font-size: 13.5px; }
.side-foot .wide { grid-column: 1 / -1; }
.main { min-width: 0; }
.page-head .top-in { max-width: none; }
.page-title { flex: 1 1 auto; min-width: 0; }
.page-title h1 { font-size: 17px; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.page-title span { display: block; font-size: 12.5px; color: var(--muted); overflow-wrap: anywhere; }
.content { display: grid; gap: 16px; padding: 16px 16px 48px; max-width: 1200px; margin: 0 auto; min-width: 0; }
/* Admin dashboard: hello and quick actions, stats with icons, two lists side by side */
.dash-hello { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; }
.dash-hello h2 { margin: 0; font-size: 20px; font-weight: 800; }
.dash-hello p { margin: 2px 0 0; }
.dash-quick { display: flex; flex-wrap: wrap; gap: 8px; }
.dash-quick .eja-btn { min-height: 40px; text-decoration: none; }
.dash-stat { display: flex; align-items: center; gap: 12px; text-align: start; }
.dash-stat .ic-plate { flex: none; }
.dash-stat-text { display: grid; min-width: 0; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; align-items: start; }
.login-wrap { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg); }
.login-wrap[hidden] { display: none; }
.login-main { flex: 1 0 auto; display: grid; place-items: center; padding: 32px 16px; }
.login-wrap > .foot { margin-top: 0; }
.login-card { width: min(440px, 100%); padding: 28px 24px 24px; display: grid; gap: 16px; position: relative; overflow: hidden; }
.login-card .signin-logo { margin-bottom: 0; }
.login-title { display: grid; gap: 4px; text-align: center; }
.login-card::before { content: ""; position: absolute; inset-inline: 0; top: 0; height: 3px; background: var(--gold); }
html[dir="ltr"] .back .eja-ic { transform: scaleX(-1); }
.login-card .plate { width: 96px; height: 64px; margin: 0 auto; }
.login-card .plate img { width: 100%; height: 100%; }
.login-card h1 { text-align: center; font-size: 20px; font-weight: 800; }
.login-card .lang-row { display: flex; justify-content: center; gap: 8px; }
.two-col { display: grid; gap: 16px; }
.release-form .src { display: flex; flex-wrap: wrap; gap: 6px; }
@media (min-width: 1100px) { .two-col { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }

/* a computer (and a tablet): the sidebar; a phone (up to 760px) has the bar on top, the drawer and the bar at the bottom (admin-nav.css) */
@media (min-width: 761px) {
  body.admin { background: var(--desk-bg); }
  .admin-shell { display: grid; grid-template-columns: var(--side-w, 248px) minmax(0, 1fr); }
  .side { display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; height: 100dvh; background: var(--card); border-inline-end: 1px solid var(--line); }
  .page-head .phone-only, .bottom-bar { display: none; }
  .page-head { padding-inline: 24px; }
  .page-title h1 { font-size: 20px; }
  .content { padding: 22px 24px 48px; }
}
@media (min-width: 1000px) {
  .page-head { padding-inline: 32px; }
  .content { padding-inline: 32px; }
}
.phone-only-inline { display: none; }
@media (max-width: 560px) {
  .wide-only { display: none !important; }
  .phone-only-inline { display: inline-grid; }
  .top { padding-inline: 12px; }
  .brand-text span { display: none; }
  .section-t { font-size: 20px; }
  .item-actions .eja-btn-sm { flex: 1 1 auto; }
}

/* ------------------------------------------------------------ how to subscribe, questions */
.steps-4 { grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); }
.faq { display: grid; gap: 10px; }
.faq details { padding: 0; }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; min-height: 48px;
  font-weight: 700; font-size: 15px; cursor: pointer; list-style: none; border-radius: inherit; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: 0 0 auto; width: 9px; height: 9px; margin-top: -4px; border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .15s; }
.faq details[open] summary::after { transform: rotate(225deg); margin-top: 4px; }
.faq summary:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.faq details p { padding: 0 16px 14px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.block { scroll-margin-top: 76px; }

/* ------------------------------------------------------------ pressed and working */
.pressed { animation: eja-press .26s ease-out; }
@keyframes eja-press { 0% { transform: scale(.95); filter: brightness(.88); } 100% { transform: none; filter: none; } }
.eja-btn:active, .eja-chip:active { filter: brightness(.9); }
.is-busy { position: relative; pointer-events: none; color: transparent !important; }
.is-busy > * { opacity: 0; }
.is-busy::after { content: ""; position: absolute; inset: 0; margin: auto; width: 18px; height: 18px; border-radius: 50%;
  border: 2px solid var(--line); border-top-color: var(--brand); animation: eja-spin .8s linear infinite; }
.eja-btn-primary.is-busy::after, .eja-btn-bad.is-busy::after { border-color: rgb(255 255 255 / .35); border-top-color: var(--on-brand); }
@keyframes eja-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pressed { animation: none; } }

/* the eye in password boxes: show or hide what was typed */
.pw-wrap { position: relative; display: block; }
.pw-wrap > input { display: block; width: 100%; padding-inline-end: 48px; }
.pw-wrap > input::-ms-reveal, .pw-wrap > input::-ms-clear { display: none; }  /* Edge's own eye: ours is enough */
.pw-eye { position: absolute; inset-inline-end: 4px; top: 0; bottom: 0; margin: auto 0; display: grid; place-items: center;
  width: 40px; height: 40px; padding: 0; border: 0; border-radius: var(--radius-10); background: transparent; color: var(--muted); cursor: pointer; }
.pw-eye:hover { background: var(--bg2); color: var(--brand); }
/* an empty password box shows faded dots, so it's clear the password goes there */
.pw-wrap > input::placeholder { color: var(--muted); opacity: .45; letter-spacing: .12em; }
.pw-eye:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; }

/* ------------------------------------------------------------------ 2.0: codes, resellers, problems, messages, tools used, contact */
.badge.info { background: rgba(224, 161, 30, .14); color: var(--wait); }
a.badge { text-decoration: none; }
.coupon-line { display: block; margin-top: 6px; font-size: 13px; color: var(--muted2); }
.coupon-line.ok { color: var(--brand); font-weight: 700; }
.coupon-line.bad { color: var(--bad); }
.price-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 18px; }
.price-line s { color: var(--muted2); font-size: 15px; }
.ask-done { display: grid; gap: 12px; justify-items: start; }
.ask-done[hidden] { display: none; }
.balance-line { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.problem-text { white-space: pre-line; }
.problem-full { padding: 12px 14px; border-radius: var(--radius-12); background: var(--bg2); overflow-wrap: anywhere; }
.problem-shot { display: block; border: 1px solid var(--line); border-radius: var(--radius-12); overflow: hidden; max-height: 360px; }
.problem-shot img { display: block; width: 100%; height: auto; }
.usage-list { list-style: none; margin: 0; padding: 8px 14px; display: grid; }
.usage-list li { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(60px, 1fr) auto; gap: 12px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--line); }
.usage-list li:last-child { border-bottom: 0; }
.usage-name { display: grid; min-width: 0; }
.usage-name b, .usage-name small { overflow-wrap: anywhere; }
.usage-name small { color: var(--muted2); font-size: 11.5px; }
.usage-bar { height: 10px; border-radius: var(--radius-pill); background: var(--bg2); overflow: hidden; }
.usage-bar i { display: block; height: 100%; background: var(--brand); border-radius: inherit; }
.usage-n { min-width: 3ch; text-align: end; }
.usage-plan { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; }
.usage-plan .eja-input { width: auto; min-width: 140px; }
.contact-note { color: var(--muted); margin-bottom: 12px; }
.contact-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
.contact-card { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; min-width: 0; }
a.contact-card:hover { border-color: var(--brand); text-decoration: none; }
.contact-text { display: grid; min-width: 0; }
.contact-text small { color: var(--muted2); font-size: 12.5px; }
.contact-text b { overflow-wrap: anywhere; }
.foot-contact { display: flex; flex-wrap: wrap; gap: 6px 16px; flex-basis: 100%; font-size: 13.5px; }
.foot-contact[hidden] { display: none; }
.foot-c { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); min-width: 0; overflow-wrap: anywhere; }
.foot-c .eja-ic { width: 16px; height: 16px; flex: none; }
.eja-stats.dash-stats { grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); }
.inline-input .eja-btn { flex: none; white-space: nowrap; }
.problem-shot { background: var(--bg2); }
.problem-shot img { max-height: 300px; object-fit: contain; }

/* Android: shown next to the Windows download, not ready yet */
.soon { cursor: default; opacity: .75; border-style: dashed; }
.soon .soon-tag { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--brand-soft, rgba(15, 107, 116, .12)); color: var(--brand, #0f6b74); margin-inline-start: 4px; }
/* 2.1 Online AI (admin-ai.js): balances, credit and their history */
.ai-head { display: grid; gap: 8px; justify-items: start; }
.ai-head .item-title { flex-wrap: wrap; }
.ai-balance { font-size: 18px; color: var(--text); }
.ai-ledger { list-style: none; margin: 0; padding: 0; display: grid; max-height: 55vh; overflow-y: auto; }
/* Your profit (admin-ai.js profitCard, 10/11/2026): what a task costs, what the customer pays, what you keep */
.ai-profit-table { width: 100%; border-collapse: collapse; font-size: .92em; }
.ai-profit-table th, .ai-profit-table td { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: start; }
.ai-profit-table th { color: var(--muted); font-weight: 600; }
@media (max-width: 560px) { .ai-profit-table { font-size: .85em; } .ai-profit-table th, .ai-profit-table td { padding: 5px 4px; } }
.ai-ledger li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: 4px 12px; align-items: baseline;
  padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.ai-ledger li:last-child { border-bottom: 0; }
.ai-ledger time { color: var(--muted2); white-space: nowrap; }
.ai-ledger-what { min-width: 0; overflow-wrap: anywhere; }
.ok-t { color: var(--brand); }
.bad-t { color: var(--bad); }
@media (max-width: 560px) { .ai-ledger li { grid-template-columns: minmax(0, 1fr) auto; } .ai-ledger time { grid-column: 1 / -1; } }
/* R89: final and beta releases (admin.js, account.js) */
.badge.beta { background: var(--bg2); color: var(--text); border: 1px dashed var(--gold); }
.beta-download { display: grid; gap: 10px; padding-top: 12px; border-top: 1px dashed var(--line); }
.beta-download .eja-btn { justify-self: start; }
/* ---------------------------------------------------------------- I187: Problems › Automatic (admin-reports.js). Nothing is cut: every line wraps. */
.rp-badge { white-space: normal; overflow-wrap: anywhere; line-height: 1.45; }
.rp-item.rp-new { border-inline-start: 4px solid var(--bad); }
.rp-item.rp-taken { border-inline-start: 4px solid var(--wait); }
.rp-item.rp-fixed { border-inline-start: 4px solid var(--brand); }
.rp-count { display: inline-grid; place-items: center; min-width: 34px; padding: 0 8px; border-radius: var(--radius-pill); background: var(--bg2);
  border: 1px solid var(--line); font-size: 13px; }
.rp-text { white-space: pre-line; overflow-wrap: anywhere; color: var(--text); }
.rp-place, .rp-keys { overflow-wrap: anywhere; }
.rp-meta > span { overflow-wrap: anywhere; min-width: 0; }
.rp-dialog .kv dd { overflow-wrap: anywhere; }
.rp-badges { flex-wrap: wrap; gap: 6px; }
.rp-note { display: grid; gap: 4px; padding: 10px 14px; border-radius: var(--radius-12); border: 1px dashed var(--gold); }
.rp-note p { margin: 0; overflow-wrap: anywhere; white-space: pre-line; }
.rp-pre { white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-word; margin: 0; font-size: 13px; }
.rp-steps { display: grid; gap: 4px; }
.rp-steps ol { margin: 0; padding-inline-start: 22px; display: grid; gap: 2px; font-size: 13.5px; overflow-wrap: anywhere; }
.rp-stack summary { cursor: pointer; font-weight: 700; }
.rp-stack pre { padding: 10px 12px; border-radius: var(--radius-12); background: var(--bg2); }

/* ---------------------------------------------------------------- remote help from EJA (I115): the technician's viewer
   (static/remote-viewer.js; the same block is in static/app.css and license-server/server/static/site.css) */
.rv { display: grid; gap: var(--space-8); min-width: 0; }
.rv-top { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; min-width: 0; }
.rv-status { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; min-width: 0; overflow-wrap: anywhere; }
.rv-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); flex: none; }
.rv-dot.wait { background: var(--wait); animation: rv-blink 1.2s ease-in-out infinite; }
.rv-dot.view { background: var(--brand); }
.rv-dot.on { background: var(--bad); }
@keyframes rv-blink { 50% { opacity: .35; } }
.rv-who { color: var(--muted); font-size: calc(13.5px * var(--ts, 1)); overflow-wrap: anywhere; min-width: 0; }
.rv-quality { margin-inline-start: auto; font-size: calc(12.5px * var(--ts, 1)); color: var(--muted); }
.rv-quality.good { color: var(--good); }
.rv-quality.fair { color: var(--wait); }
.rv-quality.bad { color: var(--bad); }
.rv-tools { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-width: 0; }
.rv-tools[hidden] { display: none; }
.rv-tools .eja-input { width: auto; min-height: 34px; padding-block: 4px; font-size: calc(13px * var(--ts, 1)); max-width: 100%; }
.rv-tools .chips { flex-wrap: nowrap; overflow: visible; padding: 0; gap: 4px; }
.rv-tools .eja-chip { min-height: 34px; padding: 0 12px; }
.rv-screens[hidden] { display: none; }
.rv-end { border-color: var(--bad); color: var(--bad); }
.rv-end .eja-ic .m { stroke: var(--bad); }
.rv-end[hidden] { display: none; }
.rv-layered { min-height: 34px; font-size: calc(13px * var(--ts, 1)); }
.rv-menu-wrap { position: relative; }
.rv-menu { position: absolute; z-index: 30; inset-inline-start: 0; top: calc(100% + 4px); width: max-content; min-width: 240px; max-width: min(340px, calc(100vw - 32px));
  display: grid; padding: 6px; border-radius: var(--radius-12); border: 1px solid var(--line); background: var(--card); box-shadow: var(--shadow-pop); }
.rv-menu[hidden] { display: none; }
.rv-menu-i { text-align: start; background: none; border: 0; padding: 8px 10px; border-radius: 8px; color: var(--text); font: inherit; font-size: calc(13.5px * var(--ts, 1)); cursor: pointer; }
.rv-menu-i:hover, .rv-menu-i:focus-visible { background: var(--brand-soft); }
.rv-menu-note { display: grid; gap: 2px; margin-top: 4px; padding: 8px 10px; border-top: 1px solid var(--line); font-size: calc(12.5px * var(--ts, 1)); color: var(--muted); }
.rv-menu-note b { color: var(--text); }
.rv-type { display: grid; gap: 6px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-12); background: var(--card); }
.rv-type[hidden] { display: none; }
.rv-type textarea { width: 100%; resize: vertical; }
.rv-type-acts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.rv-grow { flex: 1 1 auto; }
.rv-notice { padding: 10px 12px; border-radius: var(--radius-12); background: color-mix(in srgb, var(--gold) 20%, transparent); color: var(--text);
  font-size: calc(14px * var(--ts, 1)); font-weight: 600; }
.rv-notice[hidden] { display: none; }
.rv-body { display: grid; gap: var(--space-8); grid-template-columns: minmax(0, 1fr); min-width: 0; }
.rv-with-side .rv-body { grid-template-columns: minmax(0, 1fr) minmax(240px, 300px); }
.rv-stage { position: relative; min-width: 0; min-height: 220px; display: grid; place-items: start center; background: #15191c; border-radius: var(--radius-12); overflow: hidden; }
.rv-stage.rv-scroll { overflow: auto; max-height: calc(100vh - 150px); place-items: start; }
.rv-wrap { position: relative; line-height: 0; }
.rv-canvas { display: block; max-width: none; outline: none; touch-action: none; }
.rv-canvas:focus-visible { box-shadow: 0 0 0 3px var(--gold); }
.rv-cursor { position: absolute; pointer-events: none; width: 20px; height: 20px; margin: -2px 0 0 -3px; }
.rv-cursor[hidden] { display: none; }
.rv-wait { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 16px; color: #fff; text-align: center;
  font-size: calc(15px * var(--ts, 1)); }
.rv-wait[hidden] { display: none; }
.rv .spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--brand); animation: rv-spin .8s linear infinite; flex: 0 0 auto; }
@keyframes rv-spin { to { transform: rotate(360deg); } }
.rv .linkish { background: none; border: 0; padding: 0; color: var(--brand); font: inherit; font-size: calc(13px * var(--ts, 1)); cursor: pointer; text-decoration: underline; }
.rv-side { display: grid; gap: 8px; align-content: start; min-width: 0; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-12); background: var(--card); }
.rv-side[hidden] { display: none; }
.rv-side-t { margin: 0; font-size: calc(15px * var(--ts, 1)); }
.rv-chat-list { display: grid; gap: 6px; max-height: 260px; overflow-y: auto; align-content: start; }
.rv-msg { margin: 0; padding: 6px 10px; border-radius: 10px; background: var(--bg2); font-size: calc(13.5px * var(--ts, 1)); overflow-wrap: anywhere; white-space: pre-wrap; }
.rv-msg.me { background: var(--brand-soft); }
.rv-chat-form { display: flex; gap: 6px; min-width: 0; }
.rv-chat-form .eja-input { flex: 1 1 auto; min-width: 0; }
.rv-chat-form .eja-btn { flex: none; }
.rv-clip { display: grid; gap: 6px; }
.rv-clip[hidden] { display: none; }
.rv-clip textarea { width: 100%; }
.rv-files { display: grid; gap: 6px; }
.rv-file { display: grid; gap: 4px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; font-size: calc(13px * var(--ts, 1)); min-width: 0; }
.rv-file-top { display: flex; gap: 8px; justify-content: space-between; align-items: center; min-width: 0; }
.rv-file-top b { overflow-wrap: anywhere; min-width: 0; }
.rv-file.saved { border-color: var(--brand); }
.rv-file.failed, .rv-file.refused { border-color: var(--bad); }
.rv-bar { height: 6px; border-radius: var(--radius-pill); background: var(--bg2); overflow: hidden; }
.rv-bar i { display: block; height: 100%; background: var(--brand); }
.rv-count { min-width: 18px; padding: 0 5px; border-radius: var(--radius-pill); background: var(--bad); color: #fff; font-size: calc(11px * var(--ts, 1)); line-height: 18px; text-align: center; }
.rv-count[hidden] { display: none; }
.rv-full { background: var(--bg); padding: 8px; overflow: auto; }
.rv-full .rv-stage { border-radius: 0; }
.rv[data-phase="ended"] .rv-stage { opacity: .55; }
@media (max-width: 760px) {
  .rv-with-side .rv-body { grid-template-columns: minmax(0, 1fr); }
  .rv-quality { margin-inline-start: 0; flex-basis: 100%; }
}
/* remote help from EJA (I115): the admin's tab */
.ar-code { font-size: 20px; letter-spacing: .08em; }
.ar-viewer { display: grid; gap: 12px; min-width: 0; }
.ar-back { display: flex; justify-content: center; }
/* 2.1: the admin's main search (Ctrl+K), AI and services (I150), the guide of the app (I123) */
.search-open { display: inline-flex; align-items: center; gap: 8px; flex: 0 1 auto; min-width: 0; min-height: 40px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--bg2); color: var(--muted); font: inherit; font-size: 13.5px; cursor: pointer; }
.search-open:hover { border-color: var(--brand); color: var(--text); }
.search-open .eja-ic { width: 18px; height: 18px; flex: none; }
.search-open span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.search-open kbd { font: inherit; font-size: 11.5px; padding: 1px 6px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted2); }
@media (max-width: 899px) { .search-open { flex: none; width: 40px; height: 40px; padding: 0; justify-content: center; border-radius: 50%; } }
.search-pop { width: min(640px, calc(100vw - 20px)); margin-top: 8vh; }
.search-pop .eja-pop { max-height: calc(84dvh - 20px); }
.search-pop-head { display: flex; align-items: center; gap: 8px; padding: 12px; border-bottom: 1px solid var(--line); }
.search-pop-head .eja-input { flex: 1 1 auto; min-width: 0; min-height: 44px; }
.search-pop-ic .eja-ic { width: 20px; height: 20px; color: var(--muted2); }
.search-status { margin: 0; padding: 8px 14px 0; }
.search-list { list-style: none; margin: 0; padding: 6px 8px 12px; overflow-y: auto; min-height: 0; flex: 1 1 auto; }
.search-group { padding: 10px 8px 4px; font-size: 12px; font-weight: 700; color: var(--muted2); letter-spacing: .02em; }
.search-hit button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px; border: 0; border-radius: var(--radius-10);
  background: none; color: var(--text); font: inherit; text-align: start; cursor: pointer; min-width: 0; }
.search-hit button:hover, .search-hit.on button { background: var(--brand-soft); }
.search-hit .ic-plate { flex: none; }
.search-hit-text { display: grid; gap: 2px; min-width: 0; }
.search-hit-title { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; }
.search-hit-title b { overflow-wrap: anywhere; min-width: 0; }
.search-hit small { color: var(--muted); font-size: 12.5px; overflow-wrap: anywhere; }
.search-more { padding: 4px 8px; }
.search-flash { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: var(--radius-12); }
.how-to { margin-top: 6px; border-top: 1px solid var(--line); padding-top: 8px; }
.how-to summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--brand); min-height: 32px; display: flex; align-items: center; }
.how-to ol { margin: 6px 0 0; padding-inline-start: 22px; display: grid; gap: 4px; font-size: 13.5px; color: var(--muted); }
.linkish { background: none; border: 0; padding: 0; color: var(--brand); font: inherit; cursor: pointer; text-align: start; }
.linkish:hover { text-decoration: underline; }
.guide { display: grid; gap: 16px; min-width: 0; }
.guide-wrap { padding-top: 20px; padding-bottom: 48px; }
.guide-intro p { margin: 0 0 4px; max-width: 75ch; line-height: 1.55; }
.guide-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
@media (min-width: 700px) { .guide-bar { position: sticky; top: 8px; z-index: 5; } }
.guide-bar .search { flex: 1 1 260px; min-width: 0; position: relative; display: flex; align-items: center; }
.guide-bar .search .eja-ic { position: absolute; inset-inline-start: 14px; width: 18px; height: 18px; color: var(--muted2); pointer-events: none; }
.guide-bar .search .eja-input { padding-inline-start: 42px; min-height: 44px; width: 100%; }
.guide-layout { display: grid; gap: 16px; min-width: 0; }
@media (min-width: 1000px) {
  .guide-layout { grid-template-columns: 260px minmax(0, 1fr); align-items: start; }
  .guide-toc { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow-y: auto; }
}
.guide-toc summary { cursor: pointer; font-weight: 800; min-height: 32px; display: flex; align-items: center; }
.guide-toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.guide-toc ol ol { padding-inline-start: 12px; margin: 2px 0 8px; font-size: 13.5px; }
.guide-toc .toc-group { font-weight: 700; margin-top: 6px; }
.guide-toc .linkish { color: var(--text); padding: 2px 0; overflow-wrap: anywhere; }
.guide-toc ol ol .linkish { color: var(--muted); }
.guide-body { display: grid; gap: 24px; min-width: 0; }
.guide-group { display: grid; gap: 12px; min-width: 0; scroll-margin-top: 80px; }
.guide-group[hidden], .guide-entry[hidden] { display: none; }
.guide-group-head { display: flex; gap: 12px; align-items: flex-start; }
.guide-group-head p { margin: 4px 0 0; }
.guide-entry { display: grid; gap: 6px; min-width: 0; scroll-margin-top: 80px; }
.guide-entry-head { display: flex; gap: 10px; align-items: center; min-width: 0; }
.guide-entry-t { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; min-width: 0; }
.guide-entry-t .eja-card-t { margin: 0; overflow-wrap: anywhere; }
.guide-what { margin: 0; line-height: 1.55; }
.guide-h { margin: 8px 0 0; font-size: 13.5px; color: var(--muted2); }
.guide-steps, .guide-tips { margin: 0; padding-inline-start: 22px; display: grid; gap: 4px; line-height: 1.5; overflow-wrap: anywhere; }
.guide-tips { color: var(--muted); font-size: 14px; }
.guide-needs { display: flex; flex-wrap: wrap; gap: 6px; }
.guide-tabs { display: grid; gap: 8px; }
.guide-tab { padding: 10px 12px; border-radius: var(--radius-12); background: var(--bg2); display: grid; gap: 4px; min-width: 0; }
.guide-tab h5 { margin: 0; font-size: 14.5px; }
.guide-tab p { margin: 0; }
.guide-tools { display: grid; gap: 8px; min-width: 0; }
.guide-small { padding: 12px; border: 1px solid var(--line); border-radius: var(--radius-12); }
.guide-see { margin: 6px 0 0; font-size: 13.5px; color: var(--muted); }
.guide-modes { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.guide-picked { min-height: 32px; }
.guide-picked .eja-chip { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; }
.guide-picked .eja-chip span { overflow-wrap: anywhere; }
.chip-x { display: inline-grid; place-items: center; width: 22px; height: 22px; border: 0; border-radius: 50%; background: none; color: inherit; cursor: pointer; padding: 0; }
.chip-x .eja-ic { width: 14px; height: 14px; }
.guide-pick[hidden] { display: none; }
.guide-host { min-width: 0; }
/* a key typed left to right in the Arabic page: room for the eye on its left */
html[dir="rtl"] .pw-wrap > input[dir="ltr"] { padding-left: 48px; padding-right: 12px; }
@media print {
  body { background: #fff !important; color: #000; }
  .top, .side, .bottom-bar, .nav-drawer, .foot, .guide-bar, .guide-toc, .guide-top, .search-open, #login { display: none !important; }
  .admin-shell { display: block !important; }
  .content, .wrap { padding: 0 !important; max-width: none !important; }
  .guide-layout { display: block; }
  .guide-entry, .guide-tab { break-inside: avoid; box-shadow: none !important; }
  .guide-group + .guide-group { break-before: page; }
}

/* Phones: the admin's top bar (the logo, the section's name, search, ☰) and the drawer are in admin-nav.css */
.page-title h1, .page-title span { overflow-wrap: break-word; word-break: normal; }
/* Admin › Tests (I154): each version's test list; printed as the PDF */
.confirm-text { white-space: pre-line; }
.tests-list, .tests-items { display: grid; gap: 10px; }
a.tests-version { display: grid; gap: 10px; color: inherit; text-decoration: none; }
a.tests-version:hover { border-color: var(--brand); }
.tests-bar { display: grid; gap: 8px; }
.tests-counts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.tests-head { display: grid; gap: 10px; }
.tests-item { display: grid; gap: 8px; }
.tests-item.tests-fails { border-color: var(--bad); }
.tests-item .item-title b { overflow-wrap: anywhere; }
.tests-n { color: var(--muted); }
.tests-steps { margin: 0; padding-inline-start: 22px; display: grid; gap: 2px; }
.tests-expected { margin: 0; }
.tests-place { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; overflow-wrap: anywhere; }
.tests-place .badge { white-space: normal; }
.tests-result { align-items: flex-start; }
.tests-who { display: grid; gap: 2px; min-width: 0; flex: 1 1 200px; }
.tests-who b, .tests-note { overflow-wrap: anywhere; }
.tests-note { margin: 0; flex: 1 1 100%; white-space: pre-wrap; }
.tests-pics { display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 100%; }
.tests-pic img { display: block; max-width: 220px; max-height: 140px; border-radius: 8px; border: 1px solid var(--line); }
@media print {
  .no-print, .toolbar { display: none !important; }
  .tests-item, .tests-head { break-inside: avoid; box-shadow: none !important; }
}

/* Admin › Releases and Phone app: each version's direct download link, whole (wraps), with Copy and Download */
.direct-link { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 10px; align-items: center; margin-top: 8px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.direct-link-label { font-weight: 600; font-size: 13px; }
.direct-link-url { overflow-wrap: anywhere; word-break: break-word; font-size: 12.5px; min-width: 0; }
.direct-link-acts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }


/* I192: Admin › Releases and Phone app: the title row with the "Add" button (the form opens above the list), the list at the
   full width of the page, and the version history: a timeline of every version, each opening its details with a gallery of
   pictures of the app. Text wraps, it is never cut. */
.page-bar { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px 20px; }
.page-bar-main { flex: 1 1 320px; min-width: 0; display: grid; gap: 4px; }
.page-bar-main p { margin: 0; overflow-wrap: anywhere; }
.page-bar-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; max-width: 100%; }
.page-bar-acts .eja-btn { max-width: 100%; text-align: center; }
.add-panel { min-width: 0; scroll-margin-top: 84px; }
.hist-section { display: grid; gap: 14px; margin-top: 12px; min-width: 0; }
.hist { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.hist-item { position: relative; padding-inline-start: 28px; min-width: 0; }
.hist-item::before { content: ""; position: absolute; inset-inline-start: 7px; top: -12px; bottom: -12px; width: 2px; background: var(--line); }
.hist-item:first-child::before { top: 24px; }
.hist-item:last-child::before { bottom: calc(100% - 24px); }
.hist-item:only-child::before { display: none; }
.hist-dot { position: absolute; inset-inline-start: 0; top: 16px; width: 16px; height: 16px; box-sizing: border-box; border-radius: 50%;
  background: var(--card); border: 3px solid var(--brand); }
.hist-card { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 12px 16px; align-items: start; width: 100%; box-sizing: border-box;
  text-align: start; font: inherit; color: inherit; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-14);
  box-shadow: var(--shadow-card); padding: 10px 12px; cursor: pointer; }
.hist-card:hover { border-color: var(--brand); }
.hist-card:focus-visible, .hist-pick:focus-visible, .hist-main:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.hist-thumb { display: block; width: 200px; max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); }
.hist-thumb.none { display: grid; place-items: center; min-height: 100px; color: var(--muted2); }
.hist-body { display: grid; gap: 4px; min-width: 0; align-content: start; }
.hist-title { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.hist-ver { font-size: 18px; }
.hist-date, .hist-counts { font-size: 13px; color: var(--muted2); overflow-wrap: anywhere; }
.hist-sum { overflow-wrap: anywhere; }
.pop-dialog.history-dialog { width: min(1000px, calc(100vw - 20px)); }
.history-dialog .form-bd > * { min-width: 0; }
.hist-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.hist-lead { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.hist-note { margin: 0; padding: 8px 12px; border-radius: 10px; background: var(--bg2); border: 1px solid var(--line); overflow-wrap: anywhere; }
.hist-block { display: grid; gap: 8px; min-width: 0; }
.hist-h { margin: 0; font-size: 15px; font-weight: 800; }
.hist-list { margin: 0; padding-inline-start: 22px; display: grid; gap: 6px; list-style: disc; }
.hist-list li { overflow-wrap: anywhere; }
.hist-gallery { display: grid; gap: 8px; min-width: 0; }
.hist-main { display: block; }
.hist-shot { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); }
.hist-cap { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; overflow-wrap: anywhere; }
.hist-from { overflow-wrap: anywhere; }
.hist-nav { display: flex; flex-wrap: wrap; gap: 8px; }
.hist-strip { display: flex; flex-wrap: wrap; gap: 6px; }
.hist-pick { width: 96px; padding: 0; border: 2px solid transparent; border-radius: 8px; background: var(--bg2); cursor: pointer; overflow: hidden; line-height: 0; }
.hist-pick.on { border-color: var(--brand); }
.hist-pick img { display: block; width: 100%; height: auto; }
@media (max-width: 560px) {
  .hist-card { grid-template-columns: minmax(0, 1fr); }
  .hist-thumb { width: 100%; max-width: 240px; }
  .page-bar-acts, .page-bar-acts .eja-btn { width: 100%; }
  .add-panel { scroll-margin-top: 150px; }
}

/* Ask the web: the price banner and the models table (admin-ai.js) */
.price-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 14px; border: 1px solid var(--line); border-inline-start: 4px solid var(--brand); border-radius: 10px; background: var(--card, #fff); }
.price-banner.ok { border-inline-start-color: #1a7f37; }
.price-banner.bad { border-inline-start-color: #b42318; }
.price-banner .eja-row { margin-inline-start: auto; }
.ai-models-table input[type=number] { width: 7em; }
.ai-models-table td { vertical-align: middle; }
.price-history { margin: 6px 0 0; padding-inline-start: 20px; font-size: 13.5px; color: var(--muted); }
