:root {
  color-scheme: dark;
  --ink: #f7f6f2;
  --muted: #aaa8b8;
  --soft: #77768b;
  --line: rgba(255, 255, 255, 0.11);
  --panel: rgba(28, 27, 49, 0.82);
  --panel-strong: #24223d;
  --page: #121121;
  --accent: #f6b75a;
  --accent-strong: #e79338;
  --mint: #94d8c5;
  --danger: #ff8b8b;
  --font: "IBM Plex Sans Arabic", system-ui, sans-serif;
  font-family: var(--font);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--page); }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% -4%, rgba(109, 89, 195, .28), transparent 32rem),
    radial-gradient(circle at 92% 22%, rgba(246, 183, 90, .1), transparent 28rem),
    var(--page);
}
button, textarea, select, input { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .42; }
.ambient { position: fixed; pointer-events: none; border-radius: 50%; filter: blur(2px); opacity: .25; z-index: -1; }
.ambient-one { width: 14rem; height: 14rem; left: 6%; bottom: 9%; background: #6659be; filter: blur(90px); }
.ambient-two { width: 18rem; height: 18rem; right: 14%; top: 18%; background: #e99a47; filter: blur(115px); opacity: .08; }
.shell { width: min(1150px, calc(100% - 48px)); margin-inline: auto; }
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 28px 0 18px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand strong { display: block; font-size: 1.12rem; letter-spacing: -.02em; }
.brand small { display: block; margin-top: 1px; color: var(--soft); font-size: .68rem; letter-spacing: .02em; }
.brand-mark { display: flex; align-items: end; justify-content: center; gap: 3px; width: 35px; height: 35px; padding: 8px 7px; border-radius: 11px; background: var(--accent); transform: rotate(-4deg); box-shadow: 0 8px 22px rgba(246, 183, 90, .18); }
.brand-mark span { width: 4px; border-radius: 5px; background: #27203c; }
.brand-mark span:nth-child(1) { height: 10px; }.brand-mark span:nth-child(2) { height: 17px; }.brand-mark span:nth-child(3) { height: 13px; }
.privacy-chip, .local-badge { display: inline-flex; align-items: center; gap: 7px; border: 1px solid rgba(148, 216, 197, .22); border-radius: 99px; color: #b7e6d8; font-size: .75rem; padding: 7px 12px; background: rgba(148, 216, 197, .07); }
.privacy-dot, .status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 4px rgba(148, 216, 197, .1); }
.main-content { padding: 54px 0 65px; }
.intro { max-width: 680px; margin-bottom: 34px; }
.eyebrow { display: flex; align-items: center; gap: 10px; color: var(--accent); font-size: .73rem; font-weight: 600; letter-spacing: .04em; }
.eyebrow span { display: grid; place-items: center; width: 22px; height: 22px; border: 1px solid rgba(246, 183, 90, .5); border-radius: 50%; font-family: "Space Grotesk", sans-serif; font-size: .7rem; }
h1 { margin: 18px 0 12px; font-size: clamp(3.2rem, 8vw, 6rem); line-height: .98; letter-spacing: -.08em; font-weight: 700; }
h1 em { color: var(--accent); font-style: normal; }
.intro-copy { max-width: 550px; margin: 0; color: var(--muted); font-size: 1rem; line-height: 1.9; }
.steps { display: flex; align-items: center; gap: 17px; margin-top: 30px; }
.step { display: flex; align-items: center; gap: 10px; color: var(--soft); }
.step.active { color: var(--ink); }.step > span { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); font-family: "Space Grotesk", sans-serif; font-size: .75rem; }
.step.active > span { border-color: var(--accent); color: #201a2c; background: var(--accent); }
.step b, .step small { display: block; }.step b { font-size: .77rem; font-weight: 600; }.step small { margin-top: 1px; font-size: .66rem; color: var(--soft); }.step-line { width: 44px; height: 1px; background: var(--line); }
.reader-card, .control-panel { position: relative; border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(135deg, rgba(40, 38, 66, .88), rgba(24, 23, 42, .87)); box-shadow: 0 25px 70px rgba(0, 0, 0, .22); }
.reader-card { padding: 30px; }.card-topline, .panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }.card-kicker { margin: 0 0 5px; color: var(--accent); font-size: .7rem; font-weight: 600; letter-spacing: .05em; }.card-topline h2, .panel-heading h2 { margin: 0; font-size: 1.32rem; letter-spacing: -.03em; }
.lock-icon { font-size: 1rem; transform: rotate(180deg); }.textarea-wrap { position: relative; margin-top: 24px; border: 1px solid rgba(255,255,255,.13); border-radius: 15px; background: rgba(17, 16, 32, .63); transition: border .2s, box-shadow .2s; }.textarea-wrap:focus-within { border-color: rgba(246,183,90,.72); box-shadow: 0 0 0 4px rgba(246,183,90,.08); }
textarea { display: block; width: 100%; min-height: 245px; resize: vertical; border: 0; outline: 0; padding: 21px 22px 43px; color: var(--ink); background: transparent; font-size: 18px; line-height: 2; direction: rtl; }.textarea-wrap textarea::placeholder { color: #6f6c82; }.textarea-footer { position: absolute; left: 16px; right: 20px; bottom: 13px; display: flex; justify-content: space-between; color: var(--soft); font-family: var(--font); font-size: .68rem; }
.quick-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 11px; }.text-button { border: 0; padding: 7px 0; color: var(--accent); background: transparent; font-size: .75rem; }.text-button:hover { color: #ffd28d; }.text-button.muted { color: var(--soft); }.text-button span { margin-left: 4px; }
.primary-row { display: flex; align-items: center; gap: 18px; margin-top: 22px; }.primary-button { display: inline-flex; justify-content: center; align-items: center; gap: 10px; min-width: 185px; border: 0; border-radius: 12px; padding: 14px 19px; color: #2a2034; background: var(--accent); box-shadow: 0 10px 25px rgba(246,183,90,.18); font-weight: 700; transition: transform .18s, background .18s; }.primary-button:hover { background: #ffca75; transform: translateY(-2px); }.play-glyph { font-size: .78rem; }.support-note { display: flex; align-items: center; gap: 9px; color: var(--soft); font-size: .67rem; line-height: 1.5; }.support-note b { color: #aaa7ba; font-weight: 500; }.support-icon { display: grid; place-items: center; width: 25px; height: 25px; border: 1px solid rgba(148,216,197,.27); border-radius: 50%; color: var(--mint); font-size: 1rem; }
.control-panel { margin-top: 18px; padding: 29px 30px 24px; }.status-pill { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 99px; padding: 7px 11px; color: var(--muted); font-size: .7rem; }.status-pill.playing .status-dot { background: var(--accent); box-shadow: 0 0 0 4px rgba(246,183,90,.12); animation: pulse 1.4s infinite; }.status-pill.paused .status-dot { background: #bbb0f2; }.status-pill.error .status-dot { background: var(--danger); }
@keyframes pulse { 50% { opacity: .35; transform: scale(.75); } }
.reading-status { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 18px; }.status-main { display: flex; align-items: center; gap: 10px; min-height: 28px; color: var(--muted); font-size: .8rem; }.sound-wave { display: flex; align-items: center; gap: 3px; width: 19px; height: 18px; }.sound-wave i { display: block; width: 3px; height: 7px; border-radius: 4px; background: var(--accent); opacity: .65; }.sound-wave i:nth-child(2) { height: 13px; }.sound-wave i:nth-child(3) { height: 17px; }.sound-wave i:nth-child(4) { height: 10px; }.playing .sound-wave i { animation: wave .8s ease-in-out infinite alternate; }.playing .sound-wave i:nth-child(2) { animation-delay: .15s; }.playing .sound-wave i:nth-child(3) { animation-delay: .3s; }.playing .sound-wave i:nth-child(4) { animation-delay: .45s; } @keyframes wave { to { transform: scaleY(.38); opacity: .45; } }
.progress-track { height: 4px; margin-top: 13px; overflow: hidden; border-radius: 5px; background: rgba(255,255,255,.08); }.progress-track div { width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent-strong), var(--accent)); transition: width .25s ease; }
.control-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 18px; margin-top: 25px; }.control-block { min-width: 0; border: 1px solid rgba(255,255,255,.09); border-radius: 13px; padding: 15px 16px 12px; background: rgba(255,255,255,.025); }.control-block label { display: block; margin-bottom: 11px; color: var(--muted); font-size: .72rem; }.voice-control select { width: 100%; border: 1px solid rgba(255,255,255,.12); border-radius: 8px; outline: 0; padding: 8px 10px; color: var(--ink); background: #282640; font-size: .75rem; }.field-hint { min-height: 16px; margin: 8px 0 0; color: var(--soft); font-size: .62rem; }.label-line { display: flex; align-items: center; justify-content: space-between; }.label-line label { margin-bottom: 11px; }.label-line output { color: var(--accent); font-family: "Space Grotesk", sans-serif; font-size: .72rem; }.control-block input[type=range] { width: 100%; height: 4px; accent-color: var(--accent); }.range-labels { display: flex; justify-content: space-between; margin-top: 8px; color: var(--soft); font-size: .61rem; }
.transport-row { display: flex; gap: 9px; margin-top: 20px; }.transport { display: inline-flex; align-items: center; gap: 8px; border: 1px solid rgba(255,255,255,.12); border-radius: 9px; padding: 10px 14px; color: var(--muted); background: rgba(255,255,255,.04); font-size: .72rem; }.transport:hover:not(:disabled) { border-color: rgba(246,183,90,.4); color: var(--ink); }.transport span { font-size: .68rem; }.primary-transport { border-color: rgba(246,183,90,.35); color: var(--accent); }.stop-transport { color: #d49c9c; }
.storage-row { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 24px; border-top: 1px solid var(--line); padding-top: 19px; }.storage-copy { display: flex; align-items: center; gap: 10px; }.storage-icon { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid rgba(255,255,255,.12); border-radius: 8px; color: var(--muted); font-size: .82rem; }.storage-copy b, .storage-copy small { display: block; }.storage-copy b { color: var(--muted); font-size: .75rem; font-weight: 500; }.storage-copy small { margin-top: 2px; color: var(--soft); font-size: .64rem; }.switch { position: relative; display: block; width: 38px; height: 22px; margin: 0; }.switch input { position: absolute; opacity: 0; }.switch span { position: absolute; inset: 0; border-radius: 20px; background: #3a3853; transition: background .2s; }.switch span:before { content: ""; position: absolute; top: 3px; right: 3px; width: 16px; height: 16px; border-radius: 50%; background: #a9a6b5; transition: transform .2s, background .2s; }.switch input:checked + span { background: var(--accent-strong); }.switch input:checked + span:before { background: #fff; transform: translateX(-16px); }.storage-actions { display: flex; justify-content: flex-end; gap: 18px; margin-top: 9px; }
.compatibility { margin-top: 16px; border: 1px solid rgba(255,139,139,.3); border-radius: 12px; padding: 12px 15px; color: #ffc1c1; background: rgba(255,139,139,.08); font-size: .74rem; line-height: 1.7; }.footer-note { margin: 22px 3px 0; color: var(--soft); font-size: .66rem; line-height: 1.8; }
@media (min-width: 900px) { .main-content { display: grid; grid-template-columns: .84fr 1.16fr; column-gap: 54px; align-items: start; }.intro { grid-column: 1; grid-row: 1 / span 2; padding-top: 32px; }.reader-card { grid-column: 2; grid-row: 1; }.control-panel { grid-column: 2; grid-row: 2; }.compatibility, .footer-note { grid-column: 1 / -1; } }
@media (max-width: 680px) { .shell { width: min(100% - 28px, 560px); }.topbar { padding-top: 19px; }.privacy-chip { padding: 6px 9px; font-size: .62rem; }.main-content { padding-top: 35px; }.reader-card, .control-panel { padding: 21px 18px; border-radius: 18px; }.intro { margin-bottom: 25px; }.intro-copy { font-size: .88rem; line-height: 1.8; }.steps { gap: 10px; }.step-line { width: 21px; }.step small { font-size: .59rem; }h1 { font-size: clamp(3.1rem, 17vw, 5rem); }.card-topline h2, .panel-heading h2 { font-size: 1.12rem; }.local-badge { font-size: .61rem; padding: 6px 8px; }.textarea-wrap { margin-top: 18px; }textarea { min-height: 235px; padding: 16px 15px 42px; font-size: 17px; }.primary-row { align-items: stretch; flex-direction: column; }.primary-button { width: 100%; }.support-note { justify-content: center; }.control-grid { grid-template-columns: 1fr; gap: 10px; }.transport-row { flex-wrap: wrap; }.transport { flex: 1 1 30%; justify-content: center; padding: 10px 8px; }.storage-actions { flex-wrap: wrap; justify-content: flex-start; gap: 11px; }.footer-note { margin-bottom: 10px; } }
@media (max-width: 410px) { .brand small { display: none; }.privacy-chip { max-width: 130px; }.privacy-chip .privacy-dot { flex: 0 0 auto; }.step b { font-size: .68rem; }.step small { display: none; }.quick-actions { flex-wrap: wrap; }.transport { flex-basis: 44%; } }
