/* ============================================================
   Orbit Studio — shared chrome + components
   Pairs with colors_and_type.css. Used by every template.
   ============================================================ */

/* ---------- Screen wrapper ---------- */
.orbit-screen {
  position: relative;
  overflow: hidden;
  background: var(--orbit-bg);
  color: var(--orbit-text-1);
  font-family: var(--orbit-font-sans);
}
.orbit-screen.r-1920 { width: 1920px; height: 1080px; }
.orbit-screen.r-1280 { width: 1280px; height:  720px; }

/* ---------- Background layers ---------- */
.bg-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--orbit-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--orbit-border) 1px, transparent 1px);
  background-size: 80px 80px;
  opacity: 0.18;
}
.bg-glow-tr {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(45% 55% at 88% 8%, rgba(232,131,42,0.22), transparent 60%);
}
.bg-glow-bl {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(40% 50% at 8% 92%, rgba(0,188,212,0.14), transparent 60%);
}
.bg-grain {
  position: absolute; inset: 0; pointer-events: none;
  opacity: 0.05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ---------- Wordmark ---------- */
.wordmark { display: inline-flex; align-items: center; gap: 14px;
  font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-white); }
.wordmark__sq { width: 18px; height: 18px; background: var(--orbit-orange); display: inline-block; }
.wordmark__name { font-size: 22px; }
.wordmark__name span { color: var(--orbit-text-3); margin-left: 10px; font-weight: 600; }

/* ---------- Numbered eyebrow ---------- */
.eyebrow-num { display: inline-flex; align-items: center; gap: 18px;
  font-family: var(--orbit-font-mono); font-size: 14px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-text-3); }
.eyebrow-num__n { background: var(--orbit-orange); color: var(--orbit-bg);
  font-family: var(--orbit-font-sans); font-weight: 800;
  width: 44px; height: 44px; display: inline-grid; place-items: center;
  font-size: 16px; letter-spacing: 0.04em; }
.eyebrow-num__bar { flex: 1; height: 1px; background: var(--orbit-border-strong); min-width: 80px; }

/* ---------- Live indicator ---------- */
.live { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px;
  background: rgba(45,190,96,0.12); border: 1px solid rgba(45,190,96,0.4);
  font-family: var(--orbit-font-mono); font-size: 12px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-green); }
.live__dot { width: 8px; height: 8px; background: var(--orbit-green);
  animation: orbit-blink 1.5s ease-in-out infinite; }
@keyframes orbit-blink { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* ---------- Mono label ---------- */
.mono { font-family: var(--orbit-font-mono); font-size: 14px;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--orbit-text-3); }

/* ---------- Image placeholder ---------- */
.ph {
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.03) 0 14px, rgba(255,255,255,0.06) 14px 28px),
    var(--orbit-bg-surface);
  border: 1px solid var(--orbit-border-strong);
  display: grid; place-items: center;
  font-family: var(--orbit-font-mono); font-size: 12px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-text-3);
  position: relative;
}
/* Display text comes from data-label (human-readable). data-placeholder
   stays snake_case as the machine-readable identifier. */
.ph::after { content: attr(data-label); }
.ph.ph--borderless { border: none; }

/* ---------- Orbit ring signature ---------- */
.orbit-ring { position: relative; aspect-ratio: 1/1; display: grid; place-items: center; }
.orbit-ring svg { width: 100%; height: 100%; display: block; }
.orbit-ring .ring { fill: none; stroke-dasharray: 4 6; }
.orbit-ring .ring.o { stroke: var(--orbit-orange); animation: orbit-spin 24s linear infinite; transform-origin: 50% 50%; }
.orbit-ring .ring.c { stroke: var(--orbit-cyan); animation: orbit-spin 18s linear infinite reverse; transform-origin: 50% 50%; }
.orbit-ring .ring.g { stroke: var(--orbit-green); animation: orbit-spin 36s linear infinite; transform-origin: 50% 50%; }
@keyframes orbit-spin { to { transform: rotate(360deg); } }

/* ---------- Waveform ---------- */
.orbit-wave { display: inline-flex; align-items: end; gap: 3px; height: 28px; }
.orbit-wave i { width: 3px; background: var(--orbit-orange); display: inline-block;
  animation: orbit-wv 1.2s ease-in-out infinite; }
.orbit-wave i:nth-child(2) { animation-delay: .1s; }
.orbit-wave i:nth-child(3) { animation-delay: .2s; }
.orbit-wave i:nth-child(4) { animation-delay: .3s; }
.orbit-wave i:nth-child(5) { animation-delay: .4s; }
.orbit-wave i:nth-child(6) { animation-delay: .5s; }
.orbit-wave i:nth-child(7) { animation-delay: .6s; }
@keyframes orbit-wv { 0%,100% { height: 8px; } 50% { height: 28px; } }

/* ============================================================
   Reusable composites — scene chrome, subtitle bar, tile, cards
   ============================================================ */

