/* ============================================================
   Vijaya Kranthi Junior College, Challapalli
   Design system — editorial / scholarly / Andhra-rooted
   ============================================================ */

:root {
  /* Brand palette */
  --indigo-900: #0d1e36;
  --indigo-800: #14294a;
  --indigo-700: #1e3a5f;
  --indigo-600: #2a4d7a;
  --indigo-200: #c8d6e8;
  --indigo-100: #e6edf6;

  --gold-700: #9a6308;
  --gold-600: #c07a09;
  --gold-500: #d99518;
  --gold-300: #f0c66b;
  --gold-100: #f9ecc9;

  --maroon-700: #7a1e2b;
  --maroon-500: #a8323f;

  --cream-50:  #fbf6ed;
  --cream-100: #f5ecd9;
  --cream-200: #ecdfc1;
  --paper:     #fdfbf5;

  --ink-900: #11151c;
  --ink-700: #2a2f38;
  --ink-500: #5a6171;
  --ink-300: #9aa1b1;

  --rule:    #e6dfca;
  --rule-dk: #b89a4a;

  /* Type */
  --display: "Fraunces", "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --serif:   "Source Serif 4", "Source Serif Pro", Georgia, serif;
  --sans:    "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono:    "JetBrains Mono", ui-monospace, Menlo, monospace;
  --telugu:  "Noto Sans Telugu", "Mallanna", system-ui, sans-serif;

  /* Layout */
  --maxw: 1200px;
  --pad-x: clamp(1.1rem, 4vw, 2.4rem);

  /* Motion */
  --ease: cubic-bezier(.2,.7,.2,1);
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-900);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.012em;
  line-height: 1.08;
  margin: 0;
  color: var(--indigo-900);
}
h1 { font-size: clamp(2.4rem, 5.6vw, 4.4rem); font-weight: 450; }
h2 { font-size: clamp(1.8rem, 3.8vw, 3rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); }
h4 { font-size: 1.05rem; font-family: var(--sans); font-weight: 700; letter-spacing: 0.02em; }
p  { margin: 0 0 1em; color: var(--ink-700); }

.eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-700);
  padding-bottom: 4px;
  border-bottom: 1.5px solid var(--gold-500);
  margin-bottom: 1.1rem;
}

.lede { font-size: 1.12rem; color: var(--ink-700); max-width: 60ch; }

.te {
  font-family: var(--telugu);
  font-weight: 500;
  font-feature-settings: "calt", "liga";
}

/* ---------- Container ---------- */
.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad-x); }

