:root {
  --bg-gradient: radial-gradient(circle at top right, #3b0000, #0a0000);
  --primary-red: #ff1e2d;
  --primary-glow: rgba(255, 0, 0, 0.6);
  --card-bg: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 255, 255, 0.1);
  --text: #ffffff;
}

/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
  transition: all 0.25s ease;
}

body {
  background: var(--bg-gradient);
  color: var(--text);
  min-height: 100vh;
}

/* WATERMARK */
.watermark {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.05;
  width: 420px;
  pointer-events: none;
}

/* HEADER */
header {
  display: flex;
  align-items: center;
  padding: 20px 40px;
}

header img {
  height: 55px;
}

.header-text {
  flex: 1;
  text-align: center;
}

.header-text h1 {
  text-shadow: 0 0 15px var(--primary-glow);
}

.logout-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: white;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
}

.logout-btn:hover {
  background: var(--primary-red);
  box-shadow: 0 0 10px var(--primary-glow);
}

/* MAIN */
main {
  padding: 20px 40px;
}

/* FULL TEST BUTTON */
.full-test {
  background: linear-gradient(135deg, #ff1e2d, #7a0c0c);
  padding: 18px;
  text-align: center;
  border-radius: 12px;
  cursor: pointer;
  margin: 30px auto;
  width: 320px;
  box-shadow: 0 0 25px var(--primary-glow);
  transition: all 0.3s ease;
}

.full-test:hover {
  transform: scale(1.03);
  box-shadow: 0 0 40px var(--primary-glow);
}

/* GRID */
.section {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  padding: 20px 0;
}

/* CARDS */
.card {
  background: var(--card-bg);
  padding: 20px;
  text-align: center;
  border-radius: 12px;
  border: 1px solid var(--border);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.card i {
  font-size: 22px;
  color: var(--primary-red);
}

.card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 0 20px var(--primary-glow);
}

/* BIG CARD */
.center-section {
  display: flex;
  justify-content: center;
  gap: 25px;
  margin-top: 20px;
}

.big-card {
  background: var(--card-bg);
  padding: 20px;
  border-radius: 12px;
  width: 180px;
  text-align: center;
  border: 1px solid var(--border);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: all 0.3s ease;
}

.big-card i {
  font-size: 26px;
  color: var(--primary-red);
}

.big-card:hover {
  transform: scale(1.05);
  box-shadow: 0 0 25px var(--primary-glow);
}



@keyframes shimmer {
  0% { background-position: 0% center; }
  100% { background-position: 220% center; }
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .section {
    grid-template-columns: 1fr;
  }

  .center-section {
    flex-direction: column;
    align-items: center;
  }


}

/* QUOTE RECTANGLE */
.quote-rect {
  width: 80%;
  max-width: 700px;
  margin: 20px auto 40px auto;
  padding: 20px 30px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  text-align: center;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(255, 0, 0, 0.3);
  position: relative;
}

#quoteText {
  font-size: 20px;
  color: #ddd;
  font-style: italic;
  text-shadow: 0 0 12px rgba(255, 0, 0, 0.5);
  opacity: 0;
  position: absolute;
}

/* WHATSAPP BUTTON */
a.whatsapp-btn {
  display: inline-block;
  background: #25D366;
  color: white;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  margin-top: 15px;
  font-size: 16px;
}

a.whatsapp-btn i {
  margin-right: 8px;
}

/* NEW CARDS (Syllabus & Sample Papers) */
.section .card:nth-last-child(-n+2) {
  /* Ensures new cards use the same hover effect as old ones */
  cursor: pointer;
  transition: all 0.3s ease;
}

.section .card:nth-last-child(-n+2):hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 0 20px var(--primary-glow);
}

/* Center two small blocks in one row */
.row-center {
  display: flex;
  justify-content: center; /* center horizontally */
  gap: 20px;               /* space between blocks */
  margin-top: 20px;
  flex-wrap: wrap;          /* for mobile responsiveness */
}

