/* =============================================
   PRIVACY POLICY DECODER — DESIGN SYSTEM
   =============================================
   Visual identity: analytical, editorial, trustworthy.
   Color approach: deep navy base, muted teal accent,
   risk-graded color spectrum for findings.
   ============================================= */

:root {
  /* --- Base palette --- */
  --bg: #0a0e1a;
  --bg-soft: #0f1424;
  --panel: #121829;
  --panel-2: #171d31;
  --surface: #1a2038;

  /* --- Text --- */
  --text: #e8ecf4;
  --text-soft: #a3adc4;
  --text-muted: #6b7894;

  /* --- Accent (teal) --- */
  --accent: #5ec4a0;
  --accent-dim: #3a8b72;
  --accent-soft: rgba(94, 196, 160, 0.10);
  --accent-border: rgba(94, 196, 160, 0.22);

  /* --- Risk spectrum --- */
  --risk-low: #5ec4a0;
  --risk-low-bg: rgba(94, 196, 160, 0.10);
  --risk-mod: #e4b85c;
  --risk-mod-bg: rgba(228, 184, 92, 0.10);
  --risk-high: #e06060;
  --risk-high-bg: rgba(224, 96, 96, 0.10);
  --risk-unstated: #7b88a8;
  --risk-unstated-bg: rgba(123, 136, 168, 0.08);

  /* --- Grade colors --- */
  --grade-a: #4cc994;
  --grade-a-bg: rgba(76, 201, 148, 0.12);
  --grade-b: #5ec4a0;
  --grade-b-bg: rgba(94, 196, 160, 0.10);
  --grade-c: #e4b85c;
  --grade-c-bg: rgba(228, 184, 92, 0.10);
  --grade-d: #e09050;
  --grade-d-bg: rgba(224, 144, 80, 0.10);
  --grade-e: #e06060;
  --grade-e-bg: rgba(224, 96, 96, 0.10);
  --grade-f: #d44040;
  --grade-f-bg: rgba(212, 64, 64, 0.12);

  /* --- Borders --- */
  --border: rgba(255, 255, 255, 0.06);
  --border-strong: rgba(255, 255, 255, 0.10);

  /* --- Misc --- */
  --shadow: 0 16px 64px rgba(0, 0, 0, 0.30);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --content-width: 1100px;
  --mono: "JetBrains Mono", "Fira Code", "Cascadia Code", ui-monospace, monospace;

  font-family: "Inter", ui-sans-serif, system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", sans-serif;
}


/* =========================
   RESET
========================= */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(ellipse at 15% 0%,
      rgba(94, 196, 160, 0.06),
      transparent 40rem),
    radial-gradient(ellipse at 80% 5%,
      rgba(100, 140, 220, 0.04),
      transparent 30rem),
    var(--bg);

  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button,
textarea {
  font: inherit;
}

button {
  border: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
}

::selection {
  background: rgba(94, 196, 160, 0.28);
  color: var(--text);
}


/* =========================
   ACCESSIBILITY
========================= */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}


/* =========================
   APP SHELL
========================= */

.app-shell {
  width: min(calc(100% - 40px),
      var(--content-width));
  margin: 0 auto;
}


/* =========================
   HEADER
========================= */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--accent-border);
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent);
}

.brand-text {
  display: flex;
  align-items: baseline;
  gap: 5px;
  font-size: 14px;
}