/* ---------- Top admissions strip ---------- */
.topstrip {
  background: var(--indigo-900);
  color: var(--cream-100);
  font-size: 0.85rem;
  border-bottom: 1px solid var(--indigo-800);
}
.topstrip .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-block: 0.55rem; gap: 1rem; flex-wrap: wrap;
}
.topstrip strong { color: var(--gold-300); margin-right: 6px; letter-spacing: 0.04em; }
.topstrip a { color: var(--gold-300); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(253,251,245,.94);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--rule);
}
.site-header .wrap {
  display: flex; align-items: center; gap: 1.4rem;
  padding-block: 0.85rem;
}
.brand { display: flex; align-items: center; gap: 0.8rem; text-decoration: none; }
.brand-mark {
  width: 46px; height: 46px;
  background: var(--indigo-800);
  color: var(--gold-300);
  display: grid; place-items: center;
  font-family: var(--display);
  font-size: 1.25rem; font-weight: 600;
  border-radius: 4px;
  box-shadow: 0 0 0 3px var(--cream-100), 0 0 0 4px var(--indigo-800);
  letter-spacing: 0.03em;
}
.brand-text { line-height: 1.15; }
.brand-text .name {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.05rem;
  color: var(--indigo-900);
  display: block;
}
.brand-text .sub {
  font-size: 0.72rem;
  color: var(--ink-500);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.nav-primary { display: flex; gap: 1.4rem; margin-left: auto; align-items: center; }
.nav-primary a {
  text-decoration: none;
  color: var(--ink-700);
  font-size: 0.93rem;
  font-weight: 500;
  padding-block: 6px;
  border-bottom: 1.5px solid transparent;
  transition: border-color .2s var(--ease), color .2s;
}
.nav-primary a:hover, .nav-primary a.active {
  color: var(--indigo-900); border-bottom-color: var(--gold-500);
}
.nav-cta {
  background: var(--indigo-800); color: var(--cream-50) !important;
  padding: 8px 16px !important;
  border-radius: 2px; border-bottom: none !important;
  letter-spacing: 0.02em;
}
.nav-cta:hover { background: var(--indigo-900); }

.menu-toggle {
  display: none;
  background: none; border: 1px solid var(--rule);
  padding: 8px 12px; cursor: pointer;
  font: inherit; border-radius: 2px;
}

@media (max-width: 920px) {
  .nav-primary {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch;
    background: var(--paper); border-bottom: 1px solid var(--rule);
    padding: 1rem var(--pad-x); gap: 0.6rem;
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: all .25s var(--ease);
  }
  .nav-primary.open { transform: none; opacity: 1; visibility: visible; }
  .nav-primary a { padding-block: 10px; border-bottom: 1px solid var(--rule); }
  .nav-cta { text-align: center; }
  .menu-toggle { display: inline-block; margin-left: auto; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font: 600 0.93rem var(--sans);
  letter-spacing: 0.02em;
  padding: 0.85rem 1.4rem;
  border-radius: 2px;
  text-decoration: none;
  transition: transform .15s var(--ease), background .2s, color .2s;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--indigo-800); color: var(--cream-50); }
.btn-primary:hover { background: var(--indigo-900); }
.btn-gold { background: var(--gold-600); color: white; }
.btn-gold:hover { background: var(--gold-700); }
.btn-ghost { background: transparent; color: var(--indigo-900); border-color: var(--indigo-800); }
.btn-ghost:hover { background: var(--indigo-900); color: var(--cream-50); }

/* ---------- HERO ---------- */
.hero {
  position: relative;
  background: linear-gradient(180deg, var(--cream-50) 0%, var(--paper) 100%);
  overflow: hidden;
  padding-block: clamp(3rem, 7vw, 6rem) clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--rule);
}
.hero::before {
  /* Subtle decorative motif — fort silhouette nod */
  content: "";
  position: absolute; inset: 0;
  background-image:
    radial-gradient(ellipse at 88% 12%, rgba(217,149,24,.10) 0%, transparent 45%),
    radial-gradient(ellipse at 8% 90%, rgba(30,58,95,.08) 0%, transparent 50%);
  pointer-events: none;
}
.hero .wrap { position: relative; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
  align-items: center;
}
@media (max-width: 880px) { .hero-grid { grid-template-columns: 1fr; } }

.hero-tag {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.78rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--maroon-700);
  background: var(--cream-100);
  padding: 6px 14px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  margin-bottom: 1.4rem;
}
.hero-tag .dot {
  width: 6px; height: 6px; background: var(--maroon-500); border-radius: 50%;
  animation: pulse 1.8s var(--ease) infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero h1 .accent {
  background: linear-gradient(90deg, var(--gold-600), var(--maroon-700));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-style: italic; font-weight: 400;
}
.hero h1 .te {
  display: block;
  font-size: 0.55em;
  color: var(--gold-700);
  margin-top: 0.4rem;
  letter-spacing: -0.005em;
}

.hero-lede {
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  color: var(--ink-700);
  max-width: 50ch;
  margin: 1.4rem 0;
}
.hero-list {
  list-style: none; padding: 0; margin: 1.4rem 0 2rem;
  display: grid; gap: 0.55rem;
  font-size: 0.95rem;
}
.hero-list li {
  display: flex; gap: 0.7rem; align-items: flex-start;
  color: var(--ink-700);
}
.hero-list li::before {
  content: "✦";
  color: var(--gold-600);
  font-size: 0.9em;
  margin-top: 2px;
  flex-shrink: 0;
}
.hero-cta { display: flex; gap: 0.8rem; flex-wrap: wrap; }

.hero-card {
  background: var(--indigo-900);
  color: var(--cream-100);
  padding: clamp(1.6rem, 3vw, 2.2rem);
  border-radius: 4px;
  position: relative;
  box-shadow: 0 30px 60px -30px rgba(13,30,54,.4);
}
.hero-card::before {
  content: ""; position: absolute; inset: 0;
  border: 1px solid var(--gold-500);
  margin: 8px;
  pointer-events: none;
}
.hero-card .label {
  font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--gold-300); margin-bottom: 0.4rem;
}
.hero-card .big {
  font-family: var(--display);
  font-size: clamp(2.6rem, 5vw, 3.6rem);
  font-weight: 400;
  line-height: 1;
  color: var(--cream-50);
  margin-bottom: 0.4rem;
}
.hero-card .small {
  font-size: 0.85rem; color: var(--indigo-200);
  border-top: 1px solid rgba(217,149,24,.3);
  padding-top: 1rem; margin-top: 1.2rem;
}
.hero-card ul { list-style: none; padding: 0; margin: 0.8rem 0 0; }
.hero-card li {
  font-size: 0.92rem; padding-block: 0.5rem;
  border-top: 1px solid rgba(217,149,24,.18);
  color: var(--cream-100);
}
.hero-card li strong { color: var(--gold-300); margin-right: 6px; font-weight: 600; }

