@font-face {
  font-family: "Pretendard";
  src: url("./Pretendard-Regular.otf") format("opentype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Pretendard";
  src: url("./Pretendard-SemiBold.otf") format("opentype");
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ground: #f7f6f3;
  --surface: #ffffff;
  --surface-muted: #f4f3f0;
  --surface-hover: #efeeea;
  --ink: #37352f;
  --ink-muted: #787774;
  --ink-faint: #a09e99;
  --line: #ecebe8;
  --line-strong: #ddddd8;
  --brand: #ef4e3b;
  --brand-ink: #c63d30;
  --brand-soft: #fff0ed;
  --success: #3f8a5d;
  --sidebar-width: 236px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --font-sans: "Pretendard", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 32px;
}

body {
  min-width: 20rem;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 96% 0%, rgba(239, 78, 59, 0.08), transparent 23rem),
    var(--ground);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

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

::selection {
  background: rgba(239, 78, 59, 0.18);
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 8px 12px;
  border: 1px solid var(--brand);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--brand-ink);
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 140ms ease;
}

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

.site-sidebar {
  position: fixed;
  z-index: 20;
  inset: 0 auto 0 0;
  display: flex;
  width: var(--sidebar-width);
  flex-direction: column;
  padding: 16px 8px 12px;
  border-right: 1px solid var(--line);
  background: rgba(247, 246, 243, 0.94);
  backdrop-filter: blur(18px);
}

.wordmark {
  display: flex;
  min-height: 48px;
  align-items: center;
  gap: 8px;
  padding: 3px 8px 7px;
  border-radius: var(--radius-md);
  text-decoration: none;
}

.wordmark:hover {
  background: var(--surface-hover);
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  place-items: center;
}

.brand-mark img {
  display: block;
  width: 52px;
  max-width: none;
  height: 52px;
  object-fit: contain;
}

.brand-name {
  letter-spacing: -0.045em;
  font-size: 19px;
  font-weight: 700;
  line-height: 1;
}

.brand-name-cheek {
  color: var(--ink);
}

.brand-name-pouch {
  color: var(--brand);
}

.primary-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 18px;
}

.nav-section-label {
  margin: 0 8px 6px;
  color: var(--ink-faint);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.primary-nav a {
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  color: var(--ink-muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition:
    background 120ms ease,
    color 120ms ease;
}

.primary-nav a:hover {
  background: var(--surface-hover);
  color: var(--ink);
}

.primary-nav a[aria-current="page"] {
  background: var(--brand-soft);
  color: var(--brand-ink);
}

.primary-nav svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.75;
}

.docs-toc {
  margin-top: 26px;
}

.docs-toc nav {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.docs-toc a {
  padding: 5px 12px;
  border-left: 1px solid var(--line-strong);
  color: var(--ink-muted);
  font-size: 12px;
  line-height: 1.45;
  text-decoration: none;
}

.docs-toc a:hover {
  border-left-color: var(--brand);
  color: var(--brand-ink);
}

.sidebar-spacer {
  flex: 1;
}

.sidebar-release {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 8px 4px 0;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.58);
}

.status-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 4px rgba(239, 78, 59, 0.11);
}

