@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --cream: #faf6ef;
  --paper: #fffdf9;
  --ink: #221f1a;
  --ink-soft: #5a5347;
  --line: #e7ddcc;
  --terracotta: #c1592f;
  --terracotta-dark: #9c4523;
  --moss: #4f6a52;
  --moss-light: #e7efe6;
  --gold: #d9a441;
  --danger: #b3402f;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(34,31,26,.04), 0 6px 20px rgba(34,31,26,.06);

  /* per-tool accents */
  --digest: #4f6a52;
  --digest-bg: #e7efe6;
  --circle: #c1592f;
  --circle-bg: #f7e6dc;
  --gather: #a3752f;
  --gather-bg: #f4ead2;
  --reader: #3f5f7a;
  --reader-bg: #e3edf3;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}
h1, h2, h3, .display {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin: 0 0 .5em;
}
p { margin: 0 0 1em; }
a { color: var(--terracotta-dark); }
img { max-width: 100%; }
[hidden] { display: none !important; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.wrap-narrow { max-width: 700px; margin: 0 auto; padding: 0 20px; }

/* ---- top nav ---- */
.nav {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.nav-inner {
  max-width: 1040px; margin: 0 auto; padding: 16px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
}
.nav-brand { font-family: 'Fraunces', serif; font-weight: 700; font-size: 1.25rem; color: var(--ink); text-decoration: none; }
.nav-links { display: flex; gap: 18px; flex-wrap: wrap; font-size: .92rem; font-weight: 500; }
.nav-links a { color: var(--ink-soft); text-decoration: none; }
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  background: var(--ink); color: #fff; padding: 8px 16px; border-radius: 999px;
  text-decoration: none; font-size: .88rem; font-weight: 600;
}

/* ---- buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px; border: none; cursor: pointer;
  font-family: 'Inter', sans-serif; font-weight: 600; font-size: .95rem;
  text-decoration: none; transition: transform .1s ease, box-shadow .15s ease;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--terracotta); color: #fff; }
.btn-primary:hover { background: var(--terracotta-dark); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-outline { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-outline:hover { border-color: var(--ink); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-block { width: 100%; }

/* ---- cards / sections ---- */
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow);
}
.section { padding: 56px 0; }
.section-tight { padding: 32px 0; }
.eyebrow {
  text-transform: uppercase; letter-spacing: .08em; font-size: .75rem; font-weight: 700;
  color: var(--ink-soft); margin-bottom: 10px;
}
.muted { color: var(--ink-soft); }
.small { font-size: .85rem; }

/* ---- tool grid on landing ---- */
.tool-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 28px;
}
@media (max-width: 640px) { .tool-grid { grid-template-columns: 1fr; } }
.tool-card {
  display: block; text-decoration: none; color: inherit;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow); position: relative; overflow: hidden;
}
.tool-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--accent, var(--terracotta));
}
.tool-card .tool-icon {
  width: 42px; height: 42px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; background: var(--accent-bg, var(--circle-bg)); margin-bottom: 14px;
}
.tool-card h3 { margin-bottom: 6px; font-size: 1.15rem; }
.tool-card p { color: var(--ink-soft); font-size: .92rem; margin-bottom: 0; }

/* ---- forms ---- */
label { display: block; font-weight: 600; font-size: .88rem; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=url], input[type=number], textarea, select {
  width: 100%; padding: 11px 13px; border-radius: 10px; border: 1.5px solid var(--line);
  font-family: 'Inter', sans-serif; font-size: .95rem; background: #fff; color: var(--ink);
}
textarea { min-height: 160px; resize: vertical; }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--accent, var(--terracotta)); outline-offset: 1px; }
.field { margin-bottom: 18px; }
.hint { font-size: .8rem; color: var(--ink-soft); margin-top: 6px; }
.privacy-note {
  font-size: .82rem; color: var(--ink-soft); background: var(--cream);
  border: 1px dashed var(--line); border-radius: 10px; padding: 10px 12px; margin: 14px 0;
}

/* ---- loading ---- */
.loading-row { display: flex; align-items: center; gap: 10px; color: var(--ink-soft); font-size: .9rem; }
.spinner {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--line); border-top-color: var(--accent, var(--terracotta));
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- misc ---- */
.badge {
  display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; padding: 3px 9px; border-radius: 999px; background: var(--accent-bg); color: var(--accent);
}
.divider { height: 1px; background: var(--line); margin: 28px 0; border: none; }
.result-block { background: var(--cream); border-radius: 10px; padding: 16px 18px; margin-bottom: 12px; }
.pill-row { display: flex; gap: 8px; flex-wrap: wrap; }
.pill {
  padding: 6px 12px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff;
  cursor: pointer; font-size: .85rem; font-weight: 500;
}
.pill.active { background: var(--ink); color: #fff; border-color: var(--ink); }

.footer {
  border-top: 1px solid var(--line); padding: 32px 0; margin-top: 60px;
  color: var(--ink-soft); font-size: .85rem;
}
.footer a { color: var(--ink-soft); margin-right: 16px; }

.error-box {
  background: #fdece7; border: 1px solid #f0c4b4; color: var(--danger);
  padding: 12px 14px; border-radius: 10px; font-size: .9rem; margin: 14px 0;
}
.upsell-box {
  background: var(--moss-light); border: 1px solid #cddccd; border-radius: 10px;
  padding: 16px; margin: 14px 0; font-size: .9rem;
}
.upsell-box a.btn { margin-top: 10px; }