/* ---------- Affiliations strip ---------- */
.affiliations {
  background: var(--cream-100);
  border-bottom: 1px solid var(--rule);
  padding-block: 1.1rem;
  font-size: 0.82rem;
}
.affiliations .wrap {
  display: flex; flex-wrap: wrap; gap: 0.8rem 2rem;
  align-items: center; justify-content: center;
  color: var(--ink-500); letter-spacing: 0.08em; text-transform: uppercase;
  font-weight: 500;
}
.affiliations span { display: flex; align-items: center; gap: 0.5rem; }
.affiliations span::before {
  content: "○"; color: var(--gold-600); font-size: 0.7em;
}

/* ---------- Section base ---------- */
section {
  padding-block: clamp(3rem, 6vw, 5.5rem);
  position: relative;
}
.section-head {
  margin-bottom: clamp(2rem, 3vw, 3rem);
  max-width: 60ch;
}
.section-head .lede { margin-top: 0.8rem; }

/* ---------- Stat grid ---------- */
.stats {
  background: var(--paper);
  border-block: 1px solid var(--rule);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.stat {
  background: var(--paper);
  padding: 1.8rem 1.4rem;
  text-align: left;
}
.stat .num {
  font-family: var(--display);
  font-size: clamp(2.4rem, 4.5vw, 3.4rem);
  font-weight: 400;
  color: var(--indigo-900);
  line-height: 1;
  margin-bottom: 0.5rem;
}
.stat .num sup { font-size: 0.45em; color: var(--gold-600); top: -1.4em; margin-left: 4px; }
.stat .label { font-weight: 600; color: var(--ink-900); margin-bottom: 0.2rem; font-size: 0.95rem; }
.stat .sub { font-size: 0.82rem; color: var(--ink-500); }

/* ---------- Streams / programmes ---------- */
.streams { background: var(--cream-50); }
.streams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
}
.stream-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.6rem;
  position: relative;
  transition: transform .25s var(--ease), border-color .25s;
}
.stream-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold-500);
}
.stream-card .code {
  font-family: var(--display);
  font-size: 1.6rem;
  font-weight: 500;
  color: var(--maroon-700);
  letter-spacing: -0.02em;
}
.stream-card .full {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-500);
  margin: 0.3rem 0 1rem;
}
.stream-card .desc {
  font-size: 0.92rem;
  color: var(--ink-700);
  margin-bottom: 1rem;
}
.stream-card .career {
  font-size: 0.78rem;
  color: var(--gold-700);
  font-weight: 700;
  letter-spacing: 0.04em;
  border-top: 1px dashed var(--gold-300);
  padding-top: 0.7rem;
  text-transform: uppercase;
}

/* ---------- Reasons / Why us ---------- */
.reasons {
  background: var(--indigo-900);
  color: var(--cream-100);
}
.reasons h2, .reasons .eyebrow { color: var(--cream-50); }
.reasons .eyebrow { color: var(--gold-300); border-bottom-color: var(--gold-500); }
.reasons .lede { color: var(--indigo-200); }
.reasons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem 2rem;
  margin-top: 2rem;
}
.reason {
  border-top: 2px solid var(--gold-500);
  padding-top: 1.2rem;
}
.reason h3 {
  color: var(--cream-50);
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
}
.reason p { color: var(--indigo-200); font-size: 0.95rem; margin: 0; }

/* ---------- Correspondent / Founder ---------- */
.principal { background: var(--cream-50); }
.principal-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(1.8rem, 4vw, 4rem);
  align-items: center;
}
@media (max-width: 880px) { .principal-grid { grid-template-columns: 1fr; } }
.portrait {
  background: var(--indigo-900);
  aspect-ratio: 4 / 5;
  display: grid; place-items: center;
  position: relative;
  overflow: hidden;
}
.portrait::before {
  content: ""; position: absolute; inset: 12px;
  border: 1px solid var(--gold-500);
}
.portrait .initials {
  font-family: var(--display);
  font-size: clamp(3.5rem, 8vw, 5.5rem);
  font-weight: 400;
  color: var(--gold-300);
  letter-spacing: -0.02em;
}
.portrait .name-tag {
  position: absolute;
  bottom: 24px; left: 24px; right: 24px;
  background: var(--cream-50);
  padding: 0.9rem 1rem;
  border-left: 3px solid var(--gold-500);
}
.portrait .name-tag strong { display: block; color: var(--indigo-900); font-weight: 600; font-family: var(--display); font-size: 1.05rem; }
.portrait .name-tag span { font-size: 0.78rem; color: var(--ink-500); letter-spacing: 0.04em; }

