/* =========================================================
   CodeNext IT Coaching Institute — Shared Stylesheet
   Design tokens: white base, blue gradient accents, premium feel
   ========================================================= */

:root {
  /* Colors */
  --color-bg: #ffffff;
  --color-bg-soft: #f6f9ff;
  --color-ink: #0f172a;
  --color-muted: #5b6b85;
  --color-border: #e6ebf5;
  --color-primary: #2451e8;
  --color-primary-dark: #15309b;
  --color-primary-light: #5d86ff;
  --color-accent: #00c2a8;
  --gradient-primary: linear-gradient(135deg, #2451e8 0%, #15309b 100%);
  --gradient-soft: linear-gradient(135deg, #eef3ff 0%, #ffffff 60%);
  --gradient-hero: linear-gradient(120deg, #0f1f5c 0%, #2451e8 55%, #4f7dff 100%);

  /* Typography */
  --font-heading: "Sora", sans-serif;
  --font-body: "Inter", sans-serif;

  /* Radius & shadow */
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-soft: 0 10px 30px rgba(15, 31, 92, 0.08);
  --shadow-card: 0 8px 24px rgba(15, 31, 92, 0.10);

  /* Layout */
  --header-height: 76px;
}

/* =========================================================
   Base / Reset
   ========================================================= */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--color-ink);
  background-color: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-ink);
  line-height: 1.25;
}

p { color: var(--color-muted); }

a { text-decoration: none; }

img { max-width: 100%; height: auto; }

.section { padding: 84px 0; }
.section-sm { padding: 56px 0; }

.bg-soft { background: var(--color-bg-soft); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-primary);
  background: rgba(36, 81, 232, 0.08);
  padding: 6px 16px;
  border-radius: 50px;
  margin-bottom: 16px;
}

.section-title { font-size: clamp(1.8rem, 1.4rem + 1.6vw, 2.6rem); margin-bottom: 14px; }
.section-subtitle { color: var(--color-muted); max-width: 640px; }

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  background: var(--color-primary);
  color: #fff;
  padding: 10px 18px;
  z-index: 2000;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
  top: 0;
}

/* Focus visibility */
a:focus-visible,
button:focus-visible,
.form-control:focus-visible {
  outline: 3px solid var(--color-primary-light);
  outline-offset: 2px;
}

/* =========================================================
   Buttons
   ========================================================= */
