/* DelayOS site. Colors: docs/ko/brand.md (B600 #4D6BFE accent, Night #0E1224). */
:root {
  --night: #0E1224; --bg2: #121731; --card: #171d3a; --line: #262e55;
  --text: #e8ebf7; --muted: #9aa3c7; --accent: #4D6BFE; --accent2: #7C93FF; --soft: #C5CEFF;
  --warn: #ffb547;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--night); color: var(--text);
  font: 16px/1.65 "Pretendard", "Inter", "Segoe UI", "Malgun Gothic", "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; word-break: keep-all;
}
html.ko [lang="en"], html.en [lang="ko"] { display: none; }
a { color: var(--accent2); text-decoration: none; }
a:hover { color: var(--soft); }
code { font: 0.9em ui-monospace, "JetBrains Mono", Consolas, monospace; background: #0b0f20; border: 1px solid var(--line); border-radius: 6px; padding: 0.05em 0.4em; }
img { max-width: 100%; height: auto; display: block; }
.wrap { width: min(1160px, 100% - 40px); margin: 0 auto; }
.narrow { width: min(760px, 100% - 40px); }
.muted { color: var(--muted); }

/* nav */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(14, 18, 36, 0.78); backdrop-filter: blur(14px); border-bottom: 1px solid rgba(38, 46, 85, 0.7); }
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand img { height: 28px; width: auto; }
.links { display: flex; align-items: center; gap: 22px; font-size: 15px; }
.links a { color: var(--muted); }
.links a:hover { color: var(--text); }
.lang { font: inherit; font-size: 13px; color: var(--text); background: transparent; border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; cursor: pointer; }
.lang:hover { border-color: var(--accent); }

/* hero */
.hero { position: relative; overflow: hidden; padding: 80px 0 64px; }
.hero::before {
  content: ""; position: absolute; inset: -30% -10% auto 30%; height: 760px; z-index: -1;
  background: radial-gradient(closest-side, rgba(77, 107, 254, 0.35), transparent 70%);
}
.hero-in { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 56px; align-items: center; }
.tag { display: inline-block; margin: 0 0 18px; font-size: 13px; color: var(--soft); border: 1px solid var(--line); background: rgba(77, 107, 254, 0.1); border-radius: 999px; padding: 4px 12px; }
h1 { margin: 0 0 20px; font-size: clamp(40px, 5.4vw, 64px); line-height: 1.12; letter-spacing: -0.02em; }
h1 span { background: linear-gradient(180deg, #fff 30%, var(--soft)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { margin: 0 0 30px; font-size: 18px; color: var(--muted); max-width: 34em; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; justify-content: center; height: 46px; padding: 0 22px; border-radius: 12px; font-weight: 600; font-size: 15px; white-space: nowrap; }
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 8px 30px rgba(77, 107, 254, 0.35); }
.btn.primary:hover { background: #5d79ff; color: #fff; }
.btn.ghost { border: 1px solid var(--line); color: var(--text); }
.btn.ghost:hover { border-color: var(--accent); }
.btn.disabled { border: 1px dashed var(--line); color: var(--muted); cursor: not-allowed; }
.hero-shot { margin: 0; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 0 6px rgba(77, 107, 254, 0.08); }

/* stats */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--bg2); }
.stats-in { display: grid; grid-template-columns: repeat(4, 1fr); }
.stats-in > div { padding: 26px 20px; display: flex; flex-direction: column; gap: 4px; border-left: 1px solid var(--line); }
.stats-in > div:first-child { border-left: 0; }
.stats b { font-size: 32px; line-height: 1.1; letter-spacing: -0.02em; }
.stats small { font-size: 16px; color: var(--muted); margin-left: 2px; font-weight: 500; }
.stats-in > div > span { color: var(--muted); font-size: 14px; }

