:root {
  color-scheme: light;
  --navy: #0b2450;
  --navy-deep: #071a38;
  --royal: #123f7b;
  --gold: #f2c84b;
  --paper: #fffdf7;
  --white: #ffffff;
  --line: rgba(255, 255, 255, 0.32);
  --shadow: 0 20px 60px rgba(4, 19, 42, 0.24);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--navy-deep);
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--white);
}

a {
  color: inherit;
}

.welcome-page {
  position: relative;
  isolation: isolate;
  min-height: 100svh;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.background,
.overlay {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.background {
  background: url("assets/school-background.jpeg") center center / cover no-repeat;
  animation: settle 1.8s cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.overlay {
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(4, 19, 43, 0.88) 0%, rgba(4, 25, 57, 0.64) 42%, rgba(4, 21, 45, 0.12) 72%),
    linear-gradient(180deg, rgba(6, 20, 42, 0.48) 0%, transparent 28%, transparent 65%, rgba(4, 16, 36, 0.62) 100%);
}

.site-header {
  width: min(100% - 8vw, 1440px);
  margin: 0 auto;
  padding: clamp(20px, 3vw, 40px) 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  animation: reveal-down 0.8s 0.05s ease-out both;
}

.school-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  text-decoration: none;
}

.seal-wrap {
  width: clamp(56px, 5.6vw, 78px);
  aspect-ratio: 1;
  flex: 0 0 auto;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.school-seal {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
}

.brand-copy strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.05rem, 1.7vw, 1.5rem);
  line-height: 1;
  letter-spacing: 0.02em;
}

.brand-copy span {
  font-size: clamp(0.68rem, 0.9vw, 0.79rem);
  font-weight: 650;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.78;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.system-button {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.48);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0.12) 48%, rgba(255, 255, 255, 0.2)),
    rgba(255, 255, 255, 0.18);
  color: var(--white);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    inset 0 -1px 0 rgba(255, 255, 255, 0.12),
    0 10px 28px rgba(2, 14, 32, 0.24),
    0 2px 6px rgba(2, 14, 32, 0.16);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-decoration: none !important;
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.28);
  white-space: nowrap;
  -webkit-backdrop-filter: blur(20px) saturate(165%);
  backdrop-filter: blur(20px) saturate(165%);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.system-button::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 1px 1px auto;
  height: 46%;
  border-radius: 14px 14px 10px 10px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.06));
  pointer-events: none;
}

.system-button::after {
  content: "";
  position: absolute;
  inset: -70% auto -70% -38%;
  width: 42%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.32), transparent);
  transform: rotate(18deg);
  transition: left 360ms ease;
  pointer-events: none;
}

.system-button--mps {
  border-color: rgba(255, 224, 115, 0.56);
  background:
    linear-gradient(135deg, rgba(255, 236, 164, 0.34), rgba(242, 200, 75, 0.14) 52%, rgba(255, 255, 255, 0.16)),
    rgba(242, 200, 75, 0.16);
}

.system-button:hover {
  transform: translateY(-2px) scale(1.015);
  border-color: rgba(255, 255, 255, 0.72);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.42), rgba(255, 255, 255, 0.16) 48%, rgba(255, 255, 255, 0.24)),
    rgba(255, 255, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 16px 34px rgba(2, 14, 32, 0.3),
    0 3px 8px rgba(2, 14, 32, 0.18);
  text-decoration: none !important;
}

.system-button:hover::after {
  left: 112%;
}

.system-button--mps:hover {
  border-color: rgba(255, 226, 124, 0.82);
  background:
    linear-gradient(135deg, rgba(255, 240, 182, 0.44), rgba(242, 200, 75, 0.2) 52%, rgba(255, 255, 255, 0.2)),
    rgba(242, 200, 75, 0.22);
}

.system-button:visited,
.system-button:active,
.system-button:focus {
  color: var(--white);
  text-decoration: none !important;
}

.system-button:focus-visible,
.school-brand:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}

.hero {
  width: min(100% - 8vw, 1440px);
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: clamp(44px, 7vh, 92px) 0;
}

.hero-content {
  width: min(720px, 59vw);
  animation: reveal-up 0.95s 0.2s ease-out both;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: clamp(17px, 2.4vh, 28px);
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(0.68rem, 0.9vw, 0.8rem);
  font-weight: 750;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.eyebrow span {
  width: 34px;
  height: 3px;
  border-radius: 99px;
  background: var(--gold);
}

.welcome-line {
  margin: 0 0 4px;
  color: var(--gold);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.15rem, 2vw, 1.8rem);
  font-style: italic;
}

h1 {
  max-width: 900px;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3.3rem, 6.4vw, 7rem);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 0.9;
  text-wrap: balance;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.28);
}

h1 em {
  color: var(--paper);
  font-size: 0.66em;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.hero-copy {
  max-width: 610px;
  margin: clamp(22px, 3.4vh, 38px) 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1rem, 1.35vw, 1.22rem);
  line-height: 1.65;
}

.hero-note {
  display: flex;
  align-items: stretch;
  gap: 16px;
  margin-top: clamp(24px, 4.5vh, 48px);
}

.note-mark {
  width: 3px;
  border-radius: 99px;
  background: var(--gold);
}

.hero-note p {
  display: grid;
  gap: 2px;
  margin: 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 0.78rem;
  letter-spacing: 0.11em;
  line-height: 1.6;
  text-transform: uppercase;
}

.hero-note strong {
  color: var(--white);
}

