/* =========================================================
   Olewww LLP — shared design system
   Sky blue · Gardens by the Bay · transparent header/footer
   ========================================================= */

@import url("../fonts.css");

:root {
  color-scheme: light;
  --ink: #082b40;
  --text: #123b52;
  --heading: #082d44;
  --muted: #4c7185;
  --muted-2: #6f8f9f;
  --sky: #2b9fce;
  --sky-deep: #0b6e95;
  --teal: #1e8a9e;
  --line: rgba(28, 108, 140, 0.18);
  --line-strong: rgba(28, 108, 140, 0.32);
  --card: rgba(255, 255, 255, 0.76);
  --card-strong: rgba(255, 255, 255, 0.9);
  --white: #ffffff;
  --sun: #f4b74f;
  --coral: #e98563;
  --lime: #4caf7d;
  --sans: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Sora", var(--sans);
  --head-h: clamp(86px, 9.2vw, 112px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --radius: clamp(18px, 2vw, 28px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100svh;
  background: #d8f2ff;
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Shared illustrated sky / Gardens by the Bay backdrop */
.site-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0) 35%, rgba(255, 255, 255, 0.16) 72%, rgba(255, 255, 255, 0.36) 100%),
    url("../images/garden-bg.svg") center bottom / cover no-repeat,
    linear-gradient(165deg, #e9f9ff 0%, #ccefff 52%, #b6e5fa 100%);
}

.site-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(1100px 620px at 18% 18%, rgba(255, 255, 255, 0.36), transparent 66%);
}

::selection {
  background: rgba(43, 159, 206, 0.24);
  color: var(--ink);
}

img,
svg,
canvas {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

:focus-visible {
  outline: 2px solid var(--sky-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

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

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 999;
  padding: 12px 18px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 800;
  box-shadow: 0 10px 28px rgba(8, 45, 68, 0.18);
  transition: top 0.25s var(--ease);
}

.skip-link:focus {
  top: 16px;
}

/* ---------- Header ---------- */

.site-head {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 36px);
  height: var(--head-h);
  padding: 0 clamp(18px, 4.2vw, 64px);
  background: transparent;
  border: 0;
  transition: background 0.35s ease, box-shadow 0.35s ease, backdrop-filter 0.35s ease, border-color 0.35s ease;
}

.site-head.is-stuck {
  background: rgba(236, 250, 255, 0.62);
  border-bottom: 1px solid rgba(28, 108, 140, 0.12);
  box-shadow: 0 8px 30px rgba(18, 92, 124, 0.06);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: clamp(10px, 1.2vw, 16px);
  min-width: 0;
  z-index: 2;
  flex: 0 0 auto;
}

.brand__mark {
  width: auto;
  height: clamp(58px, 5.8vw, 82px);
  flex: 0 0 auto;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(19, 86, 116, 0.18));
}

.brand__name {
  font-family: var(--display);
  font-size: clamp(1.2rem, 1.8vw, 1.52rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--heading);
  white-space: nowrap;
}

.brand__name small {
  display: block;
  margin-top: 3px;
  font-family: var(--sans);
  font-size: clamp(0.62rem, 0.76vw, 0.72rem);
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #2b708c;
  white-space: normal;
  line-height: 1.35;
}

.site-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.8vw, 26px);
  z-index: 2;
}

.site-nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 9px 2px;
  font-family: var(--sans);
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: 0.005em;
  color: #123f57;
  transition: color 0.22s ease;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #1e8a9e, #60c6e5);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}

.site-nav a:hover {
  color: #0a5877;
}

.site-nav a:hover::after,
.site-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.site-nav a[aria-current="page"] {
  color: #0a5877;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(16, 83, 110, 0.22);
  background: rgba(255, 255, 255, 0.26);
  z-index: 70;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.5);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.8px;
  margin: 4px auto;
  border-radius: 2px;
  background: #0c4058;
  transition: transform 0.3s var(--ease), opacity 0.2s ease;
}

.menu-open .nav-toggle span:nth-child(1) {
  transform: translateY(5.8px) rotate(45deg);
}
.menu-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}
.menu-open .nav-toggle span:nth-child(3) {
  transform: translateY(-5.8px) rotate(-45deg);
}

/* ---------- Shared type ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-size: clamp(0.58rem, 0.72vw, 0.68rem);
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #1b6f8b;
}

.eyebrow::before {
  content: "";
  width: 24px;
  height: 1.5px;
  background: currentColor;
  opacity: 0.7;
}

.display {
  font-family: var(--display);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.045em;
  text-wrap: balance;
}

.gradient-text {
  background: linear-gradient(105deg, #0a334d 4%, #146e8f 45%, #3aaedb 92%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.glass {
  background: var(--card);
  border: 1px solid rgba(26, 105, 138, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 24px 60px rgba(25, 102, 137, 0.12);
  backdrop-filter: blur(18px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(120%);
}

/* ---------- Buttons ---------- */