.btn-gradient {
  background: var(--gradient-primary);
  color: #fff;
  border: none;
  border-radius: 50px;
  padding: 12px 28px;
  font-weight: 600;
  font-family: var(--font-heading);
  box-shadow: 0 10px 24px rgba(36, 81, 232, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}
.btn-gradient:hover,
.btn-gradient:focus {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(36, 81, 232, 0.36);
}

.btn-outline-brand {
  border: 1.5px solid var(--color-primary);
  color: var(--color-primary);
  border-radius: 50px;
  padding: 11px 26px;
  font-weight: 600;
  font-family: var(--font-heading);
  background: transparent;
  transition: all 0.2s ease;
}
.btn-outline-brand:hover,
.btn-outline-brand:focus {
  background: var(--color-primary);
  color: #fff;
}

.btn-whatsapp {
  background: #25d366;
  color: #fff;
  border-radius: 50px;
  padding: 11px 24px;
  font-weight: 600;
  font-family: var(--font-heading);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 10px 22px rgba(37, 211, 102, 0.3);
}
.btn-whatsapp:hover, .btn-whatsapp:focus {
  color: #fff;
  transform: translateY(-2px);
}

/* Floating WhatsApp button */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1200;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 12px 26px rgba(37, 211, 102, 0.4);
  transition: transform 0.2s ease;
}
.whatsapp-float:hover { transform: scale(1.08); color: #fff; }

/* =========================================================
   Navbar
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  transition: box-shadow 0.25s ease;
}
.site-header.is-scrolled { box-shadow: var(--shadow-soft); }

.navbar-brand {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--color-ink) !important;
}
.navbar-brand .brand-mark {
  background: var(--gradient-primary);
  color: #fff;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  font-size: 1rem;
}

.nav-link-custom {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-ink) !important;
  margin: 0 4px;
  position: relative;
  padding: 8px 4px !important;
}
.nav-link-custom::after {
  content: "";
  position: absolute;
  left: 0; bottom: 2px;
  width: 0; height: 2px;
  background: var(--gradient-primary);
  transition: width 0.25s ease;
}
.nav-link-custom:hover::after,
.nav-link-custom.active::after { width: 100%; }
.nav-link-custom.active { color: var(--color-primary) !important; }

/* =========================================================
   Hero
   ========================================================= */
.hero {
  background: var(--gradient-hero);
  color: #fff;
  padding: 150px 0 110px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 20%, rgba(255,255,255,0.12) 0, transparent 40%),
                     radial-gradient(circle at 85% 70%, rgba(255,255,255,0.10) 0, transparent 45%);
  pointer-events: none;
}
.hero .eyebrow { background: rgba(255,255,255,0.15); color: #fff; }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.4rem); }
.hero p.lead { color: rgba(255,255,255,0.85); }

.page-hero {
  background: var(--gradient-hero);
  color: #fff;
  padding: 140px 0 70px;
  text-align: center;
}
.page-hero h1 { color: #fff; }
.page-hero p { color: rgba(255,255,255,0.85); }
.breadcrumb-custom a { color: rgba(255,255,255,0.75); }
.breadcrumb-custom span { color: #fff; }

/* Stat chips in hero */
.hero-stat {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  backdrop-filter: blur(6px);
}
.hero-stat .num { font-family: var(--font-heading); font-weight: 700; font-size: 1.4rem; color: #fff; }
.hero-stat .label { font-size: 0.78rem; color: rgba(255,255,255,0.78); }

/* =========================================================
   Glassmorphism Cards (subtle)
   ========================================================= */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

/* =========================================================
   Generic Cards
   ========================================================= */
.card-custom {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  height: 100%;
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.card-custom:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 34px rgba(15, 31, 92, 0.14);
}

.icon-badge {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--gradient-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 18px;
}

/* Course card */
.course-card { display: flex; flex-direction: column; }
.course-card .course-title { font-size: 1.15rem; margin-bottom: 8px; }
.course-card .course-desc { font-size: 0.93rem; flex-grow: 1; }
.course-card .btn-outline-brand { align-self: flex-start; margin-top: 18px; }

/* Board card */
.board-card {
  text-align: center;
  padding: 24px 14px;
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid var(--color-border);
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-ink);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, border-color 0.2s ease;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.board-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-primary-light);
}

/* Testimonial */
.testimonial-card { position: relative; }
.testimonial-card .quote-icon {
  color: var(--color-primary-light);
  font-size: 1.6rem;
  opacity: 0.5;
  margin-bottom: 10px;
}
.testimonial-name { font-family: var(--font-heading); font-weight: 700; margin-bottom: 0; }
.testimonial-role { font-size: 0.82rem; color: var(--color-muted); }
.avatar-circle {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--gradient-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
}

/* =========================================================
   FAQ Accordion
   ========================================================= */
.accordion-custom .accordion-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md) !important;
  margin-bottom: 14px;
  overflow: hidden;
}
.accordion-custom .accordion-button {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-ink);
  background: #fff;
}
.accordion-custom .accordion-button:not(.collapsed) {
  background: var(--color-bg-soft);
  color: var(--color-primary);
  box-shadow: none;
}
.accordion-custom .accordion-button:focus { box-shadow: none; outline: 3px solid var(--color-primary-light); }

/* =========================================================
   CTA band
   ========================================================= */
.cta-band {
  background: var(--gradient-primary);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 50px 36px;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.85); }

/* =========================================================
   Contact page
   ========================================================= */
