/* Basic styling for /holo/ pages */

.holo-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}

.holo-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  padding: 16px;
  margin: 0 0 16px 0;
}

.holo-title {
  font-size: 26px;
  margin: 0 0 6px 0;
}

.holo-h2 {
  font-size: 18px;
  margin: 0 0 10px 0;
}

.holo-sub {
  margin: 0;
  opacity: 0.8;
}

.holo-muted {
  opacity: 0.75;
}

.holo-warn {
  border-color: rgba(255, 180, 0, 0.35);
}

.holo-table {
  width: 100%;
  border-collapse: collapse;
}

.holo-table th,
.holo-table td {
  text-align: left;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 10px;
  vertical-align: top;
}

.holo-table th {
  width: 180px;
  opacity: 0.8;
}

.holo-foot {
  margin: 10px 0 0;
  opacity: 0.85;
}

.holo-toolgrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.holo-toolcard {
  display: block;
  text-decoration: none;
  color: inherit;
}

.holo-toolcard:hover {
  border-color: rgba(255, 255, 255, 0.18);
}

.holo-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  opacity: 0.9;
  font-size: 12px;
}

.holo-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 3px;
  padding: 8px 12px;
  color: inherit;
  cursor: pointer;
}

.holo-btn:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.holo-pre {
  white-space: pre-wrap;
  margin: 10px 0 0;
  padding: 10px;
  border-radius: 3px;
  background: rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.08);
  overflow: auto;
}

.holo-details summary {
  cursor: pointer;
  opacity: 0.9;
}

/* Stage 9: Mask tool */

.holo-tool-app {
  display: block;
}

.mask-controls {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.mask-row {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  align-items: center;
  gap: 10px;
}

.mask-row-2 {
  grid-template-columns: 140px 1fr auto auto;
}

.mask-label {
  opacity: 0.85;
}

.mask-check {
  opacity: 0.9;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.mask-actions {
  grid-template-columns: 1fr 1fr;
}

.mask-canvas-wrap {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 3px;
  padding: 12px;
  overflow: auto;
  background: rgba(0,0,0,0.18);
}

.mask-canvas {
  display: block;
  max-width: 100%;
  height: auto;
  image-rendering: auto;
}

@media (max-width: 720px) {
  .mask-row {
    grid-template-columns: 1fr;
  }
  .mask-row-2 {
    grid-template-columns: 1fr;
  }
  .mask-actions {
    grid-template-columns: 1fr;
  }
}

.mask-canvas-wrap {
  background:
    linear-gradient(45deg, rgba(255,255,255,0.08) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(255,255,255,0.08) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(255,255,255,0.08) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(255,255,255,0.08) 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
  border-radius: 3px;
  padding: 10px;
}
.mask-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.mask-toolbar .holo-btn {
  white-space: nowrap;
}
.mask-toolbar .mask-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.mask-toolbar input[type="range"] {
  width: 160px;
}
.mask-help {
  margin-top: 8px;
  margin-bottom: 10px;
}

/* Holo — Holo structural placement */
.holo-area-wrap {
  max-width: 100%;
  padding: 0;
}

.holo-hero {
  margin: 0 0 16px 0;
}

.holo-kicker {
  margin: 0 0 6px 0;
  color: var(--muted, rgba(255,255,255,0.72));
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.8rem;
}

.holo-grid {
  display: grid;
  gap: 14px;
  margin: 14px 0;
}

.holo-grid-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.holo-grid-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.holo-list {
  margin: 0;
  padding-left: 1.2rem;
}

.holo-list li + li {
  margin-top: 6px;
}

.holo-list-numbered {
  padding-left: 1.4rem;
}

.holo-stage-panel {
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.18);
  border-radius: 3px;
  padding: 12px;
}

@media (max-width: 900px) {
  .holo-grid-two,
  .holo-grid-three {
    grid-template-columns: 1fr;
  }
}

/* DSNET HOLO START */
.holo-section-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.holo-actions-sticky {
  position: sticky;
  top: 76px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.holo-table-scroll {
  overflow-x: auto;
  overflow-y: visible;
}

body.holo-gradient-picker-open .holo-table-scroll {
  overflow: visible;
}

.holo-assets-table th,
.holo-assets-table td {
  min-width: 120px;
}

.holo-assets-table th:first-child,
.holo-assets-table td:first-child {
  min-width: 80px;
  width: 88px;
}

.holo-asset-thumb {
  display: block;
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 3px;
  background: rgba(0,0,0,0.28);
  border: 1px solid rgba(255,255,255,0.12);
}

.holo-display-input {
  min-width: 220px;
  max-width: 320px;
  width: 100%;
}

.holo-check-cell {
  text-align: center;
}

.holo-check-cell input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

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

/* DSNET HOLO START */
.holo-carousel-preview-grid {
  display: grid;
  grid-template-columns: minmax(280px, 420px) 1fr;
  gap: 16px;
  align-items: start;
}

.holo-carousel-preview-panel {
  min-width: 0;
}

.holo-carousel-preview-panel .holo-module-mount {
  max-width: 420px;
}

.holo-carousel-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.holo-carousel-table th,
.holo-carousel-table td {
  vertical-align: top;
  min-width: 140px;
}

.holo-carousel-table th:first-child,
.holo-carousel-table td:first-child {
  width: 72px;
  min-width: 72px;
  text-align: center;
}

.holo-carousel-table select,
.holo-carousel-table input[type="number"] {
  width: 100%;
  min-width: 140px;
}

.holo-carousel-row-muted {
  opacity: 0.72;
}

.holo-carousel-small {
  display: block;
  color: var(--muted, rgba(255,255,255,0.68));
  font-size: 0.82rem;
  margin-top: 4px;
}

.holo-carousel-warning {
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.08);
}

@media (max-width: 1100px) {
  .holo-carousel-preview-grid {
    grid-template-columns: 1fr;
  }
}



/* DSNET HOLO START */
.holo-background-preview-grid {
  display: grid;
  grid-template-columns: minmax(280px, 420px) 1fr;
  gap: 16px;
  align-items: start;
}

.holo-background-preview-panel {
  min-width: 0;
}

.holo-background-preview-panel .holo-module-mount {
  max-width: 420px;
  transform-origin: top center;
}

.holo-background-scale-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}

.holo-background-scale-row input[type="number"] {
  width: 110px;
}

.holo-background-table th,
.holo-background-table td {
  vertical-align: top;
  min-width: 140px;
}

.holo-background-table th:first-child,
.holo-background-table td:first-child {
  width: 72px;
  min-width: 72px;
  text-align: center;
}

.holo-background-table select,
.holo-background-table input[type="number"] {
  width: 100%;
  min-width: 140px;
}

.holo-background-small {
  display: block;
  color: var(--muted, rgba(255,255,255,0.68));
  font-size: 0.82rem;
  margin-top: 4px;
}

.holo-background-warning {
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.08);
}