.principal blockquote {
  font-family: var(--display);
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  line-height: 1.35;
  color: var(--indigo-900);
  font-weight: 400;
  margin: 0 0 1.4rem;
  font-style: italic;
  position: relative;
  padding-left: 1.4rem;
  border-left: 2px solid var(--gold-500);
}

/* ---------- Admissions timeline ---------- */
.admissions { background: var(--paper); }
.timeline {
  display: grid;
  gap: 0;
  margin-top: 2rem;
}
.tl-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.5rem;
  padding: 1.2rem 0;
  border-top: 1px solid var(--rule);
  align-items: start;
}
.tl-row:last-child { border-bottom: 1px solid var(--rule); }
.tl-date {
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  color: var(--maroon-700);
  font-weight: 600;
  padding-top: 4px;
}
.tl-body h4 { font-family: var(--display); font-size: 1.15rem; font-weight: 500; color: var(--indigo-900); margin-bottom: 0.3rem; }
.tl-body p { margin: 0; color: var(--ink-500); font-size: 0.92rem; }
@media (max-width: 600px) {
  .tl-row { grid-template-columns: 1fr; gap: 0.4rem; }
}

/* ---------- Campus ---------- */
.campus { background: var(--cream-100); }
.campus-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.facility {
  background: var(--paper);
  padding: 1.5rem;
  border-top: 3px solid var(--gold-500);
}
.facility h4 {
  font-family: var(--display); font-size: 1.15rem;
  font-weight: 500; color: var(--indigo-900);
  margin-bottom: 0.5rem;
}
.facility p { font-size: 0.92rem; color: var(--ink-500); margin: 0; }

/* ---------- News / events ---------- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}
.news-item .date {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  color: var(--gold-700);
  font-weight: 600;
  margin-bottom: 0.6rem;
  display: block;
}
.news-item .date span {
  background: var(--cream-100);
  padding: 2px 8px;
  margin-right: 6px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.news-item h3 {
  font-family: var(--display); font-size: 1.3rem;
  font-weight: 500; line-height: 1.25;
  margin-bottom: 0.6rem;
}
.news-item p { font-size: 0.95rem; color: var(--ink-500); margin: 0; }

/* ---------- Closing CTA ---------- */
.closing {
  background:
    linear-gradient(180deg, rgba(13,30,54,.92), rgba(13,30,54,.92)),
    radial-gradient(circle at 70% 30%, var(--gold-600) 0%, transparent 50%);
  background-color: var(--indigo-900);
  color: var(--cream-50);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.closing::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(90deg, transparent 0 100px, rgba(217,149,24,.06) 100px 101px);
  pointer-events: none;
}
.closing .wrap { position: relative; }
.closing h2 { color: var(--cream-50); max-width: 22ch; margin-inline: auto; }
.closing .lede { color: var(--indigo-200); margin: 1.2rem auto 2rem; }
.closing .btn-row { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.closing .btn-ghost { color: var(--cream-50); border-color: var(--gold-500); }
.closing .btn-ghost:hover { background: var(--gold-500); color: var(--indigo-900); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--indigo-900);
  color: var(--indigo-200);
  border-top: 4px solid var(--gold-500);
  padding-block: 3rem 1.6rem;
  font-size: 0.92rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 2.2rem;
  padding-bottom: 2.4rem;
  border-bottom: 1px solid rgba(217,149,24,.2);
}
@media (max-width: 880px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .footer-grid { grid-template-columns: 1fr; } }

.site-footer .brand-text .name { color: var(--cream-50); }
.site-footer .brand-text .sub { color: var(--gold-300); }
.site-footer h4 {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 0.9rem;
  font-weight: 700;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.5rem; }
.site-footer a { color: var(--indigo-200); text-decoration: none; transition: color .2s; }
.site-footer a:hover { color: var(--gold-300); }
.site-footer p { color: var(--indigo-200); }
.copyline {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
  margin-top: 1.6rem;
  font-size: 0.82rem; color: var(--ink-300);
}
.copyline .links { display: flex; gap: 1.4rem; }

/* ---------- Page-specific helpers (about, contact, etc) ---------- */
.page-hero {
  background: linear-gradient(180deg, var(--cream-50), var(--paper));
  padding-block: clamp(3.5rem, 6vw, 5rem) clamp(2rem, 4vw, 3rem);
  border-bottom: 1px solid var(--rule);
}
.page-hero .crumbs {
  font-size: 0.82rem; color: var(--ink-500);
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
}
.page-hero .crumbs a { color: var(--gold-700); text-decoration: none; }
.page-hero .crumbs a:hover { text-decoration: underline; }

