@property --score {
  syntax: '<percentage>';
  inherits: false;
  initial-value: 0%;
}

:root {
  --ink: #172026;
  --muted: #65727e;
  --line: #d8e0e7;
  --paper: #ffffff;
  --wash: #f3f6f8;
  --aqua: #0f9f9a;
  --navy: #1d3557;
  --coral: #d95d39;
  --amber: #c58b00;
  --green: #2f855a;
  --red: #c2412d;
  --shadow: 0 14px 40px rgba(23, 32, 38, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(15, 159, 154, 0.08) 1px, transparent 1px),
    linear-gradient(rgba(29, 53, 87, 0.07) 1px, transparent 1px),
    var(--wash);
  background-size: 36px 36px;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 14px;
}

.top-nav a,
.top-nav button {
  min-height: 38px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--navy);
  background: var(--paper);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
}

.top-nav a[aria-current="page"] {
  color: #ffffff;
  background: var(--navy);
  border-color: var(--navy);
}

.top-nav form {
  margin: 0;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.hero-band,
.landing-section {
  margin-bottom: 22px;
}

.hero-band {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 18px;
  align-items: stretch;
}

.hero-copy,
.hero-panel,
.cta-band {
  padding: 30px;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-copy,
.hero-panel {
  position: relative;
  overflow: hidden;
}

.hero-copy {
  color: #ffffff;
  background:
    radial-gradient(circle at top right, rgba(15, 159, 154, 0.28), transparent 34%),
    linear-gradient(135deg, #102a43 0%, #183b60 56%, #1d3557 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-panel {
  background: linear-gradient(180deg, #ffffff 0%, #f8fbfc 100%);
  border: 1px solid var(--line);
}

.hero-copy h1 {
  max-width: 12ch;
  color: #ffffff;
  font-size: clamp(2.4rem, 4vw, 4.6rem);
  line-height: 0.95;
}

.hero-copy .eyebrow {
  color: #98e8e2;
}

.hero-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.hero-chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 800;
}

.hero-chip.muted {
  color: #b7d8eb;
}

.hero-proof-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 10px;
}

.hero-proof {
  min-height: 84px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.hero-proof span {
  display: block;
  margin-bottom: 7px;
  color: #9fd5e4;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-proof strong {
  display: block;
  color: #ffffff;
  font-size: 0.98rem;
  line-height: 1.4;
}

.hero-lead {
  margin: 14px 0 18px;
  color: #d7e6ef;
  font-size: 1.06rem;
  line-height: 1.7;
  max-width: 720px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.hero-stat-grid,
.feature-grid,
.benefit-grid,
.pricing-grid {
  display: grid;
  gap: 14px;
}

.hero-stat-grid,
.benefit-grid {
  grid-template-columns: 1fr 1fr;
}

.hero-mockup {
  display: grid;
  gap: 14px;
}

.hero-mockup-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.hero-mockup-header strong {
  font-size: 1rem;
  color: var(--navy);
}

.mockup-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #e8f6f5;
  color: var(--aqua);
  font-size: 0.78rem;
  font-weight: 900;
}

.hero-score-card {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.hero-score-number {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--green));
  font-size: 2rem;
  font-weight: 900;
}

.hero-score-card span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-score-card strong {
  display: block;
  color: var(--ink);
  font-size: 1.05rem;
}

.hero-mini-list {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.hero-mini-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.hero-mini-item span {
  width: 12px;
  height: 12px;
  margin-top: 4px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--aqua), var(--navy));
}

.hero-mini-item p {
  margin-bottom: 0;
  color: #344653;
  line-height: 1.5;
}

.feature-grid,
.pricing-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

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

.section-heading h2 {
  margin-bottom: 10px;
  font-size: clamp(1.6rem, 2.6vw, 2.5rem);
  line-height: 1.1;
}

.section-heading p {
  max-width: 820px;
  color: var(--muted);
  line-height: 1.65;
}

.feature-card,
.benefit-card,
.pricing-card {
  height: 100%;
}

.feature-card h3,
.benefit-card h3,
.pricing-card h3 {
  margin-bottom: 8px;
  font-size: 1.2rem;
}

.feature-card p,
.benefit-card p,
.pricing-card p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.6;
}

.pricing-card {
  display: grid;
  gap: 14px;
  align-content: start;
  padding-top: 22px;
}

.pricing-subtitle {
  margin-top: -6px;
}

.plan-pill {
  display: inline-flex;
  width: fit-content;
  min-height: 28px;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: #eef3f6;
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.plan-pill.featured {
  color: #ffffff;
  background: var(--aqua);
}

.pricing-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
  color: #344653;
  line-height: 1.55;
}

