/* ================================================
   Suman - Coding Tutor | Global Stylesheet
   Brand: Dark Navy #0A0F2C | Electric Blue #00B4FF
   Fonts: Montserrat Bold + Source Code Pro
   ================================================ */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;900&family=Source+Code+Pro:wght@400;600&display=swap');

/* ---- CSS Variables ---- */
:root {
  --navy:       #0A0F2C;
  --navy-mid:   #0F1640;
  --navy-light: #162050;
  --blue:       #00B4FF;
  --blue-dim:   #0090cc;
  --blue-glow:  rgba(0, 180, 255, 0.15);
  --blue-line:  rgba(0, 180, 255, 0.3);
  --white:      #F0F6FF;
  --grey:       #8899BB;
  --card-bg:    rgba(15, 22, 64, 0.85);
  --border:     rgba(0, 180, 255, 0.2);
  --font-head:  'Montserrat', sans-serif;
  --font-code:  'Source Code Pro', monospace;
  --radius:     12px;
  --transition: 0.3s ease;
  --max-width:  1100px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background-color: var(--navy);
  color: var(--white);
  font-family: var(--font-head);
  font-size: 16px;
  line-height: 1.7;
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: var(--blue); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--white); }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ---- Background subtle grid ---- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,180,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,180,255,0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

/* ================================================
   NAVBAR
   ================================================ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 15, 44, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
}
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav-brand {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 1.2rem;
  color: var(--white);
  letter-spacing: -0.5px;
}
.nav-brand span { color: var(--blue); }
.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}
.nav-links a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--grey);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: color var(--transition);
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--blue);
  transition: width var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--white); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }
.nav-cta {
  background: var(--blue);
  color: var(--navy) !important;
  padding: 0.45rem 1.1rem;
  border-radius: 6px;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px;
  transition: background var(--transition), transform var(--transition) !important;
}
.nav-cta:hover { background: var(--white) !important; transform: translateY(-1px); }
.nav-cta::after { display: none !important; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.hamburger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: all var(--transition);
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav */
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 0;
  background: rgba(10, 15, 44, 0.98);
  border-top: 1px solid var(--border);
  padding: 1rem 2rem 1.5rem;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  color: var(--grey);
  font-weight: 600;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  transition: color var(--transition);
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav a:hover,
.mobile-nav a.active { color: var(--blue); }

/* ================================================
   SECTIONS + LAYOUT
   ================================================ */
.section {
  position: relative;
  z-index: 1;
  padding: 5rem 2rem;
}
.section--tight { padding: 3rem 2rem; }
.container {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* Section label */
.section-label {
  font-family: var(--font-code);
  font-size: 0.78rem;
  color: var(--blue);
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
  display: block;
}
.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 1.25rem;
  letter-spacing: -0.5px;
}
.section-title span { color: var(--blue); }
.section-sub {
  color: var(--grey);
  font-size: 1.05rem;
  max-width: 600px;
  margin-bottom: 3rem;
}

/* ================================================
   CARDS
   ================================================ */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
  position: relative;
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), transparent);
  opacity: 0;
  transition: opacity var(--transition);
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--blue-dim);
  box-shadow: 0 8px 32px rgba(0,180,255,0.1);
}
.card:hover::before { opacity: 1; }

/* Grid helpers */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }

/* ================================================
   BUTTONS
   ================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
}
.btn-primary {
  background: var(--blue);
  color: var(--navy);
}
.btn-primary:hover {
  background: var(--white);
  color: var(--navy);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,180,255,0.3);
}
.btn-outline {
  background: transparent;
  color: var(--white);
  border: 1.5px solid var(--blue-line);
}
.btn-outline:hover {
  background: var(--blue-glow);
  border-color: var(--blue);
  color: var(--blue);
  transform: translateY(-2px);
}

/* ================================================
   BLUE DIVIDER / ACCENT LINE
   ================================================ */
.accent-line {
  width: 48px; height: 3px;
  background: var(--blue);
  border-radius: 2px;
  margin-bottom: 1.5rem;
}

/* ================================================
   BADGE / TAG
   ================================================ */
.badge {
  display: inline-block;
  font-family: var(--font-code);
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--blue-glow);
  color: var(--blue);
  border: 1px solid var(--blue-line);
  border-radius: 4px;
  padding: 0.2rem 0.6rem;
  letter-spacing: 0.5px;
}

/* ================================================
   FOOTER
   ================================================ */
footer {
  position: relative;
  z-index: 1;
  background: var(--navy-mid);
  border-top: 1px solid var(--border);
  padding: 1.25rem 2rem;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 0;
}
.footer-brand .nav-brand { font-size: 1.1rem; margin-bottom: 0; }
.footer-links ul {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  align-items: center;
}
.footer-links a { color: var(--grey); font-size: 0.85rem; transition: color var(--transition); }
.footer-links a:hover { color: var(--white); }
.footer-contact { display: flex; flex-direction: row; flex-wrap: wrap; gap: 0.5rem 1.25rem; align-items: center; }
.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--grey);
  font-size: 0.82rem;
  margin-bottom: 0;
  transition: color var(--transition);
}
.footer-contact-item:hover { color: var(--white); }
.footer-bottom {
  max-width: var(--max-width);
  margin: 0.75rem auto 0;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.footer-bottom p { color: var(--grey); font-size: 0.78rem; }
.footer-socials { display: flex; gap: 0.75rem; }
.footer-socials a {
  color: var(--grey);
  transition: color var(--transition);
  display: flex; align-items: center;
}
.footer-socials a:hover { color: var(--blue); }

/* ================================================
   PAGE HERO (inner pages)
   ================================================ */
.page-hero {
  position: relative;
  z-index: 1;
  padding: 4rem 2rem 3rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, var(--navy-mid) 0%, var(--navy) 100%);
}
.page-hero .container { display: flex; flex-direction: column; gap: 0.5rem; }
.page-hero .section-label { margin-bottom: 0.25rem; }
.page-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -1px;
}
.page-hero h1 span { color: var(--blue); }
.page-hero p { color: var(--grey); font-size: 1.05rem; max-width: 560px; margin-top: 0.5rem; }

/* ================================================
   RESPONSIVE
   ================================================ */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { flex-direction: column; gap: 0.75rem; }
}

@media (max-width: 640px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; gap: 0.5rem; }
  .section { padding: 3.5rem 1.25rem; }
  .page-hero { padding: 3rem 1.25rem 2rem; }
  footer { padding: 1.25rem; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ================================================
   ANIMATIONS
   ================================================ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes pulse-blue {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,180,255,0.4); }
  50%       { box-shadow: 0 0 0 8px rgba(0,180,255,0); }
}
.animate-up { animation: fadeUp 0.7s ease forwards; }
.animate-in { animation: fadeIn 0.6s ease forwards; }

/* Staggered children */
.stagger > *:nth-child(1) { animation-delay: 0.1s; opacity: 0; animation: fadeUp 0.6s ease forwards 0.1s; }
.stagger > *:nth-child(2) { opacity: 0; animation: fadeUp 0.6s ease forwards 0.2s; }
.stagger > *:nth-child(3) { opacity: 0; animation: fadeUp 0.6s ease forwards 0.3s; }
.stagger > *:nth-child(4) { opacity: 0; animation: fadeUp 0.6s ease forwards 0.4s; }
.stagger > *:nth-child(5) { opacity: 0; animation: fadeUp 0.6s ease forwards 0.5s; }
.stagger > *:nth-child(6) { opacity: 0; animation: fadeUp 0.6s ease forwards 0.6s; }
