:root {
  --navy: #0b132b;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-600: #475569;
  --slate-500: #64748b;
  --bg: #f8fafc;
  --surface: #ffffff;
  --border: #e2e8f0;
  --emerald: #059669;
  --emerald-dark: #047857;
  --sky: #0284c7;
  --gold: #d97706;
  --gold-bg: #fef3c7;
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--slate-900);
  background: var(--bg);
  line-height: 1.6;
}
body.has-website-bg {
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
body.has-website-bg .web-section-alt {
  background: rgba(241, 245, 249, 0.88);
  backdrop-filter: blur(4px);
}
.hidden { display: none !important; }
.web-container { max-width: 1220px; margin: 0 auto; padding: 0 20px; }

/* Buttons & Pills */
.web-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 9px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}
.web-btn-primary { background: var(--sky); color: #fff; }
.web-btn-primary:hover { background: #0369a1; transform: translateY(-1px); }
.web-btn-emerald { background: var(--emerald); color: #fff; }
.web-btn-emerald:hover { background: var(--emerald-dark); transform: translateY(-1px); }
.web-btn-outline { background: #fff; color: var(--slate-900); border-color: #cbd5e1; }
.web-btn-outline:hover { background: #f1f5f9; }
.web-btn-ghost-light { background: rgba(255,255,255,0.12); color: #fff; border-color: rgba(255,255,255,0.28); }
.web-btn-ghost-light:hover { background: rgba(255,255,255,0.22); }
.web-btn-lg { padding: 13px 24px; font-size: 0.98rem; }

.web-pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: #e0f2fe;
  color: #0369a1;
}
.web-badge-gold {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  background: var(--gold-bg);
  color: #92400e;
}
.web-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: #fff;
  font-size: 1.2rem;
  cursor: pointer;
}
.web-mobile-only { display: none; }

/* Navbar */
.web-navbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.web-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 70px;
}
.web-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: var(--slate-900);
}
.web-logo-box {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--navy);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-weight: 800;
  flex-shrink: 0;
}
.web-logo-box img { width: 100%; height: 100%; object-fit: cover; }
.web-brand strong { display: block; font-size: 1rem; line-height: 1.2; }
.web-brand small { display: block; font-size: 0.74rem; color: var(--emerald); font-weight: 700; }

.web-nav-links { display: flex; align-items: center; gap: 20px; }
.web-nav-links a {
  text-decoration: none;
  color: var(--slate-600);
  font-size: 0.9rem;
  font-weight: 600;
  transition: color 0.2s ease;
}
.web-nav-links a:hover { color: var(--sky); }
.web-nav-cta { display: flex; align-items: center; gap: 8px; }

/* Hero */
.web-hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 18% 20%, rgba(56, 189, 248, 0.22), transparent 36%),
              radial-gradient(circle at 86% 78%, rgba(16, 185, 129, 0.22), transparent 40%),
              linear-gradient(135deg, #0b132b 0%, #1e293b 55%, #064e3b 100%);
  color: #fff;
  padding: 58px 0 64px;
}
.web-hero-kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.web-pill-live {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: rgba(56, 189, 248, 0.18);
  border: 1px solid rgba(125, 211, 252, 0.35);
  color: #bae6fd;
}
.web-hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}
.web-hero-chip {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #e2e8f0;
}
.web-hero.has-hero-bg {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.web-hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: 36px;
  align-items: center;
}
.web-hero-copy h1 { margin: 14px 0 10px; font-size: 2.5rem; line-height: 1.15; letter-spacing: -0.02em; }
.web-hero-sub { margin: 0 0 24px; font-size: 1.06rem; color: #cbd5e1; max-width: 560px; }
.web-hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.web-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  border-top: 1px solid rgba(255,255,255,0.14);
  padding-top: 20px;
}
.web-stat-item strong { display: block; font-size: 1.5rem; color: #fff; }
.web-stat-item span { font-size: 0.78rem; color: #94a3b8; }

.web-hero-visual { position: relative; }
.web-hero-frame {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,0.16);
  box-shadow: 0 24px 48px rgba(0,0,0,0.35);
  aspect-ratio: 16 / 10;
  background: #1e293b;
}
.web-hero-live-chip {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #a7f3d0;
  backdrop-filter: blur(6px);
}
.web-hero-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.web-hero-floating {
  margin-top: -22px;
  margin-left: 18px;
  margin-right: 18px;
  position: relative;
  background: #fff;
  color: var(--slate-900);
  border-radius: 12px;
  padding: 12px 18px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.16);
}
.web-hero-floating small { display: block; font-size: 0.72rem; color: var(--slate-500); }
.web-hero-floating strong { font-size: 0.88rem; }

