/* Saint English Medium School — design system */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,600;0,9..144,700;1,9..144,400&family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --sem-ink: #0b1220;
  --sem-ink-soft: #1a2744;
  --sem-paper: #f6f3ec;
  --sem-paper-dark: #ebe6dc;
  --sem-gold: #b8860b;
  --sem-gold-bright: #d4a017;
  --sem-sage: #4a635f;
  --sem-cream: #fffdf8;
  --sem-line: rgba(11, 18, 32, 0.12);
  --sem-shadow: 0 24px 60px rgba(11, 18, 32, 0.12);
  --sem-radius: 14px;
  --sem-radius-sm: 8px;
  --sem-nav-h: 78px;
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Outfit', system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  line-height: 1.65;
  color: var(--sem-ink);
  background: var(--sem-paper);
  font-weight: 400;
}

/* ——— Navbar ——— */
.navbar-sem {
  background: rgba(255, 253, 248, 0.92) !important;
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sem-line);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
  min-height: var(--sem-nav-h);
  padding-top: 0.35rem !important;
  padding-bottom: 0.35rem !important;
  transition: box-shadow 0.3s ease, background 0.3s ease;
}

.navbar-sem .navbar-brand {
  color: var(--sem-ink) !important;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  max-width: min(100%, 240px);
  line-height: 1.2;
}

.navbar-brand-text {
  font-family: var(--font-display), Georgia, serif;
  font-size: clamp(0.82rem, 2.5vw, 1rem);
}

.navbar-sem .navbar-brand img,
.navbar-sem .school-logo {
  height: 56px;
  max-width: 72px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--sem-line);
  background: var(--sem-cream);
}

/* Nav: uniform gaps between links; centered between logo and account (desktop) */
.navbar-sem .navbar-sem-nav {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  column-gap: 0.5rem;
  row-gap: 0.4rem;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.navbar-sem .navbar-sem-nav .nav-link {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

@media (min-width: 992px) {
  /*
   * Grid fixes “nav stuck left, blank on right”: middle column is 1fr so links
   * truly sit in the center of the bar between logo and account button.
   * (Bootstrap’s flex navbar + flex-basis:auto keeps collapse only as wide as the <ul>.)
   */
  .navbar-sem > .container {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: 0.75rem;
  }

  .navbar-sem .navbar-brand {
    grid-column: 1;
    justify-self: start;
  }

  .navbar-sem.navbar-expand-lg .navbar-collapse.navbar-sem-collapse {
    grid-column: 2;
    width: 100%;
    min-width: 0;
    display: flex !important;
    justify-content: center !important;
    align-items: center;
    flex: none !important;
    flex-basis: auto !important;
  }

  .navbar-sem .user-icon-btn {
    grid-column: 3;
    justify-self: end;
    margin-left: 0 !important;
  }
}

.navbar-sem .navbar-nav .nav-link {
  color: var(--sem-ink-soft) !important;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 0.45rem 0.7rem !important;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

.navbar-sem .navbar-nav .nav-link:hover {
  color: var(--sem-ink) !important;
  background: rgba(184, 134, 11, 0.12);
}

.navbar-sem .navbar-nav .nav-link.active {
  color: var(--sem-ink) !important;
  background: linear-gradient(135deg, rgba(184, 134, 11, 0.2), rgba(74, 99, 95, 0.12));
  font-weight: 600;
}

.navbar-sem .navbar-nav .nav-link::after {
  display: none;
}

.navbar-sem .dropdown-menu {
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius-sm);
  box-shadow: var(--sem-shadow);
  padding: 0.5rem;
}

.navbar-sem .dropdown-item {
  border-radius: 6px;
  font-size: 0.9rem;
}

.navbar-sem .dropdown-item:hover {
  background: rgba(184, 134, 11, 0.12);
  color: var(--sem-ink);
}

.navbar-sem .navbar-toggler {
  border: 1px solid var(--sem-line);
  padding: 0.4rem 0.55rem;
}

.user-icon-btn {
  background: var(--sem-cream) !important;
  border: 1px solid var(--sem-line) !important;
  box-shadow: none !important;
}

.user-icon-btn i {
  color: var(--sem-gold) !important;
}

@media (max-width: 991.98px) {
  .navbar-sem .navbar-sem-nav {
    width: 100%;
    padding-top: 0.35rem;
  }
  .navbar-sem .navbar-collapse {
    background: var(--sem-ink) !important;
    padding: 1rem 1.25rem 1.25rem !important;
    border-radius: 0 0 var(--sem-radius) var(--sem-radius);
    margin-top: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  .navbar-sem .navbar-nav .nav-link {
    color: rgba(255, 253, 248, 0.92) !important;
    border-radius: var(--sem-radius-sm);
  }
  .navbar-sem .navbar-nav .nav-link:hover,
  .navbar-sem .navbar-nav .nav-link.active {
    background: rgba(212, 160, 23, 0.2);
    color: #fff !important;
  }
  .navbar-sem .navbar-nav .dropdown-menu {
    background: var(--sem-ink-soft);
    border-color: rgba(255, 255, 255, 0.1);
  }
  .navbar-sem .navbar-nav .dropdown-item {
    color: rgba(255, 253, 248, 0.9);
  }
  .navbar-sem .navbar-nav .dropdown-item:hover {
    background: rgba(212, 160, 23, 0.15);
    color: #fff;
  }
}

/* ——— Hero (home) ——— */
.hero-sem {
  position: relative;
  min-height: 100vh;
  padding-top: var(--sem-nav-h);
  overflow: hidden;
  background-color: var(--sem-ink);
}

.hero-sem__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: saturate(0.85) contrast(1.05);
}

.hero-sem__mesh {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(11, 18, 32, 0.94) 0%, rgba(11, 18, 32, 0.78) 38%, rgba(26, 39, 68, 0.55) 62%, rgba(74, 99, 95, 0.35) 100%),
    radial-gradient(ellipse 80% 50% at 100% 0%, rgba(212, 160, 23, 0.2), transparent 50%);
  pointer-events: none;
}

.hero-sem__inner {
  position: relative;
  z-index: 1;
  min-height: calc(100vh - var(--sem-nav-h));
  display: flex;
  align-items: center;
  padding: 3rem 0 4rem;
}

.hero-sem__kicker {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--sem-gold-bright);
  margin-bottom: 1rem;
}

