/* One Design (Founder 2026-10-29): white page, ink text, orange only for large marks.
   Spec colours: #ffffff / #f8fbfd / #1c2431 / #55718d / #d7e3ee / #ea6f0a / #b4530a (ok/bad stay for status). */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #ffffff;
  font: 16px/1.5 var(--sans);
}
a { color: inherit; }
img { display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--ink);
  color: white;
  padding: 8px 12px;
  z-index: 5;
}
.skip:focus { top: 12px; }

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

/* Landing: the name and one verb. */
.landing {
  min-height: calc(100svh - 88px); margin-bottom: 40px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-bottom: 8vh;
}
.wordmark { width: 100%; max-width: 600px; }
.aw-text { fill: #ea6f0a; fill-opacity: 0; stroke: #ea6f0a; stroke-width: 1.6; stroke-dasharray: 1400; stroke-dashoffset: 1400; animation: aw-draw 1.4s ease-out 0.1s forwards, aw-fill 0.5s ease-out 1.3s forwards; }
.aw-line { stroke-dasharray: 680; stroke-dashoffset: 680; animation: aw-draw 1.5s linear 0.1s forwards; }
@keyframes aw-draw { to { stroke-dashoffset: 0; } }
@keyframes aw-fill { to { fill-opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .aw-text { animation: none; fill-opacity: 1; stroke-dashoffset: 0; }
  .aw-line { animation: none; stroke-dashoffset: 0; }
  html { scroll-behavior: auto; }
}
.landing-verb { margin-top: 28px; min-width: 240px; }
.landing-paths { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 24px; margin: 16px 0 0; font-size: 14px; font-weight: 600; color: var(--muted); }
.landing-paths a, .foot-links a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.landing-paths a:hover, .foot-links a:hover { color: var(--orange-ink); }
.foot-links { display: flex; flex-wrap: wrap; gap: 0 20px; font-weight: 600; }

.wrap { padding: 88px 6vw 72px; max-width: 1180px; margin: 0 auto; }
.kicker {
  font-family: var(--mono);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--orange);
  margin: 0 0 8px;
}
h1, .display {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(36px, 5.5vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0 0 16px;
}
h2.display { font-size: clamp(30px, 4.4vw, 46px); }
h2 { font-size: 22px; margin: 0 0 8px; }
.lede, .note { color: var(--muted); max-width: 62ch; }
.lede { font-size: 18px; margin-top: 0; }

.actions, .row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.button, button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 16px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  cursor: pointer;
}
.button.primary { min-height: 52px; padding: 0 28px; font-weight: 600; }
.button:hover, button:hover { opacity: 0.9; }
.button.ghost, button.ghost {
  background: #fff;
  color: var(--ink);
  border-color: var(--line);
}
.button.ghost:hover, button.ghost:hover { opacity: 1; border-color: var(--orange); }
button:disabled { opacity: 0.55; cursor: wait; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 28px 0; }
.card, .panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
  transition: border-color 0.15s ease;
}
.grid .card:hover { border-color: var(--orange); }
.card { padding: 18px 18px 16px; }
.card strong { display: block; margin-bottom: 6px; }
.card p, .panel p { margin: 0; color: var(--muted); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 22px 0 8px; }
.step { border-top: 2px solid var(--line); padding-top: 10px; }
.step b { display: block; font-family: var(--mono); font-size: 12px; color: var(--orange-ink); font-weight: 500; }

.sample {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 18px;
  margin-top: 28px;
  padding: 22px;
}
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.metric { border-top: 2px solid var(--ink); padding-top: 8px; }
.metric b { display: block; font-family: var(--mono); font-size: 28px; font-weight: 500; }
.metric span { color: var(--muted); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; }
.ok { color: var(--ok); }
.bad { color: var(--bad); }
.warn { color: var(--brass); }

.band {
  margin-top: 22px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--ink);
}

