/* ==========================================================
   VAULT.GLASS.CSS - LIQUID GLASS MATERIAL SYSTEM
   The OSINT Vault
   Layered optical glass treatment: tinted base, directional
   inner light, edge reflection, copper capture, atmospheric
   shadow. Loaded last so it refines, never replaces, the
   existing design system. No new markup required.
   Last Updated: October 13, 2026
   ========================================================== */

/* ----------------------------------------------------------
   1. MATERIAL TOKENS
   ---------------------------------------------------------- */
:root {
  --lg-blur-ambient: 16px;      /* Level 1: navigation */
  --lg-blur-interactive: 18px;  /* Level 2: cards, search */
  --lg-blur-signature: 22px;    /* Level 3: flagship tiles */
  --lg-tint-hi: rgba(255, 255, 255, 0.085);
  --lg-tint-lo: rgba(255, 255, 255, 0.040);
  --lg-tint-quiet-hi: rgba(255, 255, 255, 0.060);
  --lg-tint-quiet-lo: rgba(255, 255, 255, 0.032);
  --lg-edge-hi: rgba(255, 255, 255, 0.20);
  --lg-edge-mid: rgba(255, 255, 255, 0.10);
  --lg-edge-lo: rgba(255, 255, 255, 0.055);
  --lg-copper-capture: rgba(240, 154, 57, 0.14);
  --lg-copper-line: rgba(240, 154, 57, 0.30);
  --lg-shadow-rest: 0 18px 44px rgba(0, 0, 0, 0.42);
  --lg-shadow-lift: 0 26px 58px rgba(0, 0, 0, 0.55);
  --lg-motion: 220ms;
}

/* Shared geometry for glass light layers. Pseudo-elements are
   decorative only and must never intercept interaction. */
.category-nav::before,
.search-bar::before,
.feature-card::after,
.flagship-tile::before,
.flagship-tile::after,
.tool-card::after {
  pointer-events: none;
}

/* ----------------------------------------------------------
   2. LEVEL 1 - AMBIENT GLASS: sticky category navigation
   Translucent charcoal suspended over moving content.
   ---------------------------------------------------------- */
.category-nav {
  background: rgba(10, 10, 10, 0.62);
  -webkit-backdrop-filter: blur(var(--lg-blur-ambient)) saturate(1.15);
  backdrop-filter: blur(var(--lg-blur-ambient)) saturate(1.15);
  box-shadow:
    inset 0 1px 0 var(--lg-edge-mid),
    inset 0 18px 24px -20px rgba(255, 255, 255, 0.05),
    0 14px 38px rgba(0, 0, 0, 0.46);
}
/* Thin luminous upper edge, fading toward the ends */
.category-nav::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--lg-edge-hi) 22%,
    var(--lg-copper-line) 50%,
    var(--lg-edge-hi) 78%,
    transparent 100%);
  opacity: 0.7;
}
.category-nav .category-button {
  transition: background var(--lg-motion) ease, color var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease;
}
.category-nav .category-button.active {
  background: rgba(240, 154, 57, 0.10);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 0 20px rgba(240, 154, 57, 0.14);
}

/* ----------------------------------------------------------
   3. LEVEL 2 - INTERACTIVE GLASS: search control
   Light appears to move through the material on focus.
   ---------------------------------------------------------- */
.search-bar {
  position: relative;
  background: linear-gradient(180deg, var(--lg-tint-hi), var(--lg-tint-lo));
  -webkit-backdrop-filter: blur(var(--lg-blur-interactive)) saturate(1.1);
  backdrop-filter: blur(var(--lg-blur-interactive)) saturate(1.1);
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow:
    inset 0 1px 0 var(--lg-edge-mid),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35),
    0 10px 30px rgba(0, 0, 0, 0.34);
  transition: border-color var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease,
              background var(--lg-motion) ease;
}
/* Directional interior light, brightest along the top edge */
.search-bar::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 45%);
  opacity: 0.8;
  transition: opacity var(--lg-motion) ease;
}
.search-bar:hover {
  border-color: rgba(240, 154, 57, 0.32);
}
.search-bar:focus-within {
  background: linear-gradient(180deg, rgba(240, 154, 57, 0.07), var(--lg-tint-lo));
  border-color: rgba(240, 154, 57, 0.55);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.10),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35),
    0 0 0 3px rgba(240, 154, 57, 0.10),
    0 0 26px rgba(240, 154, 57, 0.10),
    0 14px 38px rgba(0, 0, 0, 0.46);
}
.search-bar:focus-within::before {
  opacity: 1;
}