/* ---------- Top / bottom bar (scenes) ---------- */
.chrome-top, .chrome-bottom {
  position: absolute; left: 0; right: 0;
  background: rgba(15,15,18,0.7); backdrop-filter: blur(12px);
  display: flex; align-items: center; padding: 0 48px; gap: 32px;
  z-index: 5;
}
.chrome-top { top: 0; height: 72px; border-bottom: 1px solid var(--orbit-border); }
.chrome-bottom {
  bottom: 0; height: 56px; border-top: 1px solid var(--orbit-border);
  gap: 24px;
  font-family: var(--orbit-font-mono); font-size: 12px;
  letter-spacing: 0.18em; color: var(--orbit-text-3); text-transform: uppercase;
}
.chrome-top__sep { width: 1px; height: 24px; background: var(--orbit-border); }

/* ---------- Subtitle bar (scene caption) ---------- */
.subtitle-bar {
  background: rgba(15,15,18,0.78); border: 1px solid var(--orbit-border-strong);
  backdrop-filter: blur(8px); padding: 20px 28px;
  display: grid; grid-template-columns: auto 1fr auto;
  gap: 28px; align-items: center;
}
.subtitle-bar__speaker { display: flex; align-items: center; gap: 14px; }
.subtitle-bar__speaker .dot { width: 8px; height: 8px; background: var(--orbit-orange); }
.subtitle-bar__name { font-size: 18px; font-weight: 700; color: var(--orbit-white); }
.subtitle-bar__role { font-family: var(--orbit-font-mono); font-size: 12px;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--orbit-text-3); }
.subtitle-bar__text { margin: 0; font-size: 22px; color: var(--orbit-text-1); line-height: 1.4; }

/* ---------- Participant tile ---------- */
.tile {
  position: relative; overflow: hidden;
  background: var(--orbit-bg-raised);
  border: 1px solid var(--orbit-border-strong);
  box-shadow: var(--sh-panel);
  width: 100%; height: 100%;
}
.tile[data-active] {
  border-color: var(--orbit-orange);
  box-shadow: 0 0 0 1px var(--orbit-orange), var(--sh-panel);
}
.tile__feed {
  position: absolute; inset: 0; border: none;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.03) 0 14px, rgba(255,255,255,0.06) 14px 28px),
    var(--orbit-bg-surface);
  display: grid; place-items: center;
  font-family: var(--orbit-font-mono); font-size: 12px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-text-3);
}
.tile__feed::after { content: attr(data-label); }
/* Active brackets */
.tile[data-active]::before,
.tile[data-active]::after {
  content: ""; position: absolute; width: 20px; height: 20px; z-index: 2;
}
.tile[data-active]::before { top: 14px; left: 14px;
  border-top: 2px solid var(--orbit-orange); border-left: 2px solid var(--orbit-orange); }
.tile[data-active]::after { bottom: 14px; right: 14px;
  border-bottom: 2px solid var(--orbit-orange); border-right: 2px solid var(--orbit-orange); }
.tile[data-active] .tile__br-tr,
.tile[data-active] .tile__br-bl { position: absolute; width: 20px; height: 20px; z-index: 2; }
.tile[data-active] .tile__br-tr { top: 14px; right: 14px;
  border-top: 2px solid var(--orbit-orange); border-right: 2px solid var(--orbit-orange); }
.tile[data-active] .tile__br-bl { bottom: 14px; left: 14px;
  border-bottom: 2px solid var(--orbit-orange); border-left: 2px solid var(--orbit-orange); }

.tile__nametag {
  position: absolute; bottom: 12px; left: 12px; right: 12px; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.tile__name-box {
  background: rgba(15,15,18,0.85); border: 1px solid var(--orbit-border-strong);
  padding: 8px 12px; display: flex; align-items: center; gap: 10px;
}
.tile__name { font-size: 14px; font-weight: 700; color: var(--orbit-white); }
.tile__role { font-family: var(--orbit-font-mono); font-size: 10px;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--orbit-text-3); }
.tile__status {
  background: rgba(15,15,18,0.85); border: 1px solid var(--orbit-border-strong);
  padding: 8px 10px;
  font-family: var(--orbit-font-mono); font-size: 10px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--orbit-green);
}
.tile[data-muted] .tile__status { color: var(--orbit-red); }
.tile[data-muted] .tile__status::before { content: "MUTED"; }
.tile:not([data-muted]) .tile__status::before { content: "LIVE"; }

/* ---------- Card variants ---------- */
.card {
  background: var(--orbit-bg-raised);
  border: 1px solid var(--orbit-border-strong);
  box-shadow: var(--sh-panel);
}

/* ---------- Utility positioning helpers ---------- */
.screen-bar-top {
  position: absolute; top: 64px; left: 96px; right: 96px;
  display: flex; justify-content: space-between; align-items: center;
}
.screen-bar-bottom {
  position: absolute; bottom: 64px; left: 96px; right: 96px;
  display: flex; justify-content: space-between; align-items: center;
}
.screen-center {
  position: absolute; left: 96px; right: 96px; top: 50%;
  transform: translateY(-50%);
}