.prose { max-width: 70ch; }
.prose p { font-size: 1.04rem; line-height: 1.75; color: var(--ink-700); }
.prose p + p { margin-top: 1rem; }
.prose h3 { margin-top: 2.4rem; margin-bottom: 0.8rem; }
.prose ul { padding-left: 1.2rem; }
.prose ul li { margin-bottom: 0.4rem; color: var(--ink-700); }

.split-2 {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
  align-items: start;
}
@media (max-width: 880px) { .split-2 { grid-template-columns: 1fr; } }

.aside-card {
  background: var(--cream-100);
  padding: 1.6rem;
  border-left: 3px solid var(--gold-500);
}
.aside-card h4 {
  font-family: var(--display); font-size: 1.15rem; font-weight: 500;
  color: var(--indigo-900); margin-bottom: 0.7rem;
}
.aside-card ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.55rem; }
.aside-card li {
  font-size: 0.92rem; color: var(--ink-700);
  display: flex; gap: 0.7rem;
  border-bottom: 1px dashed var(--rule);
  padding-bottom: 0.55rem;
}
.aside-card li:last-child { border-bottom: none; }
.aside-card li strong { color: var(--indigo-900); flex-shrink: 0; min-width: 7em; font-weight: 600; }

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 4vw, 3.5rem);
  margin-top: 2rem;
}
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.8rem;
}
.contact-card .row {
  display: grid; grid-template-columns: 90px 1fr;
  gap: 1rem; padding-block: 0.9rem;
  border-top: 1px solid var(--rule);
  font-size: 0.95rem;
}
.contact-card .row:first-of-type { border-top: none; }
.contact-card .row .key {
  font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--gold-700); padding-top: 3px; font-weight: 700;
}
.contact-card .row .val { color: var(--ink-700); }
.contact-card .row .val a { color: var(--indigo-800); text-decoration: none; border-bottom: 1px solid var(--rule); }

.map-frame {
  width: 100%; aspect-ratio: 4 / 3;
  border: 1px solid var(--rule);
  background: var(--cream-100);
  display: grid; place-items: center;
  color: var(--ink-500); font-size: 0.95rem;
  text-align: center; padding: 2rem;
  background-image:
    linear-gradient(45deg, var(--cream-100) 25%, transparent 25%),
    linear-gradient(-45deg, var(--cream-100) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--cream-100) 75%),
    linear-gradient(-45deg, transparent 75%, var(--cream-100) 75%);
  background-size: 24px 24px;
  background-position: 0 0, 0 12px, 12px -12px, -12px 0;
  background-color: var(--cream-50);
}

form .field { margin-bottom: 1rem; }
form label {
  display: block; font-size: 0.78rem; letter-spacing: 0.06em;
  text-transform: uppercase; font-weight: 700; color: var(--ink-500);
  margin-bottom: 0.4rem;
}
form input, form select, form textarea {
  width: 100%; padding: 0.75rem 0.9rem;
  border: 1px solid var(--rule); border-radius: 2px;
  font: inherit; background: var(--paper); color: var(--ink-900);
  transition: border-color .2s;
}
form input:focus, form select:focus, form textarea:focus {
  outline: none; border-color: var(--indigo-700);
  box-shadow: 0 0 0 3px var(--indigo-100);
}
form textarea { min-height: 120px; resize: vertical; }

/* ---------- Utilities ---------- */
.center { text-align: center; }
.mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; } .mt-4 { margin-top: 2rem; }
hr.rule {
  border: none; border-top: 1px solid var(--rule); margin: 2.5rem 0;
}
.divider {
  display: flex; align-items: center; gap: 1rem;
  color: var(--gold-700); font-family: var(--display);
  font-style: italic; font-size: 1.05rem;
  margin-block: 2rem;
}
.divider::before, .divider::after {
  content: ""; flex: 1; height: 1px; background: var(--rule);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   Accessibility · Theme · Mobility upgrade (May 2026)
   - Skip link, focus-visible, larger tap targets
   - Day / night theme via [data-theme="dark"]
   - Font-size scale via [data-fontsize="lg"|"xl"]
   - Mobile sticky CTA bar
   - Header controls (lang switch · theme · font-size)
   ============================================================ */

/* ---------- Skip link (always first focusable element) ---------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--indigo-900);
  color: var(--gold-300);
  padding: 12px 18px;
  z-index: 200;
  font: 600 0.92rem var(--sans);
  letter-spacing: 0.04em;
  text-decoration: none;
  border-radius: 0 0 4px 0;
}
.skip-link:focus {
  left: 0;
  outline: 3px solid var(--gold-500);
  outline-offset: 2px;
}

/* ---------- Focus rings (WCAG 2.2 AA: visible focus on all interactives) ---------- */
*:focus { outline: none; }
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--gold-500);
  outline-offset: 2px;
  border-radius: 2px;
}
.btn:focus-visible {
  outline: 3px solid var(--gold-500);
  outline-offset: 3px;
}