.hero-sem__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.1rem, 5vw, 3.75rem);
  line-height: 1.08;
  color: #fff;
  margin-bottom: 1.25rem;
}

.hero-sem__title em {
  font-style: italic;
  font-weight: 500;
  color: rgba(255, 253, 248, 0.88);
}

.hero-sem__lead {
  font-size: 1.1rem;
  max-width: 34rem;
  color: rgba(255, 253, 248, 0.82);
  font-weight: 300;
  margin-bottom: 2rem;
}

.hero-sem__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero-sem__frame {
  position: relative;
  border-radius: var(--sem-radius);
  border: 1px solid rgba(255, 253, 248, 0.2);
  background: linear-gradient(160deg, rgba(255, 253, 248, 0.08), rgba(255, 253, 248, 0.02));
  min-height: 280px;
  display: flex;
  align-items: flex-end;
  padding: 1.5rem;
  overflow: hidden;
}

.hero-sem__frame::before {
  content: '';
  position: absolute;
  inset: -40%;
  background: conic-gradient(from 210deg at 50% 50%, rgba(212, 160, 23, 0.15), transparent, rgba(74, 99, 95, 0.2), transparent);
  animation: sem-spin 28s linear infinite;
}

@keyframes sem-spin {
  to {
    transform: rotate(360deg);
  }
}

