/* === UZKIRO / SHADOW: LUXURY DIRECTORY DESIGN SYSTEM (REACT BITS) === */

:root {
  color-scheme: dark;
  --dir-bg: #06080e;
  --dir-surface: rgba(13, 18, 30, 0.72);
  --dir-surface-hover: rgba(18, 25, 42, 0.88);
  --dir-line: rgba(56, 189, 248, 0.16);
  --dir-line-hover: rgba(56, 189, 248, 0.45);
  --dir-cyan: #00e5ff;
  --dir-sky: #38bdf8;
  --dir-indigo: #6366f1;
  --dir-violet: #8b5cf6;
  --dir-emerald: #10b981;
  --dir-ink: #f8fafc;
  --dir-muted: #94a3b8;
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  position: relative;
  background-color: var(--dir-bg);
  color: var(--dir-ink);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  touch-action: manipulation;
}

button, input, select {
  font-family: inherit;
  touch-action: manipulation;
}

:focus-visible {
  outline: 2px solid var(--dir-cyan);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Background Canvas: Aurora + Neural Constellation */
#pagesAuroraCanvas {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  pointer-events: none !important;
  z-index: 0 !important;
  opacity: 0.85;
}

.directory-header,
main,
footer {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  width: calc(100% - 64px);
  margin-inline: auto;
}

/* 1. Header Navbar */
.directory-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 20px;
  padding: 10px 18px;
  min-height: 60px;
  border-radius: 18px;
  background: rgba(13, 18, 30, 0.75);
  border: 1px solid var(--dir-line);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.directory-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.05em;
}

.brand-spark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--sky), var(--violet));
  color: #06080e;
  font-size: 16px;
  font-weight: 800;
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.45);
}

.directory-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(0, 0, 0, 0.3);
  padding: 4px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.directory-nav > a {
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--dir-muted);
  transition: all 0.15s ease;
  white-space: nowrap;
}

.directory-nav > a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-back-dashboard {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.25), rgba(99, 102, 241, 0.25));
  border: 1px solid rgba(56, 189, 248, 0.4);
  box-shadow: 0 4px 15px rgba(14, 165, 233, 0.25);
  transition: all 0.2s ease;
}

.btn-back-dashboard:hover {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.4), rgba(99, 102, 241, 0.4));
  border-color: var(--dir-cyan);
  transform: translateY(-1px);
}

/* 2. Hero Section & Shiny Text */
.directory-intro {
  padding: 44px 0 28px;
}

.intro-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.intro-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--dir-sky);
}

.intro-chip.chip-online {
  color: var(--dir-emerald);
  border-color: rgba(16, 185, 129, 0.3);
  background: rgba(16, 185, 129, 0.12);
}

.shiny-text {
  font-size: clamp(32px, 4.5vw, 54px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.15;
  margin: 0 0 14px;
  background: linear-gradient(110deg, #ffffff 30%, #a5b4fc 46%, #38bdf8 54%, #ffffff 70%) !important;
  background-size: 240% 100% !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  animation: shinyStreak 5s linear infinite !important;
}

@keyframes shinyStreak {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.intro-sub {
  font-size: 15px;
  color: var(--dir-muted);
  max-width: 680px;
  margin: 0;
  line-height: 1.6;
}

/* 3. Search & Filter Cockpit */
.directory-filters {
  background: rgba(13, 18, 30, 0.75);
  border: 1px solid var(--dir-line);
  border-radius: 20px;
  padding: 20px;
  margin-bottom: 30px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.filter-main-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.search-input-wrap {
  position: relative;
  flex: 3;
  min-width: 260px;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 16px;
  font-size: 16px;
  color: var(--dir-muted);
  pointer-events: none;
}

.search-input-wrap input {
  width: 100%;
  height: 48px;
  padding: 10px 90px 10px 46px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 14px;
  transition: all 0.2s ease;
}

.search-input-wrap input:focus {
  border-color: var(--dir-sky);
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.35);
  background: rgba(0, 0, 0, 0.55);
}

.search-kbd-hint {
  position: absolute;
  right: 14px;
  padding: 4px 8px;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--dir-muted);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  pointer-events: none;
}

.group-select-wrap {
  flex: 1.5;
  min-width: 180px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.group-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--dir-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.group-select-wrap select {
  width: 100%;
  height: 48px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 0 14px;
  font-size: 13.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.group-select-wrap select:focus {
  border-color: var(--dir-sky);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.3);
}

.directory-count {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  height: 48px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.directory-count strong {
  font-size: 20px;
  font-weight: 800;
  color: var(--dir-cyan);
  font-family: var(--font-mono);
}

.directory-count span {
  font-size: 12px;
  color: var(--dir-muted);
}

/* Category Quick Filter Pills */
.directory-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.directory-pill-btn {
  padding: 6px 14px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--dir-muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.directory-pill-btn:hover {
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.18);
}

.directory-pill-btn.active {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.3), rgba(99, 102, 241, 0.3));
  border-color: var(--dir-sky);
  color: #fff;
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.35);
}

/* Status message */
#directoryStatus {
  color: var(--dir-muted);
  font-size: 14px;
  margin: 18px 0;
}

