/* 5x1 — Frutiger Aero (aligned with JRGWebsite aero theme) */

:root {
  --bg: #d8ecff;
  --bg-2: #c2e0ff;
  --bg-3: #a9cbef;
  --panel: rgba(243, 250, 255, 0.76);
  --panel-strong: #0d1724;
  --text: #102235;
  --muted: #54708c;
  --line: rgba(64, 99, 139, 0.32);
  --accent: #1f78ff;
  --accent-deep: #0b58d1;
  --accent-soft: rgba(31, 120, 255, 0.16);
  --shadow: 0 18px 38px rgba(34, 71, 112, 0.22);
  --aero-sheen: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.1));
  --radius-lg: 24px;
  --radius-md: 16px;
  --shell-width: min(1040px, calc(100% - 28px));
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Space Grotesk", sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background:
    url("assets/aero-bg.svg") center center / cover no-repeat fixed,
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 58%, var(--bg-3) 100%);
  overflow-x: hidden;
}

a {
  color: var(--accent-deep);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--accent);
}

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

/* Atmosphere overlays on top of aero-bg */
.sky {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.sky__shimmer {
  position: absolute;
  inset: -20% -30%;
  background: linear-gradient(
    115deg,
    transparent 35%,
    rgba(255, 255, 255, 0.06) 45%,
    rgba(255, 255, 255, 0.28) 50%,
    rgba(255, 255, 255, 0.06) 55%,
    transparent 65%
  );
  transform: translateX(-20%) rotate(8deg);
  opacity: 0.45;
  will-change: transform;
}

.bubbles {
  position: absolute;
  inset: 0;
}

.bubble {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(
    circle at 30% 28%,
    rgba(255, 255, 255, 0.9) 0%,
    rgba(200, 230, 255, 0.35) 35%,
    rgba(79, 143, 244, 0.1) 70%,
    transparent 100%
  );
  box-shadow:
    inset 0 0 12px rgba(255, 255, 255, 0.5),
    0 4px 16px rgba(34, 71, 112, 0.12);
  animation: float-up linear infinite;
  opacity: 0.55;
}

@keyframes float-up {
  0% {
    transform: translateY(0) translateX(0) scale(1);
    opacity: 0;
  }
  8% {
    opacity: 0.6;
  }
  92% {
    opacity: 0.4;
  }
  100% {
    transform: translateY(-110vh) translateX(var(--drift, 20px)) scale(1.05);
    opacity: 0;
  }
}

/* Shell */
.page-shell {
  position: relative;
  z-index: 1;
  width: var(--shell-width);
  margin: 0 auto;
  padding: 18px 0 32px;
}

/* Topbar — glass like JRG aero */
.topbar,
.panel,
.footer,
.hero__content {
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background-image: var(--aero-sheen);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 10px 24px rgba(34, 71, 112, 0.18);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding: 12px 16px;
  border-radius: 18px;
  background-color: rgba(233, 244, 255, 0.82);
}

.logo-mark {
  font-family: "Syne", sans-serif;
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  color: var(--text);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.55);
}

.logo-mark:hover {
  color: var(--accent-deep);
}

.topbar__links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--muted);
  font-size: 0.95rem;
}

.topbar__links a {
  color: var(--muted);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.55);
}

.topbar__links a:hover,
.topbar__links a[aria-current="page"] {
  color: var(--text);
}

.topbar__links a[aria-current="page"] {
  font-weight: 700;
}

/* Hero */
.hero {
  margin-bottom: 0;
}

.hero__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border-radius: 24px;
  background-color: rgba(236, 246, 255, 0.8);
  min-height: min(68vh, 560px);
  justify-content: center;
}

.page-hero {
  margin-top: 0;
}

.page-hero h1 {
  margin: 0;
  font-family: "Syne", sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.page-hero__lede {
  margin: 12px 0 0;
  max-width: 52ch;
  color: var(--muted);
  font-size: 1.02rem;
}

.brand {
  margin: 0 0 0.75rem;
  font-family: "Syne", sans-serif;
  font-weight: 800;
  font-size: clamp(3.5rem, 14vw, 7rem);
  line-height: 0.9;
  letter-spacing: -0.06em;
  color: var(--text);
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.8),
    0 8px 28px rgba(34, 71, 112, 0.2);
}

.hero__title {
  margin: 0;
  max-width: 16ch;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: clamp(1.45rem, 3.5vw, 2.35rem);
  line-height: 1.05;
  letter-spacing: -0.05em;
  color: var(--text);
}

