/* B Zar (Borna Rayaneh): the user's own copy, used for reading text. */
@font-face { font-family: "Zar"; src: url("/static/BZar.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Zar"; src: url("/static/BZarBd.ttf") format("truetype"); font-weight: 700; font-display: swap; }
/* Noto Naskh Arabic (SIL Open Font License 1.1): classic Naskh for reading text. */
@font-face {
  font-family: "Naskh";
  src: url("/static/NotoNaskhArabic-arabic.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-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: "Naskh";
  src: url("/static/NotoNaskhArabic-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Vazirmatn by Saber Rastikerdar (SIL Open Font License), served from this app. */
@font-face {
  font-family: "Vazirmatn";
  src: url("/static/Vazirmatn.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
:root {
  --bg: #f4f4f2; --card: #fff; --text: #16191f; --muted: #646b76; --line: #d6d8db; --line-strong: #16191f;
  --accent: #1f4e79; --danger: #b42318; --ok: #1e7a3c; --warn: #9a5b00;
  font-family: "Vazirmatn", Tahoma, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0e1013; --card: #16191e; --text: #e7e9ec; --muted: #98a0ab; --line: #2c3139;
          --line-strong: #e7e9ec; --accent: #6ea8dc; }
}
* { box-sizing: border-box; border-radius: 0 !important; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.8; }
.top { display: flex; align-items: baseline; gap: 12px; padding: 12px 20px; border-bottom: 2px solid var(--line-strong); background: var(--card); }
.brand { font-weight: 800; font-size: 1.2rem; color: var(--text); text-decoration: none; }
.tagline { color: var(--muted); font-size: .9rem; flex: 1; }
main { max-width: 860px; margin: 0 auto; padding: 20px 16px 60px; }
.card { background: var(--card); border: 1px solid var(--line); padding: 16px 18px; margin-bottom: 16px; }
h1 { font-size: 1.4rem; font-weight: 800; margin: 0 0 8px; } h2 { font-size: 1.1rem; font-weight: 700; margin: 18px 0 6px; } h3 { font-size: 1rem; margin: 12px 0 4px; }
.muted { color: var(--muted); } .small { font-size: .85rem; }
input, textarea { width: 100%; font: inherit; padding: 10px 12px; border: 1px solid var(--line); background: var(--bg); color: var(--text); margin: 6px 0; }
input:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
button, .button { font: inherit; padding: 8px 16px; border: 1px solid var(--line-strong); background: var(--card); color: var(--text); cursor: pointer; text-decoration: none; display: inline-block; }
button:hover:not(:disabled), .button:hover { background: var(--bg); }
button:disabled { opacity: .45; cursor: default; }
.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.primary:hover:not(:disabled) { background: var(--accent); filter: brightness(1.1); }
.danger, .link.danger { color: var(--danger); }
.big { font-size: 1.1rem; padding: 12px 28px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.redo { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.link { color: var(--accent); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: none; }
.link:hover:not(:disabled) { background: none; text-decoration: underline; }
details summary { cursor: pointer; color: var(--muted); margin: 6px 0; }
.list a { display: flex; justify-content: space-between; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--text); text-decoration: none; }
.list a:hover { color: var(--accent); }
.list a:last-child { border-bottom: 0; }
.chip { font-size: .8rem; padding: 0 8px; border: 1px solid var(--line); white-space: nowrap; }
.chip.recording { color: var(--danger); border-color: var(--danger); }
.chip.finishing { color: var(--warn); border-color: var(--warn); }
.chip.done { color: var(--ok); border-color: var(--ok); }
.tag { font-size: .72rem; padding: 0 6px; border: 1px solid var(--warn); color: var(--warn); white-space: nowrap; align-self: center; }
.rec-dot { display: inline-block; width: 10px; height: 10px; background: var(--danger); animation: pulse 1.2s infinite; margin-inline-end: 6px; }
@keyframes pulse { 50% { opacity: .2; } }
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--line); margin: 12px 0; }
.tabs button { border: 0; border-bottom: 3px solid transparent; background: none; }
.tabs button.on { border-bottom-color: var(--accent); color: var(--accent); font-weight: 700; }
.seg { padding: 6px 0 10px; display: flex; gap: 10px; align-items: baseline; border-bottom: 1px dashed var(--line); }
.seg:last-child { border-bottom: 0; }
.seg time { color: var(--muted); font-size: .8rem; font-variant-numeric: tabular-nums; flex: 0 0 4.2em; }
.seg p { margin: 0; white-space: pre-line; flex: 1; }
.progress { margin: 10px 0; }
.progress .bar, .bar { height: 8px; background: var(--line); overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--accent); transition: width .6s ease; }
.progress .small { margin-top: 4px; }
.outbox { margin: 8px 0; }
.action { border-inline-start: 3px solid var(--accent); padding: 4px 10px; margin: 6px 0; }
.notice { padding: 10px 14px; border-inline-start: 3px solid var(--warn); background: color-mix(in srgb, var(--warn) 10%, transparent); margin: 8px 0; }
.error { color: var(--danger); }
.login { max-width: 360px; margin: 12vh auto; }
ul { padding-inline-start: 20px; margin: 4px 0; }
.module { margin: 14px 0; border: 1px solid var(--line); background: var(--bg); }
.module figcaption { font-weight: 700; font-size: .95rem; padding: 6px 10px; border-bottom: 1px solid var(--line); background: var(--card); }
.module-frame { display: block; width: 100%; border: 0; background: transparent; }
/* reading text: report, transcript */
article, .seg p, .brand { font-family: "Zar", "Naskh", "Vazirmatn", Tahoma, serif; }
article { font-size: 1.3rem; line-height: 2; }
article h1 { font-size: 1.95rem; font-weight: 700; line-height: 1.6; }
article h2 { font-size: 1.45rem; font-weight: 700; margin-top: 26px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
article .notice, article .muted.small, article .module figcaption { font-family: "Vazirmatn", Tahoma, sans-serif; }
.seg p { font-size: 1.22rem; line-height: 1.95; }
.module figcaption { font-family: "Zar", "Naskh", "Vazirmatn", serif; font-size: 1.2rem; }
