/* ==========================================================================
   Lupe — brand styles
   Colours, type, layout primitives for the Lupe site.
   ========================================================================== */

:root {
  /* Primary palette */
  --lupe-blue:     #2fbfb0;
  --blossom-pink:  #e8637a;
  --sunny-yellow:  #f0b429;
  --leaf-green:    #5aaa6e;
  --lilac:         #9b80d4;

  /* Neutrals */
  --ink:       #1f1d18;
  --ink-mid:   #4a4638;
  --stone:     #b5ac97;
  --cream:     #fdf6ec;
  --warm-bg:   #faf2e3;

  /* Type */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Nunito", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;

  /* Rhythm */
  --radius:       14px;
  --radius-lg:    22px;
  --shadow-sm:    0 1px 2px rgba(31,29,24,0.06);
  --shadow-md:    0 6px 24px rgba(31,29,24,0.08);
  --max-w:        1100px;
  --gutter:       24px;
}

/* ------------------------------------------------------ reset-ish */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--warm-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--lupe-blue); }

/* ------------------------------------------------------ typography */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 1em; color: var(--ink-mid); }

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--lupe-blue);
  margin-bottom: 0.6em;
}

.lede { font-size: 1.15rem; color: var(--ink-mid); max-width: 58ch; }

/* ------------------------------------------------------ layout */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
section { padding: 72px 0; }
section.tight { padding: 48px 0; }