.hero-sem__badge {
  position: relative;
  z-index: 1;
  background: var(--sem-cream);
  color: var(--sem-ink);
  padding: 1rem 1.25rem;
  border-radius: var(--sem-radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  max-width: 100%;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.stats-strip {
  position: relative;
  z-index: 2;
  margin-top: -3rem;
  margin-bottom: 0;
}

.stats-strip__inner {
  background: var(--sem-cream);
  border-radius: var(--sem-radius);
  border: 1px solid var(--sem-line);
  box-shadow: var(--sem-shadow);
  padding: 1.75rem 2rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  text-align: center;
}

.stats-strip__num {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--sem-gold);
  line-height: 1;
}

.stats-strip__label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--sem-sage);
  margin-top: 0.35rem;
}

@media (max-width: 767.98px) {
  .stats-strip__inner {
    grid-template-columns: 1fr;
    text-align: left;
    padding: 1.25rem 1.5rem;
  }
  .stats-strip__num {
    font-size: 1.5rem;
  }
}

/* ——— Page shell (inner pages) ——— */
.page-shell {
  padding-top: calc(var(--sem-nav-h) + 2.5rem);
  padding-bottom: 4rem;
}

.page-hero {
  padding: 2.5rem 0 3rem;
  margin-bottom: 2.5rem;
  background: linear-gradient(180deg, var(--sem-paper-dark) 0%, var(--sem-paper) 100%);
  border-bottom: 1px solid var(--sem-line);
}

.page-hero__eyebrow {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sem-sage);
  margin-bottom: 0.75rem;
}

.page-hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--sem-ink);
  line-height: 1.15;
}

.page-hero__sub {
  max-width: 36rem;
  margin-top: 1rem;
  color: rgba(11, 18, 32, 0.72);
  font-size: 1.05rem;
}

/* ——— Sections ——— */
.section-block {
  padding: 4rem 0;
}

.section-block--alt {
  background: var(--sem-cream);
  border-top: 1px solid var(--sem-line);
  border-bottom: 1px solid var(--sem-line);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 3px solid var(--sem-gold);
}

.section-head h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  margin: 0;
  color: var(--sem-ink);
}

.section-head p {
  margin: 0;
  max-width: 28rem;
  color: rgba(11, 18, 32, 0.65);
  font-size: 0.95rem;
}

/* Mission / vision panels */
.sem-panels {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 991.98px) {
  .sem-panels {
    grid-template-columns: 1fr;
  }
}

.sem-panel {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 2rem 2rem 2rem 1.75rem;
  position: relative;
  box-shadow: 0 4px 0 var(--sem-gold);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.sem-panel:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(11, 18, 32, 0.08), 0 4px 0 var(--sem-gold);
}

.sem-panel__icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(184, 134, 11, 0.2), rgba(74, 99, 95, 0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  color: var(--sem-gold);
  margin-bottom: 1rem;
}

.sem-panel h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
  color: var(--sem-ink);
}

.sem-panel p {
  margin: 0;
  color: rgba(11, 18, 32, 0.75);
}

/* Feature grid (about / academy) */
.sem-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

@media (max-width: 991.98px) {
  .sem-features {
    grid-template-columns: 1fr;
  }
}

.sem-feature {
  border-radius: var(--sem-radius);
  padding: 1.75rem;
  background: var(--sem-ink);
  color: rgba(255, 253, 248, 0.9);
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
}

.sem-feature:nth-child(2) {
  background: linear-gradient(145deg, var(--sem-sage), #2d3d3a);
}

.sem-feature:nth-child(3) {
  background: linear-gradient(145deg, var(--sem-gold), #8a6508);
  color: var(--sem-ink);
}

.sem-feature__num {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 700;
  opacity: 0.15;
  line-height: 1;
}

.sem-feature h4 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.sem-feature p {
  font-size: 0.9rem;
  opacity: 0.88;
  margin: 0;
}

/* Story band */
.sem-story {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 2.5rem;
  align-items: start;
}

@media (max-width: 991.98px) {
  .sem-story {
    grid-template-columns: 1fr;
  }
}

.sem-story__aside {
  background: var(--sem-ink);
  color: var(--sem-cream);
  padding: 2rem;
  border-radius: var(--sem-radius);
  position: sticky;
  top: calc(var(--sem-nav-h) + 1rem);
}

.sem-story__aside h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--sem-gold-bright);
}

