/* Saymail Free Email Rewriter — page styles. Brand-consistent with the
   landing, blog and comparison pages: parchment bg, green accent, DM Sans
   + DM Serif Display. */

:root {
  --bg:           #F7F5F0;
  --surface:      #FFFFFF;
  --ink:          #1A1714;
  --ink-soft:     #6B6560;
  --accent:       #2D6A4F;
  --accent-deep:  #1F4D38;
  --accent-light: #D8EDE4;
  --accent-warm:  #E8A838;
  --border:       #E4E0D8;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "DM Sans", system-ui, -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.7;
}

/* ---- nav ---- */
.rw-nav { border-bottom: 1px solid var(--border); background: var(--surface); }
.rw-nav-inner {
  max-width: 960px; margin: 0 auto;
  padding: 18px 28px;
  display: flex; align-items: center; justify-content: space-between;
}
.rw-logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.rw-logo svg { width: 26px; height: 26px; display: block; }
.rw-logo span { font-family: "DM Serif Display", Georgia, serif; font-size: 21px; letter-spacing: -0.4px; }
.rw-cta {
  display: inline-flex; align-items: center;
  padding: 9px 18px; border-radius: 999px;
  background: var(--accent); color: #fff;
  font-family: "DM Sans", sans-serif; font-size: 13px; font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.15s ease;
}
.rw-cta:hover { background: var(--accent-deep); transform: translateY(-1px); }

/* ---- hero ---- */
.rw-hero { padding: 56px 28px 24px; text-align: center; }
.rw-eyebrow {
  font-weight: 600; font-size: 11px; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 14px;
}
.rw-hero h1 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: clamp(38px, 5.6vw, 60px);
  line-height: 1.08; letter-spacing: -0.6px;
  margin-bottom: 18px;
}
.rw-hero p {
  font-size: 18px; color: var(--ink-soft);
  max-width: 640px; margin: 0 auto 8px;
}
.rw-hero .rw-sub-small {
  font-size: 14px; color: var(--ink-soft);
  margin-top: 18px;
}

