/* ============================================
   TOOTHPENCIL — Shared Design System
   ============================================ */

:root {
  --charcoal: #16150f;
  --charcoal-soft: #2b2a22;
  --cream: #f5efe4;
  --cream-deep: #ece3d3;
  --sage: #7c9885;
  --sage-deep: #5c7867;
  --gold: #c9a24b;
  --paper: #fbf8f2;
  --line: #ddd3c1;
  --muted: #6f695c;
  --radius: 14px;
  --radius-lg: 26px;
  --shadow: 0 18px 50px -24px rgba(22, 21, 15, 0.45);
  --maxw: 1180px;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--charcoal);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; line-height: 1.08; letter-spacing: -0.01em; }

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

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

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

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--sage-deep);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 14px 28px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--charcoal); color: var(--cream); }
.btn-primary:hover { background: var(--sage-deep); }
.btn-ghost { background: transparent; color: var(--charcoal); border-color: var(--charcoal); }
.btn-ghost:hover { background: var(--charcoal); color: var(--cream); }
.btn-gold { background: var(--gold); color: var(--charcoal); }
.btn-gold:hover { background: var(--charcoal); color: var(--cream); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 248, 242, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.brand {
  font-family: var(--font-display);
  font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em;
  display: flex; align-items: center; gap: 10px;
}
.brand .mark {
  width: 26px; height: 26px; border-radius: 50%;
  background: linear-gradient(150deg, var(--sage), var(--charcoal));
  display: inline-block;
}
.nav-links { display: flex; gap: 34px; align-items: center; }
.nav-links a { font-size: 0.94rem; font-weight: 500; color: var(--charcoal-soft); transition: color 0.2s; }
.nav-links a:hover, .nav-links a.active { color: var(--sage-deep); }
.nav-cta { display: flex; align-items: center; gap: 16px; }
.nav-toggle { display: none; background: none; border: none; font-size: 1.4rem; cursor: pointer; }

/* ---------- Sections ---------- */
section { padding: 90px 0; }
.section-head { max-width: 640px; margin-bottom: 54px; }
.section-head h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 14px 0 16px; }
.section-head p { color: var(--muted); font-size: 1.08rem; }
.center { text-align: center; margin-left: auto; margin-right: auto; }

