/* IIDXwidget 랜딩 페이지. 위젯과 같은 어두운 계기판 느낌, 강조색은 KPS 게이지의 주황→빨강 */
:root {
  --bg: #0b0c10;
  --panel: #12141a;
  --panel-2: #171a22;
  --line: #232734;
  --text: #e9ebf1;
  --muted: #9aa1b0;
  --amber: #ffb020;
  --hot: #ff4d2e;
  --cyan: #4fe0ff;
  --radius: 16px;
  --display: 'Chakra Petch', 'Pretendard', sans-serif;
  --body: 'Pretendard', -apple-system, 'Segoe UI', 'Malgun Gothic', sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(255, 120, 40, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(79, 224, 255, 0.06), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: var(--body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--amber); text-decoration: none; }
a:hover { text-decoration: underline; }
code { font-family: Consolas, monospace; font-size: 0.92em; background: #1d212b; padding: 2px 6px; border-radius: 5px; }

/* 언어: html[data-lang]과 다른 언어는 숨긴다 */
html[data-lang="ko"] [lang="en"],
html[data-lang="en"] [lang="ko"] { display: none !important; }

/* ─── 상단 바 ─── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px clamp(16px, 4vw, 48px);
  background: rgba(11, 12, 16, 0.78);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: 0.04em; color: var(--text); }
.brand span { color: var(--amber); }
.brand:hover { text-decoration: none; }
.nav { display: flex; gap: 20px; margin-left: auto; }
.nav a { color: var(--muted); font-size: 14px; }
.nav a:hover { color: var(--text); text-decoration: none; }
.lang-toggle { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.lang-toggle button {
  background: none; border: 0; color: var(--muted); padding: 5px 12px; cursor: pointer;
  font-family: var(--display); font-weight: 600; font-size: 12px; letter-spacing: 0.1em;
}
.lang-toggle button.active { background: var(--amber); color: #111; }

/* ─── 첫 화면 ─── */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(24px, 5vw, 64px);
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(48px, 8vw, 110px) clamp(16px, 4vw, 48px) clamp(40px, 6vw, 80px);
}
.eyebrow { font-family: var(--display); letter-spacing: 0.24em; font-size: 12px; color: var(--muted); margin: 0 0 18px; }
h1 { font-family: var(--display); font-size: clamp(40px, 6vw, 68px); line-height: 1.05; margin: 0 0 20px; letter-spacing: -0.01em; }
h1 em {
  font-style: normal;
  background: linear-gradient(90deg, var(--amber), var(--hot));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lead { font-size: 18px; color: #c9cdd8; max-width: 34em; margin: 0 0 28px; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; }
.cta.center { justify-content: center; margin-top: 28px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 22px; border-radius: 12px; font-weight: 700; font-size: 16px;
  border: 1px solid var(--line); color: var(--text);
}
.btn:hover { text-decoration: none; }
.btn small { font-weight: 500; font-size: 12px; opacity: 0.7; }
.btn.primary { background: linear-gradient(135deg, var(--amber), var(--hot)); color: #120a04; border: 0; box-shadow: 0 10px 30px rgba(255, 90, 40, 0.25); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.ghost:hover { border-color: #3a4052; background: var(--panel); }
.fineprint { color: var(--muted); font-size: 13px; margin-top: 18px; }

.screen {
  background: #0e0f13;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.02) inset;
}
.screen-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--panel); }
.screen-bar i { width: 10px; height: 10px; border-radius: 50%; background: #2a2e3a; }
.screen-bar span { margin-left: 8px; font-family: var(--display); font-size: 12px; letter-spacing: 0.08em; color: var(--muted); }
video.demo, .feature-media img { display: block; width: 100%; height: auto; background: #0e0f13; }

/* ─── 섹션 공통 ─── */
.section { max-width: 1200px; margin: 0 auto; padding: clamp(48px, 7vw, 96px) clamp(16px, 4vw, 48px); }
.section-title { font-family: var(--display); font-size: clamp(28px, 4vw, 40px); margin: 0 0 32px; display: flex; align-items: baseline; gap: 14px; }
.section-title .num { font-size: 14px; color: var(--amber); letter-spacing: 0.2em; }

.cards { display: grid; gap: 16px; }
.cards.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card h3 { font-size: 17px; margin: 0 0 10px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

.who { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.who li { background: var(--panel); border: 1px solid var(--line); border-left: 3px solid var(--amber); border-radius: 12px; padding: 18px 20px; color: var(--muted); font-size: 15px; }
.who b { display: block; color: var(--text); font-size: 16px; margin-bottom: 6px; }

/* ─── 기능 ─── */
.feature {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 48px);
  align-items: center;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.feature.reverse .feature-media { order: 2; }
.feature.wide { grid-template-columns: 1fr; }
.feature.wide .feature-text { max-width: 760px; }
.feature-media { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45); }
.feature-text h3 { font-family: var(--display); font-size: 26px; margin: 0 0 12px; }
.feature-text p { color: #c3c8d4; margin: 0 0 16px; }
.more { font-weight: 600; font-size: 15px; }

.minis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.mini { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.mini img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; border-bottom: 1px solid var(--line); }
.mini h3 { font-size: 16px; margin: 16px 18px 6px; }
.mini p { color: var(--muted); font-size: 14px; margin: 0 18px 12px; flex: 1; }
.mini .more { margin: 0 18px 18px; font-size: 14px; }

/* ─── 시작하기 ─── */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.steps li { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; color: #c3c8d4; }
.steps b { display: block; font-family: var(--display); font-size: 32px; color: var(--amber); line-height: 1; margin-bottom: 10px; }

/* ─── 개발자 ─── */
.dev { display: flex; gap: 32px; align-items: flex-start; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 4vw, 36px); }
.dev-photo { width: 160px; height: 160px; object-fit: contain; border-radius: 20px; background: var(--panel-2); flex-shrink: 0; }
.dev-body h3 { font-family: var(--display); font-size: 28px; margin: 0 0 10px; }
.dev-body h3 small { font-size: 16px; color: var(--muted); margin-left: 6px; }
.dev-body p { color: #c3c8d4; margin: 0 0 16px; }
.dev-links { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.dev-links a { padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--text); font-size: 14px; }
.dev-links a:hover { text-decoration: none; border-color: #3a4052; }
.dev-links a.coffee { background: #ffdd00; color: #111; border-color: transparent; font-weight: 700; }
.contributors { color: var(--muted) !important; font-size: 14px; }

/* ─── 바닥 ─── */
.footer { border-top: 1px solid var(--line); padding: 32px clamp(16px, 4vw, 48px) 48px; text-align: center; color: var(--muted); font-size: 14px; }
.footer p { margin: 6px 0; }
.footer .muted { font-size: 12px; opacity: 0.7; }

/* ─── 좁은 화면 ─── */
@media (max-width: 960px) {
  .hero, .feature { grid-template-columns: 1fr; }
  .feature.reverse .feature-media { order: 0; }
  .cards.four, .minis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .who, .steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .nav { display: none; }
  .lang-toggle { margin-left: auto; }
  .cards.four, .minis, .who, .steps { grid-template-columns: 1fr; }
  .dev { flex-direction: column; align-items: center; text-align: center; }
  .dev-links { justify-content: center; }
}

/* ─── 왜 좋은가: 3장 ─── */
.cards.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ─── 한 장면 + 영역 강조 (입력 계기판·KPS·릴리즈) ───
   오른쪽 항목에 마우스를 올리면 영상에서 그 영역만 밝게 두고 나머지를 어둡게, 그 영역 쪽으로 살짝 확대한다 */
.spotlight {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 40px);
  align-items: center;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.spot-media { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45); }
.spot-stage { position: relative; transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.2, 1); transform-origin: 50% 50%; }
.spot-mask { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.spot-mask path { fill: rgba(5, 6, 9, 0.72); opacity: 0; transition: opacity 0.3s; }
.spotlight.active .spot-mask path { opacity: 1; }
.spot-list { display: flex; flex-direction: column; gap: 12px; }
.spot-item {
  padding: 16px 18px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid transparent;
  border-radius: 12px;
  background: var(--panel);
  cursor: default;
  transition: border-color 0.2s, background-color 0.2s;
  outline: none;
}
.spot-item h3 { font-family: var(--display); font-size: 20px; margin: 0 0 6px; }
.spot-item p { color: var(--muted); font-size: 14.5px; margin: 0 0 8px; }
.spot-item .more { font-size: 14px; }
.spot-item.on, .spot-item:focus-visible { border-left-color: var(--amber); background: var(--panel-2); }
.spot-item.on h3 { color: var(--amber); }

@media (max-width: 960px) {
  .spotlight { grid-template-columns: 1fr; }
  .cards.three { grid-template-columns: 1fr; }
}
