/* use-cases.css - Z-AXIS-AERO 30 Use Case Gallery.
 * Truss Standard v1.0 palette. Ink base, gold accents, glass panels.
 */

:root {
  --bg: oklch(0.12 0.008 255);
  --surface: oklch(0.15 0.012 255 / 0.75);
  --surface-raised: oklch(0.18 0.014 255 / 0.6);
  --primary: oklch(0.68 0.15 255);
  --primary-deep: oklch(0.52 0.12 255);
  --accent: oklch(0.82 0.14 220);
  --gold: oklch(0.74 0.10 75);
  --gold-deep: oklch(0.74 0.08 70);
  --gold-bright: oklch(0.76 0.11 75);
  --text: oklch(0.93 0.008 255);
  --text-dim: oklch(0.72 0.015 255);
  --border: oklch(0.45 0.02 255 / 0.12);
  --grid: oklch(0.68 0.15 255 / 0.05);
  --danger: oklch(0.80 0.22 25);
  --ok: oklch(0.72 0.17 155);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', monospace;
  --radius: 14px;
  --radius-sm: 9px;
  --glass-blur: 16px;
  --shadow: 0 2px 4px oklch(0.05 0.01 255 / 0.3), 0 12px 32px oklch(0.05 0.01 255 / 0.55);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background:
    radial-gradient(1200px 700px at 80% -10%, oklch(0.68 0.15 255 / 0.10), transparent 60%),
    radial-gradient(900px 600px at -10% 110%, oklch(0.52 0.12 255 / 0.08), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  max-width: 100vw;
  overflow-x: hidden;
}

/* Hero */
.hero {
  padding: 3rem 2rem 2rem;
  text-align: center;
  border-bottom: 1px solid var(--grid);
}
.hero-inner { max-width: 900px; margin: 0 auto; }
.brand-mark {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.12em;
  color: var(--gold);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
}
.brand-mark-img {
  height: 44px;
  width: auto;
  display: block;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.subtitle {
  font-size: 1rem;
  color: var(--text-dim);
  opacity: 0.7;
  margin-top: 0.3rem;
}
.nav {
  margin-top: 1.2rem;
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}
.nav a {
  color: var(--gold-bright);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--grid);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s, background 0.2s;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}
.nav a:hover {
  border-color: var(--gold);
  background: oklch(0.68 0.15 255 / 0.08);
}

/* Stats bar */
.stats-bar {
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding: 1.2rem 2rem;
  flex-wrap: wrap;
}
.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}
.uc-search {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.8rem;
  font-size: 0.85rem;
  min-width: 240px;
}
.uc-search:focus { outline: 2px solid var(--gold); outline-offset: 2px; }
.sim-controls-row { display: flex; gap: 0.8rem; align-items: center; flex-wrap: wrap; margin: 0.8rem 0; font-size: 0.85rem; }
.sim-controls-row input[type=range] { accent-color: var(--gold); }
.sim-canvas { width: 100%; border-radius: var(--radius-sm); border: 1px solid var(--border); background: #070d10; display: block; margin: 0.6rem 0; }
.stat-num {
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text);
}
.stat-num.live { color: var(--ok); }
.stat-num.indoor { color: var(--ok); }
.stat-num.outdoor { color: var(--gold-bright); }
.stat-num.demo { color: var(--gold-bright); }
.stat-num.concept { color: var(--text-dim); opacity: 0.5; }
.stat-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  opacity: 0.5;
  margin-top: 0.2rem;
}

/* Filter bar */
.filter-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  padding: 0 2rem 1.2rem;
  flex-wrap: wrap;
}
.filter-btn {
  background: var(--surface);
  color: var(--text-dim);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.8rem;
  font-size: 0.8rem;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.15s cubic-bezier(0.22, 1, 0.36, 1);
}
.filter-btn:hover { border-color: var(--gold); color: var(--text); }
.filter-btn.active {
  background: oklch(0.68 0.15 255 / 0.12);
  border-color: var(--gold);
  color: var(--gold-bright);
}
.filter-btn:not(:disabled):active { transform: scale(0.98); }
.filter-sep { color: var(--border); margin: 0 0.3rem; }

/* Gallery grid */
main { max-width: 1200px; margin: 0 auto; padding: 0 2rem 3rem; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1rem;
}
.uc-card {
  background: var(--surface-raised);
  border: 1px solid oklch(0.75 0.02 255 / 0.12);
  border-radius: var(--radius);
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: border-color 0.2s, transform 0.15s;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
  backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 1px 2px oklch(0.05 0.01 255 / 0.15), 0 8px 24px oklch(0.05 0.01 255 / 0.3), inset 0 1px 0 oklch(0.95 0.02 255 / 0.04);
  will-change: transform;
  animation: cardEnter 0.4s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}