.site-footer {
  width: min(100% - 8vw, 1440px);
  margin: 0 auto;
  padding: 22px 0 28px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  animation: reveal-up 0.8s 0.45s ease-out both;
}

.site-footer p {
  margin: 0;
}

@keyframes settle {
  from { transform: scale(1.035); }
  to { transform: scale(1); }
}

@keyframes reveal-up {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes reveal-down {
  from { opacity: 0; transform: translateY(-14px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 800px) {
  .welcome-page {
    min-height: 100svh;
  }

  .background {
    background-position: 57% center;
  }

  .overlay {
    background:
      linear-gradient(90deg, rgba(4, 19, 43, 0.87) 0%, rgba(4, 25, 57, 0.63) 66%, rgba(4, 21, 45, 0.3) 100%),
      linear-gradient(180deg, rgba(6, 20, 42, 0.55) 0%, transparent 38%, rgba(4, 16, 36, 0.62) 100%);
  }

  .site-header,
  .hero,
  .site-footer {
    width: min(100% - 40px, 720px);
  }

  .hero-content {
    width: min(620px, 100%);
  }
}

@media (max-width: 560px) {
  .site-header {
    padding-top: 18px;
  }

  .brand-copy {
    display: none;
  }

  .seal-wrap {
    width: 58px;
  }

  .header-actions {
    gap: 8px;
  }

  .system-button {
    min-height: 44px;
    padding: 0 14px;
    font-size: 0.61rem;
    letter-spacing: 0.06em;
  }

  .hero {
    align-items: end;
    padding: 40px 0 46px;
  }

  h1 {
    font-size: clamp(3.25rem, 16vw, 5.1rem);
  }

  .hero-copy {
    max-width: 95%;
  }

  .hero-note {
    display: none;
  }

  .site-footer {
    padding-bottom: 20px;
    display: grid;
    gap: 7px;
  }
}

@media (max-height: 700px) and (min-width: 700px) {
  .site-header {
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .seal-wrap {
    width: 58px;
  }

  .hero {
    padding-top: 28px;
    padding-bottom: 28px;
  }

  .hero-note {
    display: none;
  }

  .site-footer {
    padding-top: 17px;
    padding-bottom: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}


/* High-specificity liquid-glass navigation buttons */
.header-actions {
  gap: 16px;
}

.header-actions .glass-nav-button,
.header-actions .glass-nav-button:link,
.header-actions .glass-nav-button:visited {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 178px;
  min-height: 54px;
  padding: 0 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 17px;
  background:
    radial-gradient(circle at 18% 8%, rgba(255,255,255,.58), transparent 34%),
    linear-gradient(145deg, rgba(255,255,255,.30), rgba(255,255,255,.09) 48%, rgba(255,255,255,.18));
  color: #fff !important;
  text-decoration: none !important;
  -webkit-text-decoration: none !important;
  text-transform: uppercase;
  font-family: "Segoe UI", Arial, sans-serif;
  font-size: .74rem;
  font-weight: 800;
  letter-spacing: .12em;
  white-space: nowrap;
  text-shadow: 0 1px 6px rgba(0,0,0,.34);
  -webkit-backdrop-filter: blur(24px) saturate(190%) contrast(108%);
  backdrop-filter: blur(24px) saturate(190%) contrast(108%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.88),
    inset 0 -1px 0 rgba(255,255,255,.16),
    inset 1px 0 0 rgba(255,255,255,.26),
    0 12px 30px rgba(0,12,35,.30),
    0 2px 8px rgba(0,12,35,.22);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background .2s ease;
}

.header-actions .glass-nav-button::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 1px 1px auto;
  height: 48%;
  border-radius: 15px 15px 11px 11px;
  background: linear-gradient(180deg, rgba(255,255,255,.58), rgba(255,255,255,.04));
  pointer-events: none;
}

.header-actions .glass-nav-button::after {
  content: "";
  position: absolute;
  inset: -75% auto -75% -46%;
  width: 38%;
  transform: rotate(17deg);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.38), transparent);
  transition: left .45s ease;
  pointer-events: none;
}

.header-actions .glass-nav-button--mps {
  border-color: rgba(255, 221, 104, .58);
  background:
    radial-gradient(circle at 18% 8%, rgba(255,248,210,.62), transparent 34%),
    linear-gradient(145deg, rgba(255,232,151,.34), rgba(242,200,75,.12) 50%, rgba(255,255,255,.16));
}

.header-actions .glass-nav-button:hover,
.header-actions .glass-nav-button:focus-visible {
  transform: translateY(-2px) scale(1.018);
  border-color: rgba(255,255,255,.82);
  text-decoration: none !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.96),
    inset 0 -1px 0 rgba(255,255,255,.18),
    0 18px 38px rgba(0,12,35,.36),
    0 3px 10px rgba(0,12,35,.24);
}

.header-actions .glass-nav-button:hover::after,
.header-actions .glass-nav-button:focus-visible::after {
  left: 118%;
}

.header-actions .glass-nav-button:active {
  transform: translateY(0) scale(.99);
  text-decoration: none !important;
}

.header-actions .glass-nav-button:focus-visible {
  outline: 3px solid rgba(242,200,75,.96);
  outline-offset: 4px;
}

@media (max-width: 760px) {
  .header-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .header-actions .glass-nav-button {
    min-width: 0;
    min-height: 48px;
    padding: 0 14px;
    font-size: .65rem;
  }
}