.featured-plan {
  border-color: rgba(15, 159, 154, 0.36);
  box-shadow: 0 12px 28px rgba(15, 159, 154, 0.12);
  transform: translateY(-6px);
}

.cta-band {
  text-align: center;
}

.cta-band .section-heading p {
  margin-left: auto;
  margin-right: auto;
}

.auth-panel {
  width: min(520px, 100%);
}

.auth-input {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid #bdc9d4;
  border-radius: 6px;
  color: var(--ink);
  background: #fbfdff;
}

.auth-switch {
  margin-bottom: 0;
  color: var(--muted);
}

.auth-switch a {
  color: var(--navy);
  font-weight: 900;
}

.audit-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  padding: 24px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.brand-row {
  display: flex;
  gap: 14px;
  align-items: center;
}

.brand-mark {
  width: 54px;
  height: 54px;
  border-radius: 8px;
  object-fit: contain;
  background: #ffffff;
  border: 1px solid var(--line);
  padding: 4px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--aqua);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(2rem, 3vw, 3.6rem);
  line-height: 1;
  letter-spacing: 0;
}

.url-form {
  display: grid;
  gap: 8px;
}

.url-form label {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 10px;
}

.input-row input {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid #bdc9d4;
  border-radius: 6px;
  color: var(--ink);
  background: #fbfdff;
}

.input-row input:focus,
.email-box textarea:focus {
  outline: 3px solid rgba(15, 159, 154, 0.18);
  border-color: var(--aqua);
}

.input-row button,
.copy-button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 6px;
  color: #ffffff;
  background: var(--navy);
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.input-row button:hover,
.copy-button:hover {
  background: #1a3f5f;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(29, 53, 87, 0.25);
}

.input-row button:active,
.copy-button:active {
  transform: translateY(0);
}

.input-row button:focus-visible,
.copy-button:focus-visible {
  outline: 3px solid rgba(15, 159, 154, 0.4);
  outline-offset: 2px;
}

.copy-button.secondary:hover {
  background: #d5e3e6;
  color: #102a43;
}

.input-row button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.criteria-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.criteria-strip span {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfc;
  color: #41505c;
  font-size: 0.84rem;
  font-weight: 800;
}

.usage-banner {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.usage-item {
  min-height: 76px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfdff;
}

.usage-item span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.usage-item strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.35;
}

.results {
  margin-top: 18px;
  display: grid;
  gap: 16px;
}

.empty-state {
  min-height: 360px;
  align-content: center;
  justify-items: center;
  padding: 44px 20px;
  text-align: center;
  background: rgba(255, 255, 255, 0.78);
  border: 1px dashed #b7c6d3;
  border-radius: 8px;
}

.empty-state h2 {
  margin-bottom: 8px;
  max-width: 560px;
  font-size: 1.4rem;
}

.empty-state p {
  max-width: 620px;
  color: var(--muted);
  line-height: 1.55;
}

.empty-visual {
  width: 160px;
  height: 86px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 20px;
}

.empty-visual div {
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #ffffff;
}

.empty-visual div:nth-child(1) {
  border-top: 6px solid var(--aqua);
}

.empty-visual div:nth-child(2) {
  border-top: 6px solid var(--amber);
}

.empty-visual div:nth-child(3) {
  border-top: 6px solid var(--coral);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.results:not(.empty-state) > * {
  animation: fadeInUp 0.5s ease-out both;
}

.results > *:nth-child(2) { animation-delay: 0.08s; }
.results > *:nth-child(3) { animation-delay: 0.16s; }
.results > *:nth-child(4) { animation-delay: 0.24s; }

@keyframes shimmer {
  0%, 100% { opacity: 0.55; }
  50% { opacity: 1; }
}

.status-card.loading {
  animation: shimmer 1.8s ease-in-out infinite;
}

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

.loading-spinner {
  display: inline-block;
  animation: spin 1.2s linear infinite;
  font-size: 2rem;
}

.status-card,
.category-card,
.email-box,
.summary-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(23, 32, 38, 0.06);
}

.status-card {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  padding: 20px;
}

.status-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
  gap: 18px;
  align-items: center;
}

.score-ring {
  width: 132px;
  height: 132px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--aqua) var(--score), #e7edf2 0);
  transition: --score 1s ease-out;
}

.score-ring span {
  width: 94px;
  height: 94px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #ffffff;
  color: var(--navy);
  font-size: 2rem;
  font-weight: 900;
}

.status-card h2 {
  margin-bottom: 8px;
  font-size: 1.45rem;
}

.status-card p {
  margin-bottom: 6px;
  color: var(--muted);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.authority-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}

.authority-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  margin-bottom: 10px;
}

.authority-head span {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
}

.authority-head strong {
  color: var(--navy);
  font-size: 1.2rem;
  font-weight: 900;
}