.brand-text strong {
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand-text span {
  color: var(--text-muted);
  font-weight: 400;
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-badge {
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.02);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.01em;
}


/* =========================
   HERO
========================= */

.hero-section {
  padding: 72px 0 40px;
}

.eyebrow,
.section-kicker,
.panel-label {
  margin: 0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-copy h1 {
  max-width: 720px;
  margin: 14px 0 16px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.0;
  letter-spacing: -0.045em;
  font-weight: 800;
}

.hero-description {
  max-width: 640px;
  margin: 0;
  color: var(--text-soft);
  font-size: 16px;
  line-height: 1.7;
}


/* =========================
   PIPELINE / HOW IT WORKS
========================= */

.pipeline-section {
  padding: 0 0 48px;
}

.pipeline-steps {
  display: flex;
  align-items: stretch;
  gap: 0;
}

.pipeline-step {
  flex: 1;
  display: flex;
  gap: 12px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.015);
}

.pipeline-step:first-child {
  border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.pipeline-step:last-child {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.pipeline-step-number {
  color: var(--accent-dim);
  font-size: 11px;
  font-weight: 800;
  font-family: var(--mono);
  line-height: 1.7;
  opacity: 0.7;
}

.pipeline-step-content h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.pipeline-step-content p {
  margin: 4px 0 0;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.55;
}

.pipeline-connector {
  display: flex;
  align-items: center;
  padding: 0 2px;
  color: var(--text-muted);
  opacity: 0.35;
}


/* =========================
   GENERAL SECTION HELPERS
========================= */

.analyzer-section {
  padding: 32px 0 64px;
  border-top: 1px solid var(--border);
}

.results-section {
  padding: 32px 0 64px;
}

.section-heading,
.results-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section-heading h2,
.results-header h2 {
  margin: 6px 0 0;
  font-size: 26px;
  line-height: 1.1;
  letter-spacing: -0.035em;
  font-weight: 800;
}

.input-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.input-limit,
.results-subtitle {
  color: var(--text-muted);
  font-size: 12px;
}

.results-subtitle {
  margin: 4px 0 0;
  max-width: 500px;
}


/* =========================
   INPUT
========================= */

.input-card {
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: var(--shadow);
}

#policy-input {
  display: block;
  width: 100%;
  min-height: 320px;
  padding: 22px;
  resize: vertical;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 14px;
  line-height: 1.75;
}

#policy-input::placeholder {
  color: var(--text-muted);
  opacity: 0.5;
}

#policy-input:focus {
  box-shadow:
    inset 0 0 0 1px rgba(94, 196, 160, 0.15);
}

.input-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.015);
}

.input-toolbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.character-count {
  color: var(--text-muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  font-family: var(--mono);
}

.character-count[data-warning="true"] {
  color: var(--risk-mod);
}

.keyboard-hint {
  color: var(--text-muted);
  opacity: 0.4;
  font-size: 10px;
  font-family: var(--mono);
}


/* =========================
   BUTTONS
========================= */

.primary-button,
.secondary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 10px;
  padding: 0 16px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  transition:
    transform 140ms ease,
    opacity 140ms ease,
    border-color 140ms ease,
    background 140ms ease;
}

.primary-button {
  gap: 8px;
  background: var(--accent);
  color: #06130d;
}

.primary-button:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.primary-button:disabled,
.secondary-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.secondary-button {
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.025);
  color: var(--text);
}

.secondary-button:hover {
  border-color: var(--accent-border);
  background: var(--accent-soft);
}

.ghost-button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: transparent;
  color: var(--accent);
  font-size: 12px;
}

.ghost-button:hover {
  background: var(--accent-soft);
  border-color: var(--accent-border);
}

.button-spinner {
  width: 14px;
  height: 14px;
  display: none;
  border:
    2px solid rgba(6, 19, 13, 0.25);
  border-top-color: #06130d;
  border-radius: 50%;
  animation:
    spin 700ms linear infinite;
}

.primary-button.is-loading .button-spinner {
  display: block;
}

.primary-button.is-loading .button-label {
  opacity: 0.7;
}


/* =========================
   MESSAGES
========================= */

.message {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 13px;
}

.message-error {
  border: 1px solid rgba(224, 96, 96, 0.25);
  background: var(--risk-high-bg);
  color: #f0b0b0;
}

.privacy-note {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.6;
}

.privacy-note p {
  max-width: 600px;
  margin: 0;
}

.privacy-note-icon {
  color: var(--text-muted);
  flex: 0 0 auto;
  margin-top: 1px;
  opacity: 0.6;
}


/* =========================
   LOADING
========================= */

.loading-state {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 8px 0 56px;
  padding: 20px;
  border: 1px solid var(--accent-border);
  border-radius: var(--radius-md);
  background:
    linear-gradient(145deg,
      rgba(94, 196, 160, 0.06),
      rgba(94, 196, 160, 0.015));
}

