/* Oplin 사이트 — 색은 도트 로고에서 가져옵니다: 작업복 파랑 · 별 노랑 · 밤하늘 */
:root {
  /* 로고의 밤하늘 */
  --bg: #121117;
  --surface: #1b1a21;
  --surface-2: #23222b;
  --ink: #e9edf6;
  --ink-muted: #aab1c3;
  --ink-subtle: #747b8d;
  --line: #2f2e38;
  /* 로고의 작업복 파랑 · 별 노랑 · 서류 흰색 */
  --accent: #8fa8e8;
  --blue: #4a6cb4;
  --blue-deep: #3d5c9f;
  --accent-ink: #121117;
  --accent-soft: #212a40;
  --star: #f2c24f;
  --star-deep: #e9a23b;
  --star-soft: #2e2716;
  --paper: #eef1f6;
  --night: #16151a;
  --warn-soft: #2a2518;
  --shadow: 4px 4px 0 #050507;
  --radius: 4px;
  --font: 'Pretendard', 'Apple SD Gothic Neo', 'Noto Sans KR', 'Malgun Gothic', system-ui, sans-serif;
  --mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--bg);
  background-image: radial-gradient(ellipse 80% 420px at 50% 0, rgb(74 108 180 / 22%), transparent 70%), radial-gradient(rgb(255 255 255 / 5%) 1px, transparent 1px);
  background-size: auto, 22px 22px;
  color: var(--ink);
  font: 16px/1.7 var(--font);
  word-break: keep-all;
  overflow-wrap: anywhere;
}
a { color: var(--accent); text-underline-offset: 3px; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { line-height: 1.3; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); margin: 0 0 0.6em; }
h2 { display: flex; align-items: center; gap: 10px; }
h2::before { content: ''; flex: none; width: 10px; height: 10px; background: var(--blue); box-shadow: 10px 0 0 var(--star); margin-right: 10px; }
h2 { font-size: 1.35rem; margin: 2.2em 0 0.6em; }
h3 { font-size: 1.08rem; margin: 1.6em 0 0.4em; }
p { margin: 0 0 1em; }
code { font: 0.88em var(--mono); background: var(--accent-soft); padding: 0.1em 0.35em; border-radius: 4px; }
.muted { color: var(--ink-muted); }
.small { font-size: 0.9rem; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 10; }