/* ----------------------------------------------------------
   4. LEVEL 2 (quiet) - EXTERNAL TOOL CARDS
   Translucent depth without competing with flagship systems.
   The existing ::before copper corner gradient is preserved;
   glass edge light rides on ::after.
   ---------------------------------------------------------- */
.tool-card {
  background: linear-gradient(163deg, var(--lg-tint-quiet-hi), var(--lg-tint-quiet-lo));
  box-shadow:
    inset 0 1px 0 var(--lg-edge-lo),
    inset 0 16px 22px -18px rgba(255, 255, 255, 0.045),
    inset 0 -1px 0 rgba(0, 0, 0, 0.30);
  transition: background var(--lg-motion) ease,
              border-left-color var(--lg-motion) ease,
              transform var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease;
}
/* Perimeter light: brighter along the top, falling off down
   the sides. Follows the card geometry exactly. */
.tool-card::after {
  content: '';
  position: absolute;
  inset: 0;
  box-shadow:
    inset 0 1px 0 var(--lg-edge-lo),
    inset 1px 0 0 rgba(255, 255, 255, 0.02);
  opacity: 0.85;
  transition: opacity var(--lg-motion) ease, box-shadow var(--lg-motion) ease;
}
.tool-card:hover {
  background: linear-gradient(163deg, rgba(255, 255, 255, 0.080), rgba(255, 255, 255, 0.042));
  box-shadow:
    inset 0 1px 0 var(--lg-edge-mid),
    inset 0 -1px 0 rgba(0, 0, 0, 0.30),
    0 16px 36px rgba(0, 0, 0, 0.52);
}
.tool-card:hover::after {
  box-shadow:
    inset 0 1px 0 var(--lg-edge-hi),
    inset 1px 0 0 rgba(255, 255, 255, 0.04);
}
/* Brief tactile press feedback */
.tool-card:active {
  transform: translateY(-1px);
  transition-duration: 90ms;
}

/* ----------------------------------------------------------
   5. LEVEL 2 - FEATURE DUO (Stay in the Know / Chronicles)
   Real backdrop glass: these two cards sit over the page and
   earn genuine environmental blur.
   ---------------------------------------------------------- */
.feature-card {
  background: linear-gradient(158deg, var(--lg-tint-hi), var(--lg-tint-lo));
  -webkit-backdrop-filter: blur(var(--lg-blur-interactive)) saturate(1.12);
  backdrop-filter: blur(var(--lg-blur-interactive)) saturate(1.12);
  box-shadow:
    inset 0 1px 0 var(--lg-edge-hi),
    inset 0 20px 28px -20px rgba(255, 255, 255, 0.05),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35),
    var(--lg-shadow-rest);
  transition: border-color var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease,
              background var(--lg-motion) ease,
              transform var(--lg-motion) ease;
}
/* Copper captured along the upper left, as if the warm hero
   light is caught in the glass */
.feature-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(130% 78px at 16% 0%, var(--lg-copper-capture), transparent 62%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), transparent 30%);
  opacity: 1;
  transition: opacity var(--lg-motion) ease;
}
.feature-card:hover {
  background: linear-gradient(158deg, rgba(255, 255, 255, 0.105), rgba(255, 255, 255, 0.052));
  box-shadow:
    inset 0 1px 0 var(--lg-edge-hi),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35),
    0 0 30px rgba(201, 122, 59, 0.16),
    var(--lg-shadow-lift);
  transform: translateY(-2px);
}
.feature-card:hover::after {
  opacity: 1;
}
.feature-card:active {
  transform: translateY(0);
  transition-duration: 90ms;
}

