/* The pay page (payment build step 4, 23 Oct). The cofounder's colours and
   Cairo, served from this host; fields 16px or larger so an iPhone does not
   zoom, buttons 44px or taller. Moyasar's own styles are overridden here.
   The website's design rules since its redesign (the cofounder, 31 Oct): no
   text below 15px, the main button 56px tall with a 12px radius, fields with a
   10px radius and a darker border, weights 400/600/700/900. */

@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url(/pay/assets/cairo-arabic.woff2) format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url(/pay/assets/cairo-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --green: #156b39;
  --text: #0d1417;
  --secondary: #3c4b45;
  --page: #fbfaf7;
  --card: #ffffff;
  --border: #e3e0d8;
  --field: #8f8a7f;
  --muted: #5c6e66;
  --green-hover: #0f5029;
  --green-light: #e8f1eb;
  --error: #a3231f;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-family: 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

.card {
  max-width: 440px;
  margin: 24px auto;
  padding: 24px 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
}
@media (max-width: 480px) {
  .card { margin: 0; min-height: 100vh; border-radius: 0; border-width: 0; }
}

.brand { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; font-weight: 900; font-size: 20px; }
.brand img { border-radius: 10px; }

h1 { font-size: 22px; font-weight: 900; margin: 0 0 4px; }
.price { font-size: 18px; font-weight: 700; color: var(--green); margin: 0 0 16px; }
.test { background: #fff6e0; border: 1px solid #e8d6a8; border-radius: 10px; padding: 8px 12px; font-size: 15px; }
.consent { font-size: 15px; color: var(--secondary); margin: 12px 0 0; }
.offer { font-weight: 700; color: var(--green); margin: 0 0 12px; }

/* The mada and Apple Pay marks under the button (the cofounder, 14 Nov). */
.marks { display: flex; justify-content: center; align-items: center; gap: 16px; margin: 12px 0 0; }
.marks img { height: 30px; width: auto; }

.links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 24px; font-size: 15px; }
/* The company, as the website's footer gives it (the cofounder, 14 Nov). */
.company { font-size: 15px; color: var(--secondary); margin: 12px 0 0; line-height: 1.6; }
.links a, a { color: var(--green); }
a.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 56px; padding: 0 24px; border-radius: 12px;
  background: var(--green); color: #fff; text-decoration: none; font-weight: 700;
}
a.button:hover { background: var(--green-hover); }

/* His account pages (step 7): plain forms, no script. */
h2 { font-size: 18px; font-weight: 700; margin: 16px 0 0; }
form { margin: 16px 0 0; }
label { display: block; font-size: 15px; color: var(--secondary); margin-bottom: 4px; }
input[type='email'] {
  display: block; width: 100%; min-height: 48px; padding: 8px 12px;
  font: inherit; font-size: 16px; color: var(--text);
  background: var(--card); border: 1px solid var(--field); border-radius: 10px;
}
input[type='email']:focus { border-color: var(--green); outline: 2px solid var(--green); outline-offset: 0; }
form button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 56px; padding: 0 24px; margin-top: 12px; border: 0; border-radius: 12px;
  background: var(--green); color: #fff; font: inherit; font-size: 16px; font-weight: 700; cursor: pointer;
}
form button:hover { background: var(--green-hover); }
form button.danger { background: var(--error); }
form button.link {
  background: none; color: var(--green); padding: 0; min-height: 44px; font-weight: 400; text-decoration: underline;
}
a.button.secondary { background: var(--card); color: var(--green); border: 1px solid var(--green); }
a.button.secondary:hover { background: var(--green-light); }

/* Moyasar's form. Its rules are all `div#mysr ... !important` (form 2.3.0),
   so ours carry the same id and one more class or attribute to win:
   our font, 16px fields, 44px controls, our green, our error red. */
