/* Imtihan — midnight violet #4C1D95 on off-white #F8FAFC, clean minimal UI. */
:root {
  --violet: #4c1d95;
  --violet-dark: #3b0764;
  --violet-deep: #2b1058;
  --violet-tint: #ede9fe;
  --violet-wash: #f5f3ff;
  --base: #f8fafc;
  --ink: #1e0a3c;
  --grey: #64748b;
  --grey-line: #e2e8f0;
  --amber: #b45309;
  --amber-tint: #fef3c7;
  --red: #dc2626;
  --red-tint: #fee2e2;
  --white: #ffffff;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Inter, sans-serif;
  background: var(--base);
  color: var(--ink);
  line-height: 1.5;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: var(--white);
  border-bottom: 1px solid var(--grey-line);
}

.brand { display: flex; align-items: center; gap: 12px; font-size: 24px; }
.logo {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--violet); color: var(--white); font-weight: 800;
}
.tagline { margin: 0; color: var(--grey); }

main { max-width: 760px; margin: 0 auto; padding: 24px 16px 48px; }

.hero {
  position: relative;
  background: var(--violet);
  color: var(--white);
  border-radius: 24px;
  padding: 28px;
  overflow: hidden;
}
.hero h1 { margin: 4px 0 8px; font-size: 36px; line-height: 1.1; }
.hero p { margin: 0; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.12em; }
.hero-ring {
  margin-top: 20px;
  display: inline-flex; align-items: baseline; gap: 8px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px; padding: 8px 18px;
}
.hero-ring span { font-size: 26px; font-weight: 800; }
.hero-ring small { opacity: 0.85; }
.sample-note { margin-top: 20px !important; font-size: 13px; opacity: 0.85; }

.panel {
  background: var(--white);
  border: 1px solid var(--grey-line);
  border-radius: 24px;
  padding: 24px;
  margin-top: 20px;
}
.panel h2 { margin: 0 0 4px; font-size: 26px; }
.panel h3 { margin: 16px 0 0; font-size: 22px; }
.muted { color: var(--grey); margin: 4px 0 12px; }

.field-label { display: block; font-weight: 600; margin: 14px 0 6px; }
input[type="search"] {
  width: 100%; padding: 12px 16px; font-size: 16px;
  border: 2px solid var(--grey-line); border-radius: 14px;
  background: var(--base); color: var(--ink);
}
input[type="search"]:focus { outline: none; border-color: var(--violet); }

.paper-list, .bank-list, .topic-list { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.paper-row {
  display: flex; align-items: center; gap: 12px; width: 100%;
  text-align: left; cursor: pointer; background: var(--white);
  border: 2px solid var(--grey-line); border-radius: 16px; padding: 14px 16px;
  font-size: 16px; color: var(--ink);
}
.paper-row.active { border-color: var(--violet); background: var(--violet-wash); }
.row-main { flex: 1; display: flex; flex-direction: column; }
.row-main small { color: var(--grey); font-size: 13px; }
.row-ring { font-weight: 800; color: var(--violet-dark); }
.row-chip {
  font-size: 12px; font-weight: 800; padding: 6px 12px; border-radius: 999px;
  background: var(--violet-tint); color: var(--violet-dark); white-space: nowrap;
}
.row-chip.soon { background: var(--red-tint); color: var(--red); }
.row-chip.near { background: var(--amber-tint); color: var(--amber); }

.progress-track { height: 12px; background: var(--violet-wash); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--violet); border-radius: 999px; transition: width 0.3s; }

.topic {
  display: flex; align-items: center; gap: 12px;
  border: 2px solid var(--grey-line); border-radius: 14px; padding: 12px 14px;
  cursor: pointer; font-weight: 600;
}
.topic.done { background: var(--violet-tint); color: var(--grey); }
.topic.done span { text-decoration: line-through; }
.topic input { width: 20px; height: 20px; accent-color: var(--violet); }

.timer-card {
  margin-top: 20px; background: var(--violet); color: var(--white);
  border-radius: 20px; padding: 24px; text-align: center;
}
.timer { font-size: 64px; font-weight: 800; margin: 8px 0; letter-spacing: 0.02em; }
.timer-card .muted { color: var(--violet-tint); }
.timer-actions { display: flex; gap: 12px; justify-content: center; margin-top: 12px; }
.btn-primary, .btn-ghost, .open-btn {
  border: none; cursor: pointer; font-size: 16px; font-weight: 700;
  border-radius: 999px; padding: 12px 28px;
}
.btn-primary { background: var(--white); color: var(--violet-dark); }
.btn-ghost { background: transparent; color: var(--white); border: 2px solid rgba(255, 255, 255, 0.6); }
.open-btn { background: var(--violet); color: var(--white); padding: 10px 20px; }

.bank-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border: 2px solid var(--grey-line); border-radius: 16px; padding: 14px 16px;
}
.bank-row small { display: block; color: var(--grey); }

.last-night {
  margin-top: 20px; background: var(--violet); color: var(--white);
  border-radius: 20px; padding: 20px 24px;
}
.last-night p:last-child { margin: 8px 0 0; font-size: 18px; font-weight: 600; }

.empty { color: var(--grey); }
footer { text-align: center; color: var(--grey); padding: 0 16px 32px; font-size: 14px; }
