/* powerhacker.net look (paper, deep green, D2Coding) + a console that drops from the top */
:root {
  --bg: #faf9f6; --fg: #15171c; --muted: #f0eee8; --muted-fg: #6b6a64; --primary: #1a7f37; --border: #e0ddd4;
  --warn: #9a6700; --bad: #cf222e;
  --term: #0b0e13; --term-fg: #d8dee9; --term-dim: #6b7385;
  --mono: "D2Coding", "Pretendard Variable", ui-monospace, monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--fg);
  font: 14px/1.55 "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif; overflow: hidden; }
a { color: inherit; }
button { font: inherit; cursor: pointer; border-radius: 3px; border: 1px solid var(--primary); background: var(--primary); color: #fff; padding: 5px 12px; font-weight: 600; font-size: 13px; }
button.ghost { background: transparent; color: var(--fg); border-color: var(--border); }
.muted { color: var(--muted-fg); }

/* header — same metrics as powerhacker.net (h-16, max-w 1180) */
header.site { position: relative; z-index: 3; height: 64px; border-bottom: 1px solid var(--border); background: var(--bg); }
header.site .inner { max-width: 1180px; height: 64px; margin: 0 auto; padding: 0 20px; display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.brand { font-family: var(--mono); font-size: 17px; font-weight: 700; letter-spacing: -0.01em; text-decoration: none; }
.brand .g { color: var(--primary); }
@keyframes blink { 0%, 45% { opacity: 1 } 55%, 100% { opacity: 0 } }
.cursor::after { content: ""; display: inline-block; width: .5em; height: 1em; margin-left: .18em; vertical-align: -.12em;
  background: var(--primary); animation: blink 1.6s steps(1, end) infinite; }
@media (prefers-reduced-motion: reduce) { .cursor::after { animation: none; opacity: .5 } }
.chip { border-radius: 3px; padding: 6px 12px; font-size: 14px; border: 1px solid var(--border); }
.chip.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.grow { flex: 1; }
.pill { font-family: var(--mono); font-size: 12.5px; padding: 3px 9px; border-radius: 3px; background: var(--muted); color: var(--muted-fg); }
.pill.ok { color: var(--primary); } .pill.warn { color: var(--warn); } .pill.bad { color: var(--bad); }
.close { font-size: 14px; text-decoration: none; border: 1px solid var(--border); padding: 5px 11px; border-radius: 3px; }
.close:hover { background: var(--muted); }

/* the drop-down console */
.drop { position: absolute; left: 0; right: 0; top: 64px; bottom: 0; padding: 14px 20px 10px; display: flex; flex-direction: column;
  transform: translateY(-110%); transition: transform .55s cubic-bezier(.2,.8,.2,1); }
.drop.open { transform: translateY(0); }
.term-wrap { flex: 1; min-height: 0; max-width: 1180px; width: 100%; margin: 0 auto; display: flex; flex-direction: column;
  background: var(--term); border-radius: 6px; box-shadow: 0 18px 50px rgba(0,0,0,.28), 0 0 0 1px #000; overflow: hidden; }
.titlebar { height: 32px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 12px; background: #151a22; color: var(--term-dim);
  font-family: var(--mono); font-size: 12.5px; }
.titlebar .dots i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; background: #3a4150; }
.titlebar .dots i:first-child { background: #cf222e; } .titlebar .dots i:nth-child(2) { background: #9a6700; } .titlebar .dots i:nth-child(3) { background: #1a7f37; }
.titlebar .ttl { flex: 1; }
.titlebar .badge { color: #7ee2a0; }
.boot { flex: none; padding: 12px 16px 0; font-family: var(--mono); font-size: 13.5px; color: var(--term-fg); white-space: pre; }
.boot .ok { color: #7ee2a0; } .boot .dim { color: var(--term-dim); } .boot .err { color: #ff7b72; } .boot .hd { color: #7aa2f7; font-weight: 700; }
.console { flex: 1; min-height: 0; padding: 4px 0 0 10px; display: none; }
.foot { max-width: 1180px; width: 100%; margin: 8px auto 0; display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--muted-fg); }
.foot a { color: var(--muted-fg); }

/* mobile */
.mobile { position: absolute; inset: 64px 0 0 0; display: flex; align-items: center; justify-content: center; padding: 20px; }
.m-card { max-width: 420px; background: var(--term); color: var(--term-fg); border-radius: 8px; padding: 22px; font-size: 15px; }
.m-title { font-family: var(--mono); color: #7ee2a0; font-weight: 700; margin-bottom: 10px; }
.m-sub { color: var(--term-dim); }
.m-card .close { color: var(--term-fg); border-color: #3a4150; display: inline-block; margin-top: 8px; }

/* modals */
.modal { position: fixed; inset: 0; background: rgba(15,17,20,.55); display: none; align-items: center; justify-content: center; z-index: 10; }
.modal.scroll { overflow: auto; align-items: flex-start; }
.modal .card { background: var(--bg); border: 1px solid var(--border); border-radius: 6px; padding: 22px 26px; max-width: 460px; }
.modal .card.wide { max-width: 720px; margin: 40px auto; }
.modal h2 { margin: 0 0 6px; font-size: 19px; }
.modal h3 { margin: 16px 0 4px; font-size: 15px; color: var(--primary); }
.modal p { margin: 4px 0; }
code { font-family: var(--mono); background: var(--muted); padding: 0 4px; border-radius: 3px; }
