/* ALTIS visual system. Load last, after page composition and mobile styles.
   Page CSS owns layouts/media; this file owns shared visual decisions. */
:root {
  color-scheme: dark;
  --ds-bg: #07090b;
  --ds-surface: #101419;
  --ds-raised: #181e25;
  --ds-text: #f2f5f8;
  --ds-body: #b8c1cc;
  --ds-muted: #929eac;
  --ds-line: rgba(233, 238, 245, .14);
  --ds-line-soft: rgba(233, 238, 245, .08);
  --ds-accent: #ff7a52;
  --ds-width: 1200px;
  --ds-gutter: 24px;
  --ds-section: clamp(64px, 8vw, 104px);
  --ds-display: clamp(40px, 6.5vw, 88px);
  --ds-heading: clamp(30px, 3.6vw, 48px);
  --ds-title: clamp(22px, 2.2vw, 28px);
  --ds-radius: 8px;
  --ds-control-radius: 4px;
  --ds-duration: 180ms;
  --font-sans: "Sora", "Noto Sans KR", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: var(--font-sans);
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --sans: var(--font-sans);
  --display: var(--font-display);
  --mono: var(--font-mono);
  /* Bridge the existing page tokens to one palette. */
  --bg: var(--ds-bg);
  --midnight: var(--ds-bg);
  --surface: var(--ds-surface);
  --surface-dark: var(--ds-surface);
  --surface-raised: var(--ds-raised);
  --text: var(--ds-text);
  --text-primary: var(--ds-text);
  --cloud: var(--ds-text);
  --text-secondary: var(--ds-body);
  --muted-strong: var(--ds-body);
  --muted: var(--ds-muted);
  --text-muted: var(--ds-muted);
  --haze: var(--ds-muted);
  --line: var(--ds-line);
  --line-dark: var(--ds-line);
  --line-soft: var(--ds-line-soft);
  --accent: var(--ds-accent);
  --glow: var(--ds-accent);
  --av-bg: var(--ds-bg);
  --av-surface: var(--ds-surface);
  --av-surface-light: var(--ds-raised);
  --av-text: var(--ds-text);
  --av-muted: var(--ds-body);
  --av-line: var(--ds-line);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 96px; }
body, body.avionics-integrated {
  background: var(--ds-bg);
  color: var(--ds-text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  letter-spacing: -.015em;
  -webkit-font-smoothing: antialiased;
}
body:not(.altis-coming-page)::before { background: none; }
button, input, select, textarea { font: inherit; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--ds-accent); outline-offset: 5px; }
::selection { color: var(--ds-bg); background: var(--ds-text); }
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -.035em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

/* One content edge, including the masthead and footer. */
.container, .shell, .page-shell, .system-shell, .wrap,
.nav, .site-footer-inner {
  width: 100%;
  max-width: var(--ds-width);
  margin-inline: auto;
  padding-inline: var(--ds-gutter);
}
:is(.page-home, .page-team, .page-history, .page-join, .page-sponsors) .hero-inner {
  width: 100%;
  max-width: var(--ds-width);
  margin-inline: auto;
  padding-inline: var(--ds-gutter);
}

/* Navigation: stable controls, shared active/hover/focus treatment. */
header, body.altis-coming-page header { position: sticky; top: 0; z-index: 1000; }
.nav { min-height: 80px; padding-block: 16px; gap: 20px; }
.brand-logo { height: 40px; }
nav a { font-size: 13px; font-weight: 400; line-height: 1.5; color: var(--ds-body); }
nav a:hover, nav a[aria-current="page"], nav a.nav-current,
nav .nav-tech-link.is-current { color: var(--ds-text); }
nav a[aria-current="page"], nav a.nav-current, nav .nav-tech-link.is-current {
  text-decoration: underline;
  text-decoration-color: var(--ds-accent);
  text-underline-offset: 8px;
  text-decoration-thickness: 2px;
}
.nav-tech-dropdown-menu { border-radius: var(--ds-radius); background: var(--ds-surface); }
.nav-tech-dropdown-menu a { font-family: var(--font-mono); font-size: 11px; line-height: 1.6; }
.nav .nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: var(--ds-control-radius);
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: .02em;
  box-shadow: none;
}
.nav .menu-toggle { display: none; }
.nav .nav-cta:hover { box-shadow: none; }
.nav .altis-lang-toggle, .nav .lang-toggle.nav-lang-toggle {
  position: static;
  width: 78px;
  min-width: 78px;
  padding: 10px 8px;
  color: var(--ds-muted);
  background: var(--ds-surface);
  border-color: var(--ds-line);
  font-family: var(--font-mono);
  opacity: 1;
  transform: none;
}
.nav .lang-option { color: var(--ds-muted); }
.nav .lang-option.is-active, .nav .altis-lang-toggle .is-active { color: var(--ds-text); }
.nav .social-cta, .nav .social-cta:hover, .nav .social-cta:focus-visible {
  width: 44px; padding: 10px; gap: 0; transform: none;
}
.nav .social-cta .social-label { display: none; }