.authority-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: #dbe7f5;
  overflow: hidden;
  margin-bottom: 10px;
}

.authority-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--aqua), #1f7a8c);
}

.authority-card p {
  margin: 0;
  font-size: 0.85rem;
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.category-card {
  min-height: 280px;
  padding: 18px;
}

.category-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.category-header h3 {
  margin-bottom: 4px;
  font-size: 1.05rem;
}

.category-header p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.42;
}

.category-metrics {
  display: flex;
  gap: 8px;
  align-items: stretch;
  flex-shrink: 0;
}

.flaw-count {
  display: grid;
  place-items: center;
  min-width: 56px;
  padding: 6px 8px;
  border-radius: 6px;
  background: #eef3f6;
  color: var(--navy);
  text-align: center;
  line-height: 1.1;
}

.flaw-count strong {
  font-size: 1.4rem;
  font-weight: 900;
}

.flaw-count span {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.mini-score {
  display: grid;
  place-items: center;
  min-width: 58px;
  padding: 8px 6px;
  border-radius: 6px;
  color: #ffffff;
  background: var(--navy);
  text-align: center;
  font-size: 1.25rem;
  font-weight: 900;
  line-height: 1;
}

.mini-score small {
  font-size: 0.62rem;
  font-weight: 800;
  opacity: 0.78;
}

.mini-score.good {
  background: var(--green);
}

.mini-score.warn {
  background: var(--amber);
}

.mini-score.bad {
  background: var(--red);
}

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

.finding {
  padding: 12px;
  border: 1px solid #e2e8ef;
  border-left-width: 5px;
  border-radius: 6px;
  background: #fbfdff;
}

.finding.high {
  border-left-color: var(--red);
}

.finding.medium {
  border-left-color: var(--amber);
}

.finding.low {
  border-left-color: var(--aqua);
}

.finding-title {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
  font-weight: 900;
}

.severity {
  height: 24px;
  padding: 4px 7px;
  border-radius: 5px;
  background: #eef3f6;
  color: #475766;
  font-size: 0.72rem;
  line-height: 16px;
  text-transform: uppercase;
  white-space: nowrap;
}

.finding p {
  margin-bottom: 7px;
  color: #344653;
  font-size: 0.9rem;
  line-height: 1.45;
}

.finding p:last-child {
  margin-bottom: 0;
}

.summary-card {
  padding: 18px;
}

.dashboard-grid {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.data-table th,
.data-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 0.9rem;
}

.data-table th {
  color: var(--muted);
  font-size: 0.76rem;
  text-transform: uppercase;
}

.data-table a {
  color: var(--navy);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 900;
}

.pill.success {
  color: #1f6b48;
  background: #edf8f2;
}

.pill.warn {
  color: #7a5600;
  background: #fff4d6;
}

.pill.bad {
  color: #9f2d1f;
  background: #fff1ee;
}

.pill.muted {
  color: var(--muted);
  background: #eef3f6;
}

.muted-copy {
  color: var(--muted);
  margin-bottom: 0;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.summary-item {
  min-height: 74px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfdff;
}

.summary-item span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.summary-item strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  overflow-wrap: anywhere;
}

.email-box {
  padding: 18px;
}

.email-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.email-toolbar h3 {
  margin-bottom: 5px;
}

.email-toolbar p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.email-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.copy-button {
  min-width: 120px;
  padding: 0 14px;
}

.copy-button.secondary {
  color: var(--navy);
  background: #e8f1f3;
}

.email-preview-wrap {
  height: min(680px, 72vh);
  overflow: hidden;
  border: 1px solid #bdc9d4;
  border-radius: 8px;
  background: #eef3f6;
}

.email-preview {
  width: 100%;
  height: 100%;
  border: 0;
  background: #eef3f6;
}

.plain-email {
  margin-top: 12px;
}

.plain-email summary {
  cursor: pointer;
  color: var(--navy);
  font-weight: 800;
}

.send-email-form {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}

.send-email-form label {
  color: var(--ink);
  font-weight: 900;
}

.send-email-form p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.send-email-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 10px;
}

.send-email-row input {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid #bdc9d4;
  border-radius: 6px;
  color: var(--ink);
  background: #ffffff;
}

.send-email-row input:focus {
  outline: 3px solid rgba(15, 159, 154, 0.18);
  border-color: var(--aqua);
}

.send-status {
  padding: 11px 12px;
  border-radius: 6px;
  font-size: 0.9rem;
  line-height: 1.45;
}

.send-status.info {
  color: #1d3557;
  background: #eef5fb;
  border: 1px solid #c7dceb;
}

.send-status.success {
  color: #1f6b48;
  background: #edf8f2;
  border: 1px solid #bfe5cf;
}

