/* Minimal, clean, Mentimeter-inspired vibe */
:root {
  --bg: #0f172a;
  --card: #111827;
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #4f46e5;
  --good: #22c55e;
  --bad: #ef4444;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
  background: radial-gradient(1000px 600px at 80% -10%, #1f2937 0%, var(--bg) 60%);
  color: var(--text);
}

.header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 24px; background: rgba(17,24,39,0.8); backdrop-filter: blur(6px);
  position: sticky; top: 0; border-bottom: 1px solid #1f2937;
}
.brand { font-weight: 700; letter-spacing: .3px; }
.nav a { color: var(--muted); margin-left: 16px; text-decoration: none; }
.nav a:hover { color: var(--text); }

.container { max-width: 900px; margin: 32px auto; padding: 0 16px; }

.card {
  background: linear-gradient(180deg, rgba(17,24,39,0.9), rgba(15,23,42,0.9));
  border: 1px solid #1f2937; border-radius: 16px;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
}

h1,h2 { margin-top: 0; }
.alert { background: rgba(239,68,68,.2); border:1px solid #b91c1c; padding: 12px; border-radius: 8px; margin-bottom: 16px; }

.form label { display:block; margin: 8px 0; color: var(--muted); }
.form input[type="text"] {
  width: 100%; padding: 12px; border-radius: 12px; border: 1px solid #334155;
  background: #0b1220; color: var(--text);
}
.btn {
  display:inline-block; padding: 10px 16px; border-radius: 999px; border: 1px solid #334155; color: var(--text);
  text-decoration: none; background: #0b1220; transition: .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn.primary { background: var(--accent); border-color: var(--accent); }

.quiz-header { display:flex; justify-content: space-between; align-items: center; margin-bottom: 8px;}
.timer { font-weight: 600; color: var(--muted); }

.question { padding: 14px 0; border-bottom: 1px dashed #273449; }
.q-text { font-size: 18px; margin-bottom: 8px; }
.q-number { color: var(--muted); }

.options { display: grid; grid-template-columns: 1fr; gap: 8px; }
.option {
  display:flex; align-items:center; gap:10px; padding: 10px; border:1px solid #263243; border-radius: 12px;
  background:#0b1220; cursor:pointer;
}
.option input { transform: scale(1.2); }

.actions { margin-top: 16px; display:flex; gap:12px; }

.note { color: var(--muted); margin-top: 12px; }

.score-grid {
  display:grid; grid-template-columns: repeat(auto-fit,minmax(120px,1fr)); gap:12px;
}
.score-box {
  background:#0b1220; border:1px solid #273449; border-radius: 12px; padding:12px; text-align:center;
}
.score-box .label { color: var(--muted); font-size: 12px; }
.score-box .value { font-size: 20px; font-weight: 700; }
.value.good{ color: var(--good); }
.value.bad{ color: var(--bad); }
.total .big { font-size: 28px; }

.table { width:100%; border-collapse: collapse; }
.table th, .table td { text-align:left; padding:10px; border-bottom:1px solid #273449; }

.footer { text-align:center; color: var(--muted); padding: 24px; }

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.modal-overlay.open { display: flex; }

.modal {
  position: relative;
  background: #0b1220;
  border: 1px solid #273449;
  border-radius: 16px;
  padding: 24px;
  width: min(90vw, 520px);
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}

.modal h3 { margin: 0 0 8px; }
.modal-text { color: var(--text); margin: 0 0 16px; }

.modal-close {
  position: absolute;
  top: 10px;
  right: 14px;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 22px;
  cursor: pointer;
}