/* Sections */
.web-section { padding: 60px 0; }
.web-section-alt { background: #ffffff; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.web-section-head { margin-bottom: 28px; }
.web-head-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.web-eyebrow {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--emerald);
  margin-bottom: 6px;
}
.web-section-head h2 { margin: 0; font-size: 1.65rem; line-height: 1.25; }

/* Profile */
.web-profile-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 20px; margin-bottom: 20px; }
.web-principal-card, .web-info-card, .web-vm-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px;
  box-shadow: 0 2px 6px rgba(15,23,42,0.04);
}
.web-principal-card { display: grid; grid-template-columns: 180px 1fr; gap: 20px; align-items: start; }
.web-principal-photo { aspect-ratio: 4 / 5; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
.web-principal-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.web-principal-text h3 { margin: 10px 0 8px; font-size: 1.15rem; }
.web-principal-text p { margin: 0; color: var(--slate-600); font-size: 0.92rem; }

.web-info-card h3, .web-vm-card h3 { margin-top: 0; font-size: 1.05rem; }
.web-info-list { margin: 0; display: grid; gap: 10px; }
.web-info-list div { border-bottom: 1px solid var(--border); padding-bottom: 8px; }
.web-info-list div:last-child { border-bottom: none; padding-bottom: 0; }
.web-info-list dt { font-size: 0.75rem; font-weight: 700; color: var(--slate-500); }
.web-info-list dd { margin: 2px 0 0; font-size: 0.88rem; font-weight: 600; }

.web-vision-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.web-mission-list { color: var(--slate-600); font-size: 0.92rem; white-space: pre-line; }

/* Search & Category Tabs */
.web-search-box { display: flex; gap: 8px; }
.web-search-box input {
  padding: 9px 13px;
  border: 1px solid #cbd5e1;
  border-radius: 9px;
  font-size: 0.9rem;
  min-width: 230px;
}
.web-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.web-tab-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--slate-600);
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}
.web-tab-btn:hover { border-color: var(--sky); color: var(--sky); }
.web-tab-btn.active { background: var(--slate-900); color: #fff; border-color: var(--slate-900); }

/* Posts Grid */
.web-posts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.web-post-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.2s ease;
}
.web-post-card:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(15,23,42,0.08); background: #fff; }
.web-post-img { aspect-ratio: 16 / 10; background: #e2e8f0; overflow: hidden; }
.web-post-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.web-post-body { padding: 16px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.web-post-meta { display: flex; align-items: center; justify-content: space-between; font-size: 0.76rem; color: var(--slate-500); }
.web-post-body h3 { margin: 0; font-size: 1rem; line-height: 1.35; }
.web-post-body p { margin: 0; font-size: 0.86rem; color: var(--slate-600); }
.web-post-foot { padding: 0 16px 16px; }

/* Teachers Grid */
.web-teachers-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.web-teacher-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.2s ease;
}
.web-teacher-card:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(15,23,42,0.08); }
.web-teacher-photo { aspect-ratio: 1 / 1; background: #e2e8f0; overflow: hidden; }
.web-teacher-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.web-teacher-body { padding: 14px; }
.web-teacher-body h3 { margin: 6px 0 3px; font-size: 0.96rem; }
.web-teacher-pos { font-size: 0.8rem; font-weight: 700; color: var(--emerald); }
.web-teacher-bio { font-size: 0.8rem; color: var(--slate-600); margin: 6px 0 0; }

/* Gallery */
.web-gallery-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.web-gallery-item {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 4 / 3;
  position: relative;
  cursor: pointer;
  background: #e2e8f0;
  padding: 0;
}
.web-gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.25s ease; }
.web-gallery-item:hover img { transform: scale(1.04); }
.web-gallery-cap {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 8px 10px;
  background: linear-gradient(transparent, rgba(11,19,43,0.85));
  color: #fff;
  font-size: 0.76rem;
  font-weight: 600;
  text-align: left;
}

