/* ==============================================================
   Vistaarly · assets/css/global.css
   -----------------------------------------------------------------
   Single import point for the sitewide design system. Every role
   (public, buyer, seller, admin) loads this file first. Per-role
   overrides then load AFTER this via includes/header.php's
   $pageCss array (see also assets/css/responsive.css for media
   queries — deliberately separated per spec point 5).

   Loads (in order):
     - base/variables.css   (design tokens: color, type, spacing)
     - base/reset.css
     - base/typography.css
     - base/buttons.css
     - base/forms.css
     - base/layout.css
     - components/nav-header.css
     - components/card-listing.css
     - components/subscription-badge.css
     - components/modal-popup.css

   NOTE: media queries are NOT in this file — see responsive.css.
   ============================================================== */

@import url('./base/variables.css');
@import url('./base/reset.css');
@import url('./base/typography.css');
@import url('./base/buttons.css');
@import url('./base/forms.css');
@import url('./base/layout.css');
@import url('./components/nav-header.css');
@import url('./components/card-listing.css');
@import url('./components/subscription-badge.css');
@import url('./components/modal-popup.css');

/* ------------- Global helpers used everywhere ------------- */
.v-container { max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.v-section { padding: 64px 0; }
.v-section-tight { padding: 32px 0; }
.v-eyebrow {
  display: inline-block;
  font-family: var(--mono, 'IBM Plex Mono', monospace);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  color: var(--color-text-muted, #6b7280);
  margin-bottom: 8px;
}
.v-h-display {
  font-family: var(--display, 'Fraunces', serif);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

/* Divider */
.v-divider { border: 0; height: 1px; background: var(--color-border, #e5e7eb); margin: 32px 0; }

/* Chips (used by browse filters + tier badges) */
.v-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--color-bg-alt, #f8f7f4);
  border: 1px solid var(--color-border, #e5e7eb);
  font-size: 0.78rem;
  color: var(--color-text, #111827);
  cursor: pointer;
  transition: all .18s ease;
  white-space: nowrap;
}
.v-chip:hover { border-color: var(--color-primary, #0b0f19); }
.v-chip.is-active {
  background: var(--color-primary, #0b0f19);
  border-color: var(--color-primary, #0b0f19);
  color: #fff;
}
.v-chip .fa-solid { font-size: 0.7rem; }

/* Sticky quota strip on browse */
.v-quota-strip {
  position: sticky;
  top: 64px;
  z-index: 5;
  background: linear-gradient(90deg, #fef3c7 0%, #fde68a 100%);
  color: #78350f;
  border: 1px solid #fcd34d;
  padding: 10px 16px;
  border-radius: 12px;
  margin-bottom: 16px;
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 0.86rem;
  font-weight: 500;
}
.v-quota-strip a { color: #78350f; text-decoration: underline; font-weight: 700; }

/* Premium paywall block (shown when quota exhausted) */
.v-paywall {
  border-radius: 20px;
  padding: 48px 32px;
  text-align: center;
  background:
    radial-gradient(circle at top left, #fef3c7 0%, transparent 50%),
    radial-gradient(circle at bottom right, #dbeafe 0%, transparent 50%),
    #fffefb;
  border: 1px solid #f5e6b1;
  box-shadow: 0 8px 40px rgba(180, 140, 20, 0.08);
  margin: 24px 0 40px;
}
.v-paywall .v-paywall-crown {
  width: 72px; height: 72px; border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-size: 32px;
  margin-bottom: 20px;
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
}
.v-paywall h2 {
  font-family: var(--display, 'Fraunces', serif);
  font-size: clamp(1.6rem, 3.2vw, 2.4rem);
  font-weight: 500;
  margin: 0 0 12px;
  color: var(--color-primary, #0b0f19);
  letter-spacing: -0.01em;
}
.v-paywall p { color: var(--color-text-muted, #4b5563); max-width: 560px; margin: 0 auto 24px; font-size: 1rem; }
.v-paywall .v-paywall-cta {
  display: inline-flex; gap: 10px; align-items: center;
  padding: 14px 28px; border-radius: 999px;
  background: linear-gradient(135deg, #0b0f19, #1f2937);
  color: #fff; font-weight: 600; text-decoration: none;
  transition: transform .2s ease, box-shadow .2s ease;
}
.v-paywall .v-paywall-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(11, 15, 25, 0.28); }
.v-paywall .v-paywall-tiers { margin-top: 20px; font-size: 0.85rem; color: var(--color-text-muted); }
.v-paywall .v-paywall-tiers strong { color: var(--color-primary); }

/* Small utility */
.v-hidden { display: none !important; }
.v-visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0;
  margin: -1px; overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* Focus-visible ring across the app */
:where(button, a, input, textarea, select):focus-visible {
  outline: 2px solid var(--color-primary, #0b0f19);
  outline-offset: 2px;
  border-radius: 6px;
}