.loading-ring {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border: 2.5px solid rgba(94, 196, 160, 0.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 850ms linear infinite;
}

.loading-title {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}

.loading-description {
  margin: 2px 0 0;
  color: var(--text-soft);
  font-size: 12px;
}


/* =========================
   RESULTS — REPORT CARD
========================= */

.report-card {
  display: grid;
  grid-template-columns:
    280px minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.grade-panel {
  padding: 28px;
  border-right: 1px solid var(--border);
  background:
    radial-gradient(circle at 30% 20%,
      rgba(94, 196, 160, 0.06),
      transparent 12rem),
    rgba(255, 255, 255, 0.008);
}

.grade-panel-inner {
  position: sticky;
  top: 24px;
}

.grade-badge {
  width: 96px;
  height: 96px;
  display: grid;
  place-items: center;
  margin: 16px 0 14px;
  border-radius: 22px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);
  box-shadow:
    inset 0 0 24px rgba(94, 196, 160, 0.05),
    0 8px 32px rgba(0, 0, 0, 0.15);
  transition: background 300ms ease, border-color 300ms ease, color 300ms ease;
}

#grade-letter {
  font-size: 48px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.grade-label {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.score-display {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-top: 18px;
  color: var(--text-muted);
  font-size: 11px;
  font-family: var(--mono);
}

.score-display strong {
  color: var(--text);
  font-size: 18px;
  font-family: "Inter", sans-serif;
}

.grade-reason {
  max-width: 300px;
  margin: 10px 0 0;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.6;
}


/* --- Grade color variants --- */

.grade-a {
  background: var(--grade-a-bg);
  border-color: rgba(76, 201, 148, 0.28);
  color: var(--grade-a);
}

.grade-b {
  background: var(--grade-b-bg);
  border-color: rgba(94, 196, 160, 0.28);
  color: var(--grade-b);
}

.grade-c {
  background: var(--grade-c-bg);
  border-color: rgba(228, 184, 92, 0.28);
  color: var(--grade-c);
}

.grade-d {
  background: var(--grade-d-bg);
  border-color: rgba(224, 144, 80, 0.28);
  color: var(--grade-d);
}

.grade-e {
  background: var(--grade-e-bg);
  border-color: rgba(224, 96, 96, 0.28);
  color: var(--grade-e);
}

.grade-f {
  background: var(--grade-f-bg);
  border-color: rgba(212, 64, 64, 0.30);
  color: var(--grade-f);
}


/* =========================
   BREAKDOWN PANEL
========================= */

.breakdown-panel {
  padding: 28px;
}

.panel-heading {
  margin-bottom: 16px;
}

.panel-heading h3 {
  margin: 5px 0 0;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.score-breakdown {
  display: grid;
  gap: 10px;
}

.breakdown-row {
  display: grid;
  grid-template-columns: 150px 1fr auto;
  align-items: center;
  gap: 12px;
}

.breakdown-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.breakdown-bar-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.breakdown-bar-fill {
  height: 100%;
  border-radius: inherit;
  transition: width 400ms ease;
}

.breakdown-bar-fill[data-level="low"] {
  background: var(--risk-low);
}

.breakdown-bar-fill[data-level="moderate"] {
  background: var(--risk-mod);
}

.breakdown-bar-fill[data-level="high"] {
  background: var(--risk-high);
}

.breakdown-bar-fill[data-level="unstated"] {
  background: var(--risk-unstated);
}

.breakdown-points {
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 48px;
  text-align: right;
}

.breakdown-note {
  margin: 14px 0 0;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.5;
}


/* =========================
   SUMMARY
========================= */

.summary-section {
  margin-top: 40px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.012);
}

.summary-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.summary-list li {
  position: relative;
  padding-left: 16px;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.65;
}

.summary-list li::before {
  content: "";
  position: absolute;
  width: 4px;
  height: 4px;
  top: 0.7em;
  left: 0;
  border-radius: 50%;
  background: var(--accent);
}


/* =========================
   DIMENSIONS
========================= */

.dimensions-section,
.concerns-section {
  margin-top: 48px;
}

.dimensions-grid {
  display: grid;
  gap: 10px;
}

.dimension-card {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.015);
  transition: border-color 200ms ease;
}

.dimension-card:hover {
  border-color: var(--border-strong);
}

.dimension-card[data-risk="unstated"] {
  border-style: dashed;
  border-color: rgba(123, 136, 168, 0.18);
}

.dimension-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.dimension-title-block {
  flex: 1;
  min-width: 0;
}

.dimension-name {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.dimension-assessment {
  margin: 3px 0 0;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.dimension-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.risk-pill {
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.risk-low {
  border: 1px solid rgba(94, 196, 160, 0.20);
  background: var(--risk-low-bg);
  color: var(--risk-low);
}

.risk-moderate {
  border: 1px solid rgba(228, 184, 92, 0.20);
  background: var(--risk-mod-bg);
  color: var(--risk-mod);
}

.risk-high {
  border: 1px solid rgba(224, 96, 96, 0.20);
  background: var(--risk-high-bg);
  color: var(--risk-high);
}

.risk-unstated {
  border: 1px dashed rgba(123, 136, 168, 0.25);
  background: var(--risk-unstated-bg);
  color: var(--risk-unstated);
}

.dimension-points {
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 10px;
  font-weight: 600;
  font-family: var(--mono);
  color: var(--text-muted);
  white-space: nowrap;
}

/* --- Evidence block --- */

.dimension-evidence-block {
  margin: 14px 0 0;
  padding: 12px 14px;
  border-left: 3px solid var(--border-strong);
  border-radius: 0 8px 8px 0;
  background: rgba(255, 255, 255, 0.02);
}

.dimension-card[data-risk="low"] .dimension-evidence-block {
  border-left-color: rgba(94, 196, 160, 0.35);
}

.dimension-card[data-risk="moderate"] .dimension-evidence-block {
  border-left-color: rgba(228, 184, 92, 0.35);
}

.dimension-card[data-risk="high"] .dimension-evidence-block {
  border-left-color: rgba(224, 96, 96, 0.35);
}

.dimension-card[data-risk="unstated"] .dimension-evidence-block {
  border-left-color: rgba(123, 136, 168, 0.25);
  border-left-style: dashed;
}

.evidence-label {
  margin: 0 0 4px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.evidence-text {
  margin: 0;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-soft);
}

.no-evidence-text {
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  font-style: italic;
}

/* --- Confidence --- */

.dimension-confidence {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.confidence-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-muted);
}

.confidence-dot[data-level="high"] {
  background: var(--risk-low);
}

.confidence-dot[data-level="medium"] {
  background: var(--risk-mod);
}

.confidence-dot[data-level="low"] {
  background: var(--risk-high);
}


/* =========================
   CONCERNS
========================= */

.concerns-list {
  display: grid;
  gap: 10px;
}

.concern-card {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--panel);
  transition:
    border-color 160ms ease;
}

.concern-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.concern-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.concern-marker {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: var(--risk-high-bg);
  color: var(--risk-high);
  font-size: 12px;
  font-weight: 800;
}

.concern-title {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
}

.concern-impact {
  margin: 2px 0 0;
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-muted);
}

.concern-evidence {
  margin: 10px 0 0;
  padding-left: 40px;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.65;
  font-family: var(--mono);
}


/* =========================
   DISCLAIMER
========================= */

.results-disclaimer {
  margin-top: 28px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.012);
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.6;
}