/* ------------------------------------------------------ header */
.site-header {
  padding: 22px 0;
  border-bottom: 1px solid rgba(31,29,24,0.08);
  background: var(--warm-bg);
  position: -webkit-sticky; position: sticky; top: 0; z-index: 10;
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
}
.wordmark {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.wordmark span { color: var(--lupe-blue); }
.nav { display: flex; align-items: center; }
.nav a { margin-left: 28px; }
.nav a:first-child { margin-left: 0; }
.nav a {
  font-size: 0.95rem; text-decoration: none; color: var(--ink-mid); font-weight: 500;
  border-bottom: 2px solid transparent; padding-bottom: 2px; transition: border-color 0.2s, color 0.2s;
}
.nav a:hover { color: var(--ink); border-color: var(--stone); }
.nav a.active { color: var(--ink); border-color: var(--lupe-blue); }
.nav a.cta { color: var(--ink); font-weight: 600; }

/* ------------------------------------------------------ mobile nav */
.nav-toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  width: 44px; height: 44px; position: relative; padding: 10px 6px;
}
.nav-toggle span {
  display: block; width: 100%; height: 2px; background: var(--ink);
  border-radius: 2px; position: absolute; left: 0;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle span:nth-child(1) { top: 2px; }
.nav-toggle span:nth-child(2) { top: 11px; }
.nav-toggle span:nth-child(3) { top: 20px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--warm-bg);
  border-bottom: 1px solid rgba(31,29,24,0.08);
  padding: 0 var(--gutter);
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.mobile-nav.open {
  max-height: 300px;
  padding: 12px var(--gutter) 20px;
}
.mobile-nav a {
  font-family: var(--font-body);
  font-size: 1.05rem; font-weight: 500;
  text-decoration: none; color: var(--ink-mid);
  padding: 10px 0;
  border-bottom: 1px solid rgba(31,29,24,0.06);
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav a:hover { color: var(--lupe-blue); }

@media (max-width: 640px) {
  .nav { display: none; }
  .nav-toggle { display: block; }
  .mobile-nav { display: flex; }
}

/* ------------------------------------------------------ buttons */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 12px 22px;
  border-radius: 999px;
  text-decoration: none;
  border: 1.5px solid var(--ink);
  background: var(--ink);
  color: #fff;
  transition: transform 0.12s ease, background 0.12s ease, color 0.12s ease;
}
.btn:hover { transform: translateY(-1px); background: var(--lupe-blue); border-color: var(--lupe-blue); color: #fff; }
.btn.outline { background: transparent; color: var(--ink); }
.btn.outline:hover { background: var(--ink); color: #fff; }

/* ------------------------------------------------------ hero */
.hero {
  padding: 80px 0 56px;
  background: linear-gradient(180deg, var(--warm-bg) 0%, var(--cream) 100%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.hero h1 { margin-bottom: 20px; }
.hero .lede { margin-bottom: 28px; }
.hero .btn + .btn { margin-left: 10px; }
.hero-art {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  display: flex; align-items: center; justify-content: center;
}
.hero-art svg { width: 100%; height: auto; }
@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero-art { max-width: 420px; margin: 0 auto; }
}

/* ------------------------------------------------------ pack cards */
.packs {
  background: var(--cream);
}
.pack-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 28px;
  margin-top: 32px;
}
.pack-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(31,29,24,0.06);
  display: flex; flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  text-decoration: none;
  color: inherit;
}
.pack-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.pack-card .thumb {
  background: var(--warm-bg);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  padding: 18px;
  min-height: 180px;
}
.pack-card .thumb svg { max-width: 75%; max-height: 75%; }
.pack-card h3 { margin-bottom: 4px; }
.pack-card .meta { font-size: 0.85rem; color: var(--stone); font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; }
.pack-card.coming-soon { opacity: 0.6; }
.pack-card.coming-soon .thumb { background: var(--warm-bg); opacity: 0.7; }

/* ------------------------------------------------------ about / intro strip */
.intro-strip {
  background: var(--warm-bg);
}
.intro-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start;
}
.intro-grid .art {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.intro-grid .art > div {
  background: #fff; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  padding: 18px; box-shadow: var(--shadow-sm);
  min-height: 120px;
}
.intro-grid .art img, .intro-grid .art svg { max-width: 80%; max-height: 80%; }
@media (max-width: 820px) {
  .intro-grid { grid-template-columns: 1fr; gap: 36px; }
}

/* ------------------------------------------------------ email signup */
.signup {
  background: var(--ink);
  color: #fff;
}
.signup h2 { color: #fff; }
.signup p { color: rgba(255,255,255,0.75); }
.signup .eyebrow { color: var(--lupe-blue); }
.signup-form {
  display: flex; max-width: 480px; margin-top: 18px; flex-wrap: wrap;
}
.signup-form > * { margin-right: 10px; margin-bottom: 10px; }
.signup-form > *:last-child { margin-right: 0; }
.signup-form input[type=email] {
  flex: 1 1 220px;
  padding: 13px 18px;
  border-radius: 999px;
  border: 1.5px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.08);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.98rem;
  outline: none;
}
.signup-form input[type=email]::placeholder { color: rgba(255,255,255,0.4); }
.signup-form input[type=email]:focus { border-color: var(--lupe-blue); }
.signup-form button {
  padding: 13px 26px;
  border-radius: 999px;
  border: none;
  background: var(--lupe-blue);
  color: #fff;
  font-family: var(--font-body); font-weight: 600; font-size: 0.98rem;
  cursor: pointer;
  transition: background 0.12s ease;
}
.signup-form button:hover { background: #27a99b; }

/* ------------------------------------------------------ footer */
.site-footer {
  background: var(--warm-bg);
  padding: 40px 0 32px;
  border-top: 1px solid rgba(31,29,24,0.08);
  font-size: 0.9rem;
  color: var(--stone);
}
.site-footer .container {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap;
}
.site-footer .container > * { margin-bottom: 8px; }
.site-footer a { color: var(--ink-mid); text-decoration: none; }
.site-footer a:hover { color: var(--lupe-blue); }

/* ------------------------------------------------------ download list */
.download-list {
  display: flex; flex-direction: column; margin-top: 8px;
}
.download-list > * { margin-bottom: 14px; }
.download-list > *:last-child { margin-bottom: 0; }
.download-item {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--cream);
  border-radius: var(--radius);
  padding: 18px 22px;
}
.download-item > div { flex: 1; min-width: 0; margin-right: 16px; }
.download-item strong {
  display: block; font-size: 1rem; margin-bottom: 2px;
}
.download-item p {
  font-size: 0.9rem; color: var(--ink-mid);
}
.download-item .btn {
  flex-shrink: 0; padding: 10px 20px; font-size: 0.88rem; margin-left: 6px;
}
.download-item.coming-soon-item {
  opacity: 0.5;
}
.download-list {
  margin-bottom: 28px;
}
.license-note {
  font-size: 0.85rem;
  color: var(--ink-mid);
  padding: 12px 16px;
  background: var(--cream);
  border-radius: var(--radius);
  margin: 0 0 28px;
  line-height: 1.5;
}
.license-note strong { color: var(--ink); }
@media (max-width: 480px) {
  .download-item { flex-direction: column; align-items: flex-start; gap: 12px; }
  .license-note { font-size: 0.8rem; }
}

/* ------------------------------------------------------ PDF preview overlay */
.preview-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 100;
  background: rgba(31,29,24,0.7);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  justify-content: center; align-items: center;
}
.preview-overlay.open {
  display: flex;
}
.preview-modal {
  position: relative;
  width: 90vw; max-width: 800px;
  height: 85vh;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(31,29,24,0.3);
  overflow: hidden;
}
.preview-modal iframe {
  width: 100%; height: 100%; border: none;
}
.preview-close {
  position: absolute; top: 12px; right: 16px; z-index: 10;
  background: var(--ink); color: #fff;
  border: none; border-radius: 50%;
  width: 36px; height: 36px;
  font-size: 1.3rem; line-height: 1;
  cursor: pointer;
  display: grid; place-items: center;
  transition: background 0.12s ease;
}
.preview-close:hover { background: var(--lupe-blue); }

/* ------------------------------------------------------ product page */
.product {
  padding: 56px 0 72px;
}
.product-grid {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: start;
}
.product-gallery {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-md);
  display: flex; align-items: center; justify-content: center;
}
.product-gallery svg { width: 100%; height: auto; max-width: 420px; }
.product-meta .price { font-family: var(--font-display); font-size: 2rem; color: var(--ink); margin: 10px 0 18px; }
.product-meta .price .free { color: var(--lupe-blue); }
.product-meta ul { padding-left: 1.1em; color: var(--ink-mid); margin: 18px 0 26px; }
.product-meta ul li { margin-bottom: 6px; }
@media (max-width: 820px) {
  .product-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------ about page */
.about-hero { padding: 64px 0 40px; }
.about-hero h1 { max-width: 16ch; }
.about-body { padding-bottom: 72px; }
.about-body .container { max-width: 680px; }
.about-body p { font-size: 1.05rem; }

/* ------------------------------------------------------ gallery placeholder */
.gallery-strip { background: var(--cream); }
.gallery-placeholder {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 48px 36px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border: 2px dashed var(--stone);
  margin-top: 24px;
}
.gallery-placeholder p {
  color: var(--stone); font-size: 1rem; margin: 0;
}

/* ------------------------------------------------------ how to use */
.how-to { background: var(--warm-bg); }
.how-to-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 24px;
}
.how-to-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}
.how-to-card h3 { margin-bottom: 8px; }
.how-to-card p { margin: 0; color: var(--ink-mid); font-size: 0.95rem; line-height: 1.6; }
@media (max-width: 640px) {
  .how-to-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------ related packs */
.related-packs {
  background: var(--cream);
  padding: 56px 0;
}
.related-packs .pack-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 16px;
}
.related-packs .pack-card { text-align: center; }
.related-packs .pack-card h3 { font-size: 1.05rem; margin-top: 4px; }
@media (max-width: 640px) {
  .related-packs .pack-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------ about art grid responsive */
@media (max-width: 640px) {
  .about-body .container { padding: 0 var(--gutter); }
  .intro-strip .art[style] { grid-template-columns: 1fr 1fr !important; }
}

/* ------------------------------------------------------ mobile: global */
@media (max-width: 480px) {
  section { padding: 48px 0; }
  section.tight { padding: 32px 0; }
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.4rem; }
  .lede { font-size: 1.05rem; }
}