/* 머리 */
.top { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1180px; margin: 0 auto; padding: 0 16px; height: 60px; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1.15rem; color: var(--ink); text-decoration: none; margin-right: auto; }
.top-nav { display: flex; gap: 4px; }
.top-nav a, .menu nav a { color: var(--ink-muted); text-decoration: none; padding: 6px 12px; border-radius: 8px; font-size: 0.95rem; }
.top-nav a:hover, .menu nav a:hover { background: var(--accent-soft); color: var(--ink); }
.top-nav a[aria-current], .menu nav a[aria-current] { color: var(--ink); font-weight: 600; box-shadow: inset 0 -2px 0 var(--star); border-radius: 0; }
.menu { display: none; position: relative; }
.menu summary { list-style: none; cursor: pointer; width: 40px; height: 40px; display: grid; place-content: center; gap: 4px; border-radius: 8px; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary span { display: block; width: 20px; height: 3px; background: var(--ink); }
.menu nav { position: absolute; right: 0; top: 46px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 8px; display: grid; min-width: 180px; }
@media (max-width: 720px) {
  .top-nav { display: none; }
  .menu { display: block; }
}

/* 본문 틀 */
main { max-width: 1180px; margin: 0 auto; padding: 40px 16px 64px; }
main.doc { max-width: none; margin: 0; padding: 0; min-width: 0; }
.with-side { max-width: 1180px; margin: 0 auto; padding: 32px 16px 64px; display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; }
.side { position: sticky; top: 84px; align-self: start; font-size: 0.93rem; max-height: calc(100vh - 100px); overflow: auto; }
.side ul { list-style: none; margin: 0 0 12px; padding: 0; }
.side a { display: block; padding: 5px 10px; border-radius: 6px; color: var(--ink-muted); text-decoration: none; }
.side a:hover { background: var(--accent-soft); color: var(--ink); }
.side a[aria-current] { background: var(--accent-soft); color: var(--ink); font-weight: 600; box-shadow: inset 3px 0 0 var(--star); }
.side-home { margin-bottom: 8px; font-weight: 600; }
.side-group { margin: 12px 10px 4px; font: 600 0.75rem var(--mono); color: var(--star-deep); letter-spacing: 0.06em; }
@media (max-width: 900px) {
  .with-side { grid-template-columns: 1fr; gap: 16px; padding-top: 16px; }
  .side { position: static; max-height: none; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; background: var(--surface); }
  .side ul { display: flex; flex-wrap: wrap; gap: 2px; margin-bottom: 4px; }
  .side-group { margin: 6px 10px 2px; }
}
.doc > * { max-width: 860px; }
.doc > figure, .doc > .shots, .doc > .table-wrap { max-width: none; }

/* 꼬리 */
.foot { border-top: 2px solid var(--line); background: var(--night); }
.foot-in { max-width: 1180px; margin: 0 auto; padding: 24px 16px 40px; font-size: 0.9rem; }
.foot p { margin: 0 0 4px; }

/* 소개 첫 화면 */
.hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 48px; align-items: center; padding: 24px 0 40px; }
.hero h1 { font-size: clamp(2rem, 5vw, 3rem); }
.hero .lead { font-size: 1.15rem; color: var(--ink-muted); }
.eyebrow { display: inline-block; font: 600 0.8rem var(--mono); letter-spacing: 0.06em; color: var(--star); background: var(--star-soft); border: 1px solid #5a4a20; padding: 2px 10px; border-radius: 2px; margin-bottom: 16px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.btn { display: inline-block; padding: 10px 18px; border-radius: 8px; text-decoration: none; font-weight: 600; border: 1px solid var(--line); color: var(--ink); background: var(--surface); }
.btn { border-radius: 2px; box-shadow: var(--shadow); border-width: 2px; }
.btn.primary { background: var(--star); color: var(--accent-ink); border-color: var(--star-deep); }
.btn:hover { transform: translate(1px, 1px); box-shadow: 3px 3px 0 #050507; }
@media (max-width: 900px) { .hero { grid-template-columns: 1fr; gap: 24px; } }

/* 카드 격자 */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; margin: 16px 0 8px; }
.card { background: var(--surface); border: 2px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card h3 { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }
a.card { display: block; color: var(--ink); text-decoration: none; transition: border-color 0.15s; }
a.card:hover { border-color: var(--blue); }
a.card h3::before, .grid .card h3::before { content: ''; display: inline-block; width: 8px; height: 8px; background: var(--star); margin: 0 8px 2px 0; }
a.card .more { color: var(--accent); font-size: 0.9rem; }
.card ul { margin: 0; padding-left: 1.1em; }

/* 화면 캡처 */
figure { margin: 20px 0 28px; }
.shot { border: 2px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: var(--surface); }
figcaption { font-size: 0.88rem; color: var(--ink-muted); margin-top: 8px; }
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 20px; align-items: start; margin: 20px 0 28px; }
.shots figure { margin: 0; }
.phone .shot { border-radius: 14px; }
.zoom { display: block; }

/* 단계 */
ol.steps { counter-reset: s; list-style: none; padding: 0; margin: 0 0 1.2em; }
ol.steps > li { counter-increment: s; position: relative; padding-left: 40px; margin-bottom: 12px; }
ol.steps > li::before { content: counter(s); position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 2px; background: var(--blue); color: var(--paper); font-family: var(--mono); font-size: 0.85rem; font-weight: 700; display: grid; place-content: center; }

/* 머리 세 줄 */
.meta { border: 2px solid var(--line); border-left: 4px solid var(--blue); background: var(--surface); border-radius: var(--radius); padding: 12px 16px; margin: 0 0 24px; display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; font-size: 0.93rem; }
.meta dt { color: var(--ink-subtle); font: 600 0.8rem/1.9 var(--mono); }
.meta dd { margin: 0; }

.note { background: var(--warn-soft); border-left: 4px solid var(--star); border-radius: var(--radius); padding: 12px 16px; margin: 16px 0; font-size: 0.95rem; }
.note p:last-child { margin: 0; }

.table-wrap { overflow-x: auto; margin: 12px 0 20px; }
table { border-collapse: collapse; width: 100%; font-size: 0.93rem; background: var(--surface); border: 2px solid var(--line); border-radius: var(--radius); }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--ink-muted); font-weight: 600; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }

.pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 48px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 0.95rem; }
.section-band { margin-top: 56px; }
.diagram { width: 100%; height: auto; }

/* 도트 로고 */
.pixel { image-rendering: pixelated; }
.brand img { width: 28px; height: 28px; }
.brand .word { width: auto; height: 18px; }
.stage { position: relative; background: var(--night); border-radius: 4px; border: 2px solid var(--line); box-shadow: 8px 8px 0 #050507; aspect-ratio: 1 / 1; max-width: 440px; width: 100%; margin-left: auto; overflow: hidden;
  background-image: radial-gradient(circle at 50% 42%, rgb(90 110 170 / 35%), transparent 60%), radial-gradient(rgb(255 255 255 / 5%) 1px, transparent 1px);
  background-size: auto, 22px 22px; }
.stage img { position: absolute; inset: 0; width: 100%; height: 100%; }
.stage i { position: absolute; width: 1.6%; height: 1.6%; background: var(--star); opacity: 0.8; }
.stage-cap { color: var(--ink-muted); font-size: 0.88rem; text-align: right; margin-top: 8px; }
@media (max-width: 900px) { .stage { margin: 0 auto; max-width: 320px; } .stage-cap { text-align: center; } }

.story { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.story .card { display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: start; }
.story .card img { width: 56px; height: 56px; background: var(--night); border: 2px solid var(--line); border-radius: 2px; padding: 6px; }
.story .card h3::before { display: none; }
.story .card h3 { margin: 2px 0 6px; }
@media (max-width: 900px) { .story { grid-template-columns: 1fr; } }
figure.phone { max-width: 300px; }
