/* =============================================================================
 * pyllar-v2-base.css — Shared chrome layer for all Pyllar pages
 * Includes: design-system tokens, buttons, site header, site footer,
 *           mobile nav drawer, WhatsApp float, contact modal.
 * Load AFTER any page-specific CSS (styles.css) so chrome classes win.
 * Does NOT set body background/color — inner pages keep their own palette.
 * =========================================================================== */

/* ---------- Custom Cursive face ------------------------------------------- */
@font-face {
  font-family: "PyllarCursive";
  src: url("assets/fonts/PyllarCursive.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}

/* ---------- Design-system tokens ------------------------------------------ */
:root {
  /* V2 Premium surfaces */
  --v2-cream:           #FBF9F4;
  --v2-cream-warm:      #FAF9F1;
  --v2-card-white:      #FFFFFF;
  --v2-subtle-border:   #EFEBE9;
  --v2-frosted:         rgba(255,255,255,0.85);

  /* V2 ink */
  --v2-ink:             #3E2723;
  --v2-ink-soft:        #6D4C41;
  --v2-ink-mute:        rgba(62,39,35,0.7);
  --v2-headline-green:  #11381E;
  --v2-help-text:       #1A7A42;

  /* Brand metals */
  --v2-gold:            #D4AF37;
  --v2-gold-deep:       #8B6B25;
  --v2-gold-soft:       #C5A358;
  --v2-silver:          #9E9E9E;
  --v2-bronze:          #6D4C41;

  /* Status */
  --v2-success-green:   #2E7D32;
  --v2-volatility-red:  #C62828;

  /* Obsidian CTA */
  --v2-obsidian:        #0A2415;
  --v2-obsidian-soft:   #0A2213;
  --v2-ribbon-green:    #11381E;

  /* Gradients */
  --v2-gradient-cta-border: linear-gradient(90deg, #FFD700 0%, #8B6B25 100%);
  --v2-gradient-ribbon:     linear-gradient(180deg, #11381E 0%, #0A2213 100%);

  /* V1 Material (legacy — keep for pages still on styles.css) */
  --color-primary:          #26533E;
  --color-on-primary:       #FFFFFF;

  /* Typography */
  --font-display: "Outfit", "Inter", system-ui, sans-serif;
  --font-body:    "Outfit", "Inter", system-ui, sans-serif;
  --font-accent:  "PyllarCursive", "Caveat", cursive;

  /* Radii */
  --radius-sm:   8px;
  --radius-md:   12px;
  --radius-lg:   16px;
  --radius-pill: 9999px;

  /* Shadows */
  --shadow-card:    0 4px 16px rgba(0,0,0,0.08);
  --shadow-card-lg: 0 12px 32px rgba(0,0,0,0.10);

  /* Motion */
  --ease-standard: cubic-bezier(.2,0,0,1);
  --dur-fast:  150ms;
  --dur-base:  300ms;

  /* Layout */
  --page-max: 1200px;
  --gutter:   clamp(20px, 5vw, 64px);
}

*, *::before, *::after { box-sizing: border-box; }

/* ---------- Layout utility ------------------------------------------------ */
.v2-wrap { max-width: var(--page-max); margin: 0 auto; padding-inline: var(--gutter); }

/* ---------- Buttons ------------------------------------------------------- */
.v2-btn {
  font: inherit; cursor: pointer; border: 0; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-weight: 600; white-space: nowrap;
  transition: transform var(--dur-fast) var(--ease-standard),
              box-shadow var(--dur-base) var(--ease-standard),
              filter var(--dur-fast);
}
.v2-btn:active { transform: translateY(1px) scale(0.99); }

.v2-btn-primary {
  position: relative; color: #FBF7E9; background: var(--v2-obsidian);
  padding: 14px 24px; border-radius: var(--radius-md); font-size: 15px;
  box-shadow: 0 8px 22px rgba(10,36,21,0.26);
}
.v2-btn-primary::before {
  content: ""; position: absolute; inset: -1.5px;
  border-radius: calc(var(--radius-md) + 1.5px);
  background: var(--v2-gradient-cta-border); z-index: -1;
}
.v2-btn-primary:hover { filter: brightness(1.06); }

/* Store badges */
.v2-store-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.v2-store-badge {
  display: inline-flex; align-items: center; gap: 10px; padding: 10px 16px;
  border-radius: var(--radius-md); background: var(--v2-obsidian); color: #F5EFD8;
  text-decoration: none; font-size: 13px; line-height: 1.1;
  border: 1px solid rgba(212,175,55,0.35);
}
.v2-store-badge b { font-size: 15px; font-weight: 700; display: block; }
.v2-store-badge:hover { filter: brightness(1.08); }
.v2-store-badge svg { width: 22px; height: 22px; flex: none; }

/* ---------- Site header --------------------------------------------------- */
.v2-site-header {
  position: sticky; top: 0; z-index: 900;
  background: color-mix(in srgb, var(--v2-cream) 92%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur-base), background var(--dur-base);
}
.v2-site-header.scrolled {
  border-bottom-color: var(--v2-subtle-border);
  background: color-mix(in srgb, var(--v2-cream) 96%, transparent);
}
.v2-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px; gap: 24px;
}
.v2-brand {
  display: flex; align-items: center; gap: 12px; text-decoration: none; flex-shrink: 0;
}
.v2-brand img { width: 36px; height: 36px; border-radius: 8px; box-shadow: var(--shadow-card); }
.v2-brand .v2-wordmark {
  font-family: var(--font-display); font-weight: 700; font-size: 20px;
  color: var(--v2-ink); letter-spacing: -0.01em; text-decoration: none;
}
.v2-nav { display: flex; align-items: center; gap: 28px; }
.v2-nav a {
  color: var(--v2-ink); text-decoration: none; font-weight: 500; font-size: 15px;
  opacity: 0.8; transition: opacity var(--dur-fast), color var(--dur-fast);
}
.v2-nav a:hover { opacity: 1; color: var(--v2-gold-deep); }
.v2-header-cta { display: inline-flex; gap: 10px; align-items: center; }
.v2-cta-btn {
  position: relative; color: #FBF7E9; background: var(--v2-obsidian);
  padding: 9px 18px; border-radius: var(--radius-pill); font-size: 13.5px;
  font-weight: 600; text-decoration: none; border: 0; cursor: pointer;
  display: inline-flex; align-items: center;
  box-shadow: 0 4px 12px rgba(10,36,21,0.22);
  transition: filter var(--dur-fast);
}
.v2-cta-btn::before {
  content: ""; position: absolute; inset: -1.5px; border-radius: inherit;
  background: var(--v2-gradient-cta-border); z-index: -1; border-radius: var(--radius-pill);
}
.v2-cta-btn:hover { filter: brightness(1.08); }
.v2-nav-toggle {
  display: none; background: none; border: 0; cursor: pointer;
  color: var(--v2-ink); padding: 4px;
}

/* ---------- Mobile nav drawer --------------------------------------------- */
.v2-mobile-nav { display: none; }
.v2-mobile-nav.open { display: block; }
.v2-mobile-nav {
  position: fixed; inset: 68px 0 0; z-index: 880;
  background: var(--v2-cream); padding: 24px var(--gutter);
  overflow-y: auto;
}
.v2-mobile-nav a {
  display: block; padding: 15px 0; font-size: 18px; font-weight: 600;
  color: var(--v2-ink); text-decoration: none;
  border-bottom: 1px solid var(--v2-subtle-border);
}
.v2-mobile-nav a:hover { color: var(--v2-gold-deep); }

/* ---------- Site footer --------------------------------------------------- */
.v2-site-footer {
  background: var(--v2-obsidian);
  color: rgba(245,239,216,0.7);
  margin-top: clamp(40px, 6vw, 80px);
  font-family: var(--font-body);
}
.v2-footer-top {
  display: flex; flex-wrap: wrap; gap: 40px; justify-content: space-between;
  padding: clamp(48px, 6vw, 72px) 0 40px;
}
.v2-footer-brand { max-width: 320px; }
.v2-footer-brand .v2-brand .v2-wordmark { color: #F5EFD8; }
.v2-footer-brand p { margin: 16px 0 0; font-size: 13.5px; line-height: 1.6; color: rgba(245,239,216,0.6); }
.v2-footer-cols { display: flex; gap: clamp(28px, 5vw, 64px); flex-wrap: wrap; }
.v2-footer-col h4 {
  font-size: 11px; letter-spacing: 1.1px; text-transform: uppercase;
  color: var(--v2-gold); margin: 0 0 14px; font-weight: 700;
  font-family: var(--font-display);
}
.v2-footer-col a {
  display: block; color: rgba(245,239,216,0.72); text-decoration: none;
  font-size: 14px; margin-bottom: 10px;
}
.v2-footer-col a:hover { color: #fff; }
.v2-footer-legal {
  border-top: 1px solid rgba(245,239,216,0.12);
  padding: 20px 0 32px; font-size: 11.5px; line-height: 1.6; color: rgba(245,239,216,0.45);
}
.v2-footer-bottom {
  display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; margin-top: 12px;
  font-size: 12px;
}
.v2-footer-bottom a { color: rgba(245,239,216,0.65); text-decoration: none; }
.v2-footer-bottom a:hover { color: #fff; }

/* ---------- WhatsApp float ------------------------------------------------ */
.v2-wa-float {
  position: fixed; bottom: 24px; right: 24px; z-index: 850;
  background: #25D366; color: #fff; border-radius: 999px;
  padding: 13px 20px 13px 16px; display: inline-flex; align-items: center; gap: 9px;
  text-decoration: none; box-shadow: 0 6px 22px rgba(37,211,102,0.42);
  transition: transform var(--dur-fast); font-family: var(--font-body);
}
.v2-wa-float:hover { transform: translateY(-2px); }
.v2-wa-float svg { width: 22px; height: 22px; flex-shrink: 0; }
.v2-wa-float .v2-wa-label { font-weight: 600; font-size: 14px; }

/* ---------- Contact modal ------------------------------------------------- */
.v2-contact-modal-overlay {
  display: none !important; position: fixed; inset: 0; z-index: 1000;
  background: rgba(10,36,21,0.55); backdrop-filter: blur(4px);
  align-items: center; justify-content: center;
}
.v2-contact-modal-overlay.open { display: flex !important; }
.v2-contact-modal {
  background: var(--v2-cream); border-radius: var(--radius-lg);
  padding: 32px 28px; max-width: 380px; width: 90%; position: relative;
  box-shadow: var(--shadow-card-lg); text-align: center;
}
.v2-contact-modal h3 {
  font-family: var(--font-display); font-weight: 700; font-size: 20px;
  color: var(--v2-ink); margin: 0 0 12px;
}
.v2-contact-modal p { font-size: 15px; color: var(--v2-ink-soft); line-height: 1.6; margin: 0; }
.v2-contact-modal .v2-email {
  display: inline-block; margin-top: 10px; font-weight: 600; color: var(--v2-obsidian);
}
.v2-contact-close {
  position: absolute; top: 14px; right: 16px; background: none; border: 0;
  font-size: 22px; cursor: pointer; color: var(--v2-ink-soft); line-height: 1;
}

/* ---------- Responsive ---------------------------------------------------- */
@media (max-width: 640px) {
  .v2-nav { display: none; }
  .v2-nav-toggle { display: inline-flex; }
  .v2-header-cta .v2-cta-btn { padding: 8px 14px; font-size: 13px; }
  .v2-wa-float .v2-wa-label { display: none; }
  .v2-wa-float { padding: 14px; border-radius: 50%; }
  .v2-footer-cols { gap: 24px; }
  .v2-footer-brand { max-width: 100%; }
}
@media (max-width: 400px) {
  .v2-store-row { flex-direction: column; }
}