main div#mysr, main div#mysr *:not(apple-pay-button) { font-family: 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif !important; }
/* Its fields draw their outline with a box-shadow (`shadow-input`), not a border. */
main div#mysr input[name], main div#mysr select[name] {
  font-size: 16px !important;
  min-height: 48px !important;
  color: var(--text) !important;
  border-color: var(--field) !important;
  box-shadow: 0 0 0 1px var(--field) !important;
}
main div#mysr input[name]:focus { box-shadow: 0 0 0 2px var(--green) !important; outline-color: var(--green) !important; }
main div#mysr label:not(.mysr-never), main div#mysr legend:not(.mysr-never), main div#mysr p:not(.mysr-never) { font-size: 15px !important; color: var(--secondary) !important; }
main div#mysr button[type] { min-height: 44px !important; font-size: 16px !important; }
main div#mysr button[type='submit'] {
  min-height: 56px !important;
  border-radius: 12px !important;
  background-color: var(--green) !important;
}
main div#mysr button[type='submit']:hover { background-color: var(--green-hover) !important; }
main div#mysr [class*='text-red']:not(.mysr-never), main div#mysr [class*='error']:not(.mysr-never) { font-size: 15px !important; color: var(--error) !important; }
apple-pay-button { --apple-pay-button-height: 56px; --apple-pay-button-border-radius: 12px; width: 100%; display: block; }

/* His account (the hub, 5 Nov; the mockup Ara approved). Everything below is
   scoped to `html.acct`, so the pay page and Moyasar's form are untouched.
   One calm column on the brand's paper; the plan is the one lifted panel.
   Light and dark from the same tokens; no script, no inline style. */

html.acct {
  --sunk: #f4f2ed;
  --green-line: #b9d5c3;
  --on-green: #ffffff;
  --error-hover: #841b18;
  --error-light: #f8e9e7;
  --on-error: #ffffff;
  --warn: #7a4f00;
  --warn-light: #fbf0d9;
  --pause: #3c4b45;
  --pause-light: #ecebe6;
  --focus: #156b39;
  --shadow: 0 1px 2px rgba(13, 20, 23, .04), 0 10px 28px rgba(13, 20, 23, .06);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  html.acct {
    --page: #0e1311; --card: #161c19; --sunk: #1b2320; --border: #2a332f; --field: #6f7a74;
    --text: #eef2ee; --secondary: #c3cdc7; --muted: #9aa9a1;
    --green: #5cbf85; --green-hover: #76cf9a; --green-light: #16281e; --green-line: #2c4a38; --on-green: #06140c;
    --error: #f08a83; --error-hover: #f4a19b; --error-light: #2d1716; --on-error: #2a0d0b;
    --warn: #e7b65c; --warn-light: #2a2111; --pause: #c3cdc7; --pause-light: #232b28;
    --focus: #76cf9a; --shadow: 0 1px 0 rgba(0, 0, 0, .25);
  }
}

html.acct body { line-height: 1.7; -webkit-font-smoothing: antialiased; }
.acct .hub {
  width: 100%; max-width: 632px; margin-inline: auto;
  padding: 16px max(16px, env(safe-area-inset-right, 0px)) 56px max(16px, env(safe-area-inset-left, 0px));
  display: flex; flex-direction: column; gap: 28px;
}
.acct p { margin: 0; }
.acct h1, .acct h2, .acct h3 { margin: 0; text-wrap: balance; }
.acct h1 { font-size: 28px; font-weight: 800; line-height: 1.35; }
.acct h2 { font-size: 18px; font-weight: 700; line-height: 1.4; }
.acct a { color: var(--green); text-underline-offset: 3px; }
.acct :focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.acct form { margin: 0; }

.acct .top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; }
.acct .brand { display: flex; align-items: center; gap: 10px; margin: 0; font-weight: 800; font-size: 20px; }
.acct .mark { border-radius: 10px; display: block; }
.acct .back { display: inline-flex; align-items: center; gap: 10px; align-self: flex-start; min-height: 44px; font-weight: 600; text-decoration: none; margin-bottom: -12px; }
.acct .stack { display: flex; flex-direction: column; gap: 16px; }
.acct .lead { color: var(--secondary); }
.acct .muted { color: var(--muted); }

