:root {
  --cs-ink: #071425;
  --cs-muted: rgba(255, 255, 255, 0.72);
  --cs-line: rgba(255, 255, 255, 0.18);
  --cs-panel: rgba(255, 255, 255, 0.10);
  --cs-panel-strong: rgba(255, 255, 255, 0.92);
  --cs-blue: #1e90ff;
  --cs-cyan: #00bfff;
  --cs-green: #28a745;
  --cs-warn: #ffb84d;
  --cs-error: #ff5f6d;
  --cs-neutral: #8a9bad;
}

.cs-shell,
.cs-shell * { box-sizing: border-box; }

.cs-shell {
  position: relative;
  width: min(1180px, 100%);
  min-height: min(920px, 100vh);
  margin: 0 auto;
  padding: 24px 18px 42px;
  overflow: hidden;
  max-width: 100%;
  color: #fff;
  font-family: Inter, Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(180deg, rgba(8, 20, 40, 0.52), rgba(3, 8, 18, 0.78)),
    radial-gradient(circle at 24% 16%, rgba(0, 191, 255, 0.20), transparent 34%),
    linear-gradient(135deg, #0b2542 0%, #0d5f9a 46%, #06101e 100%);
  border-radius: 0;
  isolation: isolate;
}

.cs-shell [hidden],
.cs-ticket-shell [hidden] {
  display: none !important;
}

.cs-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.10), transparent 28%),
    url("../images/sky-field-placeholder.svg") center / cover no-repeat;
  opacity: 0.18;
  transform: scale(1.02);
}

.cs-shell__header {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: flex-start;
  margin-bottom: 20px;
}

.cs-shell__header h2 {
  max-width: 760px;
  margin: 0 0 10px;
  font-size: clamp(2.3rem, 6vw, 4.8rem);
  font-weight: 800;
  line-height: 0.98;
}

