:root {
  color-scheme: light;
  --ink: #18253d;
  --muted: #748097;
  --blue: #5268e8;
  --blue-dark: #4055d2;
  --line: #e8ebf2;
  --surface: #fff;
  --canvas: #f5f7fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--canvas); }
button, select { font: inherit; }
button:focus-visible, select:focus-visible, a:focus-visible, input:focus-visible + .switch-track { outline: 3px solid #a8b5ff; outline-offset: 3px; }
.app-shell { min-height: 100vh; overflow: hidden; background: radial-gradient(ellipse at 72% 14%, rgba(230, 235, 255, .58), transparent 34%), var(--canvas); }
.topbar { height: 76px; padding: 0 max(5.8vw, 26px); border-bottom: 1px solid rgba(222, 227, 237, .72); display: flex; align-items: center; justify-content: space-between; background: rgba(255,255,255,.64); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 760; letter-spacing: -1px; }
.brand-dot { color: var(--blue); }
.brand-mark { width: 27px; height: 27px; display: grid; grid-template-columns: 1fr 1fr; align-content: center; gap: 3px; padding: 5px; border-radius: 8px; background: var(--blue); transform: rotate(-5deg); }
.brand-mark span { border-radius: 2px; background: white; }
.brand-mark span:nth-child(2), .brand-mark span:nth-child(3) { opacity: .58; }
.topbar-right { display: flex; align-items: center; gap: 17px; }
.local-badge { color: #68758d; font-size: 12px; font-weight: 600; }
.lock-icon { margin-right: 6px; color: #35a985; font-size: 10px; }
.avatar { display: grid; width: 34px; height: 34px; place-items: center; color: #5265d7; background: #e8ebff; border-radius: 50%; font-size: 13px; font-weight: 700; }
main { width: min(1120px, calc(100% - 48px)); margin: 0 auto; }
.intro { padding: 55px 0 31px; max-width: 620px; }
.eyebrow, .section-kicker { color: #8994a8; font-size: 10px; font-weight: 750; letter-spacing: 1.55px; }
.eyebrow { display: flex; align-items: center; gap: 9px; }
.eyebrow-line { width: 19px; height: 2px; background: #7282ee; border-radius: 2px; }
h1 { margin: 15px 0 12px; font-size: clamp(35px, 4.5vw, 53px); line-height: 1.08; letter-spacing: -2.55px; font-weight: 740; }
h1 span { color: var(--blue); }
.intro p { max-width: 510px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.75; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.72fr) minmax(285px, .88fr); align-items: stretch; gap: 19px; }
.studio-card, .settings-card { background: var(--surface); border: 1px solid #e9ecf3; border-radius: 15px; box-shadow: 0 9px 32px rgba(39, 54, 93, .055); }
.studio-card { padding: 23px; min-width: 0; }
.studio-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 17px; }
.studio-heading h2, .settings-heading h2 { margin: 5px 0 0; color: var(--ink); font-size: 17px; letter-spacing: -.35px; }
.status-pill { display: flex; align-items: center; gap: 7px; padding: 7px 10px; color: #79849a; border-radius: 20px; background: #f4f6f9; font-size: 10px; font-weight: 600; white-space: nowrap; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #aab3c2; }
.status-pill.is-recording { color: #c94551; background: #fff0f1; }
.status-pill.is-recording .status-dot { background: #e04c5a; box-shadow: 0 0 0 3px rgba(224,76,90,.13); animation: pulse 1.4s infinite; }
.status-pill.is-paused { color: #ad7b23; background: #fff7e6; }
.status-pill.is-paused .status-dot { background: #e0a83f; }
.preview { position: relative; display: grid; min-height: 286px; aspect-ratio: 16 / 9; overflow: hidden; place-items: center; border: 1px solid #e8ebf2; border-radius: 10px; background: linear-gradient(145deg, #f6f8fc, #f0f3fa); }
.preview video { display: none; width: 100%; height: 100%; object-fit: contain; background: #111; }
.preview.has-video video { display: block; }
.preview-empty { display: flex; flex-direction: column; align-items: center; padding: 22px; text-align: center; }
.preview-empty strong { margin-top: 10px; color: #526078; font-size: 12px; font-weight: 650; }
.preview-empty > span { margin-top: 5px; color: #96a0b1; font-size: 10px; }
.screen-illustration { position: relative; width: 132px; height: 80px; padding: 7px; border: 2px solid #cbd3e4; border-radius: 8px; background: #e7eaf7; }
.screen-top { display: flex; gap: 3px; height: 9px; align-items: center; padding-left: 3px; border-radius: 3px 3px 0 0; background: #d6dcef; }
.screen-top i { width: 3px; height: 3px; border-radius: 50%; background: #aab5ce; }
.screen-content { position: relative; display: flex; height: 54px; align-items: center; justify-content: center; flex-direction: column; gap: 4px; border-radius: 0 0 3px 3px; background: #fff; }
.screen-play { display: grid; width: 23px; height: 23px; margin-bottom: 1px; place-items: center; padding-left: 2px; border-radius: 50%; color: #fff; background: #7383eb; font-size: 9px; }
.screen-line { width: 55px; height: 3px; border-radius: 3px; background: #e2e6f0; }
.screen-line.short { width: 32px; }
.screen-stand { position: absolute; bottom: -8px; left: 50%; width: 30px; height: 5px; transform: translateX(-50%); border-radius: 0 0 5px 5px; background: #cbd3e4; }
.preview-live, .preview-timer { position: absolute; z-index: 1; top: 12px; padding: 6px 9px; border-radius: 5px; color: white; background: rgba(20, 26, 39, .76); font-size: 10px; font-variant-numeric: tabular-nums; }
.preview-live { left: 12px; color: #fff; font-weight: 750; letter-spacing: .8px; }
.preview-live span { display: inline-block; width: 6px; height: 6px; margin-right: 5px; border-radius: 50%; background: #f0525e; }
.preview-timer { right: 12px; font-weight: 650; }
.record-controls { display: flex; flex-wrap: wrap; gap: 9px; padding-top: 17px; }
.button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 0 16px; border: 1px solid transparent; border-radius: 7px; cursor: pointer; text-decoration: none; font-size: 11px; font-weight: 680; transition: transform .15s ease, background .15s ease, box-shadow .15s ease; }
.button:not(:disabled):hover { transform: translateY(-1px); }
.button:disabled { opacity: .43; cursor: not-allowed; }
.button-record { color: white; background: var(--blue); box-shadow: 0 4px 10px rgba(82,104,232,.17); }
.button-record:not(:disabled):hover { background: var(--blue-dark); box-shadow: 0 6px 15px rgba(82,104,232,.24); }
.record-icon { width: 9px; height: 9px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.2); }
.button-secondary { color: #526078; border-color: #e5e8ef; background: #fff; }
.button-secondary:hover:not(:disabled) { background: #f8f9fc; }
.button-stop { color: #b5444e; border-color: #f2dfe1; background: #fff9f9; }
.stop-icon { width: 9px; height: 9px; border-radius: 2px; background: #ca5862; }
.pause-icon { font-size: 13px; line-height: 1; }
.inline-hint { margin: 12px 0 0; color: #909bad; font-size: 10px; }
.inline-hint span { margin-right: 4px; color: #8795ee; }
.settings-card { padding: 23px 21px; }
.settings-heading { display: flex; align-items: center; gap: 11px; padding-bottom: 25px; }
.settings-heading h2 { font-size: 16px; }
.settings-icon { display: grid; width: 35px; height: 35px; place-items: center; color: #596ce0; background: #eff1ff; border-radius: 9px; font-size: 18px; }
.setting-group { display: block; }
.setting-label { display: block; color: #394761; font-size: 11px; font-weight: 680; }
.select-wrap { position: relative; margin-top: 9px; }
.select-wrap select { width: 100%; height: 39px; appearance: none; padding: 0 34px 0 11px; border: 1px solid #e4e8f0; border-radius: 6px; color: #4c5870; background: #fff; font-size: 10px; cursor: pointer; }
.select-wrap > span { position: absolute; top: 9px; right: 12px; color: #8791a3; pointer-events: none; font-size: 15px; }
.setting-help { display: block; margin-top: 7px; color: #99a2b1; font-size: 9px; line-height: 1.5; }
.setting-divider { height: 1px; margin: 17px 0; background: #eef0f4; }
.setting-label-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.audio-group .setting-help { margin-top: 4px; }
.switch { position: relative; display: inline-flex; width: 34px; height: 19px; flex: 0 0 auto; cursor: pointer; }
.switch input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.switch-track { width: 34px; height: 19px; border-radius: 20px; background: #dce1ea; transition: background .18s; }
.switch-track::after { position: absolute; top: 3px; left: 3px; width: 13px; height: 13px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(30,42,66,.18); content: ""; transition: transform .18s; }
.switch input:checked + .switch-track { background: #6578e9; }
.switch input:checked + .switch-track::after { transform: translateX(15px); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; clip-path: inset(50%); }
.tip-card { display: flex; gap: 10px; margin-top: 25px; padding: 13px 12px; border: 1px solid #eceeff; border-radius: 8px; background: #f7f8ff; }
.tip-sparkle { color: #7585ed; font-size: 15px; }
.tip-card strong { display: block; margin-bottom: 4px; color: #5363c8; font-size: 10px; }
.tip-card p { margin: 0; color: #7f89a4; font-size: 9px; line-height: 1.6; }
.result-panel { display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 12px; border: 1px solid #dcefe6; border-radius: 8px; background: #f5fbf8; }
.result-icon { display: grid; width: 26px; height: 26px; flex: 0 0 auto; place-items: center; color: #26956b; border-radius: 50%; background: #e1f4eb; font-size: 13px; font-weight: 800; }
.result-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; gap: 3px; }
.result-copy strong { color: #32694f; font-size: 10px; }
.result-copy span { overflow: hidden; color: #7b9587; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.button-download { min-height: 32px; padding: 0 10px; color: #fff; background: #35a579; font-size: 9px; }
.button-download:hover { background: #278b65; }
.icon-button { width: 25px; height: 25px; flex: 0 0 auto; padding: 0; border: 0; color: #93a096; background: transparent; cursor: pointer; font-size: 18px; }
.page-footer { display: flex; justify-content: center; gap: 8px; padding: 25px 0 28px; color: #9aa3b2; font-size: 10px; }
.footer-separator { color: #c1c7d1; }
.toast { position: fixed; right: 22px; bottom: 22px; z-index: 3; max-width: min(380px, calc(100vw - 40px)); padding: 12px 16px; border: 1px solid #f1dcdb; border-radius: 8px; color: #8e4445; background: #fff7f6; box-shadow: 0 8px 26px rgba(31,42,66,.12); font-size: 12px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: .2s ease; }
.toast.is-visible { opacity: 1; transform: translateY(0); }
[hidden] { display: none !important; }
@keyframes pulse { 50% { box-shadow: 0 0 0 5px rgba(224,76,90,.06); } }
@media (max-width: 760px) {
  .topbar { height: 65px; padding: 0 22px; }
  main { width: min(600px, calc(100% - 36px)); }
  .intro { padding: 42px 0 24px; }
  .workspace { grid-template-columns: 1fr; }
  .settings-card { padding: 20px; }
  .tip-card { margin-top: 20px; }
}
@media (max-width: 480px) {
  .topbar-right { gap: 10px; }
  .local-badge { font-size: 10px; }
  .intro p { font-size: 13px; }
  .studio-card { padding: 16px; }
  .preview { min-height: 205px; }
  .record-controls { display: grid; grid-template-columns: 1fr 1fr; }
  .button-record { grid-column: 1 / -1; }
  .record-controls .button { padding: 0 10px; }
  .result-panel { flex-wrap: wrap; }
  .result-copy { min-width: calc(100% - 45px); }
  .button-download { margin-left: 36px; }
  .page-footer { flex-wrap: wrap; text-align: center; font-size: 9px; }
}