.btn {
  --btn-bg: linear-gradient(120deg, #0d6c91, #1184a8);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 0 26px;
  border-radius: 999px;
  background: var(--btn-bg);
  color: #ffffff;
  font-family: var(--display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow:
    0 14px 34px rgba(12, 100, 136, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.24);
  transition: transform 0.28s var(--ease), box-shadow 0.28s ease, filter 0.28s ease;
}

.btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
  box-shadow: 0 20px 44px rgba(12, 100, 136, 0.28);
}

.btn:active {
  transform: translateY(0) scale(0.985);
}

.btn svg {
  width: 16px;
  height: 16px;
  transition: transform 0.28s var(--ease);
}

.btn:hover svg {
  transform: translate(2px, -2px);
}

.btn--ghost {
  --btn-bg: rgba(255, 255, 255, 0.44);
  color: #0b4c68;
  border: 1px solid rgba(20, 97, 127, 0.24);
  box-shadow: 0 10px 26px rgba(20, 97, 127, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(20, 97, 127, 0.38);
  box-shadow: 0 16px 34px rgba(20, 97, 127, 0.12);
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(20, 97, 127, 0.18);
  background: rgba(255, 255, 255, 0.4);
  color: #12506b;
  transition: background 0.22s ease, border-color 0.22s ease;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.72);
  border-color: rgba(20, 97, 127, 0.32);
}

.icon-btn svg {
  width: 16px;
  height: 16px;
}

/* ---------- Footer (transparent, no buttons) ---------- */

.site-foot {
  position: relative;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: auto;
  padding: 22px clamp(18px, 4.2vw, 64px) 30px;
  background: transparent;
  border: 0;
  color: #245f78;
  font-size: 0.82rem;
  letter-spacing: 0.01em;
  pointer-events: none;
}

.portal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  max-width: 1240px;
}

.portal-foot__brand {
  display: flex;
  align-items: center;
  gap: 13px;
}

.portal-foot__brand img {
  height: 48px;
  width: auto;
  filter: drop-shadow(0 5px 12px rgba(17, 81, 109, 0.12));
}

.portal-foot__brand b {
  display: block;
  font-family: var(--display);
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1.2;
  color: #0d4058;
}

.portal-foot__brand small {
  display: block;
  margin-top: 2px;
  font-size: 0.72rem;
  font-weight: 500;
  color: #3a7189;
}

.portal-foot__copy {
  font-size: 0.8rem;
  color: #3e7087;
  text-align: right;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.45);
}

/* ---------- Reveal ---------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  animation: reveal 0.9s var(--ease) forwards;
  animation-delay: var(--delay, 0.1s);
}

@keyframes reveal {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(0.8); }
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 10px rgba(76, 175, 125, 0.6);
  animation: pulse 2.6s ease-in-out infinite;
}

/* ---------- Cross-document transitions ---------- */

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.4s;
  animation-timing-function: var(--ease);
}

/* ---------- Responsive ---------- */

@media (max-width: 760px) {
  .site-head {
    padding: 0 18px;
    gap: 12px;
    height: 78px;
  }

  .brand__mark {
    height: 50px;
  }

  .brand__name {
    font-size: 1.06rem;
  }

  .brand__name small {
    font-size: 0.57rem;
    margin-top: 1px;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: fixed;
    inset: 0;
    z-index: 55;
    margin: 0;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 90px 26px 40px;
    background:
      radial-gradient(600px 420px at 80% 12%, rgba(128, 211, 240, 0.32), transparent 65%),
      rgba(238, 250, 255, 0.97);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.32s ease, visibility 0.32s, transform 0.32s var(--ease);
  }

  .site-nav a {
    font-family: var(--display);
    font-size: clamp(1.9rem, 8vw, 2.7rem);
    font-weight: 500;
    letter-spacing: -0.03em;
    color: #164d67;
    padding: 8px 4px;
  }

  .site-nav a::after {
    bottom: 0;
  }

  .menu-open .site-nav {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .site-foot {
    padding: 18px 18px 24px;
  }

  .portal-foot {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
  }

  .portal-foot__brand {
    flex-direction: column;
    gap: 6px;
  }

  .portal-foot__brand img {
    height: 46px;
  }

  .portal-foot__copy {
    text-align: center;
  }
}

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