:root {
  --ink: #253442;
  --muted: #69737d;
  --line: #e5e4e2;
  --paper: #ffffff;
  --soft: #faf8f4;
  --navy: #123f63;
  --purple: #8c174d;
  --red: #e31f2b;
  --gold: #d5a11e;
  --green: #2d8e3f;
  --accent: #8c174d;
  --accent2: #e1b72f;
  --danger: #a72d2d;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Noto Sans Bengali", "Hind Siliguri", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #f3f5f5;
}
a { color: inherit; }
.shell { width: min(1120px, 94vw); margin: 0 auto; }
.topbar { background: linear-gradient(90deg,#123f63,#7d164c); color: #fff; padding: 9px 0; font-size: 13px; }
.topbar-inner { display:flex; justify-content:space-between; gap:18px; flex-wrap:wrap; }
.brand {
  display: grid;
  grid-template-columns: 150px minmax(0,1fr);
  gap: 22px;
  align-items: center;
  padding: 18px 0 20px;
}
.brand-logo { width: 145px; height: 145px; object-fit: contain; filter: drop-shadow(0 8px 16px rgba(15,45,55,.08)); }
.brand-copy { text-align: center; }
.brand .eyebrow, .eyebrow { color: var(--purple); font-weight: 800; letter-spacing: .01em; }
.brand h1 { margin: 4px 0 0; font-size: clamp(25px, 4vw, 40px); line-height: 1.12; color: #173d59; }
.brand p { margin: 7px 0 0; color: var(--ink); font-size: 17px; font-weight: 700; }
.brand-location { margin-top: 3px; color: var(--muted); font-size: 14px; }
nav { background: #fff; border-block: 1px solid var(--line); box-shadow: 0 2px 12px rgba(10,30,40,.03); }
nav .shell { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 0; }
nav a { text-decoration: none; padding: 9px 12px; border-radius: 8px; font-weight: 650; }
nav a:hover { background: #f7f1f4; color: var(--purple); }
.hero {
  min-height: 400px;
  display: grid;
  place-items: center;
  background: linear-gradient(rgba(9,33,50,.73), rgba(88,15,51,.69)), url('/assets/school.webp') center/cover;
  color: #fff;
}
.hero-card { width: min(820px, 92vw); text-align: center; padding: 44px 22px; }
.hero-kicker { font-size: 18px; font-weight: 800; color: #f4d864; }
.hero h2 { font-size: clamp(38px, 6vw, 68px); margin: 4px 0 10px; line-height:1.05; }
.hero p { font-size: 18px; line-height: 1.75; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 20px; }
.btn {
  appearance: none; border: 0; border-radius: 10px; padding: 12px 18px; cursor: pointer;
  background: var(--accent); color: #fff; font-weight: 750; text-decoration: none; display: inline-block;
}
.btn:hover { filter: brightness(.96); }
.btn.alt { background: #fff; color: var(--ink); }
.btn.warn { background: var(--accent2); color: #25300f; }
.btn.small { padding: 8px 11px; font-size: 13px; }
main { padding: 26px 0 50px; }
.page-heading { text-align:center; margin: 0 auto 20px; max-width:760px; }
.page-heading h2 { margin:4px 0 3px; font-size:clamp(26px,4vw,38px); color:#173d59; }
.page-heading p { margin:4px 0; color:var(--muted); }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 22px; box-shadow: 0 8px 30px rgba(28,60,50,.06); }
.grid { display: grid; gap: 18px; }
.grid.two { grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0,1fr)); }
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.card h3 { margin-top: 0; color:#173d59; }
.section-title { margin: 24px 0 12px; padding-bottom: 8px; border-bottom: 2px solid #ede5d2; color:#173d59; }
label { display: block; font-weight: 650; font-size: 14px; margin-bottom: 5px; }
input, select, textarea {
  width: 100%; border: 1px solid #d1d8db; border-radius: 9px; padding: 11px 12px; background: #fff; color: var(--ink); font: inherit;
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(140,23,77,.10); border-color: var(--purple); }
.field { min-width: 0; }
.help { color: var(--muted); font-size: 12px; margin-top: 5px; }
.checkline { display: flex; gap: 9px; align-items: flex-start; }
.checkline input { width: auto; margin-top: 4px; }
.notice { padding: 12px 14px; border-radius: 10px; background: #fffaf0; border: 1px solid #ead9ac; margin: 12px 0; }
.notice.error { background: #fff1f1; border-color: #efcaca; color: #7f1d1d; }
.notice.success { background: #eef9f0; border-color: #cbe7d1; color: #17572a; }
.summary { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.metric { background: var(--soft); border-radius: 12px; padding: 16px; border-top:3px solid var(--gold); }
.metric strong { display: block; font-size: 28px; color:#173d59; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { border-bottom: 1px solid var(--line); padding: 9px 8px; text-align: left; vertical-align: top; }
th { background: var(--soft); position: sticky; top: 0; }
.table-wrap { overflow: auto; max-height: 62vh; border: 1px solid var(--line); border-radius: 10px; }
.badge { display: inline-block; padding: 4px 8px; border-radius: 99px; background: #e8f0ed; font-size: 12px; font-weight: 700; }
.badge.ok { background: #dff4e5; color: #155c2b; }
.badge.pending { background: #fff3cf; color: #6e5200; }
.badge.bad { background: #fbe1e1; color: #7d2020; }
.id-card {
  width: min(680px, 100%); margin: 0 auto; background: linear-gradient(145deg,#fff,#fffaf0); border: 2px solid #173d59;
  border-radius: 18px; padding: 22px; position: relative; overflow: hidden; box-shadow: 0 12px 34px rgba(16,51,72,.10);
}
.id-card:before { content:""; position:absolute; inset:0 0 auto; height:7px; background:linear-gradient(90deg,#e4b323,#e31f2b,#8c174d,#1a91c4,#2d8e3f); }
.id-head { display: grid; grid-template-columns: 100px 1fr; gap: 14px; align-items: center; text-align: center; }
.id-head img.id-brand-logo { width: 96px; height: 96px; object-fit: contain; }
.id-head small { color:var(--muted); line-height:1.45; }
.id-head strong { display:inline-block; margin-top:5px; color:var(--purple); letter-spacing:.04em; }
.id-photo { width: 140px; height: 165px; object-fit: cover; border: 1px solid var(--line); border-radius: 10px; background: #eee; }
.id-body { display: grid; grid-template-columns: 150px 1fr; gap: 20px; margin-top: 20px; align-items: center; }
footer { color: var(--muted); font-size: 13px; padding: 28px 0; text-align: center; line-height:1.6; }
footer strong { color:#173d59; }
@media (max-width: 760px) {
  .topbar-inner { justify-content:center; text-align:center; gap:3px 14px; }
  .brand { grid-template-columns: 96px minmax(0,1fr); gap: 10px; padding:12px 0 14px; }
  .brand-logo { width: 92px; height: 92px; }
  .brand h1 { font-size: clamp(21px,6vw,30px); }
  .brand p { font-size:14px; }
  .brand-location { font-size:12px; }
  .grid.two, .grid.three, .summary { grid-template-columns: 1fr; }
  .id-head { grid-template-columns: 84px 1fr; }
  .id-head img.id-brand-logo { width:80px;height:80px; }
  .id-body { grid-template-columns: 1fr; text-align: center; }
  .id-photo { margin: 0 auto; }
}
@media (max-width: 480px) {
  .brand { grid-template-columns: 1fr; text-align:center; }
  .brand-logo { margin:0 auto; width:112px; height:112px; }
  nav .shell { justify-content:center; }
}
@media print {
  nav, .topbar, .no-print, footer { display: none !important; }
  body { background: #fff; }
  main { padding: 0; }
  .panel { box-shadow: none; border: 0; padding: 0; }
  .id-card { margin-top: 20mm; box-shadow:none; }
}

/* v0.2 portal header + fee module */
.brand.brand-three {
  grid-template-columns: 150px minmax(0,1fr) 150px;
  gap: 22px;
}
.brand-logo-wrap { display:flex; align-items:center; justify-content:center; }
.brand-logo-wrap .brand-logo { mix-blend-mode: multiply; background: transparent; }
.founder-wrap { text-align:center; align-self:center; }
.founder-photo {
  width: 112px; height: 112px; object-fit: cover; object-position: 50% 24%;
  border-radius: 50%; border: 4px solid #fff; outline: 1px solid #d5c89d;
  box-shadow: 0 8px 22px rgba(20,45,55,.14);
}
.founder-caption { margin-top:7px; color:var(--muted); font-size:11px; line-height:1.35; }
.founder-caption strong { color:#173d59; font-size:12px; }
.grid.four { grid-template-columns: repeat(4,minmax(0,1fr)); }
.fee-rate-strip {
  align-self:end; padding:12px 14px; border:1px solid #e6dbc0; border-radius:10px;
  background:#fffaf0; color:#5f4b14; font-size:13px; line-height:1.55;
}
.fee-box {
  display:grid; grid-template-columns:minmax(0,1fr) auto; gap:24px; align-items:center;
  margin-top:20px; padding:18px 20px; border:1px solid #d8d0b6; border-radius:14px;
  background:linear-gradient(135deg,#fffdf6,#f5faf7); box-shadow:0 8px 24px rgba(30,60,45,.05);
}
.fee-breakdown { margin-top:7px; color:var(--ink); line-height:1.75; }
.fee-total { min-width:150px; text-align:right; border-left:1px solid #e4dfcf; padding-left:22px; }
.fee-total span { display:block; color:var(--muted); font-size:13px; }
.fee-total strong { display:block; color:var(--purple); font-size:34px; line-height:1.2; }
.admin-section-head { display:flex; justify-content:space-between; gap:18px; align-items:center; margin-bottom:16px; }

@media (max-width: 900px) {
  .brand.brand-three { grid-template-columns: 110px minmax(0,1fr) 105px; gap:12px; }
  .founder-photo { width:86px; height:86px; }
  .founder-caption strong { font-size:11px; }
  .grid.four { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width: 760px) {
  .brand.brand-three { grid-template-columns: 82px minmax(0,1fr) 78px; }
  .brand.brand-three .brand-logo { width:80px; height:80px; }
  .founder-photo { width:66px; height:66px; border-width:2px; }
  .founder-caption { display:none; }
  .fee-box { grid-template-columns:1fr; gap:12px; }
  .fee-total { border-left:0; border-top:1px solid #e4dfcf; padding:12px 0 0; text-align:left; }
  .admin-section-head { align-items:flex-start; flex-direction:column; }
}
@media (max-width: 520px) {
  .brand.brand-three { grid-template-columns: 1fr 72px; }
  .brand.brand-three .brand-logo-wrap { display:none; }
  .brand.brand-three .brand-copy { text-align:left; }
  .grid.four { grid-template-columns:1fr; }
}


/* --- KSV AWS HEADER FINAL ALIGNMENT --- */
.brand.brand-three {
  grid-template-columns: 170px minmax(0, 1fr) 170px;
  gap: 22px;
  overflow: visible;
  margin-bottom: 38px;
}
.brand-logo-wrap,
.founder-wrap {
  position: relative;
  width: 150px;
  height: 150px;
  min-width: 150px;
  min-height: 150px;
  margin: 0 auto;
  padding: 0;
  align-self: center;
  display: block;
  overflow: visible;
}
.brand-logo-wrap .brand-logo {
  display: block;
  width: 150px !important;
  height: 150px !important;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: contain;
  background: transparent;
  mix-blend-mode: multiply;
  opacity: .96;
  filter: none;
}
.founder-photo {
  display: block;
  width: 150px !important;
  height: 150px !important;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: cover;
  object-position: 50% 24%;
}
.founder-caption {
  position: absolute;
  top: 158px;
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  margin: 0;
  padding: 0;
  text-align: center;
  line-height: 1.18;
}
.founder-caption span,
.founder-caption strong { display: block; }
.founder-caption strong { white-space: nowrap; }
@media (max-width: 900px) {
  .brand.brand-three { grid-template-columns: 130px minmax(0,1fr) 130px; }
  .brand-logo-wrap,.founder-wrap { width:116px;height:116px;min-width:116px;min-height:116px; }
  .brand-logo-wrap .brand-logo,.founder-photo { width:116px !important;height:116px !important; }
  .founder-caption { top:123px; }
}
@media (max-width: 760px) {
  .brand.brand-three { grid-template-columns:82px minmax(0,1fr) 82px; margin-bottom:0; }
  .brand-logo-wrap,.founder-wrap { width:74px;height:74px;min-width:74px;min-height:74px; }
  .brand-logo-wrap .brand-logo,.founder-photo { width:74px !important;height:74px !important; }
  .founder-caption { display:none; }
}
