/* Use of Muse — editorial directory design
   Warm off-white paper, dark ink, lime-green accent. No gradients. */

:root {
  --paper: #faf7f0;
  --paper-deep: #f3eee2;
  --ink: #1c1a16;
  --ink-soft: #5b564a;
  --ink-faint: #8a8474;
  --line: #e4ddcd;
  --accent: #65a30d;      /* lime-600: readable on cream */
  --accent-deep: #3f6212; /* lime-800: text-safe */
  --accent-wash: #ecfccb; /* lime-100 */
  --card: #ffffff;
  --radius: 14px;
  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
}

.wordmark {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.wordmark .dot {
  color: var(--accent-deep);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 14px;
  border-radius: 999px;
}

.nav-link:hover {
  color: var(--ink);
  background: var(--paper-deep);
}

.nav-link.cta {
  background: var(--ink);
  color: var(--paper);
}

.nav-link.cta:hover {
  background: var(--accent-deep);
  color: #fff;
}

.nav-link:focus-visible,
.chip:focus-visible,
.card-source:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- Hero ---------- */
.hero {
  padding: 64px 0 40px;
  text-align: center;
}

.hero-kicker {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: var(--accent-wash);
  border: 1px solid #d9f99d;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

.hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 6vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  max-width: 20ch;
  margin-left: auto;
  margin-right: auto;
}

.hero h1 em {
  font-style: italic;
  color: var(--accent-deep);
}

.hero-sub {
  color: var(--ink-soft);
  font-size: 1.15rem;
  max-width: 42ch;
  margin: 0 auto 36px;
}

.stats {
  display: flex;
  justify-content: center;
  gap: 48px;
  margin: 0 0 36px;
  flex-wrap: wrap;
}

.stat {
  min-width: 120px;
}

.stat-num {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--ink);
  display: block;
  line-height: 1.1;
}

.stat-num .accent { color: var(--accent-deep); }

.stat-label {
  font-size: 0.85rem;
  color: var(--ink-faint);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- Search + chips ---------- */
.search-row {
  max-width: 640px;
  margin: 0 auto 18px;
  text-align: left;
}

.search-row label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.search-input {
  width: 100%;
  font-size: 1.05rem;
  padding: 14px 18px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--ink);
}

.search-input::placeholder { color: var(--ink-faint); }

.search-input:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-wash);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 8px;
}

.chip {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--card);
  color: var(--ink-soft);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.chip:hover {
  border-color: var(--accent);
  color: var(--ink);
}

.chip[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

/* ---------- Directory / cards ---------- */
.directory { padding: 32px 0 72px; }

.section-title {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
}

.section-sub {
  color: var(--ink-soft);
  margin: 0 0 28px;
}

.result-count {
  font-size: 0.9rem;
  color: var(--ink-faint);
  margin-bottom: 18px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(28, 26, 22, 0.08);
}

.card-tag {
  align-self: flex-start;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: var(--accent-wash);
  border-radius: 999px;
  padding: 4px 12px;
}

.card-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  line-height: 1.3;
  margin: 0;
  letter-spacing: -0.01em;
}

.card-desc {
  color: var(--ink-soft);
  font-size: 0.96rem;
  margin: 0;
  flex: 1;
}

/* Cached screenshot preview for sources that can't be embedded live. */
.source-shot-link {
  display: block;
  margin: 14px 0 12px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.source-shot {
  display: block;
  width: 100%;
  height: auto;
}
.source-shot-link:hover .source-shot {
  opacity: 0.96;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: 6px;
  font-size: 0.88rem;
}

.card-source {
  color: var(--accent-deep);
  font-weight: 600;
  text-decoration: none;
}

.card-source:hover { text-decoration: underline; }

.card-date { color: var(--ink-faint); white-space: nowrap; }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--ink-soft);
  border: 2px dashed var(--line);
  border-radius: var(--radius);
}

/* ---------- How it works ---------- */
.how {
  background: var(--ink);
  color: var(--paper);
  padding: 72px 0;
}

.how .section-title { color: var(--paper); }
.how .section-sub { color: #b8b2a2; }

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  list-style: none;
  margin: 32px 0 0;
  padding: 0;
  counter-reset: step;
}

.step {
  background: #2a2721;
  border: 1px solid #3d382d;
  border-radius: var(--radius);
  padding: 26px 22px;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent);
  color: #1c1a16;
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 14px;
}

.step h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  margin: 0 0 8px;
}

.step p {
  margin: 0;
  color: #b8b2a2;
  font-size: 0.95rem;
}

/* ---------- Submit ---------- */
.submit { padding: 72px 0; }

.submit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.submit-copy p { color: var(--ink-soft); }

.submit-form {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--ink-soft);
  margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink);
}

.field textarea { min-height: 110px; resize: vertical; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-wash);
}

.btn {
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 22px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  background: var(--ink);
  color: var(--paper);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn:hover { background: var(--accent-deep); color: #fff; }

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--line);
  color: var(--ink-soft);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--ink);
  background: var(--accent-wash);
}

.fallback {
  font-size: 0.92rem;
  color: var(--ink-soft);
  text-align: center;
}

.fallback a { color: var(--accent-deep); font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 36px 0;
  color: var(--ink-faint);
  font-size: 0.92rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  .hero { padding: 48px 0 32px; }
  .stats { gap: 28px; }
  .submit-grid { grid-template-columns: 1fr; gap: 32px; }
  .cards { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card { transition: none; }
}

/* ---------- Live embeds ---------- */
.embed-slot {
  margin: 14px 0 4px;
  min-height: 180px;
}

/* Keep the official X / Threads / Instagram embeds calm inside our cards. */
.embed-slot .twitter-tweet,
.embed-slot .text-post-media,
.embed-slot .instagram-media {
  margin: 0 !important;
  max-width: 100%;
}

.embed-slot iframe {
  max-width: 100%;
}

/* Responsive 16:9 wrapper for YouTube. */
.yt-frame {
  position: relative;
  padding-top: 56.25%;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}

.yt-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.embed-loading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 28px 6px;
  color: var(--ink-faint);
  font-size: 0.9rem;
}

.embed-spinner {
  width: 18px;
  height: 18px;
  flex: none;
  border-radius: 50%;
  border: 2px solid var(--line);
  border-top-color: var(--accent-deep);
  animation: embed-spin 0.8s linear infinite;
}

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

@media (prefers-reduced-motion: reduce) {
  .embed-spinner { animation: none; }
}