.contact-info-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  box-shadow: var(--shadow-card);
}
.map-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card);
}
.map-placeholder {
  height: 100%;
  min-height: 320px;
  background: var(--color-bg-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: var(--color-muted);
  text-align: center;
  padding: 20px;
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  background: #0c1430;
  color: rgba(255,255,255,0.75);
  padding: 64px 0 0;
}
.site-footer h6 {
  color: #fff;
  font-family: var(--font-heading);
  margin-bottom: 18px;
  font-size: 1rem;
}
.site-footer a {
  color: rgba(255,255,255,0.65);
  display: inline-block;
  margin-bottom: 10px;
  transition: color 0.2s ease;
  font-size: 0.92rem;
}
.site-footer a:hover { color: #fff; }
.footer-brand {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.3rem;
  color: #fff;
}
.footer-social a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
}
.footer-social a:hover { background: var(--color-primary); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  margin-top: 40px;
  padding: 20px 0;
  font-size: 0.85rem;
  text-align: center;
}

/* =========================================================
   Scroll reveal (lightweight, respects reduced motion)
   ========================================================= */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* =========================================================
   Misc
   ========================================================= */
.divider-gradient {
  height: 4px;
  width: 70px;
  background: var(--gradient-primary);
  border-radius: 4px;
  margin: 0 auto 18px;
}

.back-to-top {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 1200;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--color-border);
  color: var(--color-primary);
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-card);
}

@media (max-width: 991.98px) {
  .hero { padding: 130px 0 80px; text-align: center; }
  .section { padding: 64px 0; }
}

/* =========================================================
   Dynamic site additions: forms, alerts, admin panel
   ========================================================= */
.form-control-custom {
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 12px 16px;
  font-family: var(--font-body);
}
.form-control-custom:focus {
  border-color: var(--color-primary-light);
  box-shadow: 0 0 0 3px rgba(36, 81, 232, 0.12);
}
.form-label-custom {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 6px;
}
.alert-custom-success {
  background: #e7f8f0;
  border: 1px solid #b9ebd2;
  color: #146c43;
  border-radius: var(--radius-md);
  padding: 16px 20px;
}
.alert-custom-error {
  background: #fdeeee;
  border: 1px solid #f3c3c3;
  color: #a92323;
  border-radius: var(--radius-md);
  padding: 16px 20px;
}

/* =========================================================
   Admin panel
   ========================================================= */
.admin-body { background: var(--color-bg-soft); min-height: 100vh; }
.admin-sidebar {
  background: #0c1430;
  min-height: 100vh;
  color: rgba(255,255,255,0.8);
}
.admin-sidebar .brand { color: #fff; font-family: var(--font-heading); font-weight: 700; font-size: 1.1rem; }
.admin-sidebar a {
  color: rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-radius: 10px;
  margin-bottom: 4px;
  font-size: 0.92rem;
  font-weight: 500;
}
.admin-sidebar a:hover { background: rgba(255,255,255,0.06); color: #fff; }
.admin-sidebar a.active { background: var(--gradient-primary); color: #fff; }
.admin-topbar {
  background: #fff;
  border-bottom: 1px solid var(--color-border);
  padding: 14px 24px;
}
.admin-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
}
.stat-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 22px;
  box-shadow: var(--shadow-card);
}
.stat-card .num { font-family: var(--font-heading); font-weight: 700; font-size: 1.8rem; }
.status-badge { padding: 4px 12px; border-radius: 50px; font-size: 0.76rem; font-weight: 600; }
.status-new { background: #eaf1ff; color: #2451e8; }
.status-contacted { background: #fff6e0; color: #92720a; }
.status-enrolled { background: #e7f8f0; color: #146c43; }
.status-closed { background: #f1f1f1; color: #555; }
.table-custom thead th {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-muted);
  border-bottom: 2px solid var(--color-border);
}
.admin-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-hero);
}
