:root {
  color-scheme: light;
  --bg: #f6efe6;
  --bg-deep: #f1e0cd;
  --card: rgba(255, 252, 247, 0.84);
  --card-strong: rgba(255, 250, 243, 0.94);
  --ink: #1c1c1a;
  --muted: #6d665e;
  --line: rgba(28, 28, 26, 0.1);
  --accent: #0c7a6a;
  --accent-dark: #095c4f;
  --accent-soft: rgba(12, 122, 106, 0.12);
  --warm: #f28f3b;
  --warm-soft: rgba(242, 143, 59, 0.18);
  --danger: #b24528;
  --shadow: 0 28px 80px rgba(61, 43, 20, 0.12);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(242, 143, 59, 0.2), transparent 30%),
    linear-gradient(180deg, #fbf5ee 0%, var(--bg) 58%, #f0e4d6 100%);
  color: var(--ink);
  font-family: "Space Grotesk", sans-serif;
}

.page-shell {
  position: relative;
  overflow-x: hidden;
}

.ambient {
  position: fixed;
  z-index: 0;
  filter: blur(12px);
  border-radius: 999px;
  opacity: 0.8;
}

.ambient-left {
  top: 6rem;
  left: -5rem;
  width: 18rem;
  height: 18rem;
  background: rgba(242, 143, 59, 0.22);
}

.ambient-right {
  right: -3rem;
  bottom: 8rem;
  width: 16rem;
  height: 16rem;
  background: rgba(12, 122, 106, 0.18);
}

.layout {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0 4rem;
}

.hero {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: 1.5rem;
  align-items: stretch;
  min-height: calc(100vh - 6rem);
  padding: 1rem 0 2rem;
}

