:root {
  --bg-dark: rgba(10, 20, 35, 0.55);
  --brand: #25c4c4;       /* Turquoise to echo MIFASA paint */
  --accent: #00e3a2;      /* Accent glow */
  --text: #f4f7fb;
  --muted: #c7d1df;
  --danger: #ff4d6d;
}

* { box-sizing: border-box; }
html, body {
  height: 100%;
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  color: var(--text);
  background: #0b1a2a;
}

/* Background image */
#bg {
  position: fixed;
  inset: 0;
  background-image: url("assets/bg-mifasa-2026.jpg");
  background-size: cover;
  background-position: center;
  filter: contrast(1.05) saturate(1.05) brightness(0.9);
}

/* Cinematic overlay */
.overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(60% 60% at 50% 50%, rgba(0,0,0,0.2), rgba(0,0,0,0.75));
  backdrop-filter: blur(1px);
  pointer-events: none;
}

/* Branding */
.branding {
  position: absolute;
  top: 8vh;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  animation: fadeIn 900ms ease-out both;
}

.title {
  font-size: clamp(2.6rem, 6vw, 5rem);
  letter-spacing: 0.12em;
  font-weight: 800;
  margin: 0;
  text-transform: uppercase;
  color: var(--text);
  text-shadow:
    0 0 12px rgba(0,0,0,0.6),
    0 0 24px rgba(37,196,196,0.2);
}
.subtitle {
  margin-top: 0.6rem;
  font-size: clamp(1.1rem, 3vw, 1.6rem);
  color: var(--muted);
  letter-spacing: 0.35em;
}

/* Menu */
.menu {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(92vw, 480px);
  transform: translate(-50%, -40%);
  display: grid;
  gap: 14px;
  padding: 22px;
  background: linear-gradient(180deg, rgba(16,28,45,0.65), rgba(10,20,35,0.7));
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  box-shadow:
    0 20px 40px rgba(0,0,0,0.45),
    0 0 0 1px rgba(255,255,255,0.04) inset;
  animation: floatUp 800ms ease-out 300ms both;
}

.btn {
  appearance: none;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  color: var(--text);
  padding: 14px 18px;
  font-size: 1rem;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 120ms ease, background 160ms ease, box-shadow 160ms ease;
}
.btn:hover {
  background: rgba(255,255,255,0.12);
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(0,0,0,0.35);
}
.btn:active {
  transform: translateY(0);
}
.btn.primary {
  border-color: rgba(37,196,196,0.45);
  background: linear-gradient(180deg, rgba(37,196,196,0.20), rgba(0,227,162,0.15));
  box-shadow: 0 0 18px rgba(0,227,162,0.25);
}
.btn.danger {
  border-color: rgba(255,77,109,0.45);
  background: linear-gradient(180deg, rgba(255,77,109,0.18), rgba(255,77,109,0.12));
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0,0,0,0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
}
.modal.show {
  opacity: 1;
  pointer-events: auto;
}
.modal-content {
  width: min(92vw, 520px);
  background: linear-gradient(180deg, rgba(16,28,45,0.85), rgba(10,20,35,0.9));
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 24px 48px rgba(0,0,0,0.45);
  animation: pop 200ms ease-out;
}
.settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 12px;
}
.settings-grid label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
}
.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 16px;
}

/* Toast */
#toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  background: rgba(10,20,35,0.9);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 10px 20px rgba(0,0,0,0.35);
  font-size: 0.95rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-6px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}
@keyframes floatUp {
  from { opacity: 0; transform: translate(-50%, -30%); }
  to { opacity: 1; transform: translate(-50%, -40%); }
}
@keyframes pop {
  from { transform: scale(0.98); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* Responsive tweaks */
@media (max-width: 520px) {
  .settings-grid { grid-template-columns: 1fr; }
  .menu { transform: translate(-50%, -35%); }
}