.sidebar-release > span:last-child {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.sidebar-release strong {
  font-size: 12px;
  line-height: 1.4;
}

.sidebar-release small {
  overflow: hidden;
  color: var(--ink-muted);
  font-size: 10px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-workspace {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  margin-left: var(--sidebar-width);
}

.home-page,
.docs-article,
.history-page {
  width: min(100%, 1040px);
  flex: 1;
  margin: 0 auto;
  padding: 56px clamp(32px, 5vw, 72px) 80px;
}

.home-page {
  width: min(100%, 1100px);
}

.document-header,
.page-intro {
  border-bottom: 1px solid var(--line-strong);
}

.home-header {
  display: grid;
  min-height: 312px;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 260px);
  align-items: center;
  gap: 32px;
  padding: 12px 4px 36px;
}

.home-header > div {
  max-width: 590px;
}

.eyebrow,
.card-kicker,
.release-date {
  margin: 0 0 10px;
  color: var(--brand-ink);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.4;
}

h1,
h2,
h3,
p {
  overflow-wrap: break-word;
}

h1,
h2,
h3 {
  margin-top: 0;
  color: var(--ink);
  letter-spacing: -0.035em;
  line-height: 1.25;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(36px, 5vw, 58px);
  font-weight: 700;
}

.home-header p:last-child,
.page-intro > p:last-child {
  margin: 0;
  color: var(--ink-muted);
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.7;
}

.home-mascot {
  display: block;
  width: min(100%, 250px);
  height: auto;
  justify-self: end;
  filter: drop-shadow(0 18px 30px rgba(64, 45, 38, 0.12));
}

.home-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.home-card {
  position: relative;
  display: flex;
  min-height: 234px;
  flex-direction: column;
  padding: 26px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  transition:
    border-color 140ms ease,
    background 140ms ease,
    transform 140ms ease;
}

.home-card:hover {
  border-color: rgba(239, 78, 59, 0.42);
  background: var(--surface);
  transform: translateY(-2px);
}

.home-card-primary {
  border-color: rgba(239, 78, 59, 0.25);
  background: var(--brand-soft);
}

.home-card strong {
  margin: 2px 0 8px;
  font-size: 25px;
  letter-spacing: -0.025em;
}

.home-card p {
  margin: 0;
  color: var(--ink-muted);
}

.card-action {
  margin-top: auto;
  padding-top: 22px;
  color: var(--brand-ink);
  font-size: 13px;
  font-weight: 600;
}

.home-status {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  align-items: end;
  gap: 36px;
  margin-top: 48px;
  padding: 28px 4px 8px;
  border-top: 1px solid var(--line-strong);
}

.home-status h2 {
  margin: 0;
  font-size: 24px;
}

.home-status dl {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0;
}

.home-status dl div {
  padding: 2px 18px;
  border-left: 1px solid var(--line-strong);
}

.home-status dt {
  color: var(--ink-faint);
  font-size: 11px;
}

.home-status dd {
  margin: 2px 0 0;
  font-size: 13px;
  font-weight: 600;
}

.page-intro {
  padding: 18px 0 40px;
}

.page-intro h1 {
  margin-bottom: 14px;
  font-size: clamp(34px, 5vw, 50px);
}

.page-intro > p:last-child {
  max-width: 680px;
}

.docs-article > section {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 14px;
  padding: 54px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 24px;
}

.section-number {
  padding-top: 5px;
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.docs-article section h2 {
  margin-bottom: 18px;
  font-size: 26px;
}

.docs-article section p {
  max-width: 700px;
  margin: 0 0 18px;
  color: var(--ink-muted);
}

code {
  padding: 2px 5px;
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  color: var(--brand-ink);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.88em;
}

.steps,
.plain-list,
.release-columns ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.steps {
  counter-reset: steps;
}

.steps li {
  position: relative;
  padding: 0 0 24px 38px;
  counter-increment: steps;
}

.steps li::before {
  position: absolute;
  top: -1px;
  left: 0;
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 1px solid rgba(239, 78, 59, 0.28);
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand-ink);
  content: counter(steps);
  font-size: 11px;
  font-weight: 700;
}

.steps li:not(:last-child)::after {
  position: absolute;
  top: 27px;
  bottom: 4px;
  left: 11px;
  width: 1px;
  background: var(--line-strong);
  content: "";
}

.steps p,
.steps.compact li {
  margin: 4px 0 0;
}

.steps.compact li {
  padding-bottom: 18px;
}

.callout {
  margin-top: 8px;
  padding: 18px 20px;
  border: 1px solid rgba(239, 78, 59, 0.22);
  border-left: 3px solid var(--brand);
  border-radius: var(--radius-md);
  background: var(--brand-soft);
}

.callout p {
  margin: 4px 0 0 !important;
  font-size: 13px;
}

.definition-list {
  display: grid;
  margin: 28px 0 0;
  border-top: 1px solid var(--line-strong);
}

.definition-list > div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.definition-list dt {
  font-weight: 600;
}

.definition-list dd {
  margin: 0;
  color: var(--ink-muted);
}

.plain-list li,
.release-columns li {
  position: relative;
  padding: 6px 0 6px 19px;
  color: var(--ink-muted);
}

.plain-list li::before,
.release-columns li::before {
  position: absolute;
  top: 14px;
  left: 2px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brand);
  content: "";
}

.qa-list {
  border-top: 1px solid var(--line-strong);
}

.qa-list details {
  border-bottom: 1px solid var(--line);
}

.qa-list summary {
  padding: 17px 2px;
  cursor: pointer;
  font-weight: 600;
}

.qa-list details p {
  padding: 0 2px 16px;
}

.next-page {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0 0 62px;
}

.next-page > span {
  color: var(--ink-faint);
  font-size: 11px;
}

.next-page a {
  color: var(--brand-ink);
  font-weight: 600;
  text-decoration: none;
}

.history-page {
  width: min(100%, 960px);
}

.history-intro {
  margin-bottom: 12px;
}

.release-list {
  margin-top: 10px;
}

.release-entry {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
}

.release-rail {
  position: relative;
}

.release-rail::after {
  position: absolute;
  top: 32px;
  bottom: 0;
  left: 7px;
  width: 1px;
  background: var(--line-strong);
  content: "";
}

.release-rail span {
  position: absolute;
  top: 29px;
  left: 3px;
  z-index: 1;
  width: 9px;
  height: 9px;
  border: 2px solid var(--ground);
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 1px var(--brand);
}

.release-content {
  padding: 24px 0 58px;
}

.release-content > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.release-content h2 {
  margin-bottom: 0;
  font-size: 30px;
}

.release-date {
  margin-bottom: 5px;
  color: var(--ink-faint);
  letter-spacing: 0.06em;
}