#directoryStatus:empty {
  display: none;
}

/* 4. Sections & Spotlight Cards Grid */
.directory-section {
  margin-top: 36px;
}

.directory-section h2 {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
}

.directory-section-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(56, 189, 248, 0.15);
  color: var(--dir-sky);
  font-family: var(--font-mono);
}

.directory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

/* Spotlight Card (Option 1) */
.directory-page {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  min-height: 110px;
  padding: 18px 20px;
  border-radius: 18px;
  background: var(--dir-surface);
  border: 1px solid var(--dir-line);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  overflow: hidden;
}

.directory-page:hover {
  transform: translateY(-3px);
  border-color: var(--dir-line-hover);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.5);
}

/* Spotlight radial highlight */
.directory-page::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1.5px;
  background: radial-gradient(
    240px circle at var(--mouse-x, -999px) var(--mouse-y, -999px),
    rgba(56, 189, 248, 0.8),
    rgba(99, 102, 241, 0.4) 40%,
    transparent 70%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
  z-index: 2;
}

.directory-page:hover::before {
  opacity: 1;
}

.card-top-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.card-icon-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.page-category-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 18px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.25);
  flex-shrink: 0;
}

.directory-page strong {
  font-size: 14.5px;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
}

.directory-page > span:not(.directory-arrow) {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--dir-sky);
  background: rgba(56, 189, 248, 0.08);
  padding: 4px 8px;
  border-radius: 6px;
  align-self: flex-start;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.directory-arrow {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--dir-muted);
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.directory-page:hover .directory-arrow {
  color: #fff;
  background: rgba(56, 189, 248, 0.2);
  border-color: var(--dir-sky);
  transform: translate(2px, -2px);
}

.directory-arrow svg {
  width: 15px;
  height: 15px;
}

/* 5. Footer */
footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-top: 60px;
  padding: 28px 0;
  border-top: 1px solid var(--dir-line);
  color: var(--dir-muted);
  font-size: 13px;
  flex-wrap: wrap;
}

.footer-brand {
  font-weight: 700;
  color: #fff;
}

.footer-left p {
  margin: 4px 0 0;
  font-size: 12px;
}

.footer-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-links a:hover {
  color: var(--dir-sky);
}

/* Fluid Click Spark Ripple (Option 8) */
.react-bits-spark-ripple {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  border: 2px solid rgba(0, 229, 255, 0.85);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.5), inset 0 0 12px rgba(139, 92, 246, 0.4);
  transform: translate(-50%, -50%) scale(0.1);
  animation: reactBitsRipple 0.65s cubic-bezier(0.1, 0.8, 0.2, 1) forwards;
  z-index: 99999;
}

@keyframes reactBitsRipple {
  0% { transform: translate(-50%, -50%) scale(0.1); opacity: 0.9; }
  100% { transform: translate(-50%, -50%) scale(1.6); opacity: 0; }
}

/* Responsive adjustments */
@media (max-width: 980px) {
  .directory-header, main, footer {
    width: calc(100% - 40px);
  }
  .directory-nav {
    display: none;
  }
}

@media (max-width: 640px) {
  .directory-header, main, footer {
    width: calc(100% - 24px);
  }
  .filter-main-row {
    flex-direction: column;
    align-items: stretch;
  }
  .search-input-wrap, .group-select-wrap {
    width: 100%;
    min-width: 0;
  }
  .directory-grid {
    grid-template-columns: 1fr;
  }
  footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
