/* =====================
   ROOT VARIABLES
===================== */
:root {
  --primary: #00f5ff;
  --secondary: #1dd1a1;
  --accent: #48dbfb;
  --danger: #ff6b6b;
  --success: #1dd1a1;

  --dark-bg: #050b18;
  --dark-glass: rgba(10, 20, 50, 0.75);
  --light-bg: #f4f9ff;
  --light-glass: rgba(255, 255, 255, 0.75);

  --blur: blur(18px);
  --radius: 18px;
  --shadow: 0 10px 40px rgba(0, 255, 255, 0.25);
}

/* =====================
   BASE RESET
===================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", system-ui, sans-serif;
  background: var(--dark-bg);
  color: #eafcff;
  min-height: 100vh;
  overflow-x: hidden;
  transition: background 0.4s, color 0.4s;
}

/* =====================
   THEMES
===================== */
body.light-theme {
  background: var(--light-bg);
  color: #111;
}

body.light-theme .glass {
  background: var(--light-glass);
  color: #000;
}

/* =====================
   GENERAL UI
===================== */
.screen {
  display: none;
  padding: 30px;
}

.screen.active {
  display: block;
}

.glass {
  background: var(--dark-glass);
  backdrop-filter: var(--blur);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* =====================
   HOME / WELCOME
===================== */
.background-slider {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-size: cover;
  background-position: center;
  animation: bgSlide 15s infinite;
  filter: brightness(0.35);
}

@keyframes bgSlide {
  0% {
    background-image: url("assets/bg1.jpg");
  }
  33% {
    background-image: url("assets/bg2.jpg");
  }
  66% {
    background-image: url("assets/bg3.jpg");
  }
}

.home-header {
  max-width: 900px;
  margin: auto;
  padding: 40px;
  text-align: center;
}

.app-logo {
  width: 90px;
  margin-bottom: 15px;
}

.app-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  color: var(--primary);
  text-shadow: 0 0 25px rgba(0, 255, 255, 0.6);
}

.app-title span {
  display: block;
  font-size: 1.0rem;
  letter-spacing: 2px;
  margin-top: 10px;
}

.app-description {
  margin-top: 20px;
  font-size: 1.05rem;
  line-height: 1.6;
  opacity: 0.9;
}

.app-logo {
  width: 110px;
  height: 130px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--primary);
  background: rgba(255, 255, 255, 0.15);
  padding: 6px;
  box-shadow: 0 0 25px rgba(0, 255, 255, 0.6);
}


/* =====================
   LOGIN CARD
===================== */
.login-card {
  max-width: 380px;
  margin: 40px auto;
  padding: 30px;
}

.login-card h2 {
  text-align: center;
  margin-bottom: 15px;
  color: var(--accent);
}

label {
  font-size: 0.9rem;
  margin-top: 10px;
  display: block;
}

input,
select {
  width: 100%;
  padding: 12px;
  margin-top: 6px;
  border-radius: 10px;
  border: none;
  outline: none;
  background: rgba(255, 255, 255, 0.08);
  color: blue;
}

button {
  margin-top: 15px;
  padding: 12px;
  width: 100%;
  border-radius: 12px;
  border: none;
  font-weight: bold;
  cursor: pointer;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #000;
}

button:hover {
  opacity: 0.9;
}

.admin-link {
  text-align: center;
  margin-top: 12px;
}

.admin-link a {
  color: var(--primary);
  text-decoration: none;
}

/* =====================
   RULES
===================== */
.rules {
  max-width: 600px;
  margin: 30px auto;
  padding: 25px;
}

.rules h3 {
  color: var(--secondary);
  margin-bottom: 10px;
}

.rules ul {
  list-style: none;
}

.rules li {
  margin-bottom: 8px;
  opacity: 0.9;
}

/* =====================
   FOOTER
===================== */
.footer {
  text-align: center;
  margin-top: 40px;
  font-size: 0.85rem;
  opacity: 0.8;
}

.footer a {
  color: var(--primary);
  text-decoration: none;
}

.social-icons span {
  margin: 0 6px;
  cursor: pointer;
}

/* =====================
   EXAM PAGE
===================== */
.exam-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 25px;
}

.timer {
  font-size: 1.2rem;
  color: var(--primary);
}

.exam-controls button {
  width: auto;
  padding: 8px 12px;
  margin-left: 8px;
}

.exam-body {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 20px;
  margin-top: 20px;
}

.question-section {
  padding: 25px;
}

.options label {
  display: block;
  margin: 10px 0;
  cursor: pointer;
}

.nav-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}

/* =====================
   QUESTION GRID
===================== */
.question-grid {
  padding: 15px;
}

.question-grid h4 {
  text-align: center;
  margin-bottom: 10px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.grid button {
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  padding: 8px;
}

.grid button.answered {
  background: cyan;
  color: #000;
}

/* =====================
   REVIEW
===================== */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
  gap: 10px;
  padding: 20px;
}

.review-actions {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 15px;
}

/* =====================
   CERTIFICATE
===================== */
.certificate-frame {
  max-width: 700px;
  margin: auto;
  padding: 40px;
  text-align: center;
  background: linear-gradient(135deg, #ffffff, #e6ffff);
  color: #000;
  border: 8px double #00cfff;
}

.certificate-frame h1 {
  font-size: 2.4rem;
  margin-bottom: 15px;
}

.certificate-frame h2 {
  margin: 10px 0;
}

.certificate-actions {
  margin-top: 25px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

/* =====================
   CONFETTI
===================== */
.confetti {
  position: fixed;
  inset: 0;
  background: url("assets/confetti.gif") center/cover;
  pointer-events: none;
}

/* =====================
   PAYMENT
===================== */
.payment-card {
  max-width: 400px;
  margin: auto;
  padding: 30px;
  text-align: center;
}