/* ----------------------------------------------------------
   6. LEVEL 3 - SIGNATURE LIQUID GLASS: flagship system tiles
   Reserved for OMERTA, OSINT Grid and TELLTALE. Controlled
   luminous edging, copper corner capture, single hover sweep.
   ---------------------------------------------------------- */
.flagship-tile {
  background: linear-gradient(160deg, var(--lg-tint-hi), var(--lg-tint-lo));
  -webkit-backdrop-filter: blur(var(--lg-blur-signature)) saturate(1.18);
  backdrop-filter: blur(var(--lg-blur-signature)) saturate(1.18);
  overflow: hidden;
  box-shadow:
    inset 0 1px 0 var(--lg-edge-hi),
    inset 0 26px 34px -22px rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.42),
    inset 0 0 0 1px rgba(255, 255, 255, 0.05),
    0 22px 48px rgba(0, 0, 0, 0.5);
  transition: background var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease,
              transform var(--lg-motion) ease;
}
/* Directional light: warm capture at the upper edge falling
   into a cool interior reflection */
.flagship-tile::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(135% 96px at 14% 0%, var(--lg-copper-capture), transparent 62%),
    radial-gradient(120% 72px at 86% 0%, rgba(255, 255, 255, 0.08), transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.09), transparent 30%);
  opacity: 1;
  transition: opacity var(--lg-motion) ease;
  z-index: 0;
}
/* A narrow reflected band that glides across the upper third
   once per hover, then settles. No endless shimmer. */
.flagship-tile::after {
  content: '';
  position: absolute;
  top: -12%;
  bottom: 58%;
  left: 0;
  width: 46%;
  background: linear-gradient(100deg,
    transparent 0%,
    rgba(255, 255, 255, 0.055) 38%,
    rgba(240, 172, 85, 0.07) 52%,
    rgba(255, 255, 255, 0.045) 66%,
    transparent 100%);
  transform: translateX(-130%) skewX(-12deg);
  transition: transform 640ms cubic-bezier(0.3, 0.6, 0.25, 1);
  z-index: 0;
}
.flagship-tile > * {
  position: relative;
  z-index: 1;
}
.flagship-tile:not(.is-coming-soon):hover {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.110), rgba(255, 255, 255, 0.055));
  box-shadow:
    inset 0 1px 0 var(--lg-edge-hi),
    inset 0 -1px 0 rgba(0, 0, 0, 0.38),
    inset 0 0 0 1px rgba(240, 154, 57, 0.10),
    0 0 34px rgba(240, 154, 57, 0.08),
    var(--lg-shadow-lift);
  transform: translateY(-3px);
  z-index: 2;
}
.flagship-tile:not(.is-coming-soon):hover::before {
  opacity: 1;
}
.flagship-tile:not(.is-coming-soon):hover::after {
  transform: translateX(260%) skewX(-12deg);
}
.flagship-tile:not(.is-coming-soon):active {
  transform: translateY(-1px);
  transition-duration: 90ms;
}
/* Coming-soon tiles stay quiet: glass but no light play */
.flagship-tile.is-coming-soon::after {
  display: none;
}
/* Minimum neutral light variation behind the flagship grid so the
   translucent surfaces have something real to bend. No color, no
   spotlight, no imagery. */
.stagger-section.s-flagship {
  position: relative;
}
.stagger-section.s-flagship::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(78% 92% at 50% 6%, rgba(255, 255, 255, 0.032), transparent 72%);
  pointer-events: none;
  z-index: 0;
}
.stagger-section.s-flagship .stagger-inner {
  position: relative;
  z-index: 1;
}