/* Fix spacing for Previous Year & Sample Papers row */
.row-center {
  display: flex;
  justify-content: center; /* center horizontally */
  gap: 10px;                /* horizontal space between the two blocks */
  margin-top: 20px;
  flex-wrap: wrap;          /* stack on small screens */
}

.row-center .full-test {
  margin: 0; /* remove auto centering that breaks flex */
}

/* Top row: countdown + stacked blocks */
.home-top-row {
  display: flex;
  justify-content: center;
  align-items: stretch; /* make countdown same height as stacked right */
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

/* Top row: countdown + stacked blocks */
.home-top-row {
  display: flex;
  justify-content: center;
  align-items: stretch; /* make countdown same height as stacked right */
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

/* Countdown block style (like notes cards) */
.countdown-block {
  flex: 0 0 200px; /* width of countdown block */
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Countdown inner elements */
.countdown-block #countdown-title {
  font-size: 14px;
  margin-bottom: 10px;
}

.countdown-block #countdown-days {
  font-size: 40px;
  font-weight: bold;
}

.countdown-block #countdown-hms {
  font-size: 18px;
  margin-top: 5px;
}

.countdown-block #countdown-footer {
  margin-top: 10px;
  font-size: 16px;
  font-weight: bold;
}

/* Right stacked blocks */
.home-right-stack {
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 0 0 200px; /* same width as countdown block */
}

/* Make sure .full-test keeps its size */
.home-right-stack .full-test {
  margin: 0; /* remove auto centering */
}

.keam-official-block {
    width: 200px; /* same as countdown block */
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: all 0.3s ease;
}

.keam-official-block i {
    font-size: 22px;
    color: #ffffff;
    margin-bottom: 5px;
}

.keam-official-block:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 0 20px rgba(255,0,0,0.3);
}

/* BACKDROP (NOT FULL SCREEN UI, JUST DARK OVERLAY) */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

/* 🔥 BIGGER POPUP */
.popup-box {
  position: relative;
  width: 420px;   /* increased size */
  background: rgba(211, 169, 169, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 18px;
  padding: 18px;
  text-align: center;
  backdrop-filter: blur(12px);
  box-shadow: 0 0 30px rgba(91, 10, 10, 0.5);
}

/* IMAGE */
.popup-image {
  width: 100%;
  border-radius: 12px;
  margin-bottom: 14px;
}

/* REGISTER BUTTON */
.register-btn {
  display: inline-block;
  padding: 12px 18px;
  background: linear-gradient(135deg, #ff1a1a, #990000);
  color: white;
  text-decoration: none;
  font-weight: bold;
  border-radius: 10px;
  transition: 0.3s;
}

.register-btn:hover {
  transform: scale(1.05);
}

/* ❌ BLACK CLOSE BUTTON */
.close-btn {
  position: absolute;
  top: 8px;
  right: 10px;
  font-size: 26px;
  color: rgb(251, 13, 13);   /* changed to black */
  cursor: pointer;
  font-weight: bold;
}

/* FINAL LAP REVISION CARD - LARGE THEMED */
.final-lap-card {
  width: 80%;
  max-width: 700px;
  margin: 0 auto 30px auto;
  padding: 25px;
  background: linear-gradient(135deg, rgba(255, 30, 45, 0.2), rgba(122, 12, 12, 0.4));
  border: 2px solid var(--primary-red);
  border-radius: 15px;
  text-align: center;
  cursor: pointer;
  backdrop-filter: blur(10px);
  box-shadow: 0 0 20px var(--primary-glow);
  transition: all 0.3s ease;
}

.final-lap-card:hover {
  transform: scale(1.02);
  box-shadow: 0 0 35px var(--primary-glow);
  background: linear-gradient(135deg, rgba(255, 30, 45, 0.3), rgba(122, 12, 12, 0.5));
}

.final-lap-card i {
  font-size: 35px;
  color: var(--primary-red);
  margin-bottom: 10px;
}

.final-lap-card h2 {
  font-size: 28px;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 0 0 10px var(--primary-glow);
}

.final-lap-card p {
  margin-top: 5px;
  opacity: 0.8;
  font-style: italic;
}