
/* CATEGORY COLORS */
.orange {
  --category-color: #ea580c;
  --category-background: #e6ae69;
}

.blue {
  --category-color: #2563eb;
  --category-background: #7daeee;
}

.yellow {
  --category-color: #e5d363;
  --category-background: #fefce8;
}

.green {
  --category-color: #15803d;
  --category-background: #bbf7d0;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    Arial,
    Helvetica,
    sans-serif;
  color: #172554;
  background: #f7faff;
}

/* NAVIGATION */
header {
  position: sticky;
  top: 0;
  z-index: 100;

  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;

  padding: 12px clamp(18px, 5vw, 70px);

  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #dbeafe;
  box-shadow: 0 3px 14px rgba(30, 64, 175, 0.08);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo img {
  width: 52px;
  height: 52px;
  object-fit: contain;
}

.logo-name {
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 800;
  color: #15803d;
  white-space: nowrap;
}

nav {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

nav a {
  display: block;
  padding: 10px 14px;

  border-radius: 10px;

  color: #1e3a8a;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;

  transition:
    background-color 0.2s,
    color 0.2s,
    transform 0.2s;
}

nav a:hover {
  color: white;
  background: #2563eb;
  transform: translateY(-2px);
}

nav .account-nav-link {
  color: white;
  background: #16a34a;
}

nav .account-nav-link:hover {
  background: #15803d;
}

/* HERO */
.hero {
  min-height: 360px;
  padding: 50px 20px;

  display: flex;
  justify-content: center;
  align-items: center;

  text-align: center;

  background-image:
    linear-gradient(
      rgba(239, 246, 255, 0.3),
      rgba(239, 246, 255, 0.3)
    ),
    url("images/home/headerImg.png");

  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;

  box-sizing: border-box;
}

.hero-content {
  width: min(760px, 92%);
  padding: clamp(24px, 4vw, 44px);

  background: rgba(255, 255, 255, 0.4);
  
  border-radius: 24px;
  box-shadow: 0 12px 35px rgba(30, 64, 175, 0.16);
}

.hero-label {
  margin: 0 0 12px;

  color: #15803d;
  font-size: clamp(14px, 1.6vw, 18px);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero h1 {
  margin: 0;

  color: #1d4ed8;
  font-size: clamp(34px, 5vw, 60px);
  font-weight: 900;
  line-height: 1.08;
}

.hero-description {
  max-width: 650px;
  margin: 20px auto 0;

  color: #111827;
  font-size: clamp(17px, 2vw, 22px);
  font-weight: 700;
  line-height: 1.55;
}

.resources-intro {
  width: min(760px, 90%);
  margin: 0 auto;
  padding: 55px 0 0;

  text-align: center;
}

.resources-intro h2 {
  margin: 0;

  color: #1e3a8a;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
}

.resources-intro > p:last-child {
  margin: 15px auto 0;

  color: #334155;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.55;
}

/* RESOURCE CATEGORIES */
.categories {
  width: min(1200px, 92%);
  margin: 0 auto;
  padding: 55px 0;

  display: grid;
  grid-template-columns:
    repeat(3, minmax(0, 1fr));
  gap: 24px;

  align-items: stretch;
}

.card {

  scroll-margin-top: 130px;
  margin: 0;
  padding: 26px;

  color: #172554;
  background: var(--category-background);

  border: 2px solid rgba(148, 163, 184, 0.25);
  border-top: 8px solid var(--category-color);
  border-radius: 20px;

  box-shadow: 0 8px 24px rgba(30, 64, 175, 0.1);

  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 14px 30px rgba(30, 64, 175, 0.16);
}

.card h2 {
  margin: 0 0 20px;

  color: var(--category-color);
  font-size: 27px;
  text-align: center;
}

.card ul {
  margin: 0;
  padding: 0;

  display: grid;
  gap: 12px;
}

.card li {
  list-style: none;
}

.card li .resource-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 15px 16px;

  color: #172554;
  background: white;

  border: 2px solid transparent;
  border-radius: 12px;

  font-size: 17px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;

  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.08);

  transition:
    color 0.2s,
    border-color 0.2s,
    transform 0.2s;
}

.card li a.resource-link:hover{
  color: var(--category-color);
  border-color: var(--category-color);
  transform: translateY(-2px);
}

.resource-name {
  display: block;

  font-size: clamp(20px, 2vw, 25px);
  font-weight: 800;
  line-height: 1.2;
}

.resource-description {
  display: block;

  color: #475569;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}

.coming-soon-resource {
  cursor: default;
  opacity: 0.78;
}

.coming-soon-badge {
  display: inline-block;
  margin-top: 4px;
  padding: 5px 10px;

  color: #713f12;
  background: #fef08a;

  border-radius: 999px;

  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* WHY KIDS CLASSROOM GAMES */
.why-kcg {
  padding: 60px clamp(20px, 5vw, 70px);

  background: #eef6ff;
  border-top: 1px solid #dbeafe;
}

.why-kcg-heading {
  width: min(760px, 100%);
  margin: 0 auto 35px;

  text-align: center;
}

.why-kcg-heading h2 {
  margin: 0;

  color: #1e3a8a;
  font-size: clamp(28px, 4vw, 42px);
}

.why-kcg-heading p {
  margin: 15px auto 0;

  color: #334155;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.6;
}

.why-kcg-grid {
  width: min(1100px, 100%);
  margin: 0 auto;

  display: grid;
  grid-template-columns:
    repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.why-kcg-card {
  padding: 25px;

  background: white;
  border: 2px solid #dbeafe;
  border-radius: 18px;

  text-align: center;
  box-shadow: 0 7px 20px rgba(30, 64, 175, 0.09);
}

.why-kcg-card:nth-child(1) {
  border-top: 7px solid #16a34a;
}

.why-kcg-card:nth-child(2) {
  border-top: 7px solid #2563eb;
}

.why-kcg-card:nth-child(3) {
  border-top: 7px solid #f97316;
}

.why-kcg-card h3 {
  margin: 0 0 12px;

  color: #172554;
  font-size: 22px;
}

.why-kcg-card p {
  margin: 0;

  color: #475569;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.6;
}

/* FOOTER */
.footer {
  margin-top: 20px;
  padding: 45px clamp(20px, 5vw, 70px) 16px;

  color: #dbeafe;
  background: #172554;

  border-top: 6px solid #2563eb;
}

.footer-container {
  width: min(1200px, 100%);
  margin: 0 auto;
}

.footer-inner {
  display: grid;
  grid-template-columns:
    1.2fr 0.8fr 1.2fr;
  gap: clamp(25px, 5vw, 70px);
}

.footer-section {
  min-width: 0;
}

.footer-section h3 {
  margin: 0 0 14px;

  color: white;
  font-size: 20px;
}

.footer-section p {
  margin: 0;

  color: #bfdbfe;
  line-height: 1.6;
}

.footer-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
}

.footer-links a,
.footer-email {
  color: #bfdbfe;
  font-weight: 700;
  text-decoration: none;
}

.footer-links a:hover,
.footer-email:hover {
  color: white;
  text-decoration: underline;
}

.footer-email {
  display: inline-block;
  margin-top: 12px;
  overflow-wrap: anywhere;
}

.footer-bottom {
  margin-top: 35px;
  padding-top: 15px;

  text-align: center;

  border-top: 1px solid rgba(191, 219, 254, 0.3);
}

.footer-bottom p {
  margin: 0;

  color: #93c5fd;
  font-size: 13px;
}

.logo:focus-visible,
nav a:focus-visible,
.card li a:focus-visible,
.footer a:focus-visible {
  outline: 4px solid #f93e3e;
  outline-offset: 3px;
}

/* RESPONSIVE LAYOUT */
@media (max-width: 900px) {
  header {
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
  }

  nav {
    justify-content: center;
    width: 100%;
  }

  .categories {
    grid-template-columns: 1fr;
    width: min(650px, 92%);
    padding: 35px 0;
  }

  .hero {
    min-height: 330px;
    padding: 35px 16px;
  }

  .why-kcg-grid {
    grid-template-columns: 1fr;
    width: min(650px, 100%);
  }  

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

@media (max-width: 520px) {
  .logo img {
    width: 42px;
    height: 42px;
  }

  .logo-name {
    font-size: 18px;
  }

  nav {
    gap: 5px;
  }

  nav a {
    padding: 8px 9px;
    font-size: 13px;
  }

  .hero {
    min-height: 300px;
    padding: 24px 12px;
  }

  .hero-content {
    width: 100%;
    padding: 24px 16px;
    border-radius: 18px;
  }

  .hero h1 {
    font-size: 34px;
  }

  .hero-description {
    font-size: 17px;
  }

  .card {
    padding: 20px;
  }

  .why-kcg {
    padding: 40px 16px;
  }

  .why-kcg-card {
    padding: 20px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}