/* Buttons: 56px tall, 12px radius (the website's rules, 31 Oct). */
.acct .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px; padding: 0 24px; margin: 0; border-radius: 12px; border: 1px solid transparent;
  font: inherit; font-size: 16px; font-weight: 700; line-height: 1.4; cursor: pointer; text-align: center; text-decoration: none;
  width: 100%;
}
.acct .btn-primary { background: var(--green); color: var(--on-green); }
.acct .btn-primary:hover { background: var(--green-hover); }
.acct .btn-secondary { background: var(--card); color: var(--green); border-color: var(--green); }
.acct .btn-secondary:hover { background: var(--green-light); }
.acct .btn-danger { background: var(--error); color: var(--on-error); }
.acct .btn-danger:hover { background: var(--error-hover); }
.acct .quiet {
  background: none; border: 0; padding: 0 4px; min-height: 44px; display: inline-flex; align-items: center;
  font: inherit; font-size: 16px; font-weight: 600; color: var(--green); cursor: pointer;
  text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px;
}
.acct .quiet.neutral { color: var(--secondary); }
.acct .actions { display: flex; flex-wrap: wrap; gap: 12px; }
.acct .actions > * { flex: 1 1 160px; display: flex; }
.acct .quiet-row { display: flex; }

.acct .notice { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--green-light); border: 1px solid var(--green-line); }
.acct .notice.warn { background: var(--warn-light); border-color: var(--warn); }

.acct .hello { display: flex; flex-direction: column; gap: 6px; }
.acct .hello h1 { font-size: 30px; }
.acct .hello-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; color: var(--secondary); }
.acct .agent { font-weight: 600; color: var(--text); }
.acct .pill { display: inline-flex; align-items: center; gap: 8px; padding: 1px 12px; border-radius: 999px; font-size: 15px; font-weight: 700; line-height: 1.9; white-space: nowrap; }
.acct .pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: none; }
.acct .pill.ok { background: var(--green-light); color: var(--green); }
.acct .pill.warn { background: var(--warn-light); color: var(--warn); }
.acct .pill.pause { background: var(--pause-light); color: var(--pause); }
.acct .pill.stop { background: var(--error-light); color: var(--error); }

.acct .sec { display: flex; flex-direction: column; gap: 12px; }
.acct .panel { background: var(--card); border: 1px solid var(--border); border-radius: 16px; }
.acct .plan { padding: 20px; display: flex; flex-direction: column; gap: 16px; box-shadow: var(--shadow); }
.acct .price { font-size: 24px; font-weight: 800; line-height: 1.35; color: var(--text); margin: 0; }
.acct .state { color: var(--secondary); margin-top: -8px; }
.acct .facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px 24px; margin: 0; padding-top: 16px; border-top: 1px solid var(--border); }
.acct .facts dt { font-size: 15px; color: var(--muted); }
.acct .facts dd { margin: 0; font-weight: 600; }
.acct .sub { display: block; font-size: 15px; font-weight: 400; color: var(--muted); }
.acct .sub.bad { color: var(--error); font-weight: 600; }
.acct .confirm-box { display: flex; flex-direction: column; gap: 14px; padding: 16px; border-radius: 12px; background: var(--sunk); border: 1px solid var(--border); }