@media (max-width: 1100px) {
  .holo-background-preview-grid {
    grid-template-columns: 1fr;
  }
}


/* DSNET HOLO START */
.holo-preview-foundation {
  display: grid;
  gap: 14px;
}
.holo-preview-foundation-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
}
.holo-preview-compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 14px;
  align-items: start;
}
.holo-preview-compare-panel {
  min-width: 0;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 3px;
  padding: 12px;
  background: rgba(0,0,0,0.16);
}
.holo-preview-compare-panel .holo-module-mount {
  max-width: 360px;
  margin: 0 auto;
}
.holo-preview-combined {
  grid-column: 1 / -1;
}
.holo-preview-combined .holo-module-mount {
  max-width: 440px;
}
.holo-preview-rules {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 12px;
}
@media (max-width: 900px) {
  .holo-preview-compare-grid {
    grid-template-columns: 1fr;
  }
  .holo-preview-combined {
    grid-column: auto;
  }
}


/* DSNET HOLO START */
.holo-grid-scatter-settings {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.holo-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.holo-field span:first-child {
  font-weight: 700;
}

.holo-field input,
.holo-field select {
  width: 100%;
  box-sizing: border-box;
}

.holo-field small {
  opacity: 0.72;
  line-height: 1.35;
}

.holo-inline-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}


/* DSNET HOLO START */
.holo-carousel-controls .holo-grid-scatter-settings {
  margin-top: 10px;
}

.holo-carousel-visual-card {
  margin-top: 18px;
  padding: 14px;
  border-radius: 3px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.18);
}

.holo-carousel-visual-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.holo-carousel-visual-status {
  color: var(--muted, rgba(255,255,255,0.72));
  font-size: 0.9rem;
}

.holo-carousel-strip-preview {
  --holo-carousel-width: 960px;
  --holo-carousel-height: 420px;
  --holo-carousel-visible-count: 3;
  --holo-carousel-roll-duration: 24s;
  width: min(100%, var(--holo-carousel-width));
  min-height: var(--holo-carousel-height);
}

.holo-carousel-strip-preview .holo-carousel-viewport {
  width: min(100%, var(--holo-carousel-width));
  min-height: var(--holo-carousel-height);
  overflow: hidden;
  border-radius: 3px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(0,0,0,0.24);
  position: relative;
}

.holo-carousel-strip-preview .holo-carousel-track {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: var(--holo-carousel-height);
  padding: 14px;
  will-change: transform;
}

.holo-carousel-strip-preview .holo-carousel-track.is-rolling {
  width: max-content;
  animation: dsnet-holo-carousel-roll var(--holo-carousel-roll-duration) linear infinite;
}

.holo-carousel-strip-preview .holo-carousel-track.is-static {
  justify-content: center;
}

.holo-carousel-strip-preview .holo-carousel-item {
  flex: 0 0 calc((min(100vw, var(--holo-carousel-width)) - 28px - (14px * (var(--holo-carousel-visible-count) - 1))) / var(--holo-carousel-visible-count));
  max-width: var(--holo-carousel-height);
  min-width: 110px;
}

.holo-carousel-strip-preview .holo-carousel-item-mount {
  width: 100%;
}

.holo-carousel-strip-preview .holo-carousel-item-mount .holo-renderer-stage {
  width: 100%;
}

@keyframes dsnet-holo-carousel-roll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-50% - 7px));
  }
}


/* Holo Gradiant selected thumbnail fallback for owner setup tables. */
.holo-gradient-inline-thumb {
  display: block;
  width: min(260px, 100%);
  height: 16px;
  margin-top: 6px;
  border-radius: 3px;
  background: rgba(255,255,255,0.08);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18);
}
.holo-settings-visual-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.holo-settings-visual-grid .holo-field input[type="range"] {
  width: 100%;
}
@media (max-width: 900px) {
  .holo-settings-visual-grid { grid-template-columns: 1fr; }
}
