:root {
  color-scheme: light;
  --ink: #102019;
  --muted: #52625a;
  --paper: #f3f0e8;
  --board: #fffdf7;
  --line: rgba(16, 32, 25, 0.15);
  --green: #b9ff66;
  --green-dark: #082114;
  --blue: #1546d8;
  --shadow: 0 34px 90px rgba(18, 31, 24, 0.17);
}

* {
  box-sizing: border-box;
}

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

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 14% 10%, rgba(185, 255, 102, 0.42), transparent 26rem),
    radial-gradient(circle at 88% 88%, rgba(21, 70, 216, 0.12), transparent 31rem),
    linear-gradient(rgba(16, 32, 25, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 32, 25, 0.045) 1px, transparent 1px),
    var(--paper);
  background-size: auto, auto, 32px 32px, 32px 32px, auto;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: 1rem;
  z-index: 10;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  background: var(--green-dark);
  color: white;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.page-shell {
  width: min(1120px, calc(100% - 2rem));
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(1rem, 4vw, 3rem) 0 1.5rem;
  display: grid;
  align-content: center;
  gap: 1rem;
}

.signboard {
  position: relative;
  overflow: hidden;
  min-height: min(720px, calc(100vh - 5rem));
  display: grid;
  grid-template-rows: auto 1fr auto;
  border: 1px solid var(--line);
  border-radius: clamp(1.5rem, 4vw, 3.5rem);
  background: var(--board);
  box-shadow: var(--shadow);
}

.signboard::after {
  content: "";
  position: absolute;
  right: -7rem;
  bottom: -9rem;
  width: 25rem;
  height: 25rem;
  border: 5rem solid var(--green);
  border-radius: 50%;
  opacity: 0.44;
  pointer-events: none;
}

.signboard__header,
.signboard__footer {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(1.25rem, 3vw, 2rem) clamp(1.25rem, 5vw, 3.5rem);
}

.signboard__header {
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
  text-decoration: none;
}

.brand__mark {
  width: 2.45rem;
  height: 2.45rem;
  padding: 0.48rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: end;
  gap: 0.2rem;
  border-radius: 0.75rem;
  background: var(--green-dark);
}

.brand__mark span {
  display: block;
  border-radius: 999px;
  background: var(--green);
}

.brand__mark span:nth-child(1) { height: 42%; }
.brand__mark span:nth-child(2) { height: 100%; }
.brand__mark span:nth-child(3) { height: 68%; }

.brand__name {
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.2em;
}

.powered-by {
  color: var(--muted);
  font-size: 0.85rem;
}

.powered-by strong {
  color: var(--ink);
}

.signboard__body {
  position: relative;
  z-index: 1;
  max-width: 820px;
  padding: clamp(3rem, 8vw, 7.5rem) clamp(1.25rem, 7vw, 5.5rem);
  align-self: center;
}

.route-chip {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 2.2rem;
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  color: #34443c;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.77rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.route-chip__light {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #45c56c;
  box-shadow: 0 0 0 0.3rem rgba(69, 197, 108, 0.15);
}

.is-not-found .route-chip__light {
  background: #ee9a41;
  box-shadow: 0 0 0 0.3rem rgba(238, 154, 65, 0.15);
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.7rem, 7vw, 6.6rem);
  line-height: 0.94;
  letter-spacing: -0.065em;
  text-wrap: balance;
}

.message {
  max-width: 700px;
  margin: clamp(1.5rem, 3vw, 2.1rem) 0 0;
  color: #2f4037;
  font-size: clamp(1.05rem, 2vw, 1.32rem);
  line-height: 1.6;
}

.detail {
  width: fit-content;
  margin: 1rem 0 0;
  padding: 0.68rem 0.9rem;
  border-left: 3px solid var(--green);
  background: rgba(185, 255, 102, 0.13);
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: clamp(2rem, 4vw, 3rem);
}

.button {
  min-height: 3.35rem;
  padding: 0.88rem 1.3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  border: 1px solid var(--green-dark);
  border-radius: 0.9rem;
  font-size: 0.94rem;
  font-weight: 800;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button svg {
  width: 1.1rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.button--primary {
  background: var(--green-dark);
  color: white;
  box-shadow: 0 0.7rem 1.6rem rgba(8, 33, 20, 0.16);
}

.button--primary:hover {
  background: #143b26;
  transform: translateY(-2px);
  box-shadow: 0 1rem 2rem rgba(8, 33, 20, 0.2);
}

.button--secondary {
  background: transparent;
  color: var(--ink);
}

.button--secondary:hover {
  background: rgba(16, 32, 25, 0.06);
  transform: translateY(-2px);
}

.button:focus-visible,
.brand:focus-visible,
.signboard__footer a:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 4px;
}

.signboard__footer {
  padding-top: 1.2rem;
  padding-bottom: 1.2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8rem;
}

.signboard__footer a {
  position: relative;
  z-index: 1;
  color: var(--ink);
  font-weight: 800;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.25rem;
}

.outside-note {
  margin: 0;
  color: rgba(16, 32, 25, 0.58);
  font-size: 0.72rem;
  text-align: center;
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 1rem, 1120px);
    padding: 0.5rem 0 1rem;
  }

  .signboard {
    min-height: calc(100vh - 2.5rem);
    border-radius: 1.4rem;
  }

  .powered-by {
    max-width: 8rem;
    text-align: right;
  }

  .signboard__body {
    padding-top: 3.5rem;
    padding-bottom: 4.5rem;
  }

  .route-chip {
    margin-bottom: 1.6rem;
  }

  h1 {
    font-size: clamp(2.55rem, 14vw, 4.1rem);
  }

  .actions,
  .button {
    width: 100%;
  }

  .signboard__footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .signboard::after {
    right: -12rem;
    bottom: -13rem;
  }
}

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