/* SSO CTA Banner & Footer */
.web-sso-cta-section { padding: 48px 0; }
.web-sso-cta-box {
  background: linear-gradient(135deg, #0b132b 0%, #1e293b 65%, #0369a1 100%);
  color: #fff;
  border-radius: 18px;
  padding: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.web-sso-cta-box h2 { margin: 10px 0 6px; font-size: 1.55rem; }
.web-sso-cta-box p { margin: 0; color: #cbd5e1; max-width: 680px; }

.web-footer { background: var(--navy); color: #cbd5e1; padding: 46px 0 24px; }
.web-footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 28px; margin-bottom: 28px; }
.web-footer h3, .web-footer h4 { color: #fff; margin-top: 0; }
.web-footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.web-footer-links a { color: #94a3b8; text-decoration: none; font-size: 0.88rem; }
.web-footer-links a:hover { color: #fff; }
.web-footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 18px;
  text-align: center;
  font-size: 0.82rem;
  color: #94a3b8;
}

/* Modal */
.web-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(11, 19, 43, 0.65);
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
}
.web-modal-card {
  width: 100%;
  max-width: 680px;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  padding: 22px;
}
.web-modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.web-modal-body img { width: 100%; max-height: 340px; object-fit: cover; border-radius: 12px; margin-bottom: 14px; }
.web-video-frame { width: 100%; aspect-ratio: 16 / 9; border: none; border-radius: 12px; margin-bottom: 14px; background: #0f172a; }

/* Social Channels Section */
.web-social-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.web-social-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  text-decoration: none;
  color: var(--slate-900);
  transition: all 0.2s ease;
}
.web-social-card:hover { transform: translateY(-3px); box-shadow: 0 12px 24px rgba(15,23,42,0.08); }
.web-social-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
}
.soc-yt { background: #dc2626; }
.soc-ig { background: linear-gradient(135deg, #d946ef, #f97316); }
.soc-tt { background: #0f172a; }
.soc-wa { background: #059669; }
.web-social-card strong { display: block; font-size: 0.96rem; }
.web-social-card small { display: block; font-size: 0.78rem; color: var(--slate-500); }

/* Floating WhatsApp & Asisten AI Widget */
.web-float-stack {
  position: fixed;
  right: 18px;
  bottom: 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  z-index: 65;
}
.web-float-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  border-radius: 999px;
  border: none;
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(11, 19, 43, 0.25);
  transition: transform 0.2s ease;
}
.web-float-btn:hover { transform: translateY(-2px); }
.web-float-wa { background: #059669; }
.web-float-ai { background: #0b132b; border: 1px solid rgba(255,255,255,0.2); }

.ai-drawer {
  position: fixed;
  right: 18px;
  bottom: 78px;
  width: min(370px, calc(100vw - 28px));
  max-height: 75vh;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 24px 48px rgba(11, 19, 43, 0.24);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 75;
}
.ai-head {
  background: linear-gradient(135deg, #0b132b 0%, #0369a1 100%);
  color: #fff;
  padding: 13px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ai-head strong { display: block; font-size: 0.92rem; }
.ai-head small { display: block; font-size: 0.72rem; color: #bae6fd; }
.ai-messages {
  padding: 12px;
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 9px;
  background: #f8fafc;
  min-height: 210px;
}
.ai-msg {
  max-width: 88%;
  padding: 9px 12px;
  border-radius: 12px;
  font-size: 0.84rem;
  line-height: 1.45;
  white-space: pre-line;
}
.ai-msg-bot { align-self: flex-start; background: #fff; border: 1px solid var(--border); color: var(--slate-900); }
.ai-msg-user { align-self: flex-end; background: var(--sky); color: #fff; }
.ai-quick-chips {
  display: flex;
  gap: 6px;
  padding: 8px 10px;
  overflow-x: auto;
  background: #fff;
  border-top: 1px solid var(--border);
}
.ai-quick-chips button {
  padding: 5px 9px;
  border-radius: 999px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}
.ai-quick-chips button:hover { border-color: var(--sky); color: var(--sky); }
.ai-form { display: flex; gap: 6px; padding: 10px; border-top: 1px solid var(--border); background: #fff; }
.ai-form input { flex: 1; padding: 8px 11px; border: 1px solid #cbd5e1; border-radius: 8px; font-size: 0.86rem; }

@media (max-width: 980px) {
  .web-social-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .web-hero-grid, .web-profile-grid, .web-vision-grid, .web-footer-grid { grid-template-columns: 1fr; }
  .web-posts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .web-teachers-grid, .web-gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .web-nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 14px 20px;
    flex-direction: column;
    align-items: flex-start;
  }
  .web-nav-links.open { display: flex; }
  .web-mobile-only { display: inline-flex; }
}

@media (max-width: 600px) {
  .web-hero-copy h1 { font-size: 1.85rem; }
  .web-principal-card { grid-template-columns: 1fr; }
  .web-posts-grid { grid-template-columns: 1fr; }
  .web-search-box input { min-width: 160px; flex: 1; }
}