/* ------------------------------------------------------ mobile: hero */
@media (max-width: 480px) {
  .hero { padding: 48px 0 36px; }
  .hero .btn { display: block; text-align: center; margin: 0 0 10px 0 !important; }
  .hero .lede { margin-bottom: 20px; }
}

/* ------------------------------------------------------ mobile: pack cards */
@media (max-width: 560px) {
  .pack-grid { grid-template-columns: 1fr; gap: 20px; }
}

/* ------------------------------------------------------ mobile: intro-grid art */
@media (max-width: 480px) {
  .intro-grid .art { grid-template-columns: 1fr 1fr; gap: 12px; }
}

/* ------------------------------------------------------ mobile: about page art */
.about-art-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 24px;
}
.about-art-grid > div {
  background: #fff; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  padding: 18px; box-shadow: var(--shadow-sm);
  min-height: 120px;
}
@media (max-width: 640px) {
  .about-art-grid { grid-template-columns: 1fr 1fr; }
}

/* ------------------------------------------------------ mobile: product page */
@media (max-width: 480px) {
  .product { padding: 36px 0 48px; }
  .product-grid { gap: 28px; }
  .product-gallery { padding: 20px; }
  .product-meta .price { font-size: 1.6rem; }
}

/* ------------------------------------------------------ mobile: download items */
@media (max-width: 480px) {
  .download-item { padding: 14px 16px; }
  .download-item .btn { padding: 9px 16px; font-size: 0.84rem; width: 100%; text-align: center; margin-left: 0 !important; }
  .download-item strong { font-size: 0.95rem; }
  .download-item p { font-size: 0.85rem; }
}

/* ------------------------------------------------------ mobile: how-to */
@media (max-width: 480px) {
  .how-to-card { padding: 20px; }
}

/* ------------------------------------------------------ mobile: related packs */
@media (max-width: 480px) {
  .related-packs .pack-grid { grid-template-columns: 1fr; gap: 16px; }
  .related-packs { padding: 40px 0; }
}

/* ------------------------------------------------------ mobile: signup */
@media (max-width: 480px) {
  .signup-form { flex-direction: column; }
  .signup-form input[type=email] { flex: none; width: 100%; }
  .signup-form button { width: 100%; }
}

/* ------------------------------------------------------ mobile: footer */
@media (max-width: 480px) {
  .site-footer .container { flex-direction: column; text-align: center; gap: 12px; }
}

/* ------------------------------------------------------ mobile: preview overlay */
@media (max-width: 640px) {
  .preview-modal { width: 96vw; height: 80vh; border-radius: var(--radius); }
}

/* ------------------------------------------------------ mobile: about page */
@media (max-width: 480px) {
  .about-hero { padding: 40px 0 24px; }
  .about-body { padding-bottom: 48px; }
  .about-body p { font-size: 1rem; }
}

/* ------------------------------------------------------ tiny helpers */
.center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