.channel-badge {
  margin-top: 5px;
  padding: 4px 8px 3px;
  border: 1px solid rgba(239, 78, 59, 0.25);
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-ink);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.release-summary {
  max-width: 680px;
  margin: 18px 0 26px;
  color: var(--ink-muted);
  font-size: 16px;
}

.release-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.release-columns section {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.68);
}

.release-columns h3 {
  margin-bottom: 10px;
  font-size: 14px;
}

.release-columns li {
  font-size: 13px;
}

.script-note {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--ink-muted);
  font-size: 13px;
}

.site-footer {
  display: flex;
  width: min(100%, 1040px);
  justify-content: space-between;
  gap: 16px;
  margin: auto auto 0;
  padding: 20px clamp(32px, 5vw, 72px) 30px;
  border-top: 1px solid var(--line);
  color: var(--ink-faint);
  font-size: 11px;
}

a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
}

@media (max-width: 48rem) {
  html {
    scroll-padding-top: 116px;
  }

  .site-sidebar {
    position: sticky;
    top: 0;
    display: grid;
    width: 100%;
    height: auto;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 7px 12px 8px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    background: rgba(247, 246, 243, 0.95);
  }

  .wordmark {
    width: max-content;
    min-height: 40px;
    padding: 0 5px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
  }

  .brand-mark img {
    width: 43px;
    height: 43px;
  }

  .brand-name {
    font-size: 17px;
  }

  .primary-nav {
    grid-column: 1 / -1;
    flex-direction: row;
    gap: 4px;
    margin: 5px 0 0;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .primary-nav::-webkit-scrollbar {
    display: none;
  }

  .primary-nav .nav-section-label,
  .docs-toc,
  .sidebar-spacer,
  .sidebar-release {
    display: none;
  }

  .primary-nav a {
    min-height: 34px;
    flex: 1 0 auto;
    justify-content: center;
    padding: 6px 12px;
    font-size: 13px;
  }

  .primary-nav svg {
    width: 17px;
    height: 17px;
  }

  .site-workspace {
    margin-left: 0;
  }

  .home-page,
  .docs-article,
  .history-page {
    padding: 30px 18px 56px;
  }

  .home-header {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr) 116px;
    gap: 8px;
    padding: 8px 0 28px;
  }

  .home-header h1 {
    font-size: clamp(31px, 10vw, 43px);
  }

  .home-header p:last-child {
    font-size: 15px;
  }

  .home-mascot {
    width: 132px;
    margin-right: -8px;
  }

  .home-grid,
  .release-columns {
    grid-template-columns: 1fr;
  }

  .home-card {
    min-height: 210px;
    padding: 22px;
  }

  .home-status {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .home-status dl div:first-child {
    border-left: 0;
    padding-left: 0;
  }

  .page-intro {
    padding-top: 8px;
  }

  .docs-article > section {
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 8px;
    padding: 42px 0;
  }

  .next-page {
    padding-left: 42px;
  }

  .definition-list > div {
    grid-template-columns: 90px minmax(0, 1fr);
    gap: 12px;
  }

  .release-entry {
    grid-template-columns: 22px minmax(0, 1fr);
  }

  .release-rail::after {
    left: 5px;
  }

  .release-rail span {
    left: 1px;
  }

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

@media (max-width: 30rem) {
  .home-header {
    display: flex;
    flex-direction: column-reverse;
    align-items: flex-start;
  }

  .home-mascot {
    width: 118px;
    align-self: flex-end;
    margin: -10px 0 -26px;
  }

  .home-status dl {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .home-status dl div,
  .home-status dl div:first-child {
    padding: 9px 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .docs-article > section {
    grid-template-columns: 1fr;
  }

  .section-number {
    padding-top: 0;
  }

  .next-page {
    padding-left: 0;
  }

  .site-footer {
    flex-direction: column;
    gap: 3px;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --ground: #11110f;
    --surface: #1a1917;
    --surface-muted: #1e1d1a;
    --surface-hover: #24231f;
    --ink: #f0eee8;
    --ink-muted: #aaa8a1;
    --ink-faint: #77746d;
    --line: #2a2925;
    --line-strong: #383630;
    --brand: #ff6b55;
    --brand-ink: #ff806d;
    --brand-soft: rgba(255, 107, 85, 0.12);
  }

  body {
    background:
      radial-gradient(circle at 96% 0%, rgba(255, 107, 85, 0.09), transparent 23rem),
      var(--ground);
  }

  .site-sidebar {
    background: rgba(17, 17, 15, 0.94);
  }

  .sidebar-release,
  .home-card,
  .release-columns section {
    background: rgba(26, 25, 23, 0.72);
  }

  .home-card-primary {
    background: var(--brand-soft);
  }

  .home-mascot,
  .brand-mark img {
    filter: drop-shadow(0 12px 22px rgba(0, 0, 0, 0.24));
  }
}