/* ---------- Hero ---------- */
.hero { background: var(--cream); border-bottom: 1px solid var(--line); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 50px; align-items: center; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); margin: 20px 0 22px; }
.hero p.lede { font-size: 1.2rem; color: var(--charcoal-soft); max-width: 480px; margin-bottom: 32px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-proof { display: flex; gap: 30px; margin-top: 40px; }
.hero-proof .stat b { font-family: var(--font-display); font-size: 1.7rem; display: block; }
.hero-proof .stat span { font-size: 0.82rem; color: var(--muted); }

.hero-visual {
  aspect-ratio: 4/5;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(120% 90% at 70% 15%, rgba(124,152,133,0.35), transparent 60%),
    linear-gradient(160deg, #efe6d4 0%, #d9cbb2 100%);
  position: relative;
  box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center;
}
/* Stylized product illustration (miswak "pencil") */
.pencil {
  width: 62px; height: 74%;
  border-radius: 40px 40px 8px 8px;
  background: linear-gradient(90deg, #b98a4e, #d8ab63 45%, #a9773d);
  position: relative;
  box-shadow: 0 24px 40px -18px rgba(22,21,15,0.5);
  transform: rotate(-8deg);
}
.pencil::before { /* sharpened tip */
  content: ""; position: absolute; bottom: -46px; left: 50%; transform: translateX(-50%);
  border-left: 31px solid transparent; border-right: 31px solid transparent;
  border-top: 52px solid #d8ab63;
}
.pencil::after { /* charcoal frayed bristle tip */
  content: ""; position: absolute; bottom: -70px; left: 50%; transform: translateX(-50%);
  width: 16px; height: 26px; border-radius: 0 0 6px 6px;
  background: repeating-linear-gradient(90deg, #2b2a22 0 3px, #3f3d31 3px 5px);
}
.pencil .band { position: absolute; top: 16%; left: 0; right: 0; height: 12px; background: var(--sage-deep); }
.pencil .logo { position: absolute; top: 34%; left: 0; right: 0; text-align: center; color: var(--cream); font-family: var(--font-display); font-size: 0.7rem; letter-spacing: 0.12em; transform: rotate(90deg); }

/* ---------- Marquee / trust ---------- */
.trust { background: var(--charcoal); color: var(--cream); padding: 22px 0; }
.trust .wrap { display: flex; gap: 48px; justify-content: center; flex-wrap: wrap; font-size: 0.85rem; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.9; }

/* ---------- Cards / grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 32px; transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card .ico { width: 46px; height: 46px; border-radius: 12px; background: var(--cream-deep); display: flex; align-items: center; justify-content: center; font-size: 1.4rem; margin-bottom: 18px; }
.card h3 { font-size: 1.3rem; margin-bottom: 10px; }
.card p { color: var(--muted); font-size: 0.97rem; }

/* ---------- Feature split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.split.rev .split-media { order: 2; }
.split-media {
  aspect-ratio: 5/4; border-radius: var(--radius-lg);
  background: linear-gradient(160deg, var(--sage) 0%, var(--sage-deep) 100%);
  box-shadow: var(--shadow);
  display:flex;align-items:center;justify-content:center;color:var(--cream);
  font-family: var(--font-display); font-size: 1.4rem; text-align:center; padding: 30px;
}
.split-media.charcoal { background: linear-gradient(160deg, #34322a, #16150f); }
.split-media.cream { background: linear-gradient(160deg,#efe6d4,#d9cbb2); color: var(--charcoal); }
.split h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); margin: 14px 0 16px; }
.split p { color: var(--muted); margin-bottom: 14px; }
.check-list { list-style: none; margin-top: 18px; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; font-weight: 500; }
.check-list li::before { content: "✓"; color: var(--sage-deep); font-weight: 700; }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; counter-reset: step; }
.step { position: relative; padding: 34px 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.step .num { font-family: var(--font-display); font-size: 2.4rem; color: var(--sage); }
.step h3 { font-size: 1.2rem; margin: 6px 0 8px; }
.step p { color: var(--muted); font-size: 0.95rem; }

/* ---------- Reviews ---------- */
.reviews { background: var(--cream); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.review { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; }
.review .stars { color: var(--gold); letter-spacing: 2px; margin-bottom: 12px; }
.review p { font-size: 1.02rem; }
.review .who { margin-top: 16px; font-weight: 600; font-size: 0.9rem; }
.review .who span { display:block; font-weight: 400; color: var(--muted); font-size: 0.82rem; }

/* ---------- Pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: stretch; }
.plan { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 36px 30px; background: var(--paper); display: flex; flex-direction: column; }
.plan.featured { background: var(--charcoal); color: var(--cream); border-color: var(--charcoal); transform: scale(1.03); box-shadow: var(--shadow); }
.plan.featured .price small, .plan.featured .plan-desc { color: #cfc9ba; }
.plan .tag { align-self: flex-start; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.14em; background: var(--gold); color: var(--charcoal); padding: 5px 12px; border-radius: 100px; margin-bottom: 16px; font-weight: 700; }
.plan h3 { font-size: 1.5rem; }
.plan .price { font-family: var(--font-display); font-size: 2.6rem; margin: 12px 0 4px; }
.plan .price small { font-size: 0.9rem; font-family: var(--font-body); color: var(--muted); }
.plan-desc { color: var(--muted); font-size: 0.92rem; margin-bottom: 20px; }
.plan ul { list-style: none; display: grid; gap: 12px; margin: 10px 0 28px; }
.plan ul li { display: flex; gap: 10px; font-size: 0.95rem; }
.plan ul li::before { content: "✓"; color: var(--sage); font-weight: 700; }
.plan .btn { margin-top: auto; justify-content: center; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(150deg, var(--sage-deep), var(--charcoal)); color: var(--cream); border-radius: var(--radius-lg); padding: 64px; text-align: center; }
.cta-band h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 14px; }
.cta-band p { opacity: 0.9; max-width: 520px; margin: 0 auto 28px; }

/* ---------- FAQ ---------- */
.faq details { border-bottom: 1px solid var(--line); padding: 22px 0; }
.faq summary { font-family: var(--font-display); font-size: 1.2rem; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.6rem; color: var(--sage-deep); }
.faq details[open] summary::after { content: "−"; }
.faq p { color: var(--muted); margin-top: 12px; }

/* ---------- Page hero (interior) ---------- */
.page-hero { background: var(--cream); border-bottom: 1px solid var(--line); text-align: center; padding: 80px 0; }
.page-hero h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); margin: 14px 0 16px; }
.page-hero p { color: var(--muted); font-size: 1.12rem; max-width: 620px; margin: 0 auto; }

/* ---------- Product detail ---------- */
.product-top { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.product-gallery { aspect-ratio: 1; border-radius: var(--radius-lg); background: linear-gradient(160deg,#efe6d4,#d3c3a8); box-shadow: var(--shadow); display:flex;align-items:center;justify-content:center; }
.thumbs { display: flex; gap: 12px; margin-top: 14px; }
.thumb { flex: 1; aspect-ratio: 1; border-radius: 12px; border: 1px solid var(--line); background: var(--cream-deep); }
.product-info h1 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 8px; }
.product-info .price { font-family: var(--font-display); font-size: 2rem; margin: 10px 0; }
.product-info .price small { font-size: 0.9rem; font-family: var(--font-body); color: var(--muted); }
.product-info .stars { color: var(--gold); letter-spacing: 2px; }
.buy-options { display: grid; gap: 12px; margin: 24px 0; }
.buy-opt { border: 1.5px solid var(--line); border-radius: var(--radius); padding: 16px 18px; cursor: pointer; display: flex; justify-content: space-between; align-items: center; transition: border-color 0.2s; }
.buy-opt:hover, .buy-opt.sel { border-color: var(--sage-deep); background: var(--cream); }
.buy-opt b { font-size: 0.98rem; }
.buy-opt span { color: var(--muted); font-size: 0.85rem; }
.buy-opt .save { background: var(--sage); color: var(--cream); font-size: 0.72rem; padding: 3px 9px; border-radius: 100px; font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--charcoal); color: var(--cream); padding: 70px 0 34px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.site-footer .brand { color: var(--cream); margin-bottom: 14px; }
.site-footer p.tag { color: #b7b1a3; max-width: 260px; font-size: 0.94rem; }
.footer-col h4 { font-family: var(--font-body); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.14em; color: #9a9488; margin-bottom: 16px; }
.footer-col a { display: block; color: #d9d4c8; font-size: 0.94rem; margin-bottom: 10px; transition: color 0.2s; }
.footer-col a:hover { color: var(--sage); }
.footer-bottom { border-top: 1px solid #34322a; margin-top: 44px; padding-top: 22px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; color: #8f897d; font-size: 0.85rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid, .split, .product-top { grid-template-columns: 1fr; }
  .split.rev .split-media { order: 0; }
  .grid-3, .steps, .plans { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-links { display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; background: var(--paper); padding: 20px 24px; border-bottom: 1px solid var(--line); gap: 18px; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
  .plan.featured { transform: none; }
  .cta-band { padding: 44px 24px; }
  .hero-proof { flex-wrap: wrap; gap: 20px; }
}
