:root {
  color-scheme: light;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #f9fafb;
  --accent: #111827;
  --blue: #2563eb;
  --green: #15803d;
  --red: #b91c1c;
  --radius: 14px;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-size: 15px;
  line-height: 1.6;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

a {
  color: inherit;
}

.container {
  width: min(1120px, calc(100% - 40px));
  margin-inline: auto;
}

/* Header and navigation */

.site-header {
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.header-inner {
  width: min(1120px, calc(100% - 40px));
  min-height: 72px;
  margin: auto;
  display: flex;
  align-items: center;
  gap: 30px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  white-space: nowrap;
}

.brand-logo {
  display: block;
  width: 190px;
  max-width: 100%;
  height: auto;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}

.top-nav a,
.site-footer a {
  color: #4b5563;
  text-decoration: none;
  font-size: 14px;
}

.top-nav a:hover,
.site-footer a:hover {
  color: #111827;
}

/* Product introduction */

.page-intro {
  padding: 26px 0 30px;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 25px;
  color: #9ca3af;
  font-size: 12px;
}

.breadcrumbs a {
  color: #6b7280;
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: #111827;
}

.eyebrow {
  margin: 0 0 10px;
  color: #6b7280;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .13em;
}

.page-intro h1 {
  margin: 0;
  font-size: clamp(32px, 5vw, 46px);
  line-height: 1.15;
  letter-spacing: -.045em;
}

.intro-copy {
  max-width: 760px;
  margin: 15px 0 17px;
  color: #4b5563;
  font-size: 17px;
}

.trust-points {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  color: #4b5563;
  font-size: 13px;
}

.trust-points i {
  margin-right: 5px;
  color: var(--green);
  font-style: normal;
  font-weight: 800;
}

/* Main tool area */

.tool-section {
  padding-bottom: 48px;
}

.tool-panel {
  width: 100%;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 5px 20px rgba(17, 24, 39, .035);
}

.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.section-heading h2,
.content-section h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.3;
  letter-spacing: -.02em;
}

.section-heading p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.privacy-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  border: 1px solid #dcfce7;
  border-radius: 30px;
  background: #f0fdf4;
  color: #166534;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 650;
}

.privacy-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: #16a34a;
}

/* Buttons */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
  transition: background .15s, border-color .15s, opacity .15s;
}

.button:disabled {
  opacity: .42;
  cursor: not-allowed;
}

.button-primary {
  background: #111827;
  color: #fff;
}

.button-primary:hover:not(:disabled) {
  background: #293548;
}

.button-secondary {
  border-color: #d1d5db;
  background: #fff;
  color: #111827;
}

.button-secondary:hover:not(:disabled),
.button-quiet:hover:not(:disabled) {
  background: #f3f4f6;
}

.button-quiet {
  border-color: var(--line);
  background: transparent;
  color: #4b5563;
}

/* Input and output editors */

.editor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.editor-column {
  min-width: 0;
}

.field-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}

.field-heading label {
  font-size: 14px;
  font-weight: 700;
}

.field-heading .button {
  min-height: 32px;
  padding: 5px 11px;
  font-size: 12px;
}

textarea {
  display: block;
  width: 100%;
  min-height: 280px;
  padding: 14px;
  resize: vertical;
  border: 1px solid #d1d5db;
  border-radius: 9px;
  outline: none;
  background: #fff;
  color: #111827;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  line-height: 1.65;
}

textarea:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .1);
}

textarea::placeholder {
  color: #9ca3af;
}

#outputText {
  background: #f9fafb;
}

.field-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 7px;
  color: #9ca3af;
  font-size: 11px;
}

/* Processing options */

.options-block {
  margin-top: 25px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.options-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 13px;
}

.options-title h3 {
  margin: 0;
  font-size: 15px;
}

.options-title span {
  color: var(--muted);
  font-size: 12px;
}

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

.option-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  min-height: 88px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fafbfc;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

.option-card:hover {
  border-color: #cbd5e1;
  background: #f3f4f6;
}

.option-card input {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin: 3px 0 0;
  accent-color: #2563eb;
}

.option-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.option-copy strong {
  font-size: 12px;
  line-height: 1.4;
}

.option-copy small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

/* Statistics */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 11px;
  margin-top: 22px;
}

.stat-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fafafa;
}

.stat-label {
  display: block;
  color: #6b7280;
  font-size: 11px;
  font-weight: 600;
}

