:root {
  --bg: #f4f2ee;
  --surface: #fdfcf9;
  --surface-2: #efece6;
  --ink: #1a1916;
  --muted: #6b6860;
  --faint: #9b978d;
  --green: #243d30;
  --green-dark: #1b2e25;
  --amber: #c8873a;
  --border: rgba(26, 25, 22, 0.12);
  --border-strong: rgba(26, 25, 22, 0.2);
  --maxw: 1024px;
  font-synthesis: none;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Jost", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

h1, h2, h3 { margin: 0; color: var(--ink); }
a { color: inherit; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(244, 242, 238, 0.86);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  background: var(--green);
  color: var(--bg);
}
.brand-name {
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.header-right { display: flex; align-items: center; gap: 22px; }
.header-tag {
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* Language toggle */
.lang-toggle {
  display: inline-flex;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  overflow: hidden;
}
.lang-btn {
  border: none;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 5px 12px;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}
.lang-btn:hover { color: var(--ink); }
.lang-btn.is-active { background: var(--green); color: var(--bg); }

/* ---------- Hero ---------- */
.hero { padding: 86px 24px 30px; max-width: 1024px; }
.hero-title {
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}
.hero-line-2 { color: var(--amber); }
.lede {
  color: var(--muted);
  font-size: 15px;
  margin: 0 0 30px;
}

/* ---------- Search ---------- */
.search {
  display: flex;
  align-items: stretch;
  gap: 0;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  overflow: hidden;
}
.search:focus-within { border-color: var(--green); }
.search-icon {
  display: grid;
  place-items: center;
  padding-left: 18px;
  color: var(--faint);
  flex-shrink: 0;
}
.search-input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  padding: 18px 14px;
}
.search-input::placeholder { color: var(--faint); }
.search-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: none;
  background: var(--green);
  color: var(--bg);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0 26px;
  cursor: pointer;
  transition: background 0.2s;
}
.search-btn:hover { background: var(--green-dark); }
.search-btn:disabled { opacity: 0.6; cursor: progress; }
.btn-arrow { flex-shrink: 0; }

.examples {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.examples-label {
  color: var(--faint);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  padding: 6px 13px;
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.18s;
}
.chip:hover { border-color: var(--green); color: var(--green); background: var(--surface); }

/* ---------- Results ---------- */
.results { padding: 26px 24px 40px; }
.results-head { margin-bottom: 22px; }
.results-eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin: 0 0 6px;
}
.results-head-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}
.results-head-row h2 {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 600;
  letter-spacing: -0.01em;
}
.results-count { color: var(--faint); font-size: 13px; white-space: nowrap; }
.summary { color: var(--muted); font-size: 14.5px; margin: 14px 0 0; max-width: 720px; }

.picks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: 26px;
  background: var(--border);
  border: 1px solid var(--border);
}

.pick {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  animation: rise 0.45s ease both;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.pick-photo {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--surface-2);
}
.pick-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pick-photo-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--faint);
  font-size: 12px;
  letter-spacing: 0.04em;
}
.pick-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(253, 252, 249, 0.92);
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 9px;
}
.pick-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px 18px 16px;
}
.pick-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.pick-name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.32;
}
.pick-price {
  font-family: "Albert Sans", sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--amber);
  white-space: nowrap;
}
.pick-reasoning {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
  margin: 0 0 18px;
  flex: 1;
}
.pick-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.pick-seller { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pick-avatar {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--green);
  color: var(--bg);
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}
.pick-seller-name {
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pick-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--green);
  flex-shrink: 0;
  transition: color 0.18s;
}
.pick-link:hover { color: var(--amber); }

.view-all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 30px auto 0;
  text-decoration: none;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: color 0.18s;
}
.view-all:hover { color: var(--green); }