/* ---------- Tap targets (mobility) ---------- */
@media (max-width: 920px) {
  .nav-primary a {
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  .btn { min-height: 44px; }
  form input, form select, form textarea, form button { min-height: 44px; }
  .menu-toggle { min-height: 44px; min-width: 44px; }
}

/* ---------- Font-size scale (a11y) ---------- */
html[data-fontsize="lg"] body { font-size: 17.5px; }
html[data-fontsize="lg"] .lede,
html[data-fontsize="lg"] .hero-lede { font-size: 1.18rem; }
html[data-fontsize="xl"] body { font-size: 19px; }
html[data-fontsize="xl"] .lede,
html[data-fontsize="xl"] .hero-lede { font-size: 1.25rem; }

/* ---------- Header controls cluster (lang · theme · font) ---------- */
.nav-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}
.nav-primary + .nav-controls { margin-left: 0.6rem; }

.lang-switch {
  display: inline-flex;
  border: 1px solid var(--rule);
  border-radius: 999px;
  overflow: hidden;
  background: var(--paper);
}
.lang-switch a {
  font: 600 0.78rem var(--sans);
  padding: 6px 10px;
  text-decoration: none;
  color: var(--ink-500);
  letter-spacing: 0.04em;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  transition: background .2s, color .2s;
}
.lang-switch a:hover { color: var(--indigo-900); }
.lang-switch a.active {
  background: var(--indigo-800);
  color: var(--gold-300);
}
.lang-switch a:first-child { border-right: 1px solid var(--rule); }
.lang-switch a[hreflang="te"] { font-family: var(--telugu); font-size: 0.9rem; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--ink-700);
  cursor: pointer;
  transition: color .2s, border-color .2s, background .2s;
  padding: 0;
}
.icon-btn:hover {
  color: var(--indigo-900);
  border-color: var(--gold-500);
}
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn .moon, .icon-btn .sun { display: none; }
:root:not([data-theme="dark"]) .theme-toggle .moon { display: block; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }
.font-toggle {
  font: 700 0.82rem var(--sans);
  letter-spacing: 0.02em;
}
.font-toggle .step {
  font-size: 0.62rem;
  vertical-align: super;
  margin-left: 1px;
  color: var(--gold-700);
}

@media (max-width: 920px) {
  .nav-controls {
    order: 2;
    margin-left: 0;
    margin-right: auto;
    padding-left: 0.6rem;
  }
  .menu-toggle { order: 3; }
}

/* ---------- Mobile sticky CTA dock (mobility) ---------- */
.mobile-cta-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 60;
  display: none;
  gap: 0;
  padding: 8px;
  background: var(--paper);
  border-top: 1px solid var(--rule);
  box-shadow: 0 -8px 24px -10px rgba(13,30,54,.18);
  transform: translateY(100%);
  transition: transform .3s var(--ease);
}
.mobile-cta-bar.show { transform: translateY(0); }
.mobile-cta-bar a {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 12px 14px;
  text-decoration: none;
  font: 600 0.92rem var(--sans);
  letter-spacing: 0.02em;
  border-radius: 2px;
  min-height: 44px;
}
.mobile-cta-bar .call {
  color: var(--indigo-900);
  border: 1px solid var(--indigo-800);
  margin-right: 8px;
}
.mobile-cta-bar .apply {
  background: var(--indigo-800);
  color: var(--cream-50);
}
.mobile-cta-bar svg { width: 16px; height: 16px; }
body.with-cta-bar { padding-bottom: 70px; }
@media (max-width: 720px) {
  .mobile-cta-bar { display: flex; }
}