.cs-shell__eyebrow {
  margin: 0 0 10px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.cs-shell__lead,
.cs-panel p {
  max-width: 560px;
  margin: 0;
  color: var(--cs-muted);
  font-size: 1rem;
  line-height: 1.55;
}

.cs-shell__field-note {
  margin: 6px 0 0;
  color: var(--cs-muted);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

.cs-shell__header-tools {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  max-width: 100%;
  min-width: 0;
  flex: 0 0 auto;
}

.cs-admin-badge-rail {
  display: flex;
  gap: 8px;
  margin: -10px 0 18px;
  padding-bottom: 2px;
  overflow-x: auto;
  scrollbar-width: thin;
  max-width: 100%;
  min-width: 0;
  overscroll-behavior-inline: contain;
}

.cs-shell[data-cs-admin-view="false"] .cs-admin-badge-rail { display: none; }

.cs-admin-chip {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 6px;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(3, 8, 18, 0.34);
  color: var(--cs-muted);
  font-size: 0.7rem;
  backdrop-filter: blur(14px);
}

.cs-admin-chip strong { color: #fff; font-weight: 900; }
.cs-admin-chip--primary {
  border-color: rgba(255, 211, 93, 0.45);
  background: rgba(255, 211, 93, 0.14);
  color: #fff;
  font-weight: 900;
  text-transform: uppercase;
}
.cs-admin-chip[data-state="warning"] { border-color: rgba(255, 184, 77, 0.55); background: rgba(255, 184, 77, 0.15); }

.cs-session-progress {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  max-width: 100%;
  min-width: 0;
}

.cs-session-progress li {
  position: relative;
  min-width: 0;
  padding: 9px 8px;
  border: 1px solid var(--cs-line);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.72rem;
  font-weight: 800;
  text-align: center;
  transition: opacity 180ms ease, background 180ms ease, border-color 180ms ease;
}

.cs-session-progress li span { overflow-wrap: anywhere; }

.cs-session-progress li[data-state="active"] {
  border-color: rgba(0, 191, 255, 0.8);
  background: rgba(0, 191, 255, 0.18);
  color: #fff;
}

.cs-session-progress li[data-state="completed"] {
  border-color: rgba(70, 220, 150, 0.48);
  background: rgba(50, 200, 130, 0.14);
  color: rgba(255, 255, 255, 0.88);
}

.cs-session-progress li[data-state="completed"] span::before { content: "✓ "; color: #58e6a6; }

.cs-session-authorized-summary {
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.cs-session-authorized-summary > div { display: grid; gap: 3px; min-width: 0; }
.cs-session-authorized-summary span { color: var(--cs-muted); font-size: 0.78rem; overflow-wrap: anywhere; }
.cs-session-authorized-summary .cs-state-mark { color: #58e6a6; font-weight: 800; white-space: nowrap; }

.cs-shell[data-cs-authorized="true"] [data-cs-session-form] { display: none; }
.cs-shell[data-cs-authorized="true"] .cs-session-authorized-summary { display: flex !important; }

.cs-shell__badge,
.cs-admin-toggle {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 8px 12px;
  border: 1px solid var(--cs-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
  backdrop-filter: blur(14px);
}

.cs-admin-toggle { gap: 8px; cursor: pointer; }
.cs-admin-toggle input { accent-color: var(--cs-cyan); }

.cs-shell__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(290px, 0.48fr);
  gap: 18px;
  align-items: start;
}

.cs-shell[data-cs-admin-view="false"] .cs-shell__layout {
  grid-template-columns: minmax(0, 1fr);
}

.cs-shell__main,
.cs-shell__sidebar {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.cs-shell__layout,
.cs-shell__main,
.cs-shell__sidebar,
.cs-panel,
.cs-panel__heading,
.cs-media-stage {
  max-width: 100%;
  min-width: 0;
}

.cs-shell__sidebar {
  position: sticky;
  top: 18px;
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  padding-right: 3px;
  scrollbar-width: thin;
}

.cs-shell [hidden] { display: none !important; }

.cs-panel {
  padding: 20px;
  border: 1px solid var(--cs-line);
  border-radius: 8px;
  background: var(--cs-panel);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.cs-panel--compact { padding: 16px; }
.cs-panel h3 {
  margin: 0 0 5px;
  color: #fff;
  font-size: 1.05rem;
  line-height: 1.2;
}

.cs-panel p {
  color: var(--cs-muted);
}

.cs-admin-section summary {
  cursor: pointer;
  color: #fff;
  font-size: 1rem;
  font-weight: 900;
  list-style-position: inside;
}

.cs-sidebar-title {
  margin: 2px 2px 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cs-rail-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.cs-rail-heading h3 { margin: 2px 0 0; }
.cs-rail-kicker {
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}
.cs-health__overall,
.cs-admin-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  color: var(--cs-muted);
  font-size: 0.65rem;
  font-weight: 900;
  white-space: nowrap;
}
.cs-health__overall[data-state="success"] { color: #75efb3; border-color: rgba(70, 220, 150, 0.4); }
.cs-health__overall[data-state="warning"] { color: #ffd08a; border-color: rgba(255, 184, 77, 0.44); }
.cs-health__overall[data-state="error"] { color: #ff9ba3; border-color: rgba(255, 95, 109, 0.44); }
.cs-health__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.cs-health__item {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 34px;
  padding: 7px 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.22);
  font-size: 0.72rem;
}
.cs-health__item i,
.cs-status-dot {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cs-neutral);
  box-shadow: 0 0 0 3px rgba(138, 155, 173, 0.11);
}
.cs-health__item span { color: rgba(255, 255, 255, 0.84); font-weight: 800; }
.cs-health__item strong { min-width: 0; max-width: 64px; color: var(--cs-muted); font-size: 0.65rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs-health__item[data-state="success"] i, .cs-status-dot[data-state="success"] { background: #46dc96; box-shadow: 0 0 0 3px rgba(70, 220, 150, 0.12); }
.cs-health__item[data-state="warning"] i, .cs-status-dot[data-state="warning"] { background: var(--cs-warn); box-shadow: 0 0 0 3px rgba(255, 184, 77, 0.12); }
.cs-health__item[data-state="error"] i, .cs-status-dot[data-state="error"] { background: var(--cs-error); box-shadow: 0 0 0 3px rgba(255, 95, 109, 0.12); }

.cs-control-stack { display: grid; gap: 7px; }
.cs-control-card { padding: 0; overflow: hidden; box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14); }
.cs-control-card > summary,
.cs-diagnostics > summary {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 10px;
  align-items: center;
  gap: 9px;
  min-height: 58px;
  padding: 10px 12px;
  list-style: none;
}
.cs-control-card > summary::-webkit-details-marker,
.cs-diagnostics > summary::-webkit-details-marker,
.cs-nested-section > summary::-webkit-details-marker,
.cs-console-section > summary::-webkit-details-marker { display: none; }
.cs-control-card > summary::after,
.cs-nested-section > summary::after,
.cs-console-section > summary::after {
  content: "+";
  color: rgba(255, 255, 255, 0.52);
  font-size: 1rem;
}
.cs-control-card[open] > summary::after,
.cs-nested-section[open] > summary::after,
.cs-console-section[open] > summary::after { content: "−"; }
.cs-control-card > summary .cs-status-dot { grid-column: 3; grid-row: 1; }
.cs-control-card > summary::after { grid-column: 3; grid-row: 1; opacity: 0; }
.cs-control-card[open] > summary .cs-status-dot { opacity: 0; }
.cs-control-card[open] > summary::after { opacity: 1; }
.cs-summary-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(0, 191, 255, 0.28);
  border-radius: 8px;
  background: rgba(0, 191, 255, 0.1);
  color: #bdeeff;
  font-size: 0.72rem;
  font-weight: 900;
}
.cs-summary-copy { display: grid; gap: 3px; min-width: 0; }
.cs-summary-copy strong { min-width: 0; color: #fff; font-size: 0.88rem; }
.cs-summary-copy small { color: var(--cs-muted); font-size: 0.66rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs-control-card > .cs-facts { margin: 0; padding: 0 12px 10px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.cs-control-card[open] > summary { margin-bottom: 0; background: rgba(255, 255, 255, 0.04); }
.cs-help { color: #8fdcff; cursor: help; font-size: 0.72rem; font-weight: 700; }

.cs-diagnostics { padding: 0; overflow: hidden; }
.cs-diagnostics > summary { grid-template-columns: 30px minmax(0, 1fr) auto; }
.cs-diagnostics > summary::after { content: "+"; grid-column: 3; grid-row: 1; color: rgba(255, 255, 255, 0.52); }
.cs-diagnostics[open] > summary::after { content: "−"; }
.cs-diagnostics > summary .cs-admin-tag { grid-column: 3; grid-row: 1; transition: opacity 120ms ease; }
.cs-diagnostics[open] > summary .cs-admin-tag { opacity: 0; }
.cs-diagnostics__body { display: grid; gap: 6px; padding: 0 10px 10px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.cs-nested-section { border-bottom: 1px solid rgba(255, 255, 255, 0.09); }
.cs-nested-section:last-child { border-bottom: 0; }
.cs-nested-section > summary,
.cs-console-section > summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 7px 4px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.76rem;
  font-weight: 850;
  cursor: pointer;
  list-style: none;
}
.cs-nested-section > summary::after,
.cs-console-section > summary::after { grid-column: 3; }
.cs-nested-section > .cs-admin-form,
.cs-nested-section > .cs-admin-placeholder,
.cs-nested-section > .cs-timeline { margin-left: 4px; margin-right: 4px; }
.cs-developer-console { padding-bottom: 6px; }
.cs-console-section { margin: 0 4px 5px; padding: 0 8px; border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 8px; background: rgba(3, 8, 18, 0.2); }
.cs-console-section > .cs-facts { margin-top: 0; padding-bottom: 6px; }

.cs-admin-section summary::-webkit-details-marker {
  color: rgba(255, 255, 255, 0.72);
}

.cs-admin-section[open] summary {
  margin-bottom: 10px;
}

.cs-admin-placeholder {
  margin-top: 10px !important;
  font-size: 0.88rem;
}

.cs-admin-form {
  display: grid;
  gap: 10px;
  margin: 10px 0 12px;
}

.cs-admin-form label {
  display: grid;
  gap: 5px;
}

.cs-admin-form label:has(input[type="checkbox"]) {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cs-admin-form span {
  color: var(--cs-muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.cs-admin-form input,
.cs-admin-form select {
  min-height: 36px;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font: inherit;
  padding: 6px 9px;
}

.cs-panel__heading {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  margin-bottom: 16px;
}

.cs-panel__step {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cs-blue), var(--cs-cyan));
  color: white;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(30, 144, 255, 0.24);
}

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

.cs-upload {
  display: grid;
  place-items: center;
  min-height: 92px;
  padding: 18px;
  border: 2px dashed rgba(0, 191, 255, 0.68);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  text-align: center;
  cursor: pointer;
  transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.cs-upload:hover {
  border-color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

.cs-upload strong { font-size: 1rem; }
.cs-upload span {
  margin-top: 5px;
  color: var(--cs-muted);
  font-size: 0.88rem;
  overflow-wrap: anywhere;
}

.cs-panel[data-cs-media-acquired="true"] .cs-upload {
  display: none;
}

.cs-panel[aria-disabled="true"] .cs-upload {
  cursor: not-allowed;
  opacity: 0.48;
  pointer-events: none;
}

.cs-media-ready {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding: 13px 14px;
  border: 1px solid rgba(70, 220, 150, 0.45);
  border-radius: 8px;
  background: rgba(50, 200, 130, 0.12);
}

.cs-media-ready strong::before {
  content: "✓ ";
  color: #58e6a6;
}

.cs-inline-button {
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  padding: 8px 10px;
}

.cs-media-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: clamp(270px, 48vw, 540px);
  margin-top: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.42);
  isolation: isolate;
}

.cs-media-stage > [data-cs-media-image],
.cs-media-stage > [data-cs-media-video] {
  display: block;
  position: relative;
  z-index: 1;
  width: 100%;
  max-height: 66vh;
  object-fit: contain;
  background: rgba(3, 8, 18, 0.62);
}

.cs-media-stage canvas {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 2;
  pointer-events: none;
}

.cs-video-grid-overlay {
  position: absolute;
  z-index: 2;
  overflow: hidden;
  border: 1px solid rgba(80, 170, 255, 0.46);
  background-image:
    linear-gradient(to right, rgba(80, 170, 255, 0.42) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(80, 170, 255, 0.42) 1px, transparent 1px),
    radial-gradient(circle at center, transparent 0 32%, rgba(80, 170, 255, 0.22) 32.4% 32.8%, transparent 33.2% 48%, rgba(80, 170, 255, 0.16) 48.4% 48.8%, transparent 49.2%);
  background-size: calc(100% / 6) 100%, 100% calc(100% / 6), 100% 100%;
  box-shadow: inset 0 0 28px rgba(30, 120, 255, 0.16), 0 0 20px rgba(30, 120, 255, 0.12);
  opacity: 0.72;
  pointer-events: none;
  touch-action: none;
}

.cs-shell[data-cs-engine-status="activation_running"] .cs-video-grid-overlay,
.cs-shell[data-cs-engine-status="field_active"] .cs-video-grid-overlay {
  opacity: 0.88;
}

.cs-v2-label-overlay {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  width: min(56%, 420px);
  max-width: calc(100% - 24px);
  aspect-ratio: 1 / 1;
  transform: translate(-50%, -50%) scale(0.94);
  pointer-events: none;
  display: none;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  opacity: 0;
  mix-blend-mode: multiply;
  touch-action: none;
  transition: opacity 220ms ease, transform 220ms ease;
}

.cs-v2-label-overlay.is-visible,
.cs-v2-label-overlay[data-active="true"] {
  display: flex;
  opacity: 0.58;
  transform: translate(-50%, -50%) scale(1);
}

.cs-v2-label-rotor {
  display: block;
  width: 100%;
  height: 100%;
  position: relative;
  transform-origin: 50% 50%;
  will-change: transform;
}

.cs-v2-label-overlay.is-rotating .cs-v2-label-rotor {
  animation: cs-v2-label-rotate 96s linear infinite;
}

.cs-v2-label-seal {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}

.cs-v2-label-visual {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.cs-v2-label-overlay img,
.cs-v2-label-overlay svg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cs-v2-label-overlay svg {
  overflow: visible;
}

.cs-v2-label-code {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  max-width: 68%;
  width: auto;
  padding: clamp(5px, 1.2vw, 9px) clamp(8px, 1.8vw, 14px);
  border: 1px solid rgba(30, 65, 110, 0.48);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  color: rgba(12, 32, 56, 0.82);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.48), 0 4px 18px rgba(30, 80, 140, 0.16);
  font-size: clamp(11px, 1.65vw, 14px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: translate(-50%, -50%);
}

.cs-v2-label-overlay[data-cs-label-source="canonical"] .cs-v2-label-code {
  opacity: 0.62;
}

.cs-v2-label-overlay[data-cs-label-source="fallback"] .cs-v2-label-code {
  opacity: 0.92;
}

@keyframes cs-v2-label-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.cs-shell[data-cs-engine-status="activation_running"] .cs-media-stage,
.cs-shell[data-cs-engine-status="field_active"] .cs-media-stage {
  animation: cs-shell-field-aura 2.6s ease-in-out infinite;
}

@keyframes cs-shell-field-aura {
  0%, 100% { box-shadow: 0 0 0 1px rgba(80, 140, 255, 0.18), 0 0 20px rgba(80, 140, 255, 0.22); }
  50% { box-shadow: 0 0 0 1px rgba(80, 210, 255, 0.30), 0 0 42px rgba(80, 210, 255, 0.30); }
}

.cs-media-stage__placeholder {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: white;
}

.cs-media-stage__placeholder img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cs-media-stage__placeholder span {
  position: relative;
  padding: 9px 13px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(8, 20, 40, 0.56);
  font-size: 0.84rem;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.cs-shell__actions {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1fr);
  gap: 10px;
}

.cs-panel[data-cs-region="run-controls"] .cs-shell__actions {
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
}

.cs-panel[data-cs-region="run-controls"] .cs-button--primary {
  width: 100%;
  justify-self: stretch;
}

.cs-ticket {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.cs-ticket span {
  color: var(--cs-muted);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.cs-ticket input {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.3;
  outline: none;
  padding: 0 14px;
}

.cs-ticket input::placeholder {
  color: rgba(234, 246, 255, 0.54);
}

.cs-ticket input:focus {
  border-color: rgba(255, 211, 93, 0.74);
  box-shadow: 0 0 0 3px rgba(255, 211, 93, 0.14);
}

.cs-ticket-help {
  margin-top: -4px !important;
  margin-bottom: 14px !important;
  color: var(--cs-muted);
  font-size: 0.88rem;
  font-family: inherit;
  line-height: 1.45;
}

.cs-ticket-help a {
  color: #fff;
  font-weight: 900;
}

.cs-ticket-shell {
  width: min(720px, 100%);
  margin: 0 auto;
}

.cs-ticket-result {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(255, 211, 93, 0.46);
  border-radius: 8px;
  background: rgba(255, 211, 93, 0.1);
}

.cs-ticket-result span {
  color: var(--cs-muted);
  font-size: 0.78rem;
  font-family: inherit;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.cs-ticket-result strong {
  color: #fff;
  font-family: "Courier New", Courier, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: clamp(1.45rem, 6vw, 2.4rem);
  overflow-wrap: anywhere;
}

.cs-ticket-verification,
.cs-ticket-verified {
  display: grid;
  gap: 12px;
  margin: 14px 0;
  padding: 14px;
  border: 1px solid rgba(0, 191, 255, 0.3);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.22);
}

.cs-ticket-verification > p { margin: 0; color: var(--cs-muted); }
.cs-ticket-verification .cs-ticket { margin: 0; }
.cs-ticket-verification .cs-button { width: 100%; }
.cs-ticket-verified {
  border-color: rgba(70, 220, 150, 0.45);
  background: rgba(50, 200, 130, 0.12);
}
.cs-ticket-verified strong { color: #dbffe6; }
.cs-ticket-verified span { color: var(--cs-muted); font-size: 0.88rem; }

.cs-button {
  min-height: 50px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, opacity 180ms ease;
}

.cs-button:hover:not(:disabled) { transform: translateY(-1px); }
.cs-button--primary {
  background: linear-gradient(135deg, #0b4ea2, #1e90ff);
  color: white;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  box-shadow: 0 16px 34px rgba(11, 78, 162, 0.38);
}

.cs-button--primary:disabled {
  opacity: 0.54;
  cursor: not-allowed;
  box-shadow: none;
}

.cs-button--secondary {
  background: rgba(255, 255, 255, 0.12);
  color: white;
}

.cs-shell__status {
  margin-top: 12px !important;
  padding: 11px 13px;
  border: 1px solid rgba(40, 167, 69, 0.34);
  border-radius: 8px;
  background: rgba(40, 167, 69, 0.14);
  color: #dbffe6 !important;
}

.cs-runner-contract,
.cs-result-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.cs-runner-contract div,
.cs-result-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.10);
}

.cs-runner-contract span,
.cs-result-card span,
.cs-runner-contract strong,
.cs-result-card strong { display: block; }

.cs-runner-contract span,
.cs-result-card span {
  color: var(--cs-muted);
  font-size: 0.76rem;
  font-weight: 800;
}

.cs-runner-contract strong,
.cs-result-card strong {
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.cs-result-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cs-result-card { background: var(--cs-panel-strong); color: var(--cs-ink); }
.cs-result-card span { color: rgba(7, 20, 37, 0.62); }
.cs-result-card strong { font-size: 1.08rem; }

.cs-run-timer {
  display: grid;
  gap: 6px;
  justify-items: center;
  margin: 4px 0 12px;
  padding: 16px;
  border: 1px solid rgba(0, 191, 255, 0.30);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.26);
}

.cs-run-timer span {
  color: var(--cs-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.cs-run-timer strong {
  color: #fff;
  font-family: Inter, Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(2.25rem, 8vw, 4.25rem);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1;
  text-shadow: 0 0 18px rgba(0, 191, 255, 0.28);
}

.cs-session-complete {
  display: grid;
  justify-items: center;
  gap: 10px;
  min-height: 430px;
  padding: clamp(28px, 6vw, 64px);
  text-align: center;
  background:
    radial-gradient(circle at 50% 18%, rgba(70, 220, 150, 0.18), transparent 34%),
    rgba(255, 255, 255, 0.1);
}
.cs-session-complete__mark {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border: 1px solid rgba(70, 220, 150, 0.55);
  border-radius: 50%;
  background: rgba(50, 200, 130, 0.14);
  color: #75efb3;
  font-size: 1.65rem;
  box-shadow: 0 0 30px rgba(70, 220, 150, 0.14);
}
.cs-session-complete h3 { margin: 2px 0 0; font-size: clamp(1.7rem, 5vw, 2.6rem); }
.cs-session-complete > p:not(.cs-shell__eyebrow) { max-width: 440px; }
.cs-session-complete__field {
  display: grid;
  gap: 5px;
  width: min(320px, 100%);
  margin: 10px 0;
  padding: 18px;
  border: 1px solid rgba(0, 191, 255, 0.3);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.28);
}
.cs-session-complete__field span { color: var(--cs-muted); font-size: 0.78rem; font-weight: 800; }
.cs-session-complete__field strong {
  color: #fff;
  font-size: clamp(2rem, 8vw, 3.25rem);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.035em;
}
.cs-session-complete__actions { display: grid; justify-items: center; gap: 9px; width: min(320px, 100%); }
.cs-session-complete__actions .cs-button { width: 100%; text-decoration: none; }
.cs-session-complete__actions span { color: var(--cs-muted); font-size: 0.76rem; }
.cs-session-complete__actions > a:not(.cs-button) { color: #fff; font-size: 0.88rem; font-weight: 800; }
.cs-session-complete[data-cs-completion-state="expired"] .cs-session-complete__field { border-color: rgba(255, 255, 255, 0.2); }

.cs-shell[data-cs-completion-state="active"] .cs-shell__main > [data-cs-region="controls"],
.cs-shell[data-cs-completion-state="active"] .cs-shell__main > [data-cs-region="media-input"],
.cs-shell[data-cs-completion-state="active"] .cs-shell__main > [data-cs-region="run-controls"],
.cs-shell[data-cs-completion-state="active"] .cs-shell__main > [data-cs-region="runner"],
.cs-shell[data-cs-completion-state="active"] .cs-shell__main > [data-cs-region="analysis-output"],
.cs-shell[data-cs-completion-state="expired"] .cs-shell__main > [data-cs-region="controls"],
.cs-shell[data-cs-completion-state="expired"] .cs-shell__main > [data-cs-region="media-input"],
.cs-shell[data-cs-completion-state="expired"] .cs-shell__main > [data-cs-region="run-controls"],
.cs-shell[data-cs-completion-state="expired"] .cs-shell__main > [data-cs-region="runner"],
.cs-shell[data-cs-completion-state="expired"] .cs-shell__main > [data-cs-region="analysis-output"] {
  display: none;
}

.cs-progress {
  height: 8px;
  margin-top: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.cs-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--cs-cyan), var(--cs-blue));
  transition: width 420ms ease;
}

.cs-facts { margin: 10px 0 0; }
.cs-facts div {
  display: grid;
  grid-template-columns: minmax(96px, 0.9fr) minmax(0, 1.1fr);
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.cs-facts div:last-child { border-bottom: 0; }
.cs-facts dt { color: rgba(255, 255, 255, 0.82); font-weight: 800; }
.cs-facts dd { margin: 0; color: var(--cs-muted); text-align: right; overflow-wrap: anywhere; }

.cs-timeline {
  max-height: 230px;
  margin: 12px 0 0;
  padding-left: 20px;
  overflow: auto;
  color: var(--cs-muted);
  font-size: 0.86rem;
}
.cs-timeline li + li { margin-top: 6px; }

.cs-shell__debug {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 0 0 8px;
  padding: 12px 14px;
  border: 1px dashed rgba(255, 255, 255, 0.26);
  border-radius: 8px;
  background: rgba(3, 8, 18, 0.38);
  color: var(--cs-muted);
  font-size: 0.76rem;
}

.cs-shell__debug code { overflow-wrap: anywhere; }
.cs-shell[data-cs-engine-status="ready"] [data-cs-engine-badge],
.cs-shell[data-cs-engine-status="field_active"] [data-cs-engine-badge] {
  border-color: rgba(40, 167, 69, 0.44);
  background: rgba(40, 167, 69, 0.18);
}

@media (max-width: 980px) {
  .cs-shell__layout { grid-template-columns: 1fr; }
  .cs-shell__sidebar { position: static; max-height: none; overflow: visible; padding-right: 0; }
  .cs-result-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .cs-shell {
    min-height: 100vh;
    padding: 18px 12px 30px;
  }

  .cs-shell__header {
    display: grid;
    gap: 16px;
  }

  .cs-shell__header-tools {
    width: 100%;
    justify-content: flex-end;
    justify-items: end;
  }

  .cs-admin-badge-rail { margin-top: -4px; }

  .cs-session-progress {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    width: 100%;
    overflow: hidden;
    padding-bottom: 0;
  }

  .cs-session-progress li {
    min-width: 0;
    padding: 8px 3px;
    border-radius: 12px;
    font-size: clamp(0.55rem, 2.45vw, 0.66rem);
    line-height: 1.15;
    white-space: normal;
  }

  .cs-session-progress li span {
    display: block;
    min-width: 0;
    text-align: center;
    overflow-wrap: anywhere;
  }

  .cs-panel {
    padding: 16px;
  }

  .cs-shell__actions,
  .cs-runner-contract,
  .cs-result-grid {
    grid-template-columns: 1fr;
  }

  .cs-panel[data-cs-region="run-controls"] .cs-shell__actions {
    display: flex;
    justify-content: center;
    width: 100%;
  }

  .cs-panel[data-cs-region="run-controls"] .cs-button--primary {
    width: 100%;
    min-height: 54px;
    margin: 0 auto;
  }

  .cs-run-timer strong {
    font-size: clamp(2.15rem, 14vw, 3.35rem);
  }

  .cs-media-stage {
    min-height: 310px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cs-shell *,
  .cs-shell::before {
    animation: none !important;
    transition: none !important;
  }
}

/* =========================================================
   PC1-018 — Graphic Design System integration
   Presentation-only overrides. Functional hooks are unchanged.
   ========================================================= */
:root {
  --cs-ink: #081428;
  --cs-muted: rgba(255, 255, 255, 0.74);
  --cs-line: rgba(255, 255, 255, 0.20);
  --cs-panel: rgba(255, 255, 255, 0.10);
  --cs-blue: #1e90ff;
  --cs-cyan: #00bfff;
}

.cs-shell {
  width: min(1400px, 100%);
  min-height: 100svh;
  padding: clamp(22px, 4vw, 56px);
  background:
    radial-gradient(circle at 78% 16%, rgba(0, 191, 255, 0.24), transparent 28%),
    radial-gradient(circle at 18% 38%, rgba(30, 144, 255, 0.22), transparent 38%),
    linear-gradient(145deg, rgba(10, 20, 40, 0.72), rgba(16, 62, 104, 0.62) 48%, rgba(3, 8, 18, 0.88)),
    url("../images/sky-field-placeholder.svg") center / cover no-repeat;
}

.cs-shell::before {
  background:
    linear-gradient(180deg, rgba(255,255,255,.08), transparent 26%),
    linear-gradient(90deg, rgba(8,20,40,.22), transparent 58%, rgba(8,20,40,.28));
  opacity: 1;
}

.cs-shell__header {
  position: relative;
  align-items: center;
  min-height: 220px;
  margin-bottom: 28px;
  padding: clamp(22px, 4vw, 46px);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 24px;
  background: linear-gradient(120deg, rgba(7,20,39,.48), rgba(255,255,255,.07));
  box-shadow: 0 24px 70px rgba(0,0,0,.28);
  backdrop-filter: blur(18px);
}

.cs-shell__header > div:first-child { position: relative; z-index: 2; }
.cs-shell__header h2 { font-size: clamp(3rem, 8vw, 6.5rem); letter-spacing: -.05em; text-shadow: 0 8px 30px rgba(0,0,0,.28); }
.cs-shell__header h2 span,
.cs-ticket-hero h1 span { color: var(--cs-cyan); }
.cs-shell__lead { font-size: clamp(1rem, 2vw, 1.2rem); }

.cs-sky-orb {
  position: absolute;
  right: clamp(130px, 19vw, 265px);
  width: clamp(130px, 19vw, 230px);
  aspect-ratio: 1;
  border: 1px solid rgba(0,191,255,.48);
  border-radius: 50%;
  box-shadow: 0 0 70px rgba(0,191,255,.18), inset 0 0 55px rgba(30,144,255,.1);
  opacity: .82;
}
.cs-sky-orb i { position: absolute; inset: 13%; border: 1px solid rgba(255,255,255,.28); border-radius: 50%; animation: cs-orbit 22s linear infinite; }
.cs-sky-orb i:nth-child(2) { inset: 28%; border-color: rgba(0,191,255,.58); animation-direction: reverse; animation-duration: 16s; }
.cs-sky-orb i:nth-child(3) { inset: 43%; border-color: rgba(50,205,50,.5); animation-duration: 10s; }
.cs-sky-orb b { position:absolute; inset:0; display:grid; place-items:center; font-size:clamp(.8rem,2vw,1.25rem); letter-spacing:.12em; }
@keyframes cs-orbit { to { transform: rotate(360deg); } }

.cs-session-progress { gap: 0; margin-bottom: 26px; }
.cs-session-progress li { border: 0; border-radius: 0; background: transparent; font-size: .75rem; }
.cs-session-progress li::before { content: ""; position: absolute; top: 0; left: 50%; width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.26); border-radius: 50%; background: #10233c; transform: translate(-50%,-35%); box-shadow: 0 0 0 5px rgba(255,255,255,.04); }
.cs-session-progress li:not(:last-child)::after { content:""; position:absolute; top:1px; left:calc(50% + 9px); width:calc(100% - 18px); height:2px; background:rgba(255,255,255,.2); }
.cs-session-progress li span { display:block; padding-top:15px; }
.cs-session-progress li[data-state="active"] { color:#fff; background:transparent; }
.cs-session-progress li[data-state="active"]::before { border-color:var(--cs-cyan); background:var(--cs-blue); box-shadow:0 0 22px rgba(30,144,255,.8); }
.cs-session-progress li[data-state="completed"] { color:rgba(255,255,255,.88); background:transparent; }
.cs-session-progress li[data-state="completed"]::before { border-color:#32cd32; background:#32cd32; }
[data-cs-app][data-cs-session-phase="cooldown"] .cs-session-progress li[data-cs-progress-step="field"][data-state="active"]::before { border-color:#32cd32; background:#32cd32; box-shadow:0 0 22px rgba(50,205,50,.55); }

.cs-panel {
  padding: clamp(18px, 3vw, 30px);
  border-radius: 18px;
  background: rgba(255,255,255,.095);
  box-shadow: 0 20px 55px rgba(0,0,0,.24), inset 0 1px rgba(255,255,255,.08);
  backdrop-filter: blur(20px) saturate(125%);
  transition: transform .3s ease, border-color .3s ease, background .3s ease, box-shadow .3s ease;
}
.cs-panel:hover { border-color:rgba(0,191,255,.34); background:rgba(255,255,255,.12); box-shadow:0 22px 60px rgba(0,0,0,.25), 0 0 34px rgba(0,191,255,.08); }
.cs-panel__step { width:40px; height:40px; border-radius:12px; font-size:1rem; box-shadow:0 9px 24px rgba(30,144,255,.38); }
.cs-panel__heading { grid-template-columns:40px minmax(0,1fr); gap:14px; }
.cs-panel h3 { font-size:1.15rem; }
.cs-upload { min-height:112px; border-width:1px; border-radius:14px; background:rgba(0,191,255,.06); }
.cs-media-stage { border-radius:16px; background:rgba(3,8,18,.5); box-shadow:inset 0 0 50px rgba(0,0,0,.22); }
.cs-ticket input, .cs-admin-form input, .cs-admin-form select { border-radius:12px; background:rgba(255,255,255,.09); }
.cs-ticket input:focus { border-color:var(--cs-cyan); box-shadow:0 0 0 3px rgba(0,191,255,.15); }

.cs-button { min-height:52px; border-radius:12px; }
.cs-button--primary { background:linear-gradient(135deg,#1e90ff,#00bfff); box-shadow:0 10px 28px rgba(30,144,255,.4); }
.cs-button--primary:hover:not(:disabled) { transform:translateY(-2px); box-shadow:0 15px 36px rgba(30,144,255,.56); }
.cs-button--secondary { background:rgba(255,255,255,.1); backdrop-filter:blur(12px); }
.cs-panel[data-cs-region="run-controls"] .cs-button--primary { min-height:64px; font-size:1.2rem; border-radius:16px; }
.cs-shell__status { border-radius:12px; backdrop-filter:blur(10px); }
.cs-run-timer, .cs-session-complete__field, .cs-ticket-result, .cs-ticket-verification, .cs-ticket-verified { border-radius:14px; }

.cs-v2-label-overlay { filter:drop-shadow(0 0 20px rgba(0,191,255,.22)); }
.cs-shell[data-cs-engine-status="activation_running"] .cs-v2-label-overlay,
.cs-shell[data-cs-engine-status="field_active"] .cs-v2-label-overlay { filter:drop-shadow(0 0 34px rgba(0,191,255,.34)); }

.cs-ticket-shell {
  width:100%; min-height:100svh; margin:0; padding:clamp(20px,5vw,70px);
  color:#fff; font-family:Inter,Poppins,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  background:
    linear-gradient(110deg,rgba(3,8,18,.86),rgba(8,38,72,.48)),
    url("../images/sky-field-placeholder.svg") center / cover fixed no-repeat;
}
.cs-ticket-hero { max-width:1100px; margin:0 auto 38px; padding:clamp(24px,5vw,58px) 0; }
.cs-ticket-hero h1 { margin:0; font-size:clamp(3.6rem,11vw,8rem); line-height:.9; letter-spacing:-.065em; }
.cs-ticket-hero > p:not(.cs-shell__eyebrow) { max-width:560px; margin:28px 0; color:rgba(255,255,255,.82); font-size:clamp(1rem,2vw,1.2rem); line-height:1.65; }
.cs-live-dot { display:inline-block; width:8px; height:8px; margin-right:5px; border-radius:50%; background:#32cd32; box-shadow:0 0 16px rgba(50,205,50,.8); }
.cs-ticket-existing { display:inline-flex; gap:10px; align-items:center; color:#fff; font-weight:700; text-decoration:none; }
.cs-ticket-existing:hover { color:var(--cs-cyan); }
.cs-ticket-shell > .cs-panel { width:min(720px,100%); margin:0 auto; }
.cs-ticket-footer { display:flex; justify-content:space-between; width:min(1100px,100%); margin:48px auto 0; padding-top:18px; border-top:1px solid rgba(255,255,255,.16); color:rgba(255,255,255,.55); font-size:.75rem; }

@media (max-width: 860px) {
  .cs-sky-orb { right: 110px; opacity:.34; }
  .cs-shell__header-tools { position:relative; z-index:3; }
}
@media (max-width: 640px) {
  .cs-shell { padding:14px 10px 28px; }
  .cs-shell__header { min-height:260px; padding:24px 18px; align-items:flex-start; }
  .cs-shell__header h2 { font-size:clamp(3.25rem,18vw,5.25rem); }
  .cs-sky-orb { right:-35px; bottom:-28px; width:180px; opacity:.36; }
  .cs-shell__header-tools { align-self:end; }
  .cs-session-progress li { padding-inline:1px; }
  .cs-session-progress li span { font-size:clamp(.5rem,2.35vw,.64rem); }
  .cs-panel { border-radius:16px; }
  .cs-media-stage { min-height:min(86vw,410px); }
  .cs-ticket-shell { padding:18px 14px 30px; }
  .cs-ticket-hero { padding:34px 4px 18px; }
  .cs-ticket-hero h1 { font-size:clamp(3.35rem,19vw,5.6rem); }
}

@media (prefers-reduced-motion: reduce) {
  .cs-sky-orb i { animation:none !important; }
}

/* =========================================================
   PC1-019 — Visual polish pass
   Uniform sizing, ticket hierarchy, alerts, RUN and timer.
   ========================================================= */
.cs-shell :is(input:not([type="checkbox"]), textarea, select),
.cs-ticket-shell :is(input:not([type="checkbox"]), textarea, select) {
  width: 100%;
}

.cs-shell .cs-button--primary,
.cs-ticket-shell .cs-button--primary,
.cs-shell__status,
.cs-ticket-shell [data-cs-ticket-status],
.cs-ticket-verification,
.cs-ticket-verified,
.cs-ticket-result,
.cs-media-ready,
.cs-session-authorized-summary {
  width: 100%;
  max-width: none;
}

.cs-shell__status,
.cs-ticket-shell [data-cs-ticket-status],
.cs-ticket-verification,
.cs-ticket-verified,
.cs-media-ready {
  min-height: 56px;
  padding: 15px 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  background: rgba(8, 29, 50, 0.62);
  color: rgba(255, 255, 255, 0.92) !important;
  line-height: 1.45;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
  backdrop-filter: blur(16px) saturate(120%);
}

.cs-shell[data-cs-state="error"] .cs-shell__status,
.cs-ticket-shell[data-cs-state="error"] [data-cs-ticket-status] {
  border-color: rgba(255, 95, 109, 0.52);
  background: rgba(120, 29, 44, 0.44);
  color: #ffe7ea !important;
}

.cs-shell[data-cs-state="ready"] .cs-shell__status,
.cs-shell[data-cs-state="program_ready"] .cs-shell__status,
.cs-ticket-verified,
.cs-media-ready {
  border-color: rgba(70, 220, 150, 0.44);
  background: rgba(30, 108, 78, 0.42);
  color: #e3ffef !important;
}

.cs-ticket-shell,
.cs-ticket-shell :is(h1, h2, h3, p, label, input, button, a, span, strong) {
  font-family: Inter, Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.cs-ticket-shell > .cs-panel {
  width: min(780px, 100%);
  padding: clamp(28px, 5vw, 48px);
}

.cs-ticket-shell .cs-panel__heading {
  gap: 18px;
  margin-bottom: 30px;
}

.cs-ticket-shell .cs-panel__heading h3 {
  margin-bottom: 9px;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 750;
  letter-spacing: -.02em;
}

.cs-ticket-shell .cs-panel__heading p {
  font-size: 1rem;
  line-height: 1.65;
}

.cs-ticket-shell .cs-ticket {
  gap: 10px;
  margin-bottom: 20px;
}

.cs-ticket-shell .cs-ticket span {
  font-size: .78rem;
  font-weight: 750;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.cs-ticket-shell .cs-ticket input {
  min-height: 58px;
  padding: 0 18px;
  font-size: 1rem;
  font-weight: 600;
}

.cs-ticket-shell > .cs-panel > .cs-button--primary,
.cs-ticket-verification .cs-button,
.cs-ticket-result .cs-button {
  width: 100%;
  min-height: 58px;
}

.cs-ticket-result {
  gap: 14px;
  margin-top: 24px;
  padding: clamp(22px, 4vw, 34px);
  border-color: rgba(0, 191, 255, .48);
  background:
    radial-gradient(circle at 85% 15%, rgba(0,191,255,.16), transparent 38%),
    rgba(4, 25, 47, .58);
  box-shadow: 0 18px 44px rgba(0,0,0,.22), 0 0 34px rgba(0,191,255,.09);
}

.cs-ticket-result span {
  font-size: .76rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.cs-ticket-result strong {
  margin: 4px 0 8px;
  color: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: clamp(2rem, 7vw, 3.75rem);
  font-weight: 750;
  letter-spacing: .025em;
  line-height: 1.08;
  text-align: center;
  text-shadow: 0 0 26px rgba(0,191,255,.38);
}

.cs-ticket-result .cs-button--secondary {
  border-color: rgba(255,255,255,.35);
  background: rgba(255,255,255,.13);
  text-align: center;
}

.cs-panel[data-cs-region="run-controls"] {
  padding-block: clamp(26px, 4vw, 38px);
}

.cs-panel[data-cs-region="run-controls"] .cs-panel__heading {
  margin-bottom: 24px;
}

.cs-panel[data-cs-region="run-controls"] .cs-button--primary {
  min-height: 68px;
  font-size: 1.22rem;
}

.cs-runner-contract + .cs-run-timer,
.cs-run-timer {
  position: relative;
  gap: 12px;
  margin: 12px 0 20px;
  padding: clamp(26px, 5vw, 48px) 22px;
  border-color: rgba(0,191,255,.48);
  border-radius: 18px;
  background:
    radial-gradient(circle at 50% 50%, rgba(0,191,255,.13), transparent 58%),
    rgba(3, 18, 35, .68);
  box-shadow: inset 0 1px rgba(255,255,255,.06), 0 18px 44px rgba(0,0,0,.2);
}

.cs-run-timer span {
  color: rgba(255,255,255,.72);
  font-size: .76rem;
  letter-spacing: .12em;
}

.cs-run-timer strong {
  font-size: clamp(3.5rem, 10vw, 6.6rem);
  font-weight: 720;
  line-height: .92;
  letter-spacing: -.055em;
  text-shadow: 0 0 30px rgba(0,191,255,.42);
}

.cs-progress {
  height: 10px;
  margin: 18px 0 4px;
  background: rgba(255,255,255,.18);
  box-shadow: inset 0 1px 3px rgba(0,0,0,.25);
}

@media (max-width: 640px) {
  .cs-ticket-shell > .cs-panel { padding: 24px 18px; }
  .cs-ticket-shell .cs-panel__heading { margin-bottom: 24px; }
  .cs-ticket-result strong { text-align: left; }
  .cs-run-timer { padding: 30px 14px; }
  .cs-run-timer strong { font-size: clamp(3.2rem, 17vw, 5rem); }
}

/* =========================================================
   PC1-020 — Admin + Completion final polish
   ========================================================= */
.cs-shell[data-cs-admin-view="true"] .cs-shell__layout {
  grid-template-columns: minmax(0, 1fr) minmax(340px, .62fr);
  gap: clamp(20px, 3vw, 32px);
}

.cs-shell__sidebar {
  gap: 18px;
}

.cs-shell__sidebar .cs-panel--compact {
  padding: 20px;
}

.cs-rail-heading {
  margin-bottom: 18px;
}

.cs-rail-heading h3 {
  font-size: 1.18rem;
}

.cs-health__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cs-health__item {
  grid-template-columns: 10px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 10px;
  row-gap: 5px;
  min-height: 74px;
  padding: 13px 14px;
  border-radius: 12px;
  background: rgba(3, 18, 35, .38);
}

.cs-health__item i {
  grid-column: 1;
  grid-row: 1;
}

.cs-health__item span {
  grid-column: 2;
  grid-row: 1;
  font-size: .78rem;
}

.cs-health__item strong {
  grid-column: 2;
  grid-row: 2;
  max-width: none;
  color: rgba(255,255,255,.72);
  font-size: .72rem;
  font-weight: 650;
  line-height: 1.35;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
}

.cs-control-stack {
  gap: 11px;
}

.cs-sidebar-title {
  margin: 5px 3px 10px;
}

.cs-control-card > summary {
  grid-template-columns: 38px minmax(0, 1fr) 12px;
  gap: 12px;
  min-height: 78px;
  padding: 14px 16px;
}

.cs-summary-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  font-size: .78rem;
}

.cs-summary-copy {
  gap: 7px;
}

.cs-summary-copy strong {
  font-size: .94rem;
  line-height: 1.25;
}

.cs-summary-copy small {
  /* Plain-text summaries (e.g. Diagnostics) have no <span> children to flex —
     display:flex would box the whole text as one unbreakable anonymous item
     and let it overflow into the next grid column instead of wrapping. */
  display: block;
  color: rgba(255,255,255,.66);
  font-size: .72rem;
  line-height: 1.45;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
}

.cs-summary-copy small span {
  display: inline-block;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.cs-control-card > .cs-facts {
  padding: 8px 16px 14px;
}

.cs-control-card > .cs-facts div {
  grid-template-columns: minmax(110px, .8fr) minmax(0, 1.2fr);
  gap: 14px;
  padding: 10px 0;
}

.cs-shell[data-cs-completion-state="active"] .cs-sky-orb b,
.cs-shell[data-cs-completion-state="expired"] .cs-sky-orb b {
  opacity: .06;
}

.cs-shell[data-cs-completion-state="active"] .cs-sky-orb,
.cs-shell[data-cs-completion-state="expired"] .cs-sky-orb {
  opacity: .22;
  box-shadow: 0 0 54px rgba(0,191,255,.07), inset 0 0 40px rgba(30,144,255,.05);
}

.cs-shell[data-cs-completion-state="active"] .cs-sky-orb i,
.cs-shell[data-cs-completion-state="expired"] .cs-sky-orb i {
  border-color: rgba(255,255,255,.13);
}

.cs-session-complete {
  gap: 15px;
  min-height: 520px;
  padding: clamp(38px, 7vw, 76px);
  border-color: rgba(70,220,150,.24);
  background:
    radial-gradient(circle at 50% 22%, rgba(70,220,150,.14), transparent 38%),
    linear-gradient(180deg, rgba(255,255,255,.105), rgba(255,255,255,.07));
}

.cs-session-complete__mark {
  width: 76px;
  height: 76px;
  margin-bottom: 4px;
  border-color: rgba(117,239,179,.68);
  background: rgba(50,200,130,.17);
  color: #9affca;
  font-size: 2rem;
  box-shadow: 0 0 0 10px rgba(70,220,150,.045), 0 0 42px rgba(70,220,150,.2);
}

.cs-session-complete h3 {
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -.035em;
}

.cs-session-complete__field {
  width: min(420px, 100%);
  margin: 16px 0;
  padding: 24px 22px;
  border-color: rgba(0,191,255,.42);
  border-radius: 16px;
  background:
    radial-gradient(circle at 50% 50%, rgba(0,191,255,.1), transparent 68%),
    rgba(3,18,35,.54);
  box-shadow: inset 0 1px rgba(255,255,255,.06), 0 16px 38px rgba(0,0,0,.17);
}

.cs-session-complete__field span {
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.cs-session-complete__field strong {
  margin-top: 5px;
  font-size: clamp(2.8rem, 9vw, 4.8rem);
  line-height: 1;
  text-shadow: 0 0 28px rgba(0,191,255,.32);
}

.cs-session-complete__actions {
  width: min(420px, 100%);
  gap: 12px;
}

.cs-session-complete__actions .cs-button--primary {
  min-height: 64px;
  border-radius: 15px;
  font-size: 1.05rem;
  box-shadow: 0 14px 34px rgba(30,144,255,.4);
}

@media (max-width: 1100px) {
  .cs-shell[data-cs-admin-view="true"] .cs-shell__layout { grid-template-columns: 1fr; }
  .cs-shell__sidebar { position: static; max-height: none; overflow: visible; }
  .cs-health__grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
}

@media (max-width: 640px) {
  .cs-health__grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .cs-health__item { min-height: 70px; padding: 12px; }
  .cs-control-card > summary { min-height: 74px; padding: 13px 14px; }
  .cs-session-complete { min-height: 480px; padding: 34px 18px; }
  .cs-session-complete__mark { width: 68px; height: 68px; }
}