/* ---------- Ad slots ---------- */
.ad-slot {
  margin: 30px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100px;
  border: 1px dashed var(--border-strong);
  background: repeating-linear-gradient(45deg, #efece6, #efece6 12px, #ece8e1 12px, #ece8e1 24px);
}
.ad-leaderboard { max-width: 970px; }
.ad-placeholder-text {
  color: var(--faint);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.ad-slot ins { display: block; width: 100%; }

/* ---------- Status / loader ---------- */
.status { padding: 56px 24px 30px; text-align: center; }
.loader { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.loader-ring {
  width: 42px;
  height: 42px;
  border: 3px solid var(--border-strong);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
  margin-bottom: 14px;
}
@keyframes spin { to { transform: rotate(360deg); } }
#loader-text { font-size: 17px; font-weight: 500; margin: 0; }
.loader-sub { color: var(--faint); font-size: 13.5px; max-width: 420px; margin: 4px 0 0; }
.message {
  max-width: 560px;
  margin: 0 auto;
  padding: 20px 24px;
  font-size: 15px;
  border: 1px solid var(--border);
}
.message.error { background: #faece4; color: #9a533a; border-color: #ecd3c4; }
.message.empty { background: var(--surface); color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 64px;
  background: var(--surface-2);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding-top: 26px;
  padding-bottom: 30px;
  flex-wrap: wrap;
}
.footer-name {
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.footer-fine { color: var(--faint); font-size: 12px; max-width: 560px; margin: 0; }

/* ---------- Tip jar ---------- */
.tip-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 5px 12px;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, border-color 0.18s;
}
.tip-btn svg { color: var(--amber); flex-shrink: 0; }
.tip-btn:hover { border-color: var(--green); color: var(--ink); background: var(--surface); }

.tip-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(26, 25, 22, 0.45);
  animation: tip-fade 0.18s ease;
}
@keyframes tip-fade { from { opacity: 0; } to { opacity: 1; } }
.tip-modal {
  position: relative;
  width: 100%;
  max-width: 384px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  padding: 36px 30px 26px;
  text-align: center;
  box-shadow: 0 24px 60px rgba(26, 25, 22, 0.18);
}
.tip-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: none;
  background: transparent;
  color: var(--faint);
  cursor: pointer;
  transition: color 0.18s;
}
.tip-close:hover { color: var(--ink); }
.tip-mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin: 0 auto 16px;
  color: var(--amber);
  background: rgba(200, 135, 58, 0.12);
  border: 1px solid rgba(200, 135, 58, 0.3);
}
.tip-title {
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}
.tip-sub {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
  margin: 0 0 22px;
}
.tip-amounts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.tip-amount {
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--ink);
  font-family: "Albert Sans", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 500;
  padding: 13px 6px;
  cursor: pointer;
  transition: all 0.16s;
}
.tip-amount:hover { border-color: var(--green); }
.tip-amount.is-active {
  background: var(--green);
  border-color: var(--green);
  color: var(--bg);
}
.tip-custom {
  display: flex;
  align-items: center;
  border: 1px solid var(--border-strong);
  margin-top: 10px;
}
.tip-custom:focus-within { border-color: var(--green); }
.tip-custom-symbol {
  padding: 0 4px 0 14px;
  color: var(--faint);
  font-family: "Albert Sans", system-ui, sans-serif;
  font-size: 15px;
}
.tip-custom-input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-family: "Albert Sans", system-ui, sans-serif;
  font-size: 15px;
  color: var(--ink);
  padding: 12px 14px 12px 4px;
}
.tip-custom-input::placeholder { color: var(--faint); }
.tip-submit {
  width: 100%;
  margin-top: 18px;
  border: none;
  background: var(--green);
  color: var(--bg);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px;
  cursor: pointer;
  transition: background 0.2s;
}
.tip-submit:hover { background: var(--green-dark); }
.tip-submit:disabled { opacity: 0.6; cursor: progress; }
.tip-error { color: #9a533a; font-size: 13px; margin: 12px 0 0; }
.tip-secure {
  color: var(--faint);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 16px 0 0;
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(12px);
  z-index: 60;
  max-width: calc(100vw - 40px);
  background: var(--green);
  color: var(--bg);
  padding: 13px 22px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 12px 30px rgba(26, 25, 22, 0.22);
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
}
.toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .picks { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  body { font-size: 15px; }
  .hero { padding-top: 56px; }
  .header-tag { display: none; }
  .tip-btn-label { display: none; }
  .tip-btn { padding: 5px 9px; }
  .search-btn .btn-label { display: none; }
  .search-btn { padding: 0 18px; }
  .picks { grid-template-columns: 1fr; }
}