footer.colophon {
  padding: 10px 6vw 36px;
  color: var(--muted);
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.workspace { display: grid; grid-template-columns: 220px 1fr; gap: 16px; align-items: start; }
.tools { display: flex; flex-direction: column; gap: 6px; padding: 10px; position: sticky; top: 12px; }
.tools button {
  justify-content: flex-start;
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  border-color: transparent;
}
.tools button[aria-pressed="true"] { background: var(--ink); color: white; border-color: var(--ink); }
.stage { display: grid; gap: 14px; }
.panel { padding: 18px; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 12px 0; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
input, select, textarea {
  min-height: 42px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: white;
  padding: 8px 10px;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--orange); }
textarea { min-height: 96px; resize: vertical; font-family: var(--mono); font-size: 13px; }
.check { flex-direction: row; align-items: center; gap: 8px; min-height: 42px; color: var(--ink); }
.check input { min-height: 0; width: 18px; height: 18px; }
.hidden { display: none; }
pre, .mono {
  font-family: var(--mono);
  font-size: 12px;
  white-space: pre-wrap;
  background: var(--surface);
  border-radius: 10px;
  padding: 12px;
  overflow: auto;
  max-height: 280px;
}
ul.clean { margin: 8px 0 0; padding-left: 18px; }
.account-form { display: grid; gap: 10px; max-width: 420px; }
.chip { font-size: 14px; color: var(--muted); }
.me-account a { font-weight: 600; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.connect-list { display: grid; gap: 12px; }
code, .path { font-family: var(--mono); font-size: 0.92em; }

@media (max-width: 860px) {
  .grid, .steps, .sample, .workspace, .split, .fields, .metrics { grid-template-columns: 1fr; }
  .tools { position: static; flex-direction: row; overflow: auto; }
  .wrap { padding-top: 76px; }
  .landing { min-height: calc(100svh - 76px); }
  h1 { font-size: 34px; }
}

/* MOTTO-20261031-01：全ワールドのトップに同じ一行（ワードマークのすぐ下） */
.aw-motto { margin: 8px auto 0; max-width: 720px; padding: 0 16px; text-align: center; font-family: 'Playfair Display', Georgia, serif; font-style: italic; font-weight: 700; font-size: clamp(15px, 3.8vw, 19px); line-height: 1.35; letter-spacing: .01em; color: #1c2431; text-wrap: balance; }
.aw-motto-dash { color: #ea6f0a; }

/* LANDMARK-20261103-01：見ている人の国の名所（<airffic-landmark>）。場所は最初から確保して画面を動かさない */
.aw-landmark { display: flex; width: min(240px, 70vw); height: 116px; margin: 0 auto 4px; }

/* SITE-INTRO-VIDEO-20261118 */
.landing .aw-intro-video { margin-left: auto; margin-right: auto; text-align: center; }

/* ARCHITECT-MOBILE-20261119: phone width. The desktop layout above is unchanged; these rules apply only on narrow or touch screens.
   Targets follow the shared Airffic mobile rule (airffic-common-infra packages/mobile-kit): 44px taps, 12px text, 16px inputs, no sideways scroll. */
@media (max-width: 860px) {
  .skip { min-height: 44px; display: inline-flex; align-items: center; top: -60px; }
  /* All seven tools visible at once instead of a row that hides "Conflicts" onward off-screen. */
  .tools { flex-wrap: wrap; overflow: visible; gap: 6px; }
  .tools button { flex: 1 1 auto; justify-content: center; border-color: var(--line); }
  input, select { min-height: 44px; }
  .foot-links a { min-width: 44px; justify-content: center; }
  .actions .button, .actions button, .row .button, .row button { flex: 1 1 auto; }
  .world-globe { top: max(16px, env(safe-area-inset-top)); left: max(16px, env(safe-area-inset-left)); }
  .me, .aw-mark { top: max(16px, env(safe-area-inset-top)); }
  .me { right: max(16px, env(safe-area-inset-right)); }
  footer.colophon { padding-bottom: max(36px, calc(16px + env(safe-area-inset-bottom))); }
  pre, .mono { max-width: 100%; }
}

/* UI-IMPROVE-20261121: the workspace keeps rarely changed parts behind one toggle. */
.more-fields { margin: 4px 0 8px; }
.more-fields > summary { cursor: pointer; color: var(--muted); font-size: 14px; min-height: 44px; display: flex; align-items: center; }
.more-fields[open] > summary { color: var(--ink); }
.route-map { height: 340px; border-radius: 12px; border: 1px solid var(--line, #d6e2ec); margin: 12px 0 4px; background: #eef3f6; z-index: 0; }
.route-tools { align-items: center; }
.route-tools .note { flex: 1 1 220px; margin: 0; }
.route-pin span { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #1c2431; color: #fff; font: 600 12px/1 system-ui, sans-serif; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.35); }
@media (max-width: 720px) { .route-map { height: 300px; } }
.tools button .ic { flex: none; margin-right: 10px; vertical-align: -4px; }

/* UI-IMPROVE-20261121: one path from aircraft to flight. */
.journey { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 0 0 16px; padding: 0; counter-reset: none; }
.journey li { position: relative; }
.journey button, .journey a {
  width: 100%; min-height: 48px; display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  border: 1px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); text-decoration: none; cursor: pointer; font: inherit;
}
.journey b { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--ink); font: 600 13px/1 var(--mono); flex: none; }
.journey [aria-current="step"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.journey li[data-done] b { background: var(--ink); color: #fff; }
.journey li[data-step="fly"] a { background: var(--orange); border-color: var(--orange); color: #fff; font-weight: 600; }
.journey li[data-step="fly"] b { border-color: #fff; }
.row .next { margin-left: auto; display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 0; background: var(--ink); color: #fff; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
a.next[href^="/architect/fly"] { background: var(--orange); }
@media (max-width: 720px) {
  .journey { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
  .journey button, .journey a { flex-direction: column; gap: 4px; padding: 6px 2px; font-size: 13px; justify-content: center; }
  .row .next { margin-left: 0; width: 100%; justify-content: center; }
}
