/* ==========================================================================
   School Management System - Public Site & Auth Styles
   ========================================================================== */

/* ---------- Public Header ---------- */
.pub-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 72px;
}

.pub-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.pub-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 750;
  font-size: 1.15rem;
}

.pub-brand img, .pub-brand svg {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
}

.pub-brand-text {
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 280px;
}

.pub-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.pub-nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.pub-nav-links a {
  color: var(--text-2);
  font-weight: 600;
  font-size: 0.93rem;
  transition: color 0.2s;
  padding: 0.4rem 0;
}

.pub-nav-links a:hover, .pub-nav-links a.is-active {
  color: var(--primary);
}

.pub-nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.pub-nav-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
}

/* Mobile Nav Drawer */
@media (max-width: 900px) {
  .pub-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .pub-nav-menu {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--surface);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.5rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
    z-index: 999;
    overflow-y: auto;
    border-bottom: 1px solid var(--border);
  }

  body.nav-open .pub-nav-menu {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  body.nav-open {
    overflow: hidden;
  }

  .pub-nav-links {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 0.5rem;
  }

  .pub-nav-links li {
    width: 100%;
  }

  .pub-nav-links a {
    display: block;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 1.05rem;
    width: 100%;
  }

  .pub-nav-links a:hover {
    background: var(--surface-2);
  }

  .pub-nav-actions {
    width: 100%;
    margin-top: 1rem;
  }

  .pub-nav-actions .btn {
    width: 100%;
  }
}

/* ---------- Hero Section ---------- */
.pub-hero {
  background: var(--grad-hero);
  color: #ffffff;
  padding: 4.5rem 1.25rem;
  position: relative;
  overflow: hidden;
}

.pub-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.pub-hero-content h1 {
  color: #ffffff;
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.pub-hero-content p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.15rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  max-width: 580px;
}

.pub-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.pub-hero-img {
  display: flex;
  justify-content: center;
  align-items: center;
}

.pub-hero-img img, .pub-hero-img svg {
  width: 100%;
  max-width: 480px;
  height: auto;
  filter: drop-shadow(0 12px 28px rgba(15, 27, 61, 0.25));
}

@media (max-width: 900px) {
  .pub-hero {
    padding: 3rem 1.25rem;
  }
  .pub-hero-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }
  .pub-hero-content h1 {
    font-size: 2.1rem;
  }
  .pub-hero-content p {
    margin-left: auto;
    margin-right: auto;
    font-size: 1rem;
  }
  .pub-hero-actions {
    justify-content: center;
  }
}

/* ---------- Stats Strip ---------- */
.pub-stats {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin-top: -1px;
}

.pub-stats-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.5rem;
  text-align: center;
}

.pub-stat-item {
  padding: 0.5rem;
}

.pub-stat-num {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
  margin-bottom: 0.25rem;
}

.pub-stat-label {
  font-size: 0.85rem;
  font-weight: 650;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ---------- Public Sections General ---------- */
.pub-section {
  padding: 4.5rem 1.25rem;
  max-width: 1200px;
  margin: 0 auto;
}

.pub-section-alt {
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.sec-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 3rem;
}

.sec-head h2 {
  font-size: 2rem;
  font-weight: 750;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.sec-head p {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0;
}

/* ---------- Programs Grid ---------- */
.pub-programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.75rem;
}

.pub-program-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s;
}

.pub-program-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-100);
}

.pub-program-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius);
  background: var(--primary-50);
  color: var(--primary);
  display: grid;
  place-items: center;
  margin-bottom: 1.25rem;
}

.pub-program-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.pub-program-card p {
  color: var(--text-2);
  font-size: 0.93rem;
  margin: 0;
  line-height: 1.55;
}

/* ---------- Teacher Cards ---------- */
.pub-teachers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.75rem;
}

.pub-teacher-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.pub-teacher-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.pub-teacher-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 1rem;
  border: 3px solid var(--primary-50);
  box-shadow: var(--shadow-xs);
}