.uc-card:nth-child(1) { animation-delay: 0.02s; }
.uc-card:nth-child(2) { animation-delay: 0.04s; }
.uc-card:nth-child(3) { animation-delay: 0.06s; }
.uc-card:nth-child(4) { animation-delay: 0.08s; }
.uc-card:nth-child(5) { animation-delay: 0.1s; }
.uc-card:nth-child(6) { animation-delay: 0.12s; }
.uc-card:nth-child(7) { animation-delay: 0.14s; }
.uc-card:nth-child(8) { animation-delay: 0.16s; }
.uc-card:nth-child(n+9) { animation-delay: 0.18s; }
@keyframes cardEnter { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.uc-card:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 2px 4px oklch(0.05 0.01 255 / 0.2), 0 12px 36px oklch(0.05 0.01 255 / 0.4), inset 0 1px 0 oklch(0.95 0.02 255 / 0.06);
}
.uc-card:active { transform: translateY(-2px) scale(0.98); }
.uc-card.status-live { border-left: 3px solid var(--ok); }
.uc-card.status-demo { border-left: 3px solid var(--gold-bright); }
.uc-card.status-concept { border-left: 3px solid var(--border); opacity: 0.75; }

.uc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.uc-id {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gold);
  font-weight: 600;
}
.uc-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}
.badge-live { background: oklch(0.72 0.17 155 / 0.18); color: var(--ok); border: 1px solid oklch(0.72 0.17 155 / 0.3); }
.badge-demo { background: oklch(0.82 0.14 220 / 0.12); color: var(--gold-bright); border: 1px solid oklch(0.82 0.14 220 / 0.25); }
.badge-concept { background: oklch(0.40 0.05 75 / 0.5); color: var(--text-dim); opacity: 0.6; border: 1px solid var(--border); }

.uc-title {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}
.uc-desc {
  font-size: 0.82rem;
  color: var(--text-dim);
  opacity: 0.7;
  line-height: 1.45;
}
.uc-meta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.72rem;
}
.uc-drone, .uc-ai, .uc-phase {
  font-family: var(--font-mono);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  background: var(--surface);
  color: var(--text-dim);
}
.uc-ai { color: var(--gold-bright); }
.uc-env {
  font-family: var(--font-mono);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
}
.env-indoor { background: oklch(0.72 0.17 155 / 0.18); color: var(--ok); border: 1px solid oklch(0.72 0.17 155 / 0.3); }
.env-outdoor { background: oklch(0.82 0.14 220 / 0.12); color: var(--gold-bright); border: 1px solid oklch(0.82 0.14 220 / 0.25); }

.uc-action {
  margin-top: auto;
  background: var(--surface);
  color: var(--gold-bright);
  border: 1px solid var(--gold);
  border-radius: var(--radius-sm);
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
}
.uc-action:hover {
  background: oklch(0.68 0.15 255 / 0.12);
  box-shadow: 0 0 0 2px oklch(0.68 0.15 255 / 0.2);
}
.uc-action:not(.disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px oklch(0.68 0.15 255 / 0.12), 0 4px 12px oklch(0.68 0.15 255 / 0.25);
}
.uc-action.disabled {
  border-color: var(--border);
  color: var(--text-dim);
  opacity: 0.4;
  cursor: default;
}
.uc-action:not(.disabled):active { transform: translateY(-1px) scale(0.98); }

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal.hidden { display: none; }
.modal-overlay {
  position: absolute;
  inset: 0;
  background: oklch(0.05 0.01 255 / 0.7);
  backdrop-filter: blur(6px);
}
.modal-content {
  position: relative;
  background: var(--surface-raised);
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  padding: 2rem;
  max-width: 700px;
  width: 90%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 4px 8px oklch(0.05 0.01 255 / 0.3), 0 24px 64px oklch(0.05 0.01 255 / 0.6), inset 0 1px 0 oklch(0.95 0.02 255 / 0.06);
  backdrop-filter: blur(24px) saturate(180%);
}
.modal-close {
  position: absolute;
  top: 0.8rem;
  right: 1rem;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.5rem;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}
.modal-close:hover { opacity: 1; }
.modal-content h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.modal-content p {
  font-size: 0.88rem;
  color: var(--text-dim);
  opacity: 0.8;
  margin-bottom: 1rem;
}

/* Demo components */
.demo-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.demo-row video, .demo-row canvas {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  max-width: 320px;
  max-height: 240px;
  background: var(--bg);
}
.demo-btn {
  background: var(--gold);
  color: var(--bg);
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}
.demo-btn:hover { opacity: 0.85; }
.demo-btn:disabled { opacity: 0.4; cursor: default; }
.demo-btn:active { transform: scale(0.98); }
.demo-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  resize: vertical;
  margin-bottom: 0.7rem;
}
.demo-result {
  margin-top: 0.8rem;
  min-height: 40px;
}
.demo-output {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.7rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text);
  line-height: 1.6;
}
.demo-output strong { color: var(--gold-bright); }
.demo-warn {
  background: oklch(0.58 0.22 25 / 0.12);
  border: 1px solid oklch(0.58 0.22 25 / 0.35);
  border-radius: var(--radius-sm);
  padding: 0.6rem;
  font-size: 0.82rem;
  color: var(--danger);
  margin-bottom: 0.6rem;
}
.demo-loading {
  text-align: center;
  color: var(--text-dim);
  padding: 2rem;
}
.demo-error {
  color: var(--danger);
  font-size: 0.85rem;
  padding: 0.5rem;
}
.demo-concept {
  padding: 1rem 0;
}
.demo-concept p {
  color: var(--text-dim);
  opacity: 0.7;
}
.demo-output table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
}
.demo-output th, .demo-output td {
  border: 1px solid var(--border);
  padding: 0.35rem 0.5rem;
  font-size: 0.78rem;
  text-align: left;
}
.demo-output th { color: var(--gold-bright); }