.acct .rows { list-style: none; margin: 0; padding: 0; }
.acct .rows > li + li { border-top: 1px solid var(--border); }
.acct .rc { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 2px 16px; padding: 14px 20px; color: inherit; text-decoration: none; border-radius: 15px; }
.acct .rc:hover { background: var(--sunk); }
.acct .rc-a { display: flex; flex-direction: column; min-width: 0; }
.acct .rc-b { display: flex; flex-direction: column; align-items: end; text-align: end; }
.acct .rc-date { font-weight: 600; }
.acct .rc-no, .acct .rc-card { font-size: 15px; color: var(--muted); overflow-wrap: anywhere; }
.acct .rc-amt { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.acct .tag { font-size: 15px; font-weight: 700; padding: 0 8px; border-radius: 6px; background: var(--pause-light); color: var(--pause); line-height: 1.7; }
.acct .empty { padding: 18px 20px; color: var(--muted); }
.acct .chev { display: inline-block; width: 9px; height: 9px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); flex: none; color: var(--muted); }
.acct [dir="rtl"] .rc .chev, html.acct[dir="rtl"] .rc .chev { transform: rotate(225deg); }
.acct .back .chev { color: var(--green); transform: rotate(225deg); }
html.acct[dir="rtl"] .back .chev { transform: rotate(45deg); }

/* Forms */
.acct .form { display: flex; flex-direction: column; gap: 16px; }
.acct .field { display: flex; flex-direction: column; gap: 6px; }
.acct .field label, .acct .legend { font-size: 15px; font-weight: 600; color: var(--secondary); margin: 0; }
.acct .input { width: 100%; min-height: 52px; padding: 10px 14px; font: inherit; font-size: 16px; color: var(--text); background: var(--card); border: 1px solid var(--field); border-radius: 10px; }
.acct textarea.input { min-height: 96px; resize: vertical; }
.acct .input:focus { outline: 2px solid var(--green); outline-offset: 0; border-color: var(--green); }
html.acct[dir="rtl"] .input[dir="ltr"] { text-align: right; }
.acct fieldset { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.acct legend { padding: 0; margin-bottom: 8px; }
.acct .opt { display: flex; align-items: center; gap: 12px; padding: 10px 16px; min-height: 52px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); cursor: pointer; }
.acct .opt:has(input:checked) { border-color: var(--green); background: var(--green-light); }
.acct .opt input { width: 20px; height: 20px; margin: 0; accent-color: var(--green); flex: none; }

/* Pause timeline and tick lists */
.acct .box { padding: 18px 20px; border-radius: 16px; background: var(--card); border: 1px solid var(--border); }
.acct .tl { list-style: none; margin: 0; padding: 0; }
.acct .tl li { position: relative; padding-inline-start: 30px; padding-bottom: 18px; }
.acct .tl li:last-child { padding-bottom: 0; }
.acct .tl li::before { content: ""; position: absolute; inset-inline-start: 5px; top: 8px; width: 12px; height: 12px; border-radius: 50%; background: var(--card); border: 2px solid var(--green); }
.acct .tl li::after { content: ""; position: absolute; inset-inline-start: 10px; top: 22px; bottom: 0; width: 2px; background: var(--border); }
.acct .tl li:last-child::after { display: none; }
.acct .tl li.now::before { background: var(--green); }
.acct .ticks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; color: var(--secondary); }
.acct .ticks li { position: relative; padding-inline-start: 20px; }
.acct .ticks li::before { content: ""; position: absolute; inset-inline-start: 2px; top: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--muted); }
.acct .done-mark { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: var(--green-light); color: var(--green); font-size: 28px; font-weight: 800; }
.acct .done-mark.neutral { background: var(--pause-light); color: var(--pause); }

/* A receipt: the paper */
.acct .paper { background: var(--card); border: 1px solid var(--border); border-radius: 6px; box-shadow: var(--shadow); padding: 28px 24px; display: flex; flex-direction: column; gap: 24px; }
.acct .paper-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; padding-bottom: 20px; border-bottom: 1px solid var(--border); }
.acct .paper-meta, .acct .parties { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px 24px; margin: 0; }
.acct .paper dt, .acct .parties h2 { font-size: 15px; font-weight: 600; color: var(--muted); }
.acct .paper dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.acct .lines { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.acct .lines th, .acct .lines td { padding: 12px 0; text-align: start; vertical-align: top; }
.acct .lines thead th { font-size: 15px; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--border); }
.acct .lines tbody td { border-bottom: 1px solid var(--border); }
.acct .lines .amt { text-align: end; white-space: nowrap; padding-inline-start: 16px; }
.acct .lines tfoot th, .acct .lines tfoot td { font-weight: 800; font-size: 18px; border-top: 3px double var(--text); }

