/* frames.css: the live app inside real chrome. <app-frame> scales a kit/app screen to its own width (kit/frame.js). */

app-frame { display: block; position: relative; overflow: hidden; background: var(--ground); contain: layout paint; }
app-frame iframe { position: absolute; left: 0; top: 0; border: 0; max-width: none; max-height: none; transform-origin: 0 0; pointer-events: none; color-scheme: normal; }
app-frame[interactive] iframe { pointer-events: auto; }

/* ---------- desktop window ---------- */
.win { position: relative; border-radius: 12px; overflow: hidden; background: var(--ground); box-shadow: var(--shadow-window); container-type: inline-size; }
.win[data-os="win"] { border-radius: 8px; }
.win[data-os="linux"] { border-radius: 12px; }
.win > app-frame { border-radius: inherit; }

/* ---------- the web app, in a browser ---------- */
.browser { position: relative; border-radius: 12px; overflow: hidden; background: var(--panel); box-shadow: var(--shadow-window); }
.browser > .chrome { display: flex; align-items: center; gap: 12px; height: 42px; padding: 0 14px; background: var(--rail); box-shadow: inset 0 -0.5px 0 var(--rule); }
.browser > .chrome .lights { display: flex; gap: 6px; }
.browser > .chrome .lights i { width: 11px; height: 11px; border-radius: 50%; background: #FF5F57; }
.browser > .chrome .lights i:nth-child(2) { background: #FEBC2E; } .browser > .chrome .lights i:nth-child(3) { background: #28C840; }
.browser > .chrome .url { flex: 1; max-width: 420px; margin-inline: auto; height: 28px; border-radius: 14px; background: var(--pill); display: flex; align-items: center; justify-content: center; gap: 6px;
  font: 500 12.5px/1 var(--sans); color: var(--gray); }
.browser > .chrome .url svg { width: 11px; height: 11px; color: var(--faint); }
.browser > .chrome .pad { width: 45px; }

/* ---------- phones: sizes follow the frame's own width ---------- */
.phone { position: relative; container-type: inline-size; width: 300px; max-width: 100%; }
.phone > .bezel { position: relative; padding: 2.5cqw; border-radius: 15.5cqw; background: #0E0F12;
  box-shadow: inset 0 0 0 .35cqw #2A2D33, inset 0 0 0 .7cqw #050506, 0 1px 2px rgba(16, 24, 40, .08), 0 30px 60px -30px rgba(16, 24, 40, .42); }
.phone > .bezel > app-frame { border-radius: 13.2cqw; }
:root[data-theme="dark"] .phone > .bezel { box-shadow: inset 0 0 0 .35cqw #343844, inset 0 0 0 .7cqw #050506, 0 0 0 .5px rgba(255, 255, 255, .08), 0 30px 60px -30px rgba(0, 0, 0, .9); }
/* side buttons */
.phone > .bezel::before, .phone > .bezel::after { content: ""; position: absolute; width: .9cqw; background: #1A1C20; border-radius: .5cqw; }
.phone > .bezel::before { left: -.8cqw; top: 26cqw; height: 9cqw; box-shadow: 0 13cqw 0 #1A1C20; }
.phone > .bezel::after { right: -.8cqw; top: 34cqw; height: 15cqw; }

/* ---------- terminal window ---------- */
.term { border-radius: 12px; overflow: hidden; background: var(--term-bg, #0B0E14); color: var(--term-ink, #D6DBE4); box-shadow: var(--shadow-window);
  --term-bg: #0B0E14; --term-ink: #D6DBE4; --term-dim: #7E8696; --term-faint: #4A5160; --term-line: #2B313C; --term-accent: #4D8DFF;
  --term-ok: #3CD3A3; --term-warn: #F2B544; --term-sel: rgba(77, 141, 255, .18); --term-bar: #11151D; }
:root:not([data-theme="dark"]) .term.follows { --term-bg: #FFFFFF; --term-ink: #1B1E24; --term-dim: #6E7380; --term-faint: #A1A5AF; --term-line: #CDD1D8;
  --term-accent: #0A66FF; --term-ok: #0E8F68; --term-warn: #B7780A; --term-sel: rgba(10, 102, 255, .10); --term-bar: #F7F8FA; }
.term .term-bar { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; background: var(--term-bar); box-shadow: inset 0 -0.5px 0 var(--term-line);
  font: 500 12.5px/1 var(--sans); color: var(--term-dim); }
.term .term-bar .lights { display: flex; gap: 6px; margin-right: 6px; }
.term .term-bar .lights i { width: 11px; height: 11px; border-radius: 50%; background: #FF5F57; }
.term .term-bar .lights i:nth-child(2) { background: #FEBC2E; } .term .term-bar .lights i:nth-child(3) { background: #28C840; }
.term .term-bar .ttl { flex: 1; text-align: center; margin-right: 46px; }
.term pre, .term .screen { margin: 0; padding: 14px 16px 16px; font: 400 13px/1.3 var(--mono); font-feature-settings: "tnum" 0; white-space: pre; overflow-x: auto; color: var(--term-ink); tab-size: 8; text-rendering: geometricPrecision; }
.term .a { color: var(--term-accent); } .term .i { color: var(--term-ink); } .term .m { color: var(--term-dim); } .term .f { color: var(--term-faint); }
.term .l { color: var(--term-line); } .term .ok { color: var(--term-ok); } .term .w { color: var(--term-warn); } .term .b { font-weight: 600; }
.term .sel { background: var(--term-sel); }
.term .clip { display: inline-block; width: 2ch; height: 1em; vertical-align: -0.12em; color: var(--term-dim); }
.term .clip svg { display: block; width: 1em; height: 1em; margin: 0 auto; }
.term .p { color: var(--term-accent); user-select: none; }   /* the prompt */
