/* This Is The Gift — design system
   Palette: sand background, olive accent, deep ink text */

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

:root {
  --bg: #F5F6F0;
  --bg-raised: #FFFFFF;
  --accent: #6E7C5A;
  --accent-dark: #56624A;
  --accent-light: #DCE2D2;
  --ink: #2B332A;
  --ink-soft: #5B6357;
  --border: #E1E3D8;
  --font-head: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 2px 8px rgba(43, 51, 42, 0.06);
  --shadow-lift: 0 12px 28px rgba(43, 51, 42, 0.12);
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

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

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--ink);
}

h1 { font-size: clamp(2.1rem, 4vw, 3.4rem); font-weight: 600; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; color: var(--ink-soft); }

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
  font-weight: 600;
  margin-bottom: 0.6em;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.75em 1.5em;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover { background: var(--accent-dark); box-shadow: var(--shadow-lift); }

.btn-outline {
  background: transparent;
  border-color: var(--ink);
  color: var(--ink);
}
.btn-outline:hover { background: var(--ink); color: #fff; }

.btn-ghost {
  background: transparent;
  color: var(--ink);
}
.btn-ghost:hover { background: rgba(43,51,42,0.06); }

.btn-block { width: 100%; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 246, 240, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 14px 0;
}

.logo {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  flex-shrink: 0;
}
.logo span { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }

.nav-links a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-soft);
  white-space: nowrap;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--accent-dark); }

.nav-links .dropdown {
  position: relative;
}
.nav-links .dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 14px;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lift);
  padding: 8px;
  min-width: 220px;
  z-index: 60;
}
.nav-links .dropdown:hover .dropdown-menu,
.nav-links .dropdown.open .dropdown-menu { display: block; }
.dropdown-menu a {
  display: block;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--ink);
}
.dropdown-menu a:hover { background: var(--accent-light); }

.nav-cta { flex-shrink: 0; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
}

@media (max-width: 1080px) {
  .nav-toggle { display: block; order: 3; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-raised);
    flex-direction: column;
    align-items: flex-start;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    gap: 0.9rem;
  }
  .nav-links.open { display: flex; }
  .nav-links .dropdown-menu { position: static; box-shadow: none; border: none; display: block; padding: 0 0 0 12px; margin-top: 6px; }
  .nav-links .dropdown-menu a { padding: 6px 0; }
}

/* ---------- Hero ---------- */
.hero {
  padding: 56px 0 24px;
  text-align: center;
}
.hero p.lead {
  max-width: 560px;
  margin: 0 auto;
  font-size: 1.08rem;
}

/* ---------- Quiz ---------- */
.quiz-section { padding: 8px 0 72px; }

.quiz-card {
  max-width: 640px;
  margin: 0 auto;
  background: var(--bg-raised);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px;
  border: 1px solid var(--border);
}

.quiz-progress {
  height: 6px;
  background: var(--accent-light);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 28px;
}
.quiz-progress-bar {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s ease;
  width: 0%;
}

.quiz-step-label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 10px;
}

.quiz-question h2 {
  margin-bottom: 24px;
  font-size: 1.5rem;
}

.quiz-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.quiz-options.single-col { grid-template-columns: 1fr; }

.quiz-option {
  text-align: left;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: var(--bg);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 500;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.quiz-option:hover { border-color: var(--accent); background: var(--accent-light); }
.quiz-option.selected { border-color: var(--accent); background: var(--accent); color: #fff; }

.quiz-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 32px;
}

.quiz-result {
  text-align: center;
}
.quiz-result .result-icon { font-size: 3rem; margin-bottom: 8px; }
.quiz-result h2 { margin-bottom: 8px; }
.quiz-result p { margin-bottom: 28px; }

/* ---------- Category chips grid (homepage) ---------- */
.cat-grid-section { padding: 24px 0 80px; }
.section-heading { text-align: center; margin-bottom: 40px; }

.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 18px;
}

.cat-card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.cat-card .icon { font-size: 1.8rem; margin-bottom: 10px; display: block; }
.cat-card h3 { margin-bottom: 6px; font-size: 1.05rem; }
.cat-card p { font-size: 0.88rem; margin-bottom: 0; }

/* ---------- Category landing page ---------- */
.cat-hero {
  padding: 48px 0 32px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}
.cat-hero .icon { font-size: 2.6rem; display: block; margin-bottom: 12px; }
.cat-hero p { max-width: 560px; margin: 0 auto; }

.filters {
  padding: 24px 0;
  position: sticky;
  top: 65px;
  background: var(--bg);
  z-index: 20;
  border-bottom: 1px solid var(--border);
}
.filters-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.filters-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
  margin-right: 4px;
}
.chip {
  padding: 7px 15px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--bg-raised);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  color: var(--ink-soft);
  transition: all 0.15s ease;
}
.chip:hover { border-color: var(--accent); }
.chip.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.filters-divider {
  width: 1px;
  height: 20px;
  background: var(--border);
  margin: 0 4px;
}

.products-section { padding: 40px 0 80px; }

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }

.product-image {
  aspect-ratio: 1 / 1;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-image img { width: 100%; height: 100%; object-fit: cover; }
.product-image .placeholder-icon { font-size: 2.6rem; opacity: 0.6; }

.product-body {
  padding: 18px 18px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.tag-pill {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent-dark);
  background: var(--accent-light);
  padding: 3px 9px;
  border-radius: 999px;
}

.product-name {
  font-family: var(--font-head);
  font-size: 1.08rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.product-desc {
  font-size: 0.88rem;
  margin-bottom: 14px;
  flex: 1;
  white-space: pre-line;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.product-price {
  font-weight: 700;
  font-family: var(--font-head);
  font-size: 1.1rem;
}

.no-results {
  text-align: center;
  padding: 60px 20px;
  color: var(--ink-soft);
  display: none;
}
.no-results.visible { display: block; }

/* ---------- Generic content pages ---------- */
.page-hero { padding: 56px 0 20px; }
.content-section { padding: 20px 0 80px; }
.prose { max-width: 720px; }
.prose h2 { margin-top: 1.6em; }
.prose ul { color: var(--ink-soft); padding-left: 1.2em; }
.prose li { margin-bottom: 0.4em; }

.contact-card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  max-width: 480px;
}
.contact-card a.email {
  color: var(--accent-dark);
  font-weight: 600;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
  background: var(--accent-light);
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 24px;
}
.footer-brand .logo { margin-bottom: 10px; }
.footer-brand p { max-width: 320px; font-size: 0.88rem; }
.footer-cols { display: flex; gap: 48px; flex-wrap: wrap; }
.footer-col h4 {
  font-family: var(--font-body);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
  margin-bottom: 12px;
}
.footer-col a {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--ink);
}
.footer-col a:hover { color: var(--accent-dark); }
.footer-bottom {
  border-top: 1px solid rgba(43,51,42,0.12);
  padding-top: 20px;
  font-size: 0.78rem;
  color: var(--ink-soft);
}
.footer-bottom p { margin-bottom: 0.5em; }

@media (max-width: 640px) {
  .quiz-card { padding: 28px 20px; }
  .quiz-options { grid-template-columns: 1fr; }
  .footer-grid { flex-direction: column; }
}