.pub-teacher-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.pub-teacher-designation {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 0.5rem;
}

.pub-teacher-qual {
  color: var(--muted);
  font-size: 0.82rem;
}

/* ---------- Notices Grid & Date Chips ---------- */
.pub-notices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.75rem;
}

.pub-notice-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.pub-notice-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.pub-date-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  background: var(--primary-50);
  color: var(--primary-700);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 650;
  align-self: flex-start;
}

.pub-notice-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
  line-height: 1.35;
}

.pub-notice-body {
  color: var(--text-2);
  font-size: 0.92rem;
  line-height: 1.55;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- Admissions CTA Band ---------- */
.pub-cta-band {
  background: var(--grad-primary);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 3.5rem 2rem;
  text-align: center;
  margin: 2rem 1.25rem 4rem;
  box-shadow: var(--shadow-lg);
}

.pub-cta-band h2 {
  color: #ffffff;
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.pub-cta-band p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 1.75rem;
}

/* ---------- Contact Cards ---------- */
.pub-contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.75rem;
}

.pub-contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
}

.pub-contact-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: var(--primary-50);
  color: var(--primary);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.pub-contact-info h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.pub-contact-info p {
  color: var(--text-2);
  font-size: 0.92rem;
  margin: 0;
  word-break: break-word;
}

/* ---------- Footer ---------- */
.pub-footer {
  background: #0f1b3d;
  color: #a3aec6;
  padding: 4rem 1.25rem 2rem;
  border-top: 1px solid #1e2d5a;
}

.pub-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr repeat(auto-fit, minmax(180px, 1fr));
  gap: 2.5rem;
  margin-bottom: 3rem;
}

.pub-footer-brand h3 {
  color: #ffffff;
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.pub-footer-brand p {
  font-size: 0.9rem;
  line-height: 1.6;
}

.pub-footer-col h4 {
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pub-footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.pub-footer-links a {
  color: #a3aec6;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.pub-footer-links a:hover {
  color: #ffffff;
}

.pub-footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: 0.85rem;
}

/* ---------- Auth Pages Styling (Two-Column Layout) ---------- */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  padding: 1.5rem;
}

.auth-card-split {
  width: 100%;
  max-width: 960px;
  background: var(--surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
}

.auth-form-col {
  padding: 3rem 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-form-header {
  margin-bottom: 2rem;
}

.auth-form-header h1 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 0.4rem;
}

.auth-form-header p {
  color: var(--muted);
  font-size: 0.93rem;
  margin: 0;
}

.auth-illus-col {
  background: var(--grad-hero);
  color: #ffffff;
  padding: 3rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.auth-illus-col img, .auth-illus-col svg {
  max-width: 280px;
  width: 100%;
  height: auto;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
}

.auth-illus-col h2 {
  color: #ffffff;
  font-size: 1.5rem;
  font-weight: 750;
  margin-bottom: 0.5rem;
}

.auth-illus-col p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.92rem;
  margin: 0;
  max-width: 320px;
}

/* Mobile Responsiveness for Auth Pages */
@media (max-width: 768px) {
  .auth-wrapper {
    padding: 0;
    align-items: flex-start;
  }

  .auth-card-split {
    grid-template-columns: 1fr;
    border-radius: 0;
    box-shadow: none;
    border: none;
    min-height: 100vh;
  }

  .auth-illus-col {
    order: -1;
    padding: 2rem 1.5rem;
    min-height: auto;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  }

  .auth-illus-col img, .auth-illus-col svg {
    max-width: 180px;
    margin-bottom: 1rem;
  }

  .auth-illus-col h2 {
    font-size: 1.25rem;
  }

  .auth-illus-col p {
    font-size: 0.85rem;
  }

  .auth-form-col {
    padding: 2rem 1.25rem;
  }
}