/* Footer */
footer {
  text-align: center;
  padding: 2rem;
  font-size: 0.78rem;
  color: var(--text-dim);
  opacity: 0.4;
  border-top: 1px solid var(--grid);
}

@media (max-width: 640px) {
  .hero h1 { font-size: 1.8rem; }
  .gallery-grid { grid-template-columns: 1fr; }
  .stats-bar { gap: 1rem; }
}

@media (max-width: 380px) {
  .hero { padding: 2rem 0.75rem 1.25rem; }
  .hero h1 { font-size: 1.5rem; }
  .subtitle { font-size: 0.8rem; }
  .nav { gap: 0.5rem; }
  .nav a { font-size: 0.72rem; padding: 0.25rem 0.5rem; }
  .stats-bar { gap: 0.75rem; padding: 0.75rem 1rem; }
  .uc-search {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.8rem;
  font-size: 0.85rem;
  min-width: 240px;
}
.uc-search:focus { outline: 2px solid var(--gold); outline-offset: 2px; }
.sim-controls-row { display: flex; gap: 0.8rem; align-items: center; flex-wrap: wrap; margin: 0.8rem 0; font-size: 0.85rem; }
.sim-controls-row input[type=range] { accent-color: var(--gold); }
.sim-canvas { width: 100%; border-radius: var(--radius-sm); border: 1px solid var(--border); background: #070d10; display: block; margin: 0.6rem 0; } font-size: 1.3rem; }
  .filter-bar { gap: 0.3rem; padding: 0 0.75rem 0.75rem; }
  .filter-btn { padding: 0.3rem 0.5rem; font-size: 0.72rem; min-height: 48px; }
  main { padding: 0 0.75rem 2rem; }
  .gallery-grid { grid-template-columns: 1fr; gap: 0.6rem; }
  .uc-card { padding: 0.85rem; gap: 0.4rem; }
  .uc-title { font-size: 0.95rem; }
  .uc-action { min-height: 48px; }
  .modal-content { padding: 1.25rem; width: 94%; }
}

/* =====================================================================
   ZENITH ELEVATION · specular flash · tab depth · grid background
   ===================================================================== */

/* Subtle oscilloscope grid behind the gallery. */
body {
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    radial-gradient(1200px 700px at 80% -10%, oklch(0.68 0.15 255 / 0.10), transparent 60%),
    radial-gradient(900px 600px at -10% 110%, oklch(0.52 0.12 255 / 0.08), transparent 55%);
  background-size: 40px 40px, 40px 40px, auto, auto;
  background-position: 0 0, 0 0, 0 0, 0 0;
  background-color: var(--bg);
}

/* Card hover lift with specular border flash. */
.uc-card {
  position: relative;
  border-top-color: oklch(0.97 0.02 255 / 0.12);
  transition: transform 0.2s var(--ease-out), border-color 0.2s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.uc-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
  border-top-color: oklch(0.97 0.02 255 / 0.28);
  box-shadow: 0 2px 4px oklch(0.05 0.01 255 / 0.25), 0 16px 44px oklch(0.05 0.01 255 / 0.5), 0 0 0 1px oklch(0.68 0.15 255 / 0.12), 0 0 32px oklch(0.68 0.15 255 / 0.08), inset 0 1px 0 oklch(0.97 0.02 255 / 0.14);
}

/* Specular top flash sweep on hover. */
.uc-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, oklch(0.97 0.02 255 / 0.5), transparent);
  opacity: 0;
  transition: opacity 0.25s var(--ease-out);
  pointer-events: none;
}
.uc-card:hover::before {
  opacity: 1;
}

/* Category tab depth. */
.filter-btn {
  box-shadow: inset 0 1px 0 oklch(0.95 0.02 255 / 0.06), 0 1px 2px oklch(0.05 0.01 255 / 0.2);
  transition: all 0.15s cubic-bezier(0.22, 1, 0.36, 1);
}
.filter-btn:hover {
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 oklch(0.95 0.02 255 / 0.08), 0 4px 12px oklch(0.05 0.01 255 / 0.3);
}
.filter-btn.active {
  box-shadow: inset 0 1px 0 oklch(0.95 0.02 255 / 0.1), 0 0 0 1px oklch(0.68 0.15 255 / 0.25), 0 4px 16px oklch(0.68 0.15 255 / 0.15);
}

/* Zenith brand layer (session 15): gold hairline under the hero header. */
.hero {
  position: relative;
}
.hero::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent 3%, oklch(0.74 0.10 75 / 0.45) 50%, transparent 97%);
  pointer-events: none;
}
.brand-mark-img {
  filter: drop-shadow(0 0 14px oklch(0.74 0.10 75 / 0.28));
}
