/* ============================================================
   invengic — landing page custom styles
   Tailwind handles 90% of styling. This file holds:
   - base tokens / body background
   - small reusable component classes (btn, card, feature, etc.)
   - empty media slots (where images & video go in)
   - reveal-on-scroll + ambient float
   ============================================================ */

:root {
  --ink-900: #0a0a0a;
  --ink-600: #525252;
  --ink-400: #a3a3a3;
  --surface: #fafafa;
  --glow: #ffb776;
  --shadow-soft: 0 10px 40px -20px rgb(0 0 0 / 0.15);
  --shadow-soft-lg: 0 24px 60px -24px rgb(0 0 0 / 0.22);
}

html {
  scroll-behavior: smooth;
}

body {
  background: linear-gradient(to bottom, #ffffff 0%, #fafafa 100%);
  background-attachment: fixed;
  min-height: 100vh;
  font-feature-settings: "ss01", "cv11";
}

::selection {
  background: var(--ink-900);
  color: #fff;
}

/* ---------- Layout helpers ---------- */
.container-page {
  margin-inline: auto;
  width: 100%;
  max-width: 1200px;
  padding-inline: 1.5rem;
}
@media (min-width: 768px) {
  .container-page { padding-inline: 2rem; }
}

.section-pad {
  padding-block: 6rem;
}
@media (min-width: 768px) {
  .section-pad { padding-block: 8rem; }
}

/* ---------- Typography ---------- */
.eyebrow {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-400);
}

/* ---------- Navbar ---------- */
#navbar.is-scrolled {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid rgba(229, 229, 229, 0.7);
}
.nav-link {
  font-size: 14px;
  color: var(--ink-600);
  transition: color 0.2s ease;
}
.nav-link:hover { color: var(--ink-900); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 14px;
  font-weight: 500;
  border-radius: 9999px;
  padding: 0.625rem 1.25rem;
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(0.98); }

.btn-primary {
  background: var(--ink-900);
  color: #fff;
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover { background: #000; }

.btn-secondary {
  background: #fff;
  color: var(--ink-900);
  border: 1px solid #e5e5e5;
}
.btn-secondary:hover { border-color: #d4d4d4; }

.btn-ghost {
  color: var(--ink-900);
  padding: 0.5rem 0.75rem;
}
.btn-ghost:hover { color: var(--ink-600); }

.play-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 1.25rem;
  width: 1.25rem;
  border-radius: 9999px;
  border: 1px solid currentColor;
}
.play-dot svg { margin-left: 1px; }

/* ---------- Empty media slots (drop images/videos here) ---------- */
.media-slot {
  position: relative;
  width: 100%;
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}
.media-slot::before {
  content: attr(data-label);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(163, 163, 163, 0.7);
  pointer-events: none;
}
/* If the slot already has children (img/video/iframe), hide the label */
.media-slot:has(> *)::before { display: none; }

.media-slot > img,
.media-slot > video,
.media-slot > iframe {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---------- Cards (Details that matter) ---------- */
.card {
  background: #fff;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
@media (min-width: 768px) {
  .card { padding: 2rem; }
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-soft-lg);
}

/* ---------- Callouts (close-up section) ---------- */
.callout {
  position: relative;
}
.callout::before {
  content: "";
  position: absolute;
  left: -27px;
  top: 8px;
  height: 6px;
  width: 6px;
  border-radius: 9999px;
  background: #d4d4d4;
}
.callout-active::before {
  background: var(--glow);
  box-shadow: 0 0 8px rgba(255, 183, 118, 0.8);
}

/* ---------- Features strip ---------- */
.feature {
  text-align: center;
}
.feature-icon {
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 3rem;
  width: 3rem;
  border-radius: 9999px;
  background: #fff;
  box-shadow: var(--shadow-soft);
  color: var(--ink-900);
}
.feature-icon svg { height: 1.25rem; width: 1.25rem; }
.feature-title {
  margin-top: 1rem;
  font-size: 14px;
  font-weight: 600;
}
.feature-caption {
  margin-inline: auto;
  margin-top: 0.375rem;
  max-width: 14ch;
  font-size: 12px;
  line-height: 1.55;
  color: var(--ink-600);
}

/* ---------- Footer ---------- */
.footer-heading {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-400);
}
.footer-link {
  font-size: 14px;
  color: var(--ink-600);
  transition: color 0.2s ease;
}
.footer-link:hover { color: var(--ink-900); }

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  will-change: opacity, transform;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger inside a row (used by features grid + how-it-works steps) */
.reveal[data-delay="1"] { transition-delay: 80ms; }
.reveal[data-delay="2"] { transition-delay: 160ms; }
.reveal[data-delay="3"] { transition-delay: 240ms; }
.reveal[data-delay="4"] { transition-delay: 320ms; }
.reveal[data-delay="5"] { transition-delay: 400ms; }

/* ---------- Ambient float (hero product) ---------- */
@keyframes float-loop {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}
.float-loop {
  animation: float-loop 6s ease-in-out infinite;
  will-change: transform;
}

/* ---------- Pre-order modal (frosted glass card) ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal.is-open {
  display: flex;
  animation: modal-fade 0.2s ease-out;
}
@keyframes modal-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: pointer;
}

.glass-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow:
    0 30px 80px -20px rgba(0, 0, 0, 0.35),
    inset 0 0 0 1px rgba(255, 255, 255, 0.4);
  overflow: hidden;
  max-height: calc(100vh - 2rem);
  overflow-y: auto;
  animation: card-pop 0.3s cubic-bezier(0.2, 0.7, 0.3, 1) backwards;
}
@keyframes card-pop {
  from { opacity: 0; transform: translateY(12px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--ink-900);
  z-index: 2;
  transition: background 0.2s ease, transform 0.2s ease;
  cursor: pointer;
}
.modal-close:hover {
  background: rgba(255, 255, 255, 0.95);
  transform: scale(1.05);
}
.modal-close svg { width: 16px; height: 16px; }

.glass-card-image {
  position: relative;
  aspect-ratio: 4 / 3;
  background: linear-gradient(180deg, #ffffff 0%, #f5f5f5 100%);
  overflow: hidden;
}
.glass-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.glass-card-body {
  padding: 1.5rem 1.5rem 1.25rem;
}
.glass-card-title {
  margin-top: 0.5rem;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink-900);
}
.glass-card-desc {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--ink-600);
}

.glass-card-price {
  margin-top: 1.5rem;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}
.price-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-400);
  font-weight: 500;
}
.price-value {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--ink-900);
  letter-spacing: -0.01em;
}

.glass-card-cta {
  margin-top: 1.25rem;
  display: flex;
  justify-content: center;
  min-height: 52px;
  padding: 6px;
  border-radius: 14px;
  border: 1px solid rgba(10, 10, 10, 0.12);
  background: rgba(255, 255, 255, 0.4);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.glass-card-cta:hover {
  border-color: rgba(10, 10, 10, 0.25);
  background: rgba(255, 255, 255, 0.6);
}
.glass-card-cta form {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.glass-card-fineprint {
  margin-top: 0.875rem;
  text-align: center;
  font-size: 11px;
  color: var(--ink-400);
}

body.modal-open {
  overflow: hidden;
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .reveal,
  .float-loop,
  .btn,
  .card {
    transition: none !important;
    animation: none !important;
    transform: none !important;
    opacity: 1 !important;
  }
  html { scroll-behavior: auto; }
}
