
:root{
  --bg0:#f6f7fb;
  --bg1:#eef1f7;
  --card: rgba(0,0,0,.04);
  --stroke: rgba(0,0,0,.10);
  --text:#0b0b10;
  --muted: rgba(0,0,0,.60);
  --muted2: rgba(0,0,0,.42);
  --accent:#0ea5e9;
  --r:18px;
  --shadow: 0 18px 70px rgba(0,0,0,.12);
}

body.dark{
  --bg0:#07070a;
  --bg1:#0e0e14;
  --card: rgba(255,255,255,.06);
  --stroke: rgba(255,255,255,.12);
  --text:#f5f5f7;
  --muted: rgba(255,255,255,.65);
  --muted2: rgba(255,255,255,.42);
  --accent:#22c55e;
  --shadow: 0 18px 70px rgba(0,0,0,.55);
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
  color:var(--text);
  background: radial-gradient(900px 600px at 10% 10%, rgba(0,0,0,.04), transparent 60%),
              radial-gradient(900px 600px at 90% 20%, rgba(14,165,233,.14), transparent 60%),
              linear-gradient(180deg, var(--bg0), var(--bg1));
}

.bg{
  position:fixed; inset:0;
  pointer-events:none;
  opacity:.7;
  background-image:
    radial-gradient(circle at 30% 20%, rgba(0,0,0,.06), transparent 45%),
    radial-gradient(circle at 75% 35%, rgba(14,165,233,.12), transparent 45%);
}

.top{
  position:sticky; top:0; z-index:5;
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 16px;
  backdrop-filter: blur(10px);
  background: linear-gradient(180deg, rgba(255,255,255,.65), rgba(255,255,255,0));
  border-bottom:1px solid var(--stroke);
}
body.dark .top{
  background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,0));
}

.brand{display:flex; gap:12px; align-items:center}
.logo{
  width:44px; height:44px; display:grid; place-items:center;
  border:1px solid var(--stroke);
  background: var(--card);
  border-radius:14px;
  box-shadow: var(--shadow);
  font-weight:800;
}
.title{font-weight:800; letter-spacing:.2px}
.sub{font-size:12px; color:var(--muted)}

.actions{display:flex; gap:8px; align-items:center; flex-wrap:wrap}
.btn{
  border:1px solid var(--stroke);
  background: var(--card);
  color:var(--text);
  padding:10px 12px;
  border-radius:14px;
  cursor:pointer;
  box-shadow: var(--shadow);
}
.btn.ghost{background:transparent; box-shadow:none}

.wrap{max-width:1000px; margin:18px auto; padding:0 16px 40px}
.card{
  border:1px solid var(--stroke);
  background: var(--card);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  padding:16px;
}
.row{display:flex; align-items:baseline; justify-content:space-between; gap:10px}
.hint{font-size:12px; color:var(--muted)}
.search{margin:12px 0 10px}
.search input{
  width:100%;
  padding:12px 14px;
  border-radius:14px;
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.7);
  color:var(--text);
  outline:none;
}
body.dark .search input{background: rgba(0,0,0,.18);}

.list{display:grid; gap:10px; margin-top:10px}
.item{
  display:flex; justify-content:space-between; gap:12px;
  padding:12px;
  border:1px solid var(--stroke);
  border-radius:16px;
  text-decoration:none;
  color:var(--text);
  background: rgba(255,255,255,.75);
}
body.dark .item{background: rgba(0,0,0,.14);}
.num{
  width:40px; height:40px;
  display:grid; place-items:center;
  border:1px solid var(--stroke);
  border-radius:14px;
  font-weight:800;
  background: var(--card);
}
.names{display:flex; flex-direction:column; gap:2px; flex:1}
.latin{font-weight:800}
.arti{font-size:12px; color:var(--muted)}
.arab{font-weight:800; font-size:18px}

.loading{margin-top:10px; color:var(--muted)}
.empty{margin-top:10px; color:var(--muted)}
.hidden{display:none}
.foot{margin-top:14px; font-size:12px; color:var(--muted2); text-align:center}

.detailHead{display:flex; align-items:center; gap:12px}
.detailTitle{display:flex; flex-direction:column; gap:2px}
.h1{font-size:20px; font-weight:900}
.meta{font-size:12px; color:var(--muted)}

.verses{display:grid; gap:10px; margin-top:12px}
.verse{
  border:1px solid var(--stroke);
  border-radius:16px;
  padding:12px;
  background: rgba(255,255,255,.75);
}
body.dark .verse{background: rgba(0,0,0,.14);}

.vtop{display:flex; align-items:center; justify-content:space-between; gap:10px}
.play{
  border:1px solid var(--stroke);
  border-radius:14px;
  padding:8px 10px;
  cursor:pointer;
  background: var(--card);
}
.arText{margin-top:10px; font-size:24px; line-height:1.8; text-align:right; font-family: "Amiri", serif;}
.latText{margin-top:8px; color:var(--muted); font-size:13px}
.idText{margin-top:8px; font-size:14px}

.selected{
  outline: 2px solid rgba(14,165,233,.28);
  border-color: rgba(14,165,233,.55);
}
body.dark .selected{
  outline: 2px solid rgba(34,197,94,.35);
  border-color: rgba(34,197,94,.55);
}

.lastBox{
  margin-top:10px;
  border:1px dashed var(--stroke);
  border-radius:16px;
  padding:12px;
  color:var(--muted);
}
.mt{margin-top:10px}

.prayBox{margin-top:12px; display:grid; gap:10px}
.prayItem{
  display:flex; align-items:center; justify-content:space-between;
  border:1px solid var(--stroke);
  border-radius:16px;
  padding:12px;
  background: rgba(255,255,255,.75);
}
body.dark .prayItem{background: rgba(0,0,0,.14);}