.sem-story__body p {
  margin-bottom: 1.1rem;
  color: rgba(11, 18, 32, 0.78);
}

.sem-story__body p:last-child {
  margin-bottom: 0;
}

/* ——— Contact layout ——— */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 2rem;
  align-items: start;
}

@media (max-width: 991.98px) {
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

.contact-stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-tile {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 1.35rem 1.5rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  transition: border-color 0.2s ease;
}

.contact-tile:hover {
  border-color: rgba(184, 134, 11, 0.45);
}

.contact-tile i {
  font-size: 1.5rem;
  color: var(--sem-gold);
  flex-shrink: 0;
}

.contact-form-card {
  background: var(--sem-cream);
  border-radius: var(--sem-radius);
  border: 1px solid var(--sem-line);
  padding: 2rem;
  box-shadow: var(--sem-shadow);
}

.contact-form-card h3 {
  font-family: var(--font-display);
  margin-bottom: 1.25rem;
}

.map-wrap {
  border-radius: var(--sem-radius);
  overflow: hidden;
  border: 1px solid var(--sem-line);
  box-shadow: var(--sem-shadow);
  margin-top: 2.5rem;
}

.map-wrap iframe {
  width: 100%;
  min-height: 360px;
  border: 0;
  display: block;
}

/* ——— Admission ——— */
.sem-age-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

@media (max-width: 767.98px) {
  .sem-age-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.sem-age-chip {
  text-align: center;
  padding: 1.25rem 0.75rem;
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius-sm);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.sem-age-chip:hover {
  background: rgba(184, 134, 11, 0.1);
  border-color: var(--sem-gold);
}

.sem-age-chip strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--sem-ink);
}

.sem-age-band {
  background: linear-gradient(90deg, var(--sem-ink) 0%, var(--sem-ink-soft) 50%, var(--sem-sage) 100%);
  color: var(--sem-cream);
  border-radius: var(--sem-radius);
  padding: 2rem;
  margin-bottom: 2.5rem;
}

.sem-age-band h3 {
  font-family: var(--font-display);
  margin-bottom: 1.25rem;
  color: var(--sem-gold-bright);
}

.sem-timeline {
  position: relative;
  padding-left: 2.5rem;
}

.sem-timeline::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(var(--sem-gold), var(--sem-sage));
  border-radius: 2px;
}

.sem-timeline__item {
  position: relative;
  padding-bottom: 2rem;
}

.sem-timeline__item:last-child {
  padding-bottom: 0;
}

.sem-timeline__dot {
  position: absolute;
  left: -2.5rem;
  top: 0.15rem;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--sem-cream);
  border: 3px solid var(--sem-gold);
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--sem-ink);
}

.sem-rules {
  columns: 2;
  column-gap: 2rem;
}

@media (max-width: 767.98px) {
  .sem-rules {
    columns: 1;
  }
}

.sem-rule {
  break-inside: avoid;
  display: flex;
  gap: 0.65rem;
  padding: 0.65rem 0;
  border-bottom: 1px dashed var(--sem-line);
  font-size: 0.95rem;
}

.sem-rule i {
  color: var(--sem-sage);
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.sem-split-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 767.98px) {
  .sem-split-cards {
    grid-template-columns: 1fr;
  }
}

.sem-split-card {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 1.75rem;
}

.sem-split-card h4 {
  font-family: var(--font-display);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--sem-gold);
}