/* sections */
.section { padding: 88px 0; }
.section.alt { background: var(--bg2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
h2 { margin: 0 0 36px; font-size: clamp(28px, 3.4vw, 38px); letter-spacing: -0.015em; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 24px; transition: border-color 0.15s, transform 0.15s; }
.card:hover { border-color: rgba(77, 107, 254, 0.6); transform: translateY(-2px); }
.card h3 { margin: 0 0 8px; font-size: 18px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.card.warn { border-color: rgba(255, 181, 71, 0.35); }
.card.warn b { color: var(--warn); font-weight: 600; }

.shots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.shots figure { margin: 0; }
.shots img { border-radius: 12px; border: 1px solid var(--line); }
.shots figcaption { margin-top: 10px; color: var(--muted); font-size: 14px; text-align: center; }

.dl { display: flex; align-items: center; justify-content: space-between; gap: 20px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 22px 24px; }
.dl p { margin: 0; }
.beta { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; color: var(--warn); border: 1px solid rgba(255, 181, 71, 0.5); border-radius: 6px; padding: 1px 6px; vertical-align: 2px; }
.dl-title { font-weight: 600; font-size: 17px; margin-bottom: 4px !important; }
.small { font-size: 14px; margin: 18px 0 0; }
.code { margin: 8px 0 0; background: #0b0f20; border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; overflow-x: auto; font-size: 14px; line-height: 1.7; }
.code code { background: none; border: 0; padding: 0; }
.code .c { color: #6b75a0; }

.steps { margin: 0 0 24px; padding: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; position: relative; padding: 0 0 20px 52px; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: -2px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 700; font-size: 15px; background: rgba(77, 107, 254, 0.15); color: var(--soft); border: 1px solid rgba(77, 107, 254, 0.4);
}

.foot { padding: 40px 0 56px; }
.foot-in { display: flex; align-items: flex-start; gap: 18px; color: var(--muted); font-size: 13px; }
.foot-in p { margin: 0; flex: 1; }

/* screenshots open large */
.hero-shot img, .shots img { cursor: zoom-in; transition: transform 0.15s, box-shadow 0.15s; }
.shots img:hover { transform: scale(1.02); box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45); }
.hero-shot img:focus-visible, .shots img:focus-visible { outline: 2px solid var(--accent2); outline-offset: 3px; }
.lightbox { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center;
  background: rgba(6, 8, 18, 0.92); backdrop-filter: blur(6px); padding: 24px 72px; animation: lbIn 0.15s ease-out; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; cursor: zoom-out; }
.lightbox img { max-width: min(1600px, 100%); max-height: calc(100vh - 110px); width: auto; border-radius: 12px; border: 1px solid var(--line); box-shadow: 0 30px 90px rgba(0, 0, 0, 0.6); cursor: default; }
.lightbox figcaption { margin-top: 14px; color: var(--muted); font-size: 15px; }
.lb-close, .lb-nav { position: absolute; border: 1px solid var(--line); background: rgba(23, 29, 58, 0.85); color: var(--text);
  border-radius: 50%; width: 46px; height: 46px; font-size: 28px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.lb-close:hover, .lb-nav:hover { border-color: var(--accent); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
@keyframes lbIn { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 900px) {
  .hero-in { grid-template-columns: 1fr; gap: 40px; }
  .grid, .shots { grid-template-columns: 1fr 1fr; }
  .stats-in { grid-template-columns: 1fr 1fr; }
  .stats-in > div:nth-child(3) { border-left: 0; }
  .stats-in > div:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 600px) {
  .links a:not([href^="https"]) { display: none; }
  .grid, .shots { grid-template-columns: 1fr; }
  .hero { padding-top: 48px; }
  .dl { flex-direction: column; align-items: flex-start; }
  .foot-in { flex-direction: column; }
  .lightbox { padding: 64px 8px; }
  .lb-nav { top: auto; bottom: 14px; transform: none; }
}

/* install guide (install.html, ko/install.html) */
.guide-head { padding: 64px 0 8px; }
.guide-head h1 { font-size: clamp(34px, 4.6vw, 52px); margin-bottom: 14px; }
.guide-head .lead { margin-bottom: 22px; }
.toc { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; font-size: 14px; }
.toc a { display: inline-block; border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; color: var(--muted); }
.toc a:hover { border-color: var(--accent); color: var(--text); }
.guide { padding: 48px 0 72px; }
.guide h2 { margin: 56px 0 18px; scroll-margin-top: 84px; }
.guide h2:first-child { margin-top: 0; }
.guide h3 { margin: 28px 0 8px; font-size: 18px; }
.guide p, .guide li { color: var(--text); }
.guide .steps > li { padding-bottom: 40px; }
.guide .steps > li > h3 { margin: 2px 0 8px; scroll-margin-top: 84px; }
.guide ul { padding-left: 1.2em; }
.guide ul li { margin: 4px 0; }
.shot { margin: 16px 0 0; }
.shot img { width: 100%; min-height: 140px; border-radius: 12px; border: 1px solid var(--line); background: var(--card);
  color: var(--muted); font-size: 14px; text-align: center; line-height: 140px; }
.shot figcaption { margin-top: 8px; color: var(--muted); font-size: 14px; }
.note { margin: 16px 0; padding: 14px 18px; border-radius: 12px; border: 1px solid rgba(77, 107, 254, 0.4); background: rgba(77, 107, 254, 0.08); }
.note.warn { border-color: rgba(255, 181, 71, 0.45); background: rgba(255, 181, 71, 0.07); }
.note > :first-child { margin-top: 0; } .note > :last-child { margin-bottom: 0; }
.tbl { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 15px; }
.tbl th, .tbl td { text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl th { color: var(--muted); font-weight: 600; font-size: 14px; }
kbd { font: 0.88em ui-monospace, Consolas, monospace; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 6px; padding: 0 0.4em; background: #0b0f20; }
.faq details { border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: 0 18px; margin: 10px 0; }
.faq summary { cursor: pointer; padding: 14px 0; font-weight: 600; }
.faq details[open] summary { border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.faq details > p:last-child { margin-bottom: 16px; }
.dl-help { margin: 14px 0 0; font-size: 15px; }
.dl-help a { font-weight: 600; }

/* English is the default page; a Korean browser gets a hint, never a redirect */
.langhint { position: sticky; top: 0; z-index: 60; display: flex; justify-content: center; gap: 12px; align-items: center;
            padding: 8px 16px; background: #1A2142; border-bottom: 1px solid var(--line); font-size: 14px; }
.langhint button { font: inherit; color: var(--text); background: transparent; border: 0; cursor: pointer; font-size: 18px; line-height: 1; }