.send-status.error {
  color: #9f2d1f;
  background: #fff1ee;
  border: 1px solid #f0c0b6;
}

.email-box textarea {
  width: 100%;
  min-height: 310px;
  margin-top: 10px;
  resize: vertical;
  padding: 14px;
  border: 1px solid #bdc9d4;
  border-radius: 6px;
  color: #24313a;
  background: #fbfdff;
  line-height: 1.55;
}

.notice {
  padding: 14px 16px;
  border: 1px solid #f1c9bd;
  border-left: 5px solid var(--coral);
  border-radius: 8px;
  background: #fff7f4;
}

.notice strong {
  display: block;
  margin-bottom: 4px;
}

@media (max-width: 900px) {
  .score-grid,
  .summary-grid,
  .feature-grid,
  .pricing-grid,
  .usage-banner {
    grid-template-columns: 1fr 1fr;
  }

  .hero-band {
    grid-template-columns: 1fr;
  }

  .hero-proof-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding-top: 10px;
  }

  .top-nav {
    justify-content: stretch;
  }

  .top-nav a,
  .top-nav form,
  .top-nav button {
    flex: 1;
  }

  .audit-panel,
  .status-card,
  .category-card,
  .email-box,
  .summary-card {
    padding: 14px;
  }

  .input-row,
  .send-email-row,
  .status-card,
  .status-main,
  .score-grid,
  .summary-grid,
  .hero-stat-grid,
  .feature-grid,
  .benefit-grid,
  .pricing-grid,
  .usage-banner {
    grid-template-columns: 1fr;
  }

  .hero-score-card {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .hero-score-number {
    width: 72px;
    height: 72px;
    font-size: 1.7rem;
  }

  .featured-plan {
    transform: none;
  }

  .score-ring {
    width: 112px;
    height: 112px;
  }

  .score-ring span {
    width: 80px;
    height: 80px;
    font-size: 1.6rem;
  }

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

  .email-actions {
    justify-content: stretch;
  }

  .copy-button {
    width: 100%;
  }

  .email-preview-wrap {
    height: 620px;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e1e7ed;
    --muted: #8c99a6;
    --line: #283542;
    --paper: #151e27;
    --wash: #0c1219;
    --navy: #4da3d4;
    --shadow: 0 14px 40px rgba(0, 0, 0, 0.4);
  }

  body {
    background:
      linear-gradient(90deg, rgba(15, 159, 154, 0.04) 1px, transparent 1px),
      linear-gradient(rgba(29, 53, 87, 0.04) 1px, transparent 1px),
      var(--wash);
    background-size: 36px 36px;
  }

  .brand-mark { background: #0a1622; }

  .input-row input,
  .send-email-row input {
    background: #1a2533;
    border-color: #344556;
    color: var(--ink);
  }

  .input-row button,
  .copy-button {
    background: #2a6496;
  }

  .input-row button:hover,
  .copy-button:hover {
    background: #3478ad;
    box-shadow: 0 4px 12px rgba(42, 100, 150, 0.3);
  }

  .copy-button.secondary {
    background: #1a2533;
    color: #8cbde6;
  }

  .copy-button.secondary:hover {
    background: #223344;
    color: #a8d0f0;
  }

  .criteria-strip span {
    background: #1a2533;
    border-color: var(--line);
    color: var(--muted);
  }

  .empty-state {
    background: rgba(21, 30, 39, 0.85);
    border-color: var(--line);
  }

  .empty-visual div {
    background: #1a2533;
    border-color: var(--line);
  }

  .finding {
    background: #1a2533;
    border-color: #283542;
  }

  .severity {
    background: #1a2533;
    color: var(--muted);
  }

  .finding p { color: #a0b0c0; }

  .summary-item {
    background: #1a2533;
    border-color: var(--line);
  }

  .flaw-count {
    background: #1a2533;
    color: #8cbde6;
  }

  .score-ring {
    background: conic-gradient(var(--aqua) var(--score), #1a2533 0);
  }

  .score-ring span {
    background: var(--paper);
    color: #4da3d4;
  }

  .email-box textarea {
    background: #1a2533;
    border-color: #344556;
    color: var(--ink);
  }

  .email-preview-wrap {
    background: #1a2533;
    border-color: #344556;
  }

  .email-preview { background: #1a2533; }

  .send-email-form {
    background: #1a2533;
    border-color: var(--line);
  }

  .send-status.info {
    background: #101c28;
    border-color: #1a3550;
    color: #68a8d8;
  }

  .send-status.success {
    background: #0c1e14;
    border-color: #184530;
    color: #58b880;
  }

  .send-status.error {
    background: #1e0e0e;
    border-color: #451a1a;
    color: #d87070;
  }

  .notice {
    background: #1e1410;
    border-color: #45261c;
  }
}