.acct .foot { display: flex; flex-wrap: wrap; gap: 4px 20px; padding-top: 8px; border-top: 1px solid var(--border); font-size: 15px; }
.acct .foot a { display: inline-flex; align-items: center; min-height: 44px; }

@media (min-width: 640px) {
  .acct .hub { padding-top: 28px; padding-bottom: 72px; }
  .acct .plan { padding: 24px; }
  .acct .paper { padding: 36px 40px; }
}

/* Your details (6 Nov, part 2): a row per detail with its Edit; the change
   pages' current value, the code he sends from the new phone, and the wait. */
.acct .drow { display: flex; align-items: center; gap: 12px; padding-block: 12px; padding-inline: 20px 12px; min-height: 64px; }
.acct .drow-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.acct .drow-label { font-size: 15px; color: var(--muted); }
.acct .drow-value { font-weight: 600; overflow-wrap: anywhere; }
.acct .drow .quiet { flex: none; }
.acct .current { display: flex; flex-direction: column; padding: 12px 16px; border-radius: 12px; background: var(--sunk); }
.acct .current span:first-child { font-size: 15px; color: var(--muted); }
.acct .current span:last-child { font-weight: 600; overflow-wrap: anywhere; }
.acct .hint { font-size: 15px; color: var(--muted); }
.acct .err { color: var(--error); font-size: 15px; font-weight: 600; }
.acct .has-err .input { border-color: var(--error); }
.acct .code { display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; gap: 12px; padding: 20px 16px; border-radius: 16px; background: var(--sunk); border: 1px solid var(--border); font-size: 30px; font-weight: 800; line-height: 1.3; }
.acct .code bdi { letter-spacing: .12em; font-variant-numeric: tabular-nums; }
.acct .wait { display: flex; align-items: center; gap: 14px; }
.acct .wait h2 { font-size: 18px; }
.acct .spin { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--green); flex: none; }
@media (prefers-reduced-motion: no-preference) {
  .acct .spin { animation: acct-turn 1s linear infinite; }
}
@keyframes acct-turn { to { transform: rotate(360deg); } }

/* Your assistant (6 Nov, part 3): its address selected whole by one click (no
   script may run here, so no Copy button), the calendar's state, and the setup
   steps left, each "how" a <details>. */
.acct .addr { user-select: all; -webkit-user-select: all; cursor: text; }
.acct .drow-value.plain { font-weight: 400; }
.acct .dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-inline-end: 8px; vertical-align: middle; }
.acct .dot.ok { background: var(--green); }
.acct .dot.warn { background: var(--warn); }
.acct details { margin-top: 6px; }
.acct details > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--green); font-weight: 700; }
.acct details > summary::-webkit-details-marker { display: none; }
.acct details > summary .chev { color: var(--green); transform: rotate(135deg); margin-top: -4px; }
.acct details[open] > summary .chev { transform: rotate(-45deg); margin-top: 4px; }
.acct .how { display: flex; flex-direction: column; gap: 8px; padding: 12px 16px; border-radius: 12px; background: var(--sunk); color: var(--secondary); }
.acct .how ol { margin: 0; padding-inline-start: 24px; display: flex; flex-direction: column; gap: 4px; }
html.acct[lang="ar"] .how ol { list-style-type: arabic-indic; }
.acct .setup { padding: 16px 20px; display: flex; flex-direction: column; gap: 16px; }
.acct .setup h3 { margin: 0; font-size: 16px; }
.acct .step { display: flex; flex-direction: column; gap: 4px; }
.acct .step + .step { padding-top: 16px; border-top: 1px solid var(--border); }
.acct .step-title { font-weight: 700; }