/* ——— Academy bento ——— */
.sem-bento {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

.sem-bento__cell {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.sem-bento__cell--accent {
  background: var(--sem-ink);
  color: var(--sem-cream);
  border-color: transparent;
}

.sem-bento__cell--accent h4 {
  color: var(--sem-gold-bright);
}

@media (min-width: 992px) {
  .sem-bento {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: auto auto;
  }
  .sem-bento__hero {
    grid-column: 1 / 2;
    grid-row: 1 / 3;
  }
  .sem-bento__cell:nth-of-type(2) {
    grid-column: 2;
    grid-row: 1;
  }
  .sem-bento__cell:nth-of-type(3) {
    grid-column: 2;
    grid-row: 2;
  }
  .sem-bento__span {
    grid-column: 1 / -1;
    grid-row: 3;
  }
}

.sem-bento__cell h4 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.sem-bento__cell p,
.sem-bento__cell li {
  font-size: 0.92rem;
  color: rgba(11, 18, 32, 0.75);
}

.sem-bento__cell--accent p,
.sem-bento__cell--accent li {
  color: rgba(255, 253, 248, 0.85);
}

/* ——— Facility rows ——— */
.sem-facility-row {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 1.5rem;
  align-items: start;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--sem-line);
}

.sem-facility-row:first-of-type {
  padding-top: 0;
}

.sem-facility-row:last-child {
  border-bottom: none;
}

.sem-facility-row__icon {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: var(--sem-paper-dark);
  border: 2px solid var(--sem-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--sem-ink);
}

.sem-facility-row:nth-child(even) .sem-facility-row__icon {
  background: var(--sem-ink);
  color: var(--sem-gold-bright);
  border-color: rgba(212, 160, 23, 0.5);
}

.sem-facility-row h4 {
  font-family: var(--font-display);
  margin-bottom: 0.5rem;
}

.sem-facility-wrap {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 0 2rem;
  margin-top: 1rem;
}

@media (max-width: 575.98px) {
  .sem-facility-row {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .sem-facility-row__icon {
    margin: 0 auto;
  }
}

/* ——— Gallery ——— */
.sem-gallery {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1rem;
}

.sem-gallery figure {
  margin: 0;
}

.sem-gallery__item {
  grid-column: span 4;
  position: relative;
  border-radius: var(--sem-radius);
  overflow: hidden;
  aspect-ratio: 4/3;
  border: 1px solid var(--sem-line);
}

.sem-gallery__item:nth-child(1) {
  grid-column: span 8;
  aspect-ratio: 16/9;
}

.sem-gallery__item:nth-child(4) {
  grid-column: span 6;
}

.sem-gallery__item:nth-child(5) {
  grid-column: span 6;
}

@media (max-width: 991.98px) {
  .sem-gallery__item,
  .sem-gallery__item:nth-child(1),
  .sem-gallery__item:nth-child(4),
  .sem-gallery__item:nth-child(5) {
    grid-column: span 12;
    aspect-ratio: 4/3;
  }
}

.sem-gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.sem-gallery__item:hover img {
  transform: scale(1.06);
}

.sem-gallery__cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1rem 1.25rem;
  background: linear-gradient(transparent, rgba(11, 18, 32, 0.88));
  color: #fff;
  font-weight: 500;
  font-size: 0.95rem;
}

/* ——— Mandatory disclosure ——— */
.disclosure-page .page-hero__title {
  font-size: clamp(1.65rem, 3vw, 2.25rem);
}

.sem-disclosure-card {
  background: var(--sem-cream);
  border: 1px solid var(--sem-line);
  border-radius: var(--sem-radius);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}

.sem-disclosure-card h4 {
  font-family: var(--font-display);
  text-align: center;
  margin-bottom: 1.25rem;
  color: var(--sem-ink);
}

.table-sem thead th {
  background: var(--sem-ink) !important;
  color: var(--sem-cream) !important;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border: none !important;
  padding: 0.9rem !important;
}

.table-sem tbody tr:nth-child(even) {
  background: rgba(246, 243, 236, 0.6);
}

.table-sem td,
.table-sem th {
  vertical-align: middle;
  font-size: 0.88rem;
}

/* ——— Footer ——— */
.footer-sem {
  background: var(--sem-ink);
  color: rgba(255, 253, 248, 0.85);
  padding: 3.5rem 0 2rem;
  margin-top: 0;
  position: relative;
}

.footer-sem::before {
  content: '';
  display: block;
  height: 6px;
  width: 100%;
  position: absolute;
  top: 0;
  left: 0;
  background: linear-gradient(90deg, var(--sem-gold), var(--sem-sage), var(--sem-gold-bright));
}

.footer-sem h5 {
  font-family: var(--font-display);
  color: #fff;
  font-size: 1.15rem;
  margin-bottom: 1rem;
}

.footer-sem .brand-lockup {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.footer-sem .brand-lockup img {
  height: 48px;
  width: auto;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.footer-sem a {
  color: rgba(255, 253, 248, 0.75);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-sem a:hover {
  color: var(--sem-gold-bright) !important;
}

.footer-sem .social-links a {
  display: inline-flex;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(255, 253, 248, 0.2);
  margin-right: 0.5rem;
}

.footer-sem .social-links a:hover {
  border-color: var(--sem-gold);
  transform: translateY(-2px);
}

.footer-sem .quick-links-col ul {
  padding: 0;
  margin: 0;
}

.footer-sem .quick-links-col li {
  margin-bottom: 0.5rem;
}

.footer-sem hr {
  border-color: rgba(255, 253, 248, 0.12);
  opacity: 1;
}

/* ——— Buttons (override Bootstrap) ——— */
.btn-sem-primary {
  background: var(--sem-gold);
  border: none;
  color: var(--sem-ink);
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-sem-primary:hover {
  background: var(--sem-gold-bright);
  color: var(--sem-ink);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(184, 134, 11, 0.35);
}

.btn-sem-ghost {
  background: transparent;
  border: 2px solid rgba(255, 253, 248, 0.65);
  color: #fff;
  font-weight: 600;
  padding: 0.6rem 1.45rem;
  border-radius: 999px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.btn-sem-ghost:hover {
  background: rgba(255, 253, 248, 0.12);
  border-color: #fff;
  color: #fff;
}

.btn-primary,
.offcanvas .auth-toggle .btn.btn-primary {
  background: var(--sem-ink) !important;
  border: none !important;
  border-radius: 999px !important;
  font-weight: 600;
  padding: 0.55rem 1.35rem;
  color: #fff !important;
}

.btn-primary:hover {
  background: var(--sem-ink-soft) !important;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(11, 18, 32, 0.2);
}

.btn-outline-primary {
  border-color: var(--sem-ink) !important;
  color: var(--sem-ink) !important;
  border-radius: 999px !important;
  font-weight: 600;
}

.btn-outline-primary:hover {
  background: var(--sem-ink) !important;
  color: #fff !important;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--sem-gold);
  box-shadow: 0 0 0 0.2rem rgba(184, 134, 11, 0.2);
}

/* ——— Back to top & WhatsApp ——— */
.back-to-top {
  background: var(--sem-ink) !important;
  border: 2px solid var(--sem-gold) !important;
  color: var(--sem-gold-bright) !important;
}

.back-to-top:hover {
  background: var(--sem-gold) !important;
  color: var(--sem-ink) !important;
  border-color: var(--sem-gold) !important;
}

.whatsapp-float {
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
}

/* ——— User panel ——— */
.user-panel {
  --bs-offcanvas-width: min(420px, 92vw);
}

.offcanvas-header {
  border-bottom: 1px solid var(--sem-line);
}

.offcanvas-title {
  font-family: var(--font-display);
}

/* ——— Legacy compatibility ——— */
.main-page-section {
  background: var(--sem-paper);
  padding-top: 0;
}

.section-content {
  padding: 0;
  animation: none;
}

.underline {
  display: none;
}

.card {
  border-radius: var(--sem-radius);
  border: 1px solid var(--sem-line);
}

.contact-link {
  color: var(--sem-ink);
  font-weight: 600;
}

.contact-link:hover {
  color: var(--sem-gold);
}

.social-icons .social-circle {
  border-color: var(--sem-line);
  color: var(--sem-ink);
}

.social-icons .social-circle:hover {
  background: var(--sem-ink);
  color: var(--sem-gold-bright);
  border-color: var(--sem-ink);
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--sem-paper-dark);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(var(--sem-gold), var(--sem-sage));
  border-radius: 6px;
}

/* Collapse toggle on contact */
#contactFormToggle.collapsed {
  opacity: 1;
}