.results-disclaimer strong {
  color: var(--text-soft);
}


/* =========================
   FOOTER
========================= */

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0 36px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 11px;
}

.site-footer div {
  display: flex;
  align-items: center;
  gap: 6px;
}

.site-footer strong {
  color: var(--text-soft);
}

.site-footer p {
  margin: 0;
  font-style: italic;
  opacity: 0.7;
}

.footer-sep {
  opacity: 0.3;
}


/* =========================
   ANIMATIONS
========================= */

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}


/* =========================
   RESPONSIVE
========================= */

@media (max-width: 900px) {
  .report-card {
    grid-template-columns: 1fr;
  }

  .grade-panel {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .grade-panel-inner {
    position: static;
  }

  .pipeline-steps {
    flex-direction: column;
  }

  .pipeline-step:first-child {
    border-radius: var(--radius-md) var(--radius-md) 0 0;
  }

  .pipeline-step:last-child {
    border-radius: 0 0 var(--radius-md) var(--radius-md);
  }

  .pipeline-connector {
    justify-content: center;
    padding: 2px 0;
    transform: rotate(90deg);
  }
}

@media (max-width: 700px) {
  .app-shell {
    width: min(calc(100% - 20px),
        var(--content-width));
  }

  .site-header {
    min-height: 60px;
  }

  .header-badge {
    display: none;
  }

  .brand-text {
    flex-direction: column;
    gap: 0;
  }

  .hero-section {
    padding: 48px 0 28px;
  }

  .hero-copy h1 {
    font-size: clamp(32px, 11vw, 52px);
  }

  .hero-description {
    font-size: 14px;
  }

  .section-heading,
  .results-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .input-actions {
    flex-direction: row-reverse;
  }

  .section-heading h2,
  .results-header h2 {
    font-size: 22px;
  }

  #policy-input {
    min-height: 260px;
    padding: 16px;
    font-size: 13px;
  }

  .input-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .input-toolbar-left {
    justify-content: space-between;
  }

  .keyboard-hint {
    display: none;
  }

  .primary-button {
    width: 100%;
  }

  .breakdown-row {
    grid-template-columns: 110px 1fr auto;
    gap: 8px;
  }

  .breakdown-label {
    font-size: 11px;
  }

  .grade-panel,
  .breakdown-panel {
    padding: 20px;
  }

  .summary-section {
    padding: 18px;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-footer div {
    flex-wrap: wrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}


/* Force hidden elements to stay hidden */
[hidden] {
  display: none !important;
}