.hero__lede {
  max-width: 42ch;
  margin: 14px 0 0;
  font-size: 1.02rem;
  line-height: 1.65;
  color: var(--muted);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

/* Buttons — glossy aero (JRG) */
.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 12px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid rgba(52, 102, 164, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    0 1px 0 rgba(255, 255, 255, 0.4);
  transition:
    transform 150ms ease,
    filter 150ms ease;
  overflow: hidden;
}

.button:hover {
  transform: translateY(-1px);
}

.button--primary {
  background: linear-gradient(180deg, #8dc2ff 0%, #4f8ff4 48%, #1f6fe9 49%, #1d61d6 100%);
  color: #f8fcff;
}

.button--primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(255, 255, 255, 0.4) 48%,
    transparent 66%
  );
  transform: translateX(-120%);
  transition: transform 0.5s var(--ease-out);
  pointer-events: none;
}

.button--primary:hover::after {
  transform: translateX(120%);
}

.button--primary:hover {
  filter: brightness(1.05);
  color: #fff;
}

.button--ghost {
  background: linear-gradient(180deg, #fdfefe 0%, #dcecff 100%);
  color: #163658;
}

.button--ghost:hover {
  color: var(--text);
  filter: brightness(1.03);
}

/* Main panels */
main {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.panel {
  padding: clamp(1.15rem, 3vw, 1.5rem);
  border-radius: 22px;
  background-color: rgba(236, 246, 255, 0.8);
}

.section-heading {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.eyebrow {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-deep);
}

.section-heading h2 {
  margin: 0;
  font-family: "Syne", sans-serif;
  font-size: clamp(1.3rem, 2.8vw, 2rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.section__lede {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 1.02rem;
}

.about__flow {
  display: grid;
  gap: 1rem;
}

.about__flow p {
  margin: 0;
  color: var(--muted);
}

.about__flow a,
.section__lede a,
.steps a {
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
}

code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.92em;
  padding: 0.12em 0.4em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(64, 99, 139, 0.22);
  color: var(--text);
}

/* Hub / script cards */
.hub-grid,
.script-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.hub-card,
.script-card {
  display: block;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid rgba(76, 118, 166, 0.28);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(206, 226, 247, 0.86));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
  color: inherit;
  transition: transform 150ms ease, filter 150ms ease;
}

a.hub-card:hover {
  transform: translateY(-2px);
  filter: brightness(1.02);
  color: inherit;
}

.hub-card__kicker,
.script-card__kicker {
  margin: 0 0 8px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.hub-card h3,
.script-card h3 {
  margin: 0 0 8px;
  font-family: "Syne", sans-serif;
  font-size: 1.15rem;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.hub-card p,
.script-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.script-card__meta {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text);
}

.script-card__meta li {
  padding-left: 0.85rem;
  position: relative;
}

.script-card__meta li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.steps {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--muted);
  display: grid;
  gap: 0.85rem;
}

.steps strong {
  color: var(--text);
}

.panel .hero__actions {
  margin-top: 1.25rem;
}

/* Endpoints */
.endpoint-list {
  margin: 0;
  display: grid;
  gap: 0;
}

.endpoint {
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}

.endpoint:first-child {
  padding-top: 0;
}

.endpoint:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.endpoint dt {
  margin: 0 0 0.3rem;
}

.endpoint dd {
  margin: 0;
  font-size: 0.95rem;
  color: var(--muted);
}

.endpoint__host {
  display: inline-flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0;
  border: none;
  background: none;
  font-family: "Syne", sans-serif;
  font-size: clamp(1.1rem, 2.4vw, 1.35rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  text-decoration: none;
}

.endpoint__host:hover,
.endpoint__host:focus-visible {
  color: var(--accent-deep);
}

.endpoint__host:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 4px;
}

.endpoint__hint {
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
  opacity: 0.7;
}

.endpoint__host:hover .endpoint__hint,
.endpoint__host:focus-visible .endpoint__hint,
.endpoint__host.copied .endpoint__hint {
  opacity: 1;
}

.endpoint__host.copied .endpoint__hint {
  color: #0a6b3c;
}

/* Footer — dark glass like JRG aero */
.footer {
  margin-top: 18px;
  padding: 18px 20px;
  border-radius: 22px;
  background-color: rgba(18, 34, 55, 0.94);
  background-image: none;
  color: rgba(245, 251, 255, 0.82);
  text-align: center;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 10px 24px rgba(34, 71, 112, 0.22);
}

.footer p {
  margin: 0 auto;
  max-width: 36rem;
  font-size: 0.95rem;
}

.footer a {
  color: #9ec8ff;
  font-weight: 700;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
}

.footer a:hover {
  color: #cfe4ff;
}

/* Responsive */
@media (max-width: 860px) {
  .hub-grid,
  .script-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero__actions {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .button {
    width: 100%;
  }

  .endpoint__host {
    flex-wrap: wrap;
    gap: 0.35rem 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .bubble,
  .sky__shimmer,
  .button,
  .button--primary::after {
    animation: none !important;
    transition: none !important;
  }
}
