/* Government Boys High School Ranjata — light theme */
:root {
  --green: #0b6b3a;
  --green-dark: #08522d;
  --green-light: #e7f4ec;
  --charcoal: #333333;
  --charcoal-soft: #555555;
  --bg: #ffffff;
  --bg-alt: #f4f8f5;
  --border: #dfe7e1;
  --radius: 12px;
  --shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  color: var(--charcoal);
  background: var(--bg);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

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

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--charcoal);
}

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

.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-name { font-weight: 700; font-size: 0.95rem; }
.brand-place {
  font-size: 0.8rem;
  letter-spacing: 0.35em;
  color: var(--green);
  font-weight: 600;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  padding: 0 10px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--charcoal);
  border-radius: 2px;
}

.main-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg);
  flex-direction: column;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.main-nav.open { display: flex; }
.main-nav a {
  padding: 0.8rem 1.2rem;
  text-decoration: none;
  color: var(--charcoal);
  border-top: 1px solid var(--border);
  font-weight: 500;
}
.main-nav a:hover { background: var(--green-light); color: var(--green-dark); }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, var(--green-light) 0%, var(--bg) 100%);
  padding: 3rem 0 2.5rem;
}
.hero-inner {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  align-items: center;
  text-align: center;
}
.hero-kicker {
  color: var(--green);
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-size: 0.8rem;
  margin-bottom: 0.75rem;
}
.hero h1 { font-size: 2rem; line-height: 1.2; margin-bottom: 0.75rem; }
.hero-sub { color: var(--charcoal-soft); max-width: 34rem; margin: 0 auto 1.5rem; }
.hero-actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }
.hero-media img {
  max-width: 420px;
  width: 100%;
  margin: 0 auto;
  border-radius: var(--radius);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.7rem 1.4rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  border: 2px solid var(--green);
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.2s, color 0.2s;
}
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-dark); border-color: var(--green-dark); }
.btn-outline { background: transparent; color: var(--green-dark); }
.btn-outline:hover { background: var(--green-light); }
.btn-small { padding: 0.45rem 0.9rem; font-size: 0.9rem; }

/* ---------- Sections ---------- */
.section { padding: 3rem 0; }
.section-alt { background: var(--bg-alt); }
.section-title {
  font-size: 1.7rem;
  color: var(--green-dark);
  margin-bottom: 0.25rem;
  text-align: center;
}
.section-sub { text-align: center; color: var(--charcoal-soft); margin-bottom: 1.5rem; }
.sample-note {
  text-align: center;
  font-size: 0.85rem;
  color: var(--charcoal-soft);
  background: #fff8e1;
  border: 1px dashed #d9b93c;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  margin: 0.75rem auto 1.5rem;
  max-width: 40rem;
}
.section-alt .sample-note { background: #fffdf4; }
.sub-heading { margin: 2rem 0 1rem; color: var(--green-dark); }

/* ---------- Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
.cards-2 { grid-template-columns: 1fr; }
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.section-alt .card { background: #fff; }
.card h3 { margin-bottom: 0.5rem; color: var(--charcoal); }
.card p { color: var(--charcoal-soft); font-size: 0.95rem; }
.card-date {
  display: inline-block;
  font-size: 0.78rem;
  color: var(--green-dark);
  background: var(--green-light);
  border-radius: 20px;
  padding: 0.15rem 0.7rem;
  margin-bottom: 0.6rem;
  font-weight: 600;
}
.photo-card img {
  border-radius: 8px;
  margin-bottom: 0.9rem;
  width: 100%;
}

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin-bottom: 0.75rem; }
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  font-size: 0.92rem;
}
.data-table th, .data-table td {
  padding: 0.7rem 0.9rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table th {
  background: var(--green);
  color: #fff;
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tbody tr:nth-child(even) { background: var(--bg-alt); }

/* ---------- Demo boxes & forms ---------- */
.demo-box {
  background: #fff;
  border: 2px dashed var(--green);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.demo-box h3 { color: var(--green-dark); margin-bottom: 0.5rem; }
.demo-accounts {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}
.demo-account {
  background: var(--green-light);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.92rem;
}
.demo-hint { font-size: 0.9rem; color: var(--green-dark); margin-top: 0.75rem; min-height: 1.2em; }
.demo-form, .contact-form {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-top: 1rem;
}
.demo-form label, .contact-form label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-weight: 600;
  font-size: 0.92rem;
}
.demo-form input, .demo-form select,
.contact-form input, .contact-form textarea {
  padding: 0.65rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  background: #fff;
}
.demo-form input:focus, .demo-form select:focus,
.contact-form input:focus, .contact-form textarea:focus {
  outline: 2px solid var(--green);
  border-color: var(--green);
}

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
}
.gallery-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.gallery-item figcaption {
  padding: 0.6rem 0.8rem;
  font-size: 0.88rem;
  color: var(--charcoal-soft);
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
.contact-info h3, .contact-form h3 { color: var(--green-dark); margin-bottom: 0.75rem; }
.contact-info p { margin-bottom: 0.5rem; color: var(--charcoal-soft); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--charcoal);
  color: #e8e8e8;
  padding: 2.5rem 0 1.5rem;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  align-items: center;
  text-align: center;
}
.footer-logo { width: 64px; height: 64px; object-fit: contain; margin: 0 auto 0.75rem; }
.footer-brand p { font-size: 0.92rem; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; justify-content: center; }
.footer-nav a { color: #cfd8d2; text-decoration: none; font-size: 0.92rem; }
.footer-nav a:hover { color: #fff; text-decoration: underline; }
.footer-copy { font-size: 0.82rem; color: #a9b3ad; }

/* ---------- Larger screens ---------- */
@media (min-width: 720px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .cards-2 { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .demo-accounts { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr 1.2fr; }
  .hero-inner { flex-direction: row; text-align: left; gap: 3rem; }
  .hero-text { flex: 1.1; }
  .hero-media { flex: 1; }
  .hero-sub { margin-left: 0; }
  .hero-actions { justify-content: flex-start; }
  .hero h1 { font-size: 2.6rem; }
}

@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  .main-nav {
    display: flex;
    position: static;
    flex-direction: row;
    border: none;
    box-shadow: none;
    gap: 0.1rem;
  }
  .main-nav a { border: none; padding: 0.6rem 0.7rem; font-size: 0.95rem; border-radius: 8px; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .cards-2 { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(4, 1fr); }
}
