/* The QUIZZER website: QUIZZER's look (ios/Quizzer/UI/Theme.swift): cream paper, navy ink and hard shadows, amber as a fill with ink
   on it, never as text on cream. Right to left, phone first, light only. */
:root {
  color-scheme: only light;
  --paper: #FCF2E5;
  --card: #FFF9F0;
  --well: #F3E6D3;
  --ink: #12304F;
  --muted: #4D6175;
  --amber: #FDB400;
  --wash: #FFEFC7;
  --ok: #168049;
  --okwash: #D6F2E0;
  --bad: #C9381C;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: ui-rounded, -apple-system, "SF Arabic Rounded", "SF Arabic", "Geeza Pro", "Noto Kufi Arabic", Tahoma, sans-serif;
  line-height: 1.7;
  padding: calc(20px + env(safe-area-inset-top, 0px)) calc(16px + env(safe-area-inset-right, 0px)) calc(32px + env(safe-area-inset-bottom, 0px)) calc(16px + env(safe-area-inset-left, 0px));
}
main { max-width: 620px; margin: 0 auto; }
.brand {
  --o: 3px;
  text-align: center;
  color: var(--amber);
  font-size: 40px;
  font-weight: 900;
  line-height: 1.25;
  margin: 0 0 12px;
  text-shadow:
    var(--o) 0 0 var(--ink), calc(-1 * var(--o)) 0 0 var(--ink), 0 var(--o) 0 var(--ink), 0 calc(-1 * var(--o)) 0 var(--ink),
    2.5px 2.5px 0 var(--ink), -2.5px 2.5px 0 var(--ink), 2.5px -2.5px 0 var(--ink), -2.5px -2.5px 0 var(--ink),
    0 5px 0 var(--ink), 2.5px 4.5px 0 var(--ink), -2.5px 4.5px 0 var(--ink);
}
h1 { font-size: 26px; font-weight: 900; line-height: 1.35; margin: 0 0 6px; text-align: center; }
h2 { font-size: 18px; font-weight: 900; line-height: 1.4; margin: 0 0 6px; }
h3 { font-size: 18px; font-weight: 900; line-height: 1.3; margin: 0; }
p { margin: 0 0 10px; }
p:last-child { margin-bottom: 0; }
.lead { text-align: center; color: var(--muted); margin-bottom: 18px; }
.muted { color: var(--muted); font-size: 15px; }
a { color: var(--ink); font-weight: 800; text-decoration: underline; text-decoration-color: var(--amber); text-decoration-thickness: 3px; text-underline-offset: 4px; }
ul.plain { margin: 0 0 10px; padding-inline-start: 22px; }
ul.plain li { margin-bottom: 6px; color: var(--muted); }
ul.plain li::marker { color: var(--ink); }
.card { background: var(--card); border: 3px solid var(--ink); border-radius: 20px; box-shadow: 0 4px 0 var(--ink); padding: 16px; margin: 0 0 18px; }
.btn {
  display: inline-block; appearance: none; font: inherit; font-weight: 900; color: var(--ink); background: var(--amber);
  border: 3px solid var(--ink); border-radius: 14px; box-shadow: 0 3px 0 var(--ink); padding: 8px 18px; min-height: 46px; cursor: pointer; text-decoration: none; text-align: center;
}
.btn:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.btn:disabled { background: var(--well); color: var(--muted); cursor: default; }
.btn-ghost { background: var(--card); }
.btn-wide { display: block; width: 100%; }
.btn-text { appearance: none; border: 0; background: none; font: inherit; font-weight: 800; color: var(--ink); text-decoration: underline; text-decoration-color: var(--amber); text-decoration-thickness: 3px; text-underline-offset: 4px; padding: 10px 2px; cursor: pointer; }
.btn-text:disabled { color: var(--muted); text-decoration: none; cursor: default; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 16px 0; }
.note { background: var(--wash); border: 2px solid var(--ink); border-radius: 12px; padding: 8px 12px; font-weight: 700; font-size: 15px; margin: 0 0 16px; }
.note.test { text-align: center; }

/* the price list */
.packs { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pack { background: var(--card); border: 3px solid var(--ink); border-radius: 18px; box-shadow: 0 4px 0 var(--ink); padding: 12px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pack-head { min-height: 50px; }
.per { display: block; font-size: 13px; color: var(--muted); }
.price { font-size: 28px; font-weight: 900; line-height: 1.2; margin: 2px 0; }
.price small { font-size: 15px; font-weight: 800; }
.compare { font-size: 13.5px; line-height: 1.5; color: var(--muted); margin: 0 0 8px; }
.compare s { white-space: nowrap; }
.compare b { color: var(--ok); }
.pack .btn { margin-top: auto; padding: 6px 8px; }
.soon { margin-top: auto; display: block; text-align: center; font-weight: 900; background: var(--well); border: 3px dashed var(--ink); border-radius: 14px; padding: 7px 8px; min-height: 46px; }

/* signing in */
form { margin: 0; }
label { display: block; font-weight: 800; margin: 0 0 4px; }
input {
  font: inherit; width: 100%; background: #fff; color: var(--ink); border: 3px solid var(--ink); border-radius: 12px; padding: 8px 12px; min-height: 46px; margin: 0 0 12px;
}
input[dir="ltr"] { text-align: left; }
input:focus { outline: 3px solid var(--amber); outline-offset: 1px; }
:focus-visible { outline: 3px solid #1F5FD0; outline-offset: 3px; }
#message { color: var(--bad); font-weight: 800; margin: 10px 0 0; }
#message:empty { display: none; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }

/* the buyer's orders */
.orders { list-style: none; margin: 0; padding: 0; }
.orders li { border-top: 2px solid var(--well); padding: 10px 0; }
.orders li:first-child { border-top: 0; padding-top: 0; }
.orders li:last-child { padding-bottom: 0; }
.tag { display: inline-block; font-size: 13px; font-weight: 800; background: var(--well); border-radius: 8px; padding: 1px 8px; }
.tag.ok { background: var(--okwash); }
.tag.bad { background: #F9D9D2; }

/* the result page */
.result { text-align: center; }
.result h1 { margin-bottom: 8px; }
.ref { font-size: 13px; color: var(--muted); white-space: pre-line; overflow-wrap: anywhere; }

/* the seller's details and the links at the foot of every page */
footer { margin-top: 24px; font-size: 14px; color: var(--muted); text-align: center; }
.links { display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: center; margin: 0 0 10px; }
.seller { margin: 0; }
.seller div { display: inline-block; margin: 0 8px; }
.seller dt, .seller dd { display: inline; margin: 0; }
.seller dt::after { content: ": "; }
.draft { text-align: center; }
