:root {
  color-scheme: light;
  --bg: #faf8f7;
  --bg-soft: #f4f0ee;
  --surface: rgba(255, 255, 255, .88);
  --surface-solid: #fff;
  --text: #252124;
  --muted: #776f73;
  --line: rgba(63, 49, 56, .11);
  --accent: #f64f63;
  --accent-dark: #df3e53;
  --accent-soft: #fff0f2;
  --success: #25a869;
  --shadow: 0 26px 80px rgba(72, 45, 53, .11);
  --shadow-small: 0 12px 35px rgba(72, 45, 53, .09);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --max: 980px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #171416;
  --bg-soft: #211c1f;
  --surface: rgba(37, 31, 34, .9);
  --surface-solid: #251f22;
  --text: #f8f3f5;
  --muted: #b8adb2;
  --line: rgba(255, 255, 255, .1);
  --accent-soft: rgba(246, 79, 99, .14);
  --shadow: 0 26px 80px rgba(0, 0, 0, .3);
  --shadow-small: 0 12px 35px rgba(0, 0, 0, .23);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "PingFang TC", "Microsoft JhengHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, textarea, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }

.ambient { position: fixed; z-index: -1; border-radius: 999px; filter: blur(2px); pointer-events: none; }
.ambient-one { width: 420px; height: 420px; top: -190px; right: -110px; background: radial-gradient(circle, rgba(246,79,99,.18), rgba(246,79,99,0) 70%); }
.ambient-two { width: 380px; height: 380px; left: -200px; top: 420px; background: radial-gradient(circle, rgba(247,170,112,.13), rgba(247,170,112,0) 72%); }

.topbar {
  width: min(calc(100% - 36px), 1160px);
  margin: 0 auto;
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text); text-decoration: none; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px; background: linear-gradient(145deg, #ff6d7d, #ee3e56); color: #fff; box-shadow: 0 9px 24px rgba(246,79,99,.25); }
.brand-mark svg { width: 21px; stroke: none; fill: currentColor; transform: translateX(1px); }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 17px; letter-spacing: .03em; }
.brand small { margin-top: 1px; color: var(--muted); font-size: 11px; }
.icon-button { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--text); cursor: pointer; backdrop-filter: blur(18px); }
.icon-button svg { width: 20px; }