/* Type scale and editorial rhythm across all active pages. */
body :is(.hero, .team-hero, .history-hero) h1,
body.avionics-integrated .hero-copy h1 {
  font-size: var(--ds-display);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -.045em;
}
:is(.page-team, .page-history) :is(.team-hero, .history-hero),
:is(.page-join, .page-sponsors, .page-structure, .page-motor) .hero,
body.avionics-integrated .hero {
  min-height: clamp(560px, 76svh, 820px);
  align-items: center;
}
:is(.page-team, .page-history, .page-join, .page-sponsors) .hero-inner {
  padding-block: 96px;
}
.page-structure .hero-copy { padding-block: 96px; }
.page-structure .hero h1 { max-width: 18ch; text-shadow: none; }
.page-structure .hero h1 span { font-size: .58em; line-height: 1.5; color: var(--ds-body); }
body.avionics-integrated .hero-copy h1 span { line-height: 1.5; color: var(--ds-body); }
.page-motor .hero, body.avionics-integrated .hero { padding: 96px 0; }
.page-motor .hero-copy, body.avionics-integrated .hero-copy {
  width: 100%; max-width: var(--ds-width); padding-inline: var(--ds-gutter);
  justify-items: start; text-align: left;
}
.page-motor .hero-content { justify-items: start; }
.page-motor .hero-actions { justify-content: flex-start; }
.page-motor .hero-lead { text-align: left; }
.page-team .team-hero::after { color: rgba(242, 245, 248, .16); }
body :is(.lead, .hero-lead, .team-hero .hero-copy, .history-hero .hero-copy) {
  color: var(--ds-body); font-size: 16px; font-weight: 400; line-height: 1.8;
  letter-spacing: -.015em; word-break: keep-all;
}
body :is(.eyebrow, .kicker, .hero-kicker, .system-eyebrow, .section-index,
.section-label, .outreach-label, .about-footer-kicker, .step-no, .tech-kicker) {
  color: var(--ds-muted); font-family: var(--font-mono); font-size: 11px;
  font-weight: 500; line-height: 1.6; letter-spacing: .12em; text-transform: uppercase;
}
body :is(.section-head, .section-heading, .system-heading) { margin-bottom: 48px; }
body :is(.section-head h2, .section-heading h2, .system-heading h2,
.statement h2, .closing h2, .outreach-copy h2, .capability-box h2) {
  font-size: var(--ds-heading); line-height: 1.3; letter-spacing: -.035em;
}
body #partner .section-head h2 { font-size: var(--ds-heading); line-height: 1.3; }
body :is(.section, .system-section, .roster-section, .timeline-section, .statement, .closing) {
  padding-block: var(--ds-section);
}
body :is(.section-head p, .section-heading > div > p, .system-heading-copy,
.timeline-copy p, .outreach-copy p, .step-text, .analysis-copy p, .detail-card p,
.info-item p, .track-item > p, .support-item p, .process-step p, .media-body p, .about-team-card p) {
  color: var(--ds-body); font-size: 15px; font-weight: 400; line-height: 1.8;
  letter-spacing: -.015em;
}
body :is(.info-item h3, .track-item h3, .support-item h3, .media-body h3,
.about-team-card h3, .analysis-copy h3, .detail-card h3, .capability-card h3) {
  font-size: var(--ds-title); line-height: 1.4; letter-spacing: -.025em;
}
.page-history .section-head, .page-team .section-heading, .system-heading,
.page-structure :is(.statement-grid, .process-head, .closing-inner) {
  grid-template-columns: 170px minmax(0, 1fr); gap: 32px;
}
.system-heading-copy { margin-top: -12px; }
.page-team .section-heading + .lead-grid { margin-top: 0; }
.page-team .person-code, .architecture-index { color: var(--ds-muted); }
.page-team .person-name { line-height: 1.2; }
.page-team .person-name-roman { letter-spacing: .04em; line-height: 1.6; }
.page-history .outreach-section { padding-bottom: var(--ds-section); }
.page-structure :is(.step, .analysis-grid, .detail-grid) {
  width: calc(100% - var(--ds-gutter) * 2);
  max-width: calc(var(--ds-width) - var(--ds-gutter) * 2);
}