/* ----------------------------------------------------------
   7. MOBILE - lighter optics, touch states instead of hover
   ---------------------------------------------------------- */
@media (max-width: 660px) {
  :root {
    --lg-blur-ambient: 12px;
    --lg-blur-interactive: 13px;
    --lg-blur-signature: 14px;
  }
  .flagship-tile:not(.is-coming-soon):hover,
  .feature-card:hover {
    transform: none;
  }
  .flagship-tile:not(.is-coming-soon):active,
  .feature-card:active,
  .tool-card:active {
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.110), rgba(255, 255, 255, 0.055));
    box-shadow:
      inset 0 1px 0 var(--lg-edge-hi),
      inset 0 -1px 0 rgba(0, 0, 0, 0.38),
      0 10px 26px rgba(0, 0, 0, 0.45);
  }
}

/* ----------------------------------------------------------
   8. ACCESSIBILITY + COMPATIBILITY
   ---------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .flagship-tile::after {
    transition: none;
    transform: translateX(-130%) skewX(-12deg);
  }
  .flagship-tile:not(.is-coming-soon):hover::after {
    transform: translateX(-130%) skewX(-12deg);
  }
  .flagship-tile,
  .feature-card,
  .tool-card,
  .search-bar,
  .category-nav .category-button {
    transition-duration: 1ms;
  }
}

/* Older engines without backdrop-filter get deeper tints so
   surfaces stay legible instead of turning muddy. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .category-nav { background: rgba(8, 8, 8, 0.94); }
  .search-bar { background: linear-gradient(180deg, rgba(20, 20, 20, 0.97), rgba(12, 12, 12, 0.96)); }
  .feature-card { background: linear-gradient(158deg, rgba(20, 20, 20, 0.97), rgba(12, 12, 12, 0.96)); }
  .flagship-tile { background: linear-gradient(160deg, rgba(20, 20, 20, 0.97), rgba(12, 12, 12, 0.96)); }
}

/* Keyboard focus stays crisp through the glass */
.search-bar:focus-within #searchInput,
.flagship-tile:focus-visible,
.feature-card:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

/* ----------------------------------------------------------
   9. QUICK-LINK CHIPS - clear liquid glass
   Neutral translucent chips with real liquid refraction: an
   SVG displacement filter warps each chip the way fluid glass
   bends what passes under it. Geometry, typography, and order
   unchanged; only the material changes.
   ---------------------------------------------------------- */
.quick-links {
  gap: 8px;
  padding-top: 12px;
  border-top: none;
}
.quick-link {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.045);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
  backdrop-filter: blur(16px) saturate(1.15);
  box-shadow:
    inset 0 2px 3px rgba(255, 255, 255, 0.28),
    inset 0 -1px 2px rgba(0, 0, 0, 0.22),
    0 10px 28px rgba(0, 0, 0, 0.28);
  transition: color var(--lg-motion) ease,
              border-color var(--lg-motion) ease,
              background var(--lg-motion) ease,
              box-shadow var(--lg-motion) ease;
}
.quick-link::before {
  content: "";
  position: absolute;
  inset: -14%;
  background:
    radial-gradient(62% 95% at 22% 0%, rgba(255, 255, 255, 0.16), transparent 60%),
    radial-gradient(48% 75% at 82% 100%, rgba(255, 255, 255, 0.06), transparent 65%);
  filter: url(#vault-liquid-glass);
  pointer-events: none;
}
.quick-link .ql-t { position: relative; z-index: 1; }
.quick-link:first-child { border-left: 1px solid rgba(255, 255, 255, 0.11); }
.quick-link:hover {
  color: var(--copper);
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(240, 154, 57, 0.35);
  box-shadow:
    inset 0 2px 4px rgba(255, 255, 255, 0.36),
    inset 0 -1px 2px rgba(0, 0, 0, 0.22),
    0 12px 30px rgba(0, 0, 0, 0.34);
}
.quick-link:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 2px;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .quick-link { background: rgba(18, 18, 18, 0.92); }
}