.hero-copy,
.tool-card,
.proof-card,
.result-card {
  backdrop-filter: blur(16px);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.hero-copy {
  border-radius: var(--radius-xl);
  padding: clamp(1.5rem, 4vw, 3rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.eyebrow-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.eyebrow,
.panel-label,
.status-chip,
.dropzone-badge {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  font-weight: 700;
}

.eyebrow {
  color: var(--accent-dark);
}

.status-chip {
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: var(--warm-soft);
  color: #8c4b16;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Fraunces", serif;
  font-weight: 700;
  line-height: 0.98;
}

h1 {
  margin-top: 1rem;
  font-size: clamp(3rem, 7vw, 5.3rem);
  max-width: 11ch;
}

.lede {
  margin: 1.25rem 0 0;
  max-width: 38rem;
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--muted);
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.stat-card {
  padding: 1.15rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(28, 28, 26, 0.08);
  background: rgba(255, 255, 255, 0.44);
}

.stat-card strong,
.proof-card strong,
.result-stat strong,
.result-meta strong {
  display: block;
  margin-top: 0.5rem;
  font-size: 1.25rem;
}

.stat-kicker,
.proof-card span,
.result-stat span,
.result-meta span {
  color: var(--muted);
  font-size: 0.88rem;
}

.stat-card p,
.tool-card p,
.proof-card p {
  margin: 0.65rem 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.tool-card {
  border-radius: var(--radius-xl);
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.tool-header,
.tool-footer,
.result-main {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}

.panel-label {
  margin: 0 0 0.35rem;
  color: var(--accent-dark);
}

.plan-pill {
  min-width: 104px;
  padding: 0.85rem 1rem;
  border-radius: 18px;
  background: linear-gradient(140deg, #0f8b78, #0c6658);
  color: #fff;
  text-align: right;
}

.plan-pill span {
  display: block;
  font-size: 0.78rem;
  opacity: 0.8;
}

.plan-pill strong {
  font-size: 1.1rem;
}

.compress-form {
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
}

.dropzone {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.6rem;
  min-height: 240px;
  padding: 1.4rem;
  border-radius: var(--radius-lg);
  border: 1.5px dashed rgba(12, 122, 106, 0.28);
  background:
    linear-gradient(180deg, rgba(12, 122, 106, 0.08), rgba(12, 122, 106, 0.02)),
    rgba(255, 255, 255, 0.65);
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.dropzone:hover,
.dropzone.drag-active {
  transform: translateY(-2px);
  border-color: rgba(12, 122, 106, 0.6);
  background:
    linear-gradient(180deg, rgba(12, 122, 106, 0.14), rgba(12, 122, 106, 0.04)),
    rgba(255, 255, 255, 0.75);
}

.dropzone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.dropzone strong {
  font-size: 1.5rem;
}

.dropzone span {
  color: var(--muted);
}

.dropzone-badge {
  color: var(--accent-dark);
}

.selected-file,
.form-note {
  color: var(--muted);
  font-size: 0.95rem;
}

.progress-wrap {
  padding: 0.95rem 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(28, 28, 26, 0.06);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.7rem;
  font-size: 0.9rem;
}

.progress-track,
.bar-track {
  overflow: hidden;
  width: 100%;
  border-radius: 999px;
  background: rgba(28, 28, 26, 0.08);
}

.progress-track {
  height: 10px;
}

.progress-fill,
.bar-fill {
  height: 100%;
  border-radius: inherit;
}

.progress-fill,
.compressed-fill {
  background: linear-gradient(90deg, #0c7a6a, #33a38f);
}

.primary-button,
.secondary-button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  padding: 0.95rem 1.25rem;
  cursor: pointer;
  transition: transform 160ms ease, opacity 160ms ease, background 160ms ease;
}

.primary-button {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
}

.secondary-button {
  background: rgba(28, 28, 26, 0.08);
  color: var(--ink);
}

.primary-button:hover,
.secondary-button:hover {
  transform: translateY(-1px);
}

.primary-button:disabled,
.secondary-button:disabled {
  opacity: 0.55;
  cursor: default;
  transform: none;
}

.inline-message {
  min-height: 1.2rem;
  margin: 0;
  font-size: 0.93rem;
}

.inline-message[data-mode="error"] {
  color: var(--danger);
}

.inline-message[data-mode="success"] {
  color: var(--accent-dark);
}

.inline-message[data-mode="muted"] {
  color: var(--muted);
}

.proof-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.proof-card {
  padding: 1rem 1.1rem;
  border-radius: 18px;
}

.result-shell {
  min-height: 100vh;
}

.result-layout {
  max-width: 980px;
  padding-top: 3rem;
}

.result-header {
  margin-bottom: 1.2rem;
}

.back-link {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--accent-dark);
  text-decoration: none;
  font-weight: 700;
}

.result-header h1 {
  max-width: none;
  font-size: clamp(2.6rem, 6vw, 4.2rem);
}

.result-card {
  border-radius: var(--radius-xl);
  padding: 1.4rem;
}

.loading-state {
  padding: 4rem 1rem;
  text-align: center;
  color: var(--muted);
}

.result-body {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.inline-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.result-stats,
.result-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
}

.result-stat,
.result-meta > div,
.compare-card {
  padding: 1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.54);
  border: 1px solid rgba(28, 28, 26, 0.06);
}

.compare-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.compare-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 1rem;
  align-items: center;
}

.bar-track {
  height: 16px;
}

.bar-fill {
  min-width: 8%;
}

.original-fill {
  background: linear-gradient(90deg, #f28f3b, #f5b46f);
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .tool-card {
    order: -1;
  }

  .hero-grid,
  .proof-strip,
  .result-stats,
  .result-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .layout {
    width: min(100% - 1rem, 1180px);
    padding-bottom: 2rem;
  }

  .hero-copy,
  .tool-card,
  .result-card {
    padding: 1rem;
  }

  h1 {
    font-size: 2.6rem;
  }

  .result-header h1 {
    font-size: 2.35rem;
  }

  .hero-grid,
  .proof-strip,
  .result-stats,
  .result-meta {
    grid-template-columns: 1fr;
  }

  .tool-header,
  .tool-footer,
  .result-main,
  .eyebrow-row {
    flex-direction: column;
  }

  .plan-pill {
    width: 100%;
    text-align: left;
  }

  .compare-row {
    grid-template-columns: 1fr;
  }

  .dropzone {
    min-height: 180px;
  }
}