.page-shell { width: min(calc(100% - 36px), var(--max)); margin: 0 auto; padding: 56px 0 72px; }
.hero { max-width: 790px; margin: 0 auto 38px; text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow span { width: 20px; height: 2px; border-radius: 2px; background: currentColor; }
.hero h1 { margin: 17px 0 16px; font-size: clamp(38px, 7vw, 66px); line-height: 1.08; letter-spacing: -.055em; }
.hero h1 em { color: var(--accent); font-style: normal; white-space: nowrap; }
.hero p { max-width: 710px; margin: 0 auto; color: var(--muted); font-size: 16px; line-height: 1.85; }

.parse-card, .result-card, .how-card, .history-section {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}
.parse-card { padding: clamp(22px, 4vw, 38px); border-radius: var(--radius-xl); }
.card-heading, .section-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.card-heading { margin-bottom: 19px; }
.step-label { margin: 0 0 5px; color: var(--accent); font-size: 10px; font-weight: 900; letter-spacing: .17em; }
h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.secure-badge, .result-status { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; border-radius: 999px; font-size: 12px; font-weight: 700; }
.secure-badge { padding: 8px 11px; color: var(--muted); background: var(--bg-soft); }
.secure-badge svg { width: 15px; }

.input-wrap { overflow: hidden; border: 1.5px solid var(--line); border-radius: 20px; background: var(--bg-soft); transition: border-color .2s, box-shadow .2s, transform .2s; }
.input-wrap:focus-within { border-color: rgba(246,79,99,.7); box-shadow: 0 0 0 4px rgba(246,79,99,.1); transform: translateY(-1px); }
textarea { display: block; width: 100%; min-height: 145px; resize: vertical; border: 0; outline: 0; padding: 20px 20px 8px; background: transparent; color: var(--text); font-size: 15px; line-height: 1.75; }
textarea::placeholder { color: color-mix(in srgb, var(--muted) 72%, transparent); }
.input-tools { display: flex; justify-content: space-between; align-items: center; padding: 4px 15px 12px 20px; color: var(--muted); font-size: 11px; }
.text-button { padding: 6px 8px; border: 0; background: transparent; color: var(--accent); font-size: 12px; font-weight: 750; cursor: pointer; }
.primary-actions { display: grid; grid-template-columns: 1fr 1.35fr; gap: 12px; margin-top: 16px; }
.button { min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; border: 1px solid transparent; border-radius: 16px; padding: 0 18px; text-decoration: none; font-weight: 800; cursor: pointer; transition: transform .16s ease, box-shadow .16s ease, background .16s ease; }
.button:hover { transform: translateY(-2px); }
.button:active { transform: translateY(0); }
.button svg { width: 20px; }
.button-primary { background: linear-gradient(135deg, #ff6677, var(--accent-dark)); color: #fff; box-shadow: 0 12px 28px rgba(246,79,99,.22); }
.button-secondary { border-color: var(--line); background: var(--surface-solid); color: var(--text); box-shadow: 0 5px 18px rgba(42,30,35,.04); }
.button-ghost { color: var(--accent); background: var(--accent-soft); }
.button-loading { display: none; align-items: center; gap: 9px; }
.button.is-loading .button-label { display: none; }
.button.is-loading .button-loading { display: inline-flex; }
.button:disabled { opacity: .72; cursor: wait; transform: none; }
.spinner { width: 17px; height: 17px; border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: spin .75s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.error-box { display: flex; gap: 12px; margin-top: 16px; padding: 14px 16px; border: 1px solid rgba(207,56,75,.18); border-radius: 15px; background: rgba(246,79,99,.08); color: #c83247; }
.error-box svg { flex: 0 0 auto; width: 21px; }
.error-box strong { font-size: 13px; }
.error-box p { margin: 3px 0 0; font-size: 12px; line-height: 1.55; }

.result-section { margin-top: 42px; }
.section-title-row { margin: 0 4px 15px; align-items: center; }
.result-status { padding: 7px 11px; color: var(--success); background: rgba(37,168,105,.09); }
.result-status span { width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 4px rgba(37,168,105,.1); }
.result-card { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(300px, .92fr); overflow: hidden; border-radius: var(--radius-xl); }

/* Format picker as standalone section, not overlaid */
.format-picker {
  grid-column: 1 / -1;
  border-top: 1px solid var(--line);
  padding: 18px 20px 20px;
}
.format-picker-header {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 14px;
  letter-spacing: .04em;
}

@media (max-width: 760px) {
  .format-picker {
    padding: 14px 16px 16px;
  }
}
.media-panel { position: relative; display: grid; place-items: center; min-height: 430px; overflow: hidden; background: #100e0f; }
.media-video { width: 100%; max-height: 680px; min-height: 430px; object-fit: contain; background: #100e0f; }
.media-placeholder { color: rgba(255,255,255,.4); }
.media-placeholder svg { width: 60px; }
.image-grid { width: 100%; height: 100%; max-height: 680px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 3px; overflow: auto; background: var(--line); }
.image-item { position: relative; min-height: 210px; overflow: hidden; background: #171416; }
.image-item img { width: 100%; height: 100%; min-height: 210px; display: block; object-fit: cover; }
.image-download { position: absolute; right: 10px; bottom: 10px; width: 38px; height: 38px; display: grid; place-items: center; border: 0; border-radius: 12px; color: #fff; background: rgba(18,14,16,.72); backdrop-filter: blur(12px); cursor: pointer; }
.image-download svg { width: 18px; }
.result-content { padding: clamp(25px, 4vw, 40px); display: flex; flex-direction: column; justify-content: center; }
.result-meta-top { display: flex; align-items: center; gap: 8px; margin-bottom: 15px; }
.media-type, .parser-label { display: inline-flex; align-items: center; min-height: 27px; padding: 0 10px; border-radius: 999px; font-size: 11px; font-weight: 800; }
.media-type { color: #fff; background: var(--accent); }
.parser-label { color: var(--muted); background: var(--bg-soft); }
.platform-label { background: linear-gradient(135deg, #7c5cff, #5f73ff); color: #fff; }
.result-content h3 { margin: 0; font-size: clamp(24px, 4vw, 34px); line-height: 1.25; letter-spacing: -.035em; }
.author-line { margin: 10px 0 0; color: var(--accent); font-size: 13px; font-weight: 750; }
.description { display: -webkit-box; margin: 16px 0 0; overflow: hidden; color: var(--muted); font-size: 14px; line-height: 1.75; -webkit-line-clamp: 5; -webkit-box-orient: vertical; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 24px 0; }
.facts div { padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg-soft); }
.facts dt { color: var(--muted); font-size: 10px; }
.facts dd { margin: 5px 0 0; font-size: 13px; font-weight: 800; overflow-wrap: anywhere; }
.result-actions { display: flex; flex-direction: column; gap: 8px; }
.result-actions-primary { display: grid; grid-template-columns: 1.35fr 1fr; gap: 9px; }
.result-actions-secondary { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.result-actions .button-ghost { min-height: 43px; }

/* YouTube vd6s-style format picker */
.yt-section {
  margin-bottom: 18px;
}
.yt-section:last-child {
  margin-bottom: 0;
}
.yt-section-title {
  font-size: 14px;
  font-weight: 800;
  color: var(--muted);
  padding: 0 4px 10px;
  letter-spacing: .05em;
  border-bottom: 1px solid var(--line);
  margin-bottom: 8px;
}
.yt-format-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  transition: background .12s;
}
.yt-format-row:last-child {
  border-bottom: none;
}
.yt-format-row:hover {
  background: var(--bg-soft);
}
.yt-format-info {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.yt-format-label {
  font-size: 14px;
  font-weight: 750;
  color: var(--text);
  white-space: nowrap;
}
.yt-format-size {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.yt-format-codec {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--bg-soft);
  color: var(--muted);
  font-weight: 600;
  letter-spacing: .02em;
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
}
.yt-format-dl {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: background .12s, transform .1s;
  border: none;
}
.yt-format-dl:hover {
  background: var(--accent-dark);
  transform: scale(1.03);
}
.yt-format-dl:active {
  transform: scale(.97);
}

.yt-overlay-msg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,.7);
  font-size: 14px;
  font-weight: 700;
  pointer-events: none;
  z-index: 1;
}
.yt-overlay-msg svg {
  width: 28px;
  fill: none;
  stroke: currentColor;
}

.history-section { margin-top: 42px; padding: 24px; border-radius: var(--radius-lg); }
.section-title-row.compact { margin: 0 0 14px; }
.history-list { display: grid; gap: 8px; }
.history-item { display: grid; grid-template-columns: 48px minmax(0,1fr) auto; align-items: center; gap: 12px; width: 100%; padding: 10px; border: 1px solid var(--line); border-radius: 15px; background: var(--bg-soft); color: var(--text); text-align: left; cursor: pointer; }
.history-thumb { width: 48px; height: 48px; display: grid; place-items: center; overflow: hidden; border-radius: 12px; background: var(--surface-solid); color: var(--accent); }
.history-thumb img, .history-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.history-thumb svg { width: 20px; }
.history-info { min-width: 0; }
.history-info strong, .history-info span { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.history-info strong { font-size: 13px; }
.history-info span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.history-arrow { width: 17px; color: var(--muted); }

.how-card { display: flex; gap: 18px; margin-top: 42px; padding: 24px; border-radius: var(--radius-lg); box-shadow: var(--shadow-small); }
.how-icon { flex: 0 0 auto; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 15px; background: var(--accent-soft); color: var(--accent); }
.how-icon svg { width: 23px; }
.how-card h2 { font-size: 17px; }
.how-card p { margin: 7px 0 0; color: var(--muted); font-size: 13px; line-height: 1.7; }

footer { width: min(calc(100% - 36px), var(--max)); margin: 0 auto; padding: 0 0 38px; color: var(--muted); text-align: center; font-size: 11px; line-height: 1.7; }
footer p { margin: 4px 0; }
.version-info { font-size: 10px; opacity: 0.6; }
.toast { position: fixed; z-index: 50; left: 50%; bottom: 26px; transform: translate(-50%, 20px); min-width: 160px; max-width: calc(100% - 40px); padding: 12px 17px; border-radius: 13px; background: rgba(31,26,28,.92); color: #fff; box-shadow: 0 16px 44px rgba(0,0,0,.22); font-size: 13px; text-align: center; opacity: 0; pointer-events: none; transition: opacity .22s, transform .22s; backdrop-filter: blur(12px); }
.toast { position: fixed; z-index: 50; left: 50%; bottom: 26px; transform: translate(-50%, 20px); min-width: 160px; max-width: calc(100% - 40px); padding: 12px 17px; border-radius: 13px; background: rgba(31,26,28,.92); color: #fff; box-shadow: 0 16px 44px rgba(0,0,0,.22); font-size: 13px; text-align: center; opacity: 0; pointer-events: none; transition: opacity .22s, transform .22s; backdrop-filter: blur(12px); }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.is-hidden { display: none !important; }

@media (max-width: 760px) {
  .page-shell { padding-top: 34px; }
  .hero { margin-bottom: 28px; }
  .hero h1 em { white-space: normal; }
  .secure-badge { display: none; }
  .primary-actions { grid-template-columns: 1fr; }
  .result-card { grid-template-columns: 1fr; }
  .media-panel, .media-video { min-height: 330px; }
  .result-actions-primary { grid-template-columns: 1fr; }
  .result-actions-secondary { grid-template-columns: 1fr; }
}

@media (max-width: 470px) {
  .topbar { min-height: 72px; }
  .page-shell { width: min(calc(100% - 24px), var(--max)); }
  .hero h1 { font-size: 38px; }
  .hero p { font-size: 14px; }
  .parse-card { padding: 20px; border-radius: 24px; }
  .facts { grid-template-columns: 1fr 1fr; }
  .facts div:last-child { grid-column: 1 / -1; }
  .image-grid { grid-template-columns: 1fr; }
  .image-item { min-height: 280px; }
  .how-card { align-items: flex-start; }
}

.analysis-section { margin-top: 42px; }
.analysis-status { display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: 999px; color: var(--accent); background: var(--accent-soft); font-size: 12px; font-weight: 800; }
.analysis-status span { width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 4px rgba(246,79,99,.1); }
.analysis-status.is-done { color: var(--success); background: rgba(37,168,105,.09); }
.analysis-card { padding: clamp(22px, 4vw, 38px); border: 1px solid var(--line); border-radius: var(--radius-xl); background: var(--surface); box-shadow: var(--shadow); backdrop-filter: blur(22px); }
.analysis-loading { min-height: 170px; display: flex; align-items: center; justify-content: center; gap: 15px; color: var(--muted); text-align: left; }
.analysis-loading strong { display: block; color: var(--text); font-size: 17px; }
.analysis-loading p { margin: 5px 0 0; font-size: 12px; line-height: 1.6; }
.analysis-spinner { width: 30px; height: 30px; flex: 0 0 auto; border: 3px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; }
.analysis-error { padding: 20px; border: 1px solid rgba(207,56,75,.18); border-radius: 16px; background: rgba(246,79,99,.08); color: #c83247; }
.analysis-error p { margin: 7px 0 8px; color: inherit; line-height: 1.65; }
.analysis-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.analysis-mode { display: inline-flex; min-height: 28px; align-items: center; padding: 0 11px; border-radius: 999px; color: #fff; background: linear-gradient(135deg, #7c5cff, #5f73ff); font-size: 11px; font-weight: 800; }
.analysis-warning { color: #b66a12; font-size: 11px; line-height: 1.45; }
.analysis-summary { padding: 20px; border-radius: 18px; background: linear-gradient(135deg, var(--accent-soft), var(--bg-soft)); }
.analysis-kicker { margin: 0 0 6px; color: var(--accent); font-size: 10px; font-weight: 900; letter-spacing: .12em; }
.analysis-summary h3 { margin: 0; font-size: clamp(20px, 3vw, 28px); line-height: 1.45; letter-spacing: -.025em; }
.analysis-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.analysis-grid > div { padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--bg-soft); }
.analysis-grid .analysis-wide { grid-column: 1 / -1; }
.analysis-grid span { color: var(--accent); font-size: 10px; font-weight: 900; letter-spacing: .08em; }
.analysis-grid p { margin: 7px 0 0; font-size: 13px; line-height: 1.7; }
.analysis-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
.analysis-columns > div { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface-solid); }
.analysis-columns h4, .optimized-heading h4 { margin: 0; font-size: 14px; }
.analysis-columns ul { margin: 12px 0 0; padding-left: 20px; color: var(--muted); font-size: 13px; line-height: 1.8; }
.keyword-row { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; }
.keyword-row span { padding: 7px 10px; border-radius: 999px; color: var(--accent); background: var(--accent-soft); font-size: 11px; font-weight: 750; }
.optimized-box { margin-top: 16px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: var(--bg-soft); }
.optimized-heading { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 0; }
.optimized-box pre { margin: 0; padding: 14px 16px 18px; color: var(--text); font: inherit; font-size: 13px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.transcript-box { margin-top: 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface-solid); }
.transcript-box summary { cursor: pointer; color: var(--accent); font-size: 13px; font-weight: 800; }
.transcript-box p { margin: 10px 0 0; color: var(--muted); font-size: 11px; }
.transcript-box div { max-height: 260px; overflow: auto; margin-top: 10px; padding: 12px; border-radius: 12px; background: var(--bg-soft); color: var(--muted); font-size: 12px; line-height: 1.8; white-space: pre-wrap; }
.analysis-copy-all { width: 100%; margin-top: 14px; }

@media (max-width: 760px) {
  .analysis-grid, .analysis-columns { grid-template-columns: 1fr; }
  .analysis-grid .analysis-wide { grid-column: auto; }
}

.ai-guard {
  display: grid;
  gap: 12px;
  padding: 16px;
  margin-bottom: 18px;
  border: 1px solid var(--line, rgba(255,255,255,.1));
  border-radius: 18px;
  background: color-mix(in srgb, var(--card-bg, #fff) 78%, transparent);
}

.ai-guard-copy p {
  margin: 6px 0 0;
}

.ai-guard-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.ai-guard-input {
  flex: 1 1 260px;
}

.ai-guard-status {
  margin: 0;
  font-size: .94rem;
  color: var(--text-soft, #666);
}

.ai-guard-status.is-ok {
  color: #0d8a57;
}

.ai-guard-status.is-warn {
  color: #b25a00;
}


/* v0.4.4 compact first-screen layout */
.topbar {
  min-height: 66px;
}

.brand {
  gap: 9px;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 12px;
}

.brand-mark svg {
  width: 18px;
}

.brand strong {
  font-size: 15px;
}

.brand small {
  font-size: 10px;
}

.icon-button {
  width: 36px;
  height: 36px;
  border-radius: 12px;
}

.icon-button svg {
  width: 17px;
}

.page-shell {
  padding-top: 18px;
}

.hero {
  max-width: 720px;
  margin-bottom: 16px;
}

.eyebrow {
  gap: 6px;
  font-size: 10px;
  letter-spacing: .11em;
}

.eyebrow span {
  width: 15px;
}

.hero h1 {
  margin: 8px 0 8px;
  font-size: clamp(29px, 5.4vw, 46px);
  line-height: 1.1;
  letter-spacing: -.045em;
}

.hero p {
  max-width: 650px;
  font-size: 13px;
  line-height: 1.55;
}

.parse-card {
  padding: clamp(16px, 2.6vw, 24px);
  border-radius: 22px;
}

.card-heading {
  margin-bottom: 12px;
}

.step-label {
  margin-bottom: 3px;
  font-size: 9px;
}

h2 {
  font-size: 19px;
}

.secure-badge {
  padding: 6px 9px;
  font-size: 10px;
}

.input-wrap {
  border-radius: 16px;
}

textarea {
  min-height: 92px;
  padding: 14px 16px 5px;
  font-size: 14px;
  line-height: 1.55;
}

.input-tools {
  padding: 2px 12px 8px 16px;
  font-size: 10px;
}

.primary-actions {
  gap: 9px;
  margin-top: 10px;
}

.button {
  min-height: 44px;
  border-radius: 13px;
  padding: 0 14px;
  font-size: 14px;
}

.button svg {
  width: 18px;
}

.error-box {
  margin-top: 10px;
}

@media (max-width: 760px) {
  .page-shell {
    padding-top: 12px;
  }

  .hero {
    margin-bottom: 12px;
  }

  .hero h1 {
    font-size: 31px;
  }

  .hero p {
    font-size: 12.5px;
    line-height: 1.45;
  }

  .parse-card {
    padding: 16px;
  }

  textarea {
    min-height: 84px;
  }

  .primary-actions {
    grid-template-columns: 1fr 1.18fr;
  }
}

@media (max-width: 470px) {
  .topbar {
    min-height: 58px;
  }

  .page-shell {
    width: min(calc(100% - 20px), var(--max));
    padding-top: 8px;
  }

  .brand small {
    display: none;
  }

  .hero {
    margin-bottom: 10px;
  }

  .eyebrow {
    font-size: 9px;
  }

  .hero h1 {
    margin: 6px 0;
    font-size: 27px;
    line-height: 1.12;
  }

  .hero p {
    font-size: 12px;
    line-height: 1.4;
  }

  .parse-card {
    padding: 14px;
    border-radius: 18px;
  }

  .card-heading {
    margin-bottom: 9px;
  }

  h2 {
    font-size: 17px;
  }

  textarea {
    min-height: 78px;
    padding: 12px 13px 4px;
    font-size: 13px;
  }

  .input-tools {
    padding: 1px 10px 7px 13px;
  }

  .primary-actions {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 8px;
  }

  .button {
    min-height: 42px;
    padding: 0 10px;
    font-size: 13px;
  }
}