.stat-card strong {
  display: block;
  margin-top: 5px;
  font-size: 25px;
  line-height: 1.2;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}

.helper-note {
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 12px;
}

/* Instructions and product information */

.content-section {
  padding: 8px 0 56px;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 46px;
  padding: 30px 0;
  border-top: 1px solid var(--line);
}

.content-grid article {
  min-width: 0;
}

.content-grid h2 {
  margin-bottom: 12px;
}

.content-grid p,
.content-grid li,
.faq-section p,
.privacy-section p {
  color: #4b5563;
  font-size: 14px;
}

.content-grid p {
  margin: 0;
}

.content-grid ol {
  margin: 0;
  padding-left: 21px;
}

.content-grid li {
  padding: 4px 0;
}

/* FAQ */

.faq-section {
  max-width: 860px;
  margin: 8px auto 0;
}

.faq-section h2 {
  margin-bottom: 13px;
}

.faq-section details {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.faq-section details:first-of-type {
  border-top: 1px solid var(--line);
}

.faq-section summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 650;
}

.faq-section summary:hover {
  color: #2563eb;
}

.faq-section details p {
  margin: 8px 0 2px;
}

/* Privacy statement */

.privacy-section {
  max-width: 860px;
  margin: 32px auto 0;
  padding: 19px 21px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--soft);
}

.privacy-section h2 {
  margin: 0 0 7px;
  font-size: 16px;
  letter-spacing: -.01em;
}

.privacy-section p {
  margin: 0;
  font-size: 13px;
}

/* Unified footer */

.site-footer {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: #9ca3af;
  font-size: 12px;
}

.footer-inner nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
}

.site-footer a {
  font-size: 12px;
}

/* Tablet */

@media (max-width: 800px) {
  .header-inner {
    min-height: 0;
    padding: 13px 0;
    flex-wrap: wrap;
    gap: 12px 18px;
  }

  .top-nav {
    order: 3;
    width: 100%;
    margin: 0;
    gap: 20px;
  }

  .page-intro {
    padding-top: 36px;
  }

  .intro-copy {
    font-size: 15px;
  }

  .trust-points {
    gap: 9px 17px;
  }

  .tool-panel {
    padding: 19px;
  }

  .editor-grid {
    gap: 13px;
  }

  .options-grid {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .option-card {
    min-height: 0;
  }

  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .content-grid {
    gap: 25px;
  }
}

/* Mobile */

@media (max-width: 520px) {
  .container,
  .header-inner {
    width: calc(100% - 28px);
  }

  .brand-logo {
    width: 155px;
  }

  .top-nav a {
    font-size: 12px;
  }

  .page-intro {
    padding-top: 27px;
  }

  .breadcrumbs {
    gap: 7px;
    margin-bottom: 21px;
    font-size: 11px;
  }

  .page-intro h1 {
    font-size: 34px;
  }

  .trust-points {
    gap: 7px 13px;
    font-size: 12px;
  }

  .section-heading {
    flex-direction: column;
    gap: 12px;
  }

  .tool-panel {
    padding: 15px;
  }

  .editor-grid {
    grid-template-columns: 1fr;
    gap: 22px;
    margin-top: 19px;
  }

  textarea {
    min-height: 210px;
  }

  .options-title {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .stats-grid {
    gap: 8px;
  }

  .stat-card {
    padding: 11px;
  }

  .stat-card strong {
    font-size: 23px;
  }

  .content-grid {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 24px 0;
  }

  .faq-section {
    margin-top: 5px;
  }

  .privacy-section {
    margin-top: 25px;
    padding: 16px;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .footer-inner nav {
    gap: 12px 18px;
  }
}

/* CONTENT ALIGNMENT OVERRIDE */
.content-section {
  max-width: 860px;
  margin-left: 0;
  margin-right: 0;
}

.content-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  max-width: 860px;
  margin-left: 0;
  margin-right: 0;
  padding: 26px 0;
}

.content-grid article + article {
  margin-top: 26px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.faq-section {
  max-width: 860px;
  margin: 32px 0 0;
}

.privacy-section {
  max-width: 860px;
  margin: 28px 0 0;
}

/* CONTENT ALIGNMENT TO HEADER EDGE */
.content-section.container {
  max-width: none;
  margin-left: auto;
  margin-right: auto;
}

.content-section .content-grid,
.content-section .faq-section,
.content-section .privacy-section {
  max-width: 860px;
  margin-left: 0;
  margin-right: 0;
}