/* ---- tool card ---- */
.rw-tool-wrap { max-width: 760px; margin: 0 auto; padding: 28px; }
.rw-tool {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 20px 48px -28px rgba(26, 23, 20, 0.18);
}
.rw-label {
  font-weight: 600; font-size: 10px; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 10px;
}
.rw-textarea {
  width: 100%; min-height: 180px; max-height: 360px; resize: vertical;
  padding: 14px 16px;
  border: 1px solid var(--border); border-radius: 12px;
  background: var(--bg);
  color: var(--ink);
  font-family: inherit; font-size: 15.5px; line-height: 1.55;
}
.rw-textarea:focus { outline: none; border-color: var(--accent); }
.rw-textarea::placeholder { color: #908a83; font-style: italic; }

.rw-tones { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 20px; }
.rw-pill {
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--ink-soft);
  font-family: inherit; font-size: 13px; cursor: pointer;
  transition: all 0.15s ease;
}
.rw-pill:hover:not(.rw-active) { border-color: var(--accent); color: var(--ink); }
.rw-pill.rw-active { background: var(--accent); border-color: var(--accent); color: #fff; }

.rw-go {
  width: 100%; padding: 14px;
  border: none; border-radius: 12px;
  background: var(--ink); color: #fff;
  font-family: inherit; font-size: 14px; font-weight: 600;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background 0.15s ease;
}
.rw-go:hover:not(:disabled) { background: #000; }
.rw-go:disabled { opacity: 0.55; cursor: default; }
.rw-spinner {
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: #fff; border-radius: 50%;
  animation: rw-spin 0.7s linear infinite;
}
@keyframes rw-spin { to { transform: rotate(360deg); } }

/* ---- notice / error ---- */
.rw-notice {
  margin-top: 18px; padding: 14px 16px;
  border-radius: 10px; font-size: 14.5px;
  background: var(--accent-light); color: var(--accent-deep);
}
.rw-notice.rw-error { background: #fbe9e7; color: #9b3b2c; }
.rw-notice a { color: inherit; font-weight: 600; }

/* ---- result ---- */
.rw-result { margin-top: 24px; }
.rw-result-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px;
}
.rw-result-label {
  font-weight: 600; font-size: 10px; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent);
}
.rw-copy {
  border: 1px solid var(--border); background: var(--bg);
  color: var(--ink);
  padding: 7px 12px; border-radius: 8px;
  font-family: inherit; font-size: 12.5px; cursor: pointer;
  transition: border-color 0.15s ease;
}
.rw-copy:hover { border-color: var(--accent); color: var(--accent); }
.rw-output {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
  white-space: pre-wrap;
  font-size: 15px; line-height: 1.7;
  color: var(--ink);
}

/* ---- single-line text input (used by /out-of-office-generator) ---- */
.rw-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 12px;
  background: var(--bg); color: var(--ink);
  font-family: inherit; font-size: 15px;
}
.rw-input:focus { outline: none; border-color: var(--accent); }
.rw-input::placeholder { color: #908a83; font-style: italic; }
.rw-field { margin-bottom: 18px; }
.rw-textarea-small {
  width: 100%; min-height: 90px; max-height: 220px; resize: vertical;
  padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 12px;
  background: var(--bg); color: var(--ink);
  font-family: inherit; font-size: 14.5px; line-height: 1.55;
}
.rw-textarea-small:focus { outline: none; border-color: var(--accent); }
.rw-textarea-small::placeholder { color: #908a83; font-style: italic; }
.rw-hint {
  font-size: 12px; color: var(--ink-soft);
  margin-top: 6px;
}

/* ---- subject-line variants list (used by /email-subject-line-generator) ---- */
.rw-variants { display: flex; flex-direction: column; gap: 8px; }
.rw-variant {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px 12px 16px;
  display: flex; align-items: center; gap: 12px;
}
.rw-variant-text {
  flex: 1;
  font-size: 15px; line-height: 1.45;
  color: var(--ink);
  word-break: break-word;
}
.rw-variant-meta {
  font-size: 11px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.rw-variant-meta.rw-long { color: var(--accent-warm); }
.rw-variant-copy {
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-soft);
  padding: 6px 12px; border-radius: 8px;
  font-family: inherit; font-size: 12px; cursor: pointer;
  transition: all 0.15s ease;
}
.rw-variant-copy:hover { border-color: var(--accent); color: var(--accent); }
.rw-variant-copy.rw-copied { background: var(--accent-light); color: var(--accent-deep); border-color: #c8e3d4; }

/* inline install CTA after the result */
.rw-install {
  margin-top: 20px;
  background: var(--accent-light);
  border: 1px solid #c8e3d4;
  border-radius: 14px;
  padding: 18px 20px;
  display: flex; gap: 16px; align-items: center; justify-content: space-between;
}
.rw-install p { margin: 0; color: var(--accent-deep); font-size: 14.5px; }
.rw-install strong { color: var(--accent-deep); }
.rw-install a {
  flex-shrink: 0;
  background: var(--accent); color: #fff;
  padding: 10px 18px; border-radius: 999px;
  text-decoration: none; font-weight: 500; font-size: 13.5px;
  transition: background 0.15s ease;
}
.rw-install a:hover { background: var(--accent-deep); }

.rw-hidden { display: none !important; }

/* ---- long-form content ---- */
.rw-content { max-width: 760px; margin: 24px auto 0; padding: 32px 28px 80px; }
.rw-content h2 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: clamp(26px, 3.2vw, 34px);
  letter-spacing: -0.3px; line-height: 1.2;
  margin: 56px 0 14px;
}
.rw-content h3 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 22px; letter-spacing: -0.2px; line-height: 1.3;
  margin: 32px 0 10px;
}
.rw-content p, .rw-content ul, .rw-content ol { margin-bottom: 18px; }
.rw-content ul, .rw-content ol { padding-left: 22px; }
.rw-content li { margin-bottom: 8px; }
.rw-content a { color: var(--accent); }
.rw-content strong { color: var(--ink); }

.rw-ba { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 16px 0 28px; }
@media (max-width: 640px) { .rw-ba { grid-template-columns: 1fr; } }
.rw-ba-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  font-size: 14.5px; line-height: 1.6;
  white-space: pre-wrap;
}
.rw-ba-card .lbl {
  display: block;
  font-family: "DM Sans", sans-serif;
  font-weight: 600; font-size: 10px; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 10px;
}

/* final CTA */
.rw-final {
  background: var(--ink); color: #fff;
  border-radius: 16px;
  padding: 36px 32px;
  text-align: center;
  margin: 56px 0 0;
}
.rw-final h3 {
  font-family: "DM Serif Display", Georgia, serif;
  font-size: 26px; margin-bottom: 10px; color: #fff;
}
.rw-final p { color: rgba(255,255,255,0.65); margin-bottom: 22px; }
.rw-final a {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  background: var(--accent); color: #fff;
  text-decoration: none; font-weight: 500; font-size: 15px;
  transition: background 0.15s ease;
}
.rw-final a:hover { background: var(--accent-deep); }

/* footer */
.rw-foot {
  border-top: 1px solid var(--border);
  margin-top: 56px; padding-top: 24px;
  font-size: 14px; color: var(--ink-soft);
  display: flex; gap: 20px; flex-wrap: wrap;
}
.rw-foot a { text-decoration: none; color: var(--accent); }
.rw-foot a:hover { text-decoration: underline; }