/* ---------- Dark mode (data-theme="dark") ---------- */
:root[data-theme="dark"] {
  --indigo-900: #f0e9d8;
  --indigo-800: #e7dec5;
  --indigo-700: #d4c79f;
  --indigo-600: #c1b27a;
  --indigo-200: #6b6651;
  --indigo-100: #312d22;

  --gold-700: #f0c66b;
  --gold-600: #d99518;
  --gold-500: #c07a09;
  --gold-300: #9a6308;
  --gold-100: #2c2010;

  --maroon-700: #f0a3ad;
  --maroon-500: #c8606e;

  --cream-50:  #14181f;
  --cream-100: #1b2029;
  --cream-200: #252b37;
  --paper:     #0e1218;

  --ink-900: #f3eedf;
  --ink-700: #d8d2c1;
  --ink-500: #9aa1b1;
  --ink-300: #6f7689;

  --rule:    #2b3140;
  --rule-dk: #4a4632;
}
:root[data-theme="dark"] body {
  background: var(--paper);
  color: var(--ink-900);
}
:root[data-theme="dark"] .topstrip {
  background: #060911;
  color: #f0e9d8;
  border-bottom-color: #1b2029;
}
:root[data-theme="dark"] .site-header {
  background: rgba(14,18,24,.94);
  border-bottom-color: var(--rule);
}
:root[data-theme="dark"] .brand-mark {
  background: var(--cream-200);
  color: var(--gold-700);
  box-shadow: 0 0 0 3px var(--cream-100), 0 0 0 4px var(--cream-200);
}
:root[data-theme="dark"] .brand-text .name { color: var(--ink-900); }
:root[data-theme="dark"] h1,
:root[data-theme="dark"] h2,
:root[data-theme="dark"] h3,
:root[data-theme="dark"] h4 { color: var(--ink-900); }
:root[data-theme="dark"] p { color: var(--ink-700); }
:root[data-theme="dark"] .lede,
:root[data-theme="dark"] .hero-lede { color: var(--ink-700); }
:root[data-theme="dark"] .nav-primary a { color: var(--ink-700); }
:root[data-theme="dark"] .nav-primary a:hover,
:root[data-theme="dark"] .nav-primary a.active { color: var(--ink-900); }
:root[data-theme="dark"] .nav-cta {
  background: var(--gold-600);
  color: #0e1218 !important;
}
:root[data-theme="dark"] .nav-cta:hover { background: var(--gold-700); color: #0e1218 !important; }
:root[data-theme="dark"] .icon-btn,
:root[data-theme="dark"] .lang-switch {
  background: var(--cream-100);
  border-color: var(--rule);
  color: var(--ink-700);
}
:root[data-theme="dark"] .lang-switch a { color: var(--ink-500); }
:root[data-theme="dark"] .lang-switch a.active {
  background: var(--gold-600);
  color: #0e1218;
}
:root[data-theme="dark"] .lang-switch a:first-child { border-right-color: var(--rule); }
:root[data-theme="dark"] .hero {
  background: linear-gradient(180deg, var(--cream-50) 0%, var(--paper) 100%);
}
:root[data-theme="dark"] .hero-tag {
  background: var(--cream-200);
  color: var(--maroon-500);
  border-color: var(--rule);
}
:root[data-theme="dark"] .hero-card {
  background: var(--cream-200);
  color: var(--ink-700);
  box-shadow: 0 30px 60px -30px rgba(0,0,0,.6);
}
:root[data-theme="dark"] .hero-card .big { color: var(--ink-900); }
:root[data-theme="dark"] .hero-card li { color: var(--ink-700); }
:root[data-theme="dark"] .hero-card .label { color: var(--gold-700); }
:root[data-theme="dark"] .hero-card .small { color: var(--ink-500); }
:root[data-theme="dark"] .stat .num { color: var(--ink-900); }
:root[data-theme="dark"] .stat .label { color: var(--ink-900); }
:root[data-theme="dark"] .stream-card,
:root[data-theme="dark"] .facility,
:root[data-theme="dark"] .contact-card,
:root[data-theme="dark"] .news-item {
  background: var(--cream-100);
  border-color: var(--rule);
}
:root[data-theme="dark"] .stream-card .desc,
:root[data-theme="dark"] .stream-card .full,
:root[data-theme="dark"] .facility p { color: var(--ink-500); }
:root[data-theme="dark"] .principal {
  background: var(--cream-50);
}
:root[data-theme="dark"] .portrait {
  background: var(--cream-200);
}
:root[data-theme="dark"] .portrait .name-tag {
  background: var(--paper);
  border-left-color: var(--gold-600);
}
:root[data-theme="dark"] .portrait .name-tag strong { color: var(--ink-900); }
:root[data-theme="dark"] .reasons {
  background: #060911;
  color: var(--ink-900);
}
:root[data-theme="dark"] .reasons h2,
:root[data-theme="dark"] .reasons .eyebrow,
:root[data-theme="dark"] .reason h3 { color: var(--ink-900); }
:root[data-theme="dark"] .reasons .lede,
:root[data-theme="dark"] .reason p { color: var(--ink-700); }
:root[data-theme="dark"] .closing {
  background:
    linear-gradient(180deg, rgba(6,9,17,.92), rgba(6,9,17,.92)),
    radial-gradient(circle at 70% 30%, var(--gold-600) 0%, transparent 50%);
  background-color: #060911;
}
:root[data-theme="dark"] .closing h2 { color: var(--ink-900); }
:root[data-theme="dark"] .site-footer {
  background: #060911;
}
:root[data-theme="dark"] form input,
:root[data-theme="dark"] form select,
:root[data-theme="dark"] form textarea {
  background: var(--cream-100);
  border-color: var(--rule);
  color: var(--ink-900);
}
:root[data-theme="dark"] .aside-card {
  background: var(--cream-100);
  border-left-color: var(--gold-600);
}
:root[data-theme="dark"] .map-frame {
  background-color: var(--cream-50);
  border-color: var(--rule);
}
:root[data-theme="dark"] .btn-primary {
  background: var(--gold-600);
  color: #0e1218;
}
:root[data-theme="dark"] .btn-primary:hover { background: var(--gold-700); color: #0e1218; }
:root[data-theme="dark"] .btn-ghost {
  color: var(--ink-900);
  border-color: var(--gold-600);
}
:root[data-theme="dark"] .btn-ghost:hover {
  background: var(--gold-600);
  color: #0e1218;
}

/* Honour OS preference when user hasn't chosen yet */
@media (prefers-color-scheme: dark) {
  html:not([data-theme]) {
    /* Same overrides as [data-theme="dark"] block above, applied via attribute selector. */
    /* JS adds data-theme=dark on first paint when no localStorage choice exists. */
  }
}

/* ---------- Print: keep it light + readable ---------- */
@media print {
  .topstrip, .site-header, .closing, .mobile-cta-bar, .nav-controls, .skip-link { display: none !important; }
  body { background: white; color: black; }
  a { color: #0d1e36; text-decoration: underline; }
}

/* ---------- High-contrast preference ---------- */
@media (prefers-contrast: more) {
  :root {
    --rule: #4d4631;
    --ink-700: #15181d;
    --ink-500: #2c303a;
  }
  .btn { border-width: 2px; }
  .nav-primary a:hover, .nav-primary a.active { border-bottom-width: 2.5px; }
}

/* ---------- Visually-hidden helper (for sr-only labels) ---------- */
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ---------- Degree-college specific helpers ---------- */
.deg-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.4rem;
}
.deg-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--maroon-500);
  padding: 1.8rem;
  transition: transform .25s var(--ease), border-color .25s;
}
.deg-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold-500);
}
.deg-card .code {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--maroon-700);
  letter-spacing: -0.01em;
  margin-bottom: 0.2rem;
}
.deg-card .full {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-500);
  margin: 0.3rem 0 1rem;
}
.deg-card p { font-size: 0.93rem; color: var(--ink-700); }
.deg-card .meta {
  list-style: none; padding: 0; margin: 1rem 0 0;
  border-top: 1px dashed var(--rule);
  padding-top: 0.9rem;
  display: grid; gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--ink-500);
}
.deg-card .meta strong { color: var(--indigo-900); margin-right: 6px; font-weight: 600; }
:root[data-theme="dark"] .deg-card { background: var(--cream-100); border-color: var(--rule); }
:root[data-theme="dark"] .deg-card p { color: var(--ink-700); }
:root[data-theme="dark"] .deg-card .meta strong { color: var(--ink-900); }

.notice {
  background: var(--cream-100);
  border-left: 3px solid var(--maroon-500);
  padding: 1rem 1.2rem;
  font-size: 0.92rem;
  color: var(--ink-700);
  border-radius: 0 4px 4px 0;
}
.notice strong { color: var(--indigo-900); }
:root[data-theme="dark"] .notice { background: var(--cream-100); color: var(--ink-700); }
:root[data-theme="dark"] .notice strong { color: var(--ink-900); }

/* ---------- Transport / EAMCET callout (small marketing tile) ---------- */
.callout {
  background: var(--cream-100);
  border: 1px solid var(--rule);
  border-left: 4px solid var(--gold-500);
  padding: 1.2rem 1.4rem;
  border-radius: 0 4px 4px 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.6rem 1rem;
  align-items: center;
  margin-block: 1.4rem;
}
.callout .pip {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-700);
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}
.callout strong { color: var(--indigo-900); }
.callout p { margin: 0; color: var(--ink-700); font-size: 0.93rem; }
:root[data-theme="dark"] .callout { background: var(--cream-100); }
:root[data-theme="dark"] .callout .pip { background: var(--paper); }
:root[data-theme="dark"] .callout strong { color: var(--ink-900); }
