html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 0;
  padding-top: 0;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* ===== Hero Slider ===== */
.hero-slide {
  min-height: 100vh;
  background: linear-gradient(135deg, #161d30 0%, #202C45 50%, #1a2a4a 100%);
  background-size: cover;
  background-position: center;
  position: relative;
}

.hero-slide-overlay {
  position: absolute;
  inset: 0;
}

#heroCarousel .carousel-item {
  transition: transform 0.8s ease-in-out;
}

/* ===== Hero slide: where our alumni study ===== */
.hero-colleges {
  background: linear-gradient(135deg, #161d30 0%, #202C45 55%, #1a2a4a 100%);
}

.college-heading {
  font-size: clamp(1.8rem, 4vw, 3rem);
}

.college-sub {
  color: rgba(255, 255, 255, 0.72);
}

/* Flex rather than grid so a short last row sits centred under the rest
   instead of hanging off the left edge. */
.college-wall {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
  max-width: 1020px;
}

/* A tile holds either a logo file or, until one is added, the school's name. */
/* Light tiles: these are the schools' own logos in their own colours, and most of
   them are dark ink meant for a white page. */
.college-chip {
  flex: 0 0 186px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  min-height: 92px;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.75rem;
  background: #fff;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.college-chip:hover {
  box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.35);
  transform: translateY(-2px);
}

.college-logo {
  max-height: 46px;
  max-width: 100%;
  object-fit: contain;
}

/* A white reverse mark would vanish on the light tile; render it solid dark instead.
   brightness(0) flattens whatever colour is there to black without recolouring it. */
.college-logo--reverse {
  filter: brightness(0) opacity(0.82);
}

.college-mark {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: #202c45;
  line-height: 1.1;
}

.college-full {
  font-size: 0.74rem;
  line-height: 1.25;
  color: #5d6676;
}

/* ===== Hero slide: the two schools side by side ===== */
.hero-campuses {
  background: linear-gradient(135deg, #161d30 0%, #202C45 55%, #1a2a4a 100%);
}

/* Flex column so the figures line up across both panels even when one school has
   a mascot line above them and the other does not. */
.campus-panel {
  display: flex;
  flex-direction: column;
  padding: 1.75rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.05);
}

/* A white card behind the crest, because the school marks are navy on transparent
   and would disappear straight into the slide. */
.campus-crest {
  align-self: center;   /* the panel is a flex column; don't stretch the card */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  border-radius: 0.6rem;
  background: #fff;
}

/* Sized for a roughly square mascot; a wide wordmark used as the fallback is held
   back by the width instead. */
.campus-crest img {
  max-height: 110px;
  max-width: 220px;
  object-fit: contain;
}

.campus-mascot {
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--brand-gold, #feb600);
  font-weight: 600;
}

/* auto keeps the figures on the bottom edge, so they line up across both panels
   whether or not the school above them has a mascot line. */
.campus-figures {
  margin-top: auto;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.campus-panel h3 {
  margin-bottom: 0.35rem;
}

.campus-number {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700;
  line-height: 1.1;
}

.campus-label {
  margin-top: 0.2rem;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.66);
}

/* ===== Contact cards ===== */
.contact-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.contact-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 0.5rem 1.5rem rgba(32, 44, 69, 0.14) !important;
}

.contact-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  font-size: 1.25rem;
  color: #202c45;
  background: rgba(254, 182, 0, 0.18);
}

/* Only on tiles whose logo is shared with a sibling campus. */
.college-campus {
  margin-top: 0.15rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6b7384;
}

@media (max-width: 575.98px) {
  .college-wall {
    gap: 0.6rem;
  }

  .college-chip {
    flex: 0 0 calc(50% - 0.3rem);
    min-height: 74px;
    padding: 0.6rem 0.5rem;
  }
}

#heroCarousel .carousel-indicators button {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.hero-section {
  min-height: 100vh;
  background: linear-gradient(135deg, #161d30 0%, #202C45 50%, #1a2a4a 100%);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: heroPattern 20s linear infinite;
}

@keyframes heroPattern {
  0% { transform: translate(0, 0); }
  100% { transform: translate(50px, 50px); }
}

.hero-title {
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* ===== Branding Colors ===== */
:root {
  --brand-navy: #202C45;
  --brand-gold: #feb600;
}

/* ===== Navbar ===== */
#mainNav {
  background-color: var(--brand-navy);
  transition: background-color 0.3s ease, padding 0.3s ease;
}

#mainNav.navbar-scrolled {
  background-color: rgba(32,44,69,0.97) !important;
  padding-top: 0.3rem;
  padding-bottom: 0.3rem;
}

#mainNav .navbar-brand {
  color: var(--brand-gold) !important;
}

#mainNav .nav-link {
  color: rgba(255,255,255,0.85);
  transition: color 0.2s ease;
}

#mainNav .nav-link:hover,
#mainNav .nav-link:focus {
  color: var(--brand-gold);
}

.btn-brand-gold {
  background-color: var(--brand-gold);
  color: var(--brand-navy);
  border: none;
  font-weight: 600;
}

.btn-brand-gold:hover {
  background-color: #e5a400;
  color: var(--brand-navy);
}

/* ===== Bootstrap overrides with branding ===== */
.btn-primary {
  background-color: var(--brand-gold);
  border-color: var(--brand-gold);
  color: var(--brand-navy);
  font-weight: 600;
}

.btn-primary:hover {
  background-color: #e5a400;
  border-color: #e5a400;
  color: var(--brand-navy);
}

.btn-outline-primary {
  color: var(--brand-gold);
  border-color: var(--brand-gold);
}

.btn-outline-primary:hover {
  background-color: var(--brand-gold);
  border-color: var(--brand-gold);
  color: var(--brand-navy);
}

.bg-primary {
  background-color: var(--brand-navy) !important;
}

.text-primary {
  color: var(--brand-gold) !important;
}

.bg-primary.bg-opacity-10 {
  background-color: rgba(254,182,0,0.1) !important;
}

.badge.bg-primary.bg-opacity-10.text-primary {
  background-color: rgba(254,182,0,0.12) !important;
  color: #c48e00 !important;
}

footer.bg-dark {
  background-color: var(--brand-navy) !important;
}

/* ===== About Image Placeholder ===== */
.about-image-placeholder {
  width: 100%;
  height: 350px;
  background: linear-gradient(135deg, #e3f2fd, #bbdefb);
}

/* ===== Event Cards ===== */
.event-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border-radius: 0.75rem;
}

.event-card:hover {
  transform: translateY(-4px);
}

.event-date {
  min-width: 60px;
}

/* ===== Stat Items ===== */
.stat-item h2 {
  font-variant-numeric: tabular-nums;
}

/* ===== Smooth scroll offset for fixed nav ===== */
section[id] {
  scroll-margin-top: 70px;
}