/* Shared buttons and content surfaces. */
body :is(.btn, .hero-btn, .tech-cta) {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 20px; border: 1px solid var(--ds-line);
  border-radius: var(--ds-control-radius); background: var(--ds-surface);
  color: var(--ds-text); font-family: var(--font-sans); font-size: 13px;
  font-weight: 500; line-height: 1.5; letter-spacing: -.015em;
  text-decoration: none; text-transform: none; cursor: pointer; box-shadow: none;
  transition: background var(--ds-duration), border-color var(--ds-duration), color var(--ds-duration);
}
body :is(.btn.primary, .hero-btn.primary) {
  background: var(--ds-text); border-color: var(--ds-text); color: var(--ds-bg);
}
body :is(.btn, .hero-btn, .tech-cta):hover {
  background: var(--ds-raised); border-color: var(--ds-muted); transform: none; box-shadow: none;
}
body :is(.btn.primary, .hero-btn.primary):hover { background: #dce3eb; color: var(--ds-bg); }
body :is(.hero-actions, .cta-actions, .proposal-actions, .recruiting-gate-actions) { gap: 12px; }
body :is(.media-card, .about-team-card, .capability-card) {
  background: var(--ds-surface); border-color: var(--ds-line);
  border-radius: var(--ds-radius); box-shadow: none;
}
body :is(.timeline-image, .outreach-gallery img, .person-avatar,
.step-media, .step-media img, .analysis-media, .detail-image, .about-photo) { border-radius: var(--ds-radius); }
body :is(.hero-system, .recruiting-gate-status),
body.avionics-integrated .hero-system {
  border-radius: var(--ds-control-radius); border-color: var(--ds-line);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em;
}
body .recruiting-gate-panel h2, body.altis-coming-page .card h1 {
  font-size: var(--ds-heading); line-height: 1.3; letter-spacing: -.035em;
}
body .recruiting-gate-panel p { color: var(--ds-body); line-height: 1.8; }

/* Footer uses the same edge, surface and typography on every route. */
body .site-footer {
  margin-top: 0; padding: 0; background: var(--ds-bg) !important;
  border: 0 !important; border-top: 1px solid var(--ds-line) !important;
  border-radius: 0; box-shadow: none !important;
}
body .site-footer-inner { padding-block: 48px 32px; }
body .site-footer-divider { display: none; }
body .site-footer-grid { display: grid; grid-template-columns: 1fr auto; gap: 24px; margin-top: 0; }
body .site-footer :is(.site-footer-contact p, .site-footer-copy) {
  margin: 0; color: var(--ds-muted); font-family: var(--font-sans);
  font-size: 12px; font-weight: 400; line-height: 1.8; letter-spacing: -.015em;
}

@media (max-width: 1100px) and (min-width: 901px) {
  .nav { gap: 12px; }
  nav a, .nav-tech-dropdown { margin-right: 12px; }
  .nav-actions { gap: 8px; }
}
@media (max-width: 900px) {
  :root { --ds-gutter: 20px; }
  .container, .shell, .page-shell, .system-shell, .wrap,
  body .site-footer-inner { padding-inline: var(--ds-gutter) !important; }
  .nav { min-height: 72px; padding: 14px var(--ds-gutter) !important; }
  .nav .brand-logo { height: 34px !important; }
  .nav .menu-toggle { min-height: 44px; right: var(--ds-gutter) !important; }
  .nav .altis-lang-toggle, .nav .lang-toggle.nav-lang-toggle {
    min-height: 44px !important; right: calc(var(--ds-gutter) + 84px) !important;
  }
  .nav .instagram-link { display: none; }
  nav { max-height: calc(100svh - 72px); }
  .nav-tech-dropdown-menu { border-radius: 0; }
  body :is(.hero, .history-hero, .team-hero) { min-height: 560px !important; }
  :is(.page-home, .page-team, .page-history, .page-join, .page-sponsors) .hero-inner,
  .page-structure .hero-copy { padding: 80px var(--ds-gutter) !important; }
  body #site-content .hero h1 { font-size: var(--ds-display); }
  body #site-content .section > .section-head { padding-inline: var(--ds-gutter) !important; }
  .timeline-section, .outreach-section { padding-inline: 0; }
  .page-history .section-head, .page-team .section-heading, .system-heading,
  .page-structure :is(.statement-grid, .process-head, .closing-inner) {
    grid-template-columns: minmax(0, 1fr); gap: 16px;
  }
  .system-heading-copy { grid-column: 1; margin-top: 0; }
  body :is(.section-head, .section-heading, .system-heading) { margin-bottom: 32px; }
  .timeline-item-featured :is(.timeline-index, .timeline-image) { grid-column: 1; }
  .timeline-index { justify-self: start; }
  body :is(.step-media, .analysis-media, .detail-image) { border-radius: var(--ds-radius) !important; }
  .info-item + .info-item, .track-item + .track-item, .support-item + .support-item { border-left: 0; }
  body .site-footer-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  body .site-footer-inner { padding-block: 32px !important; }
}
@media (max-width: 560px) {
  :root { --ds-gutter: 16px; }
  .nav .menu-toggle { width: 70px !important; }
  .nav .altis-lang-toggle, .nav .lang-toggle.nav-lang-toggle { right: 94px !important; }
  body :is(.hero, .history-hero, .team-hero) { min-height: 520px !important; }
  body .site-footer :is(.site-footer-contact p, .site-footer-copy) { font-size: 12px !important; }
  body :is(.hero-actions, .cta-actions, .proposal-actions) { width: 100%; }
  body :is(.hero-actions, .cta-actions, .proposal-actions) > :is(a, button) { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    scroll-behavior: auto !important; animation-duration: .01ms !important;
    animation-iteration-count: 1 !important; transition-duration: .01ms !important;
  }
}

/* Clear legacy link rules that otherwise stack two current-page markers. */
nav a.nav-current, nav a[aria-current="page"] { border-bottom-color: transparent; }
.nav .brand { flex: 0 0 auto; }
.nav .brand a { flex: 0 0 auto; }
body :is(.capability h3, .timeline-copy h3) { font-size: var(--ds-title); line-height: 1.4; }
body :is(.capability p, .architecture-node p) { color: var(--ds-body); font-size: 15px; line-height: 1.8; }
body .hero-tagline { font-family: var(--font-sans); color: var(--ds-body); font-size: 13px; letter-spacing: .04em; }

/* Keep the 3D model inside the same content grid as the specification copy. */
body.avionics-integrated .avionics-3d-stage {
  --stage-bleed: 0px;
  --stage-push: 0px;
  width: 100%;
  min-width: 0;
  margin-inline: 0;
}

body.avionics-integrated .avionics-model-section {
  overflow: hidden;
}

.page-home .section > .section-head {
  width: 100%;
  max-width: var(--ds-width);
  margin-inline: auto;
  padding-inline: var(--ds-gutter);
}

/* Homepage recruitment notice */
.page-home .recruitment-banner {
  position: relative;
  z-index: 1001;
  display: block;
  min-height: 56px;
  color: var(--ds-text);
  background:
    radial-gradient(circle at 50% -80%, rgba(255, 122, 82, .2), transparent 48%),
    #0b0e12;
  border-top: 2px solid var(--ds-accent);
  border-bottom: 1px solid var(--ds-line);
  text-decoration: none;
  overflow: hidden;
  transition: background .2s ease;
}

.page-home .recruitment-banner:hover {
  background:
    radial-gradient(circle at 50% -80%, rgba(255, 122, 82, .28), transparent 52%),
    #0e1116;
}

.page-home .recruitment-banner-inner {
  position: relative;
  width: 100%;
  max-width: var(--ds-width);
  min-height: 54px;
  margin-inline: auto;
  padding-inline: var(--ds-gutter);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

.page-home .recruitment-banner-kicker,
.page-home .recruitment-banner-action {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.page-home .recruitment-banner-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 8px;
  color: #ff9b7c;
  border: 1px solid rgba(255, 122, 82, .32);
  border-radius: 3px;
  background: rgba(255, 122, 82, .06);
}

.page-home .recruitment-banner-kicker i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 10px rgba(255, 122, 82, .7);
}

.page-home .recruitment-banner strong {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: -.01em;
}

.page-home .recruitment-banner-action {
  margin-left: 2px;
  padding-left: 18px;
  color: var(--ds-body);
  border-left: 1px solid var(--ds-line);
  transition: color .2s ease, transform .2s ease;
}

.page-home .recruitment-banner:hover .recruitment-banner-action {
  color: #ff9b7c;
  transform: translateX(2px);
}

.page-home .recruitment-banner-action b {
  font-size: 13px;
  font-weight: 500;
}

@media (max-width: 700px) {
  .page-home .recruitment-banner {
    min-height: 50px;
  }

  .page-home .recruitment-banner-inner {
    min-height: 48px;
    justify-content: space-between;
    gap: 12px;
  }

  .page-home .recruitment-banner-kicker {
    display: none;
  }

  .page-home .recruitment-banner strong {
    min-width: 0;
    font-size: 12px;
  }

  .page-home .recruitment-banner-action {
    margin-left: 0;
    padding-left: 12px;
    font-size: 9px;
    white-space: nowrap;
  }
}
