/* =========================
   DISEÑADOR DE CAMISETAS · v4 (estilo CREW)
   Paleta: bg #0b0b0b · teal #00c4b0 · lima #c8f535
========================= */

/* HERO */
.dis-hero {
  text-align: center;
  padding: 56px 20px 28px;
}
.dis-hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 800;
  letter-spacing: -0.5px;
  margin: 0 0 10px;
  line-height: 1.1;
  color: var(--texto);
}
.dis-hero h1 span { color: var(--lima); }
.dis-hero p {
  color: var(--gris);
  font-size: 15px;
  max-width: 580px;
  margin: 0 auto;
  line-height: 1.55;
}

/* APP CONTAINER */
.dis-app {
  max-width: 1180px;
  margin: 16px auto 100px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
}

/* ───────── STAGE: vista de la camiseta ───────── */
.dis-stage {
  position: sticky;
  top: 16px;
  z-index: 5;
  background:
    radial-gradient(ellipse at top, #1a1a1a 0%, #0b0b0b 70%);
  border-radius: 18px;
  padding: 12px;
  border: 1px solid #1f1f1f;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.dis-stage-inner {
  background:
    linear-gradient(180deg, #1c1c1c 0%, #111 100%);
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.04);
  overflow: hidden;
}

/* TABS Mi camiseta / Escudo */
.dis-tabs-main {
  display: flex;
  background: #050505;
  border-radius: 12px;
  padding: 4px;
  margin: 8px;
  gap: 4px;
}
.tab-main {
  flex: 1;
  background: transparent;
  border: none;
  padding: 12px 8px;
  font-size: 13px;
  font-weight: 700;
  color: #888;
  border-radius: 9px;
  cursor: pointer;
  transition: all .15s;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}
.tab-main.active {
  background: linear-gradient(135deg, var(--teal), #00a896);
  color: #0b0b0b;
  box-shadow: 0 4px 14px rgba(0,196,176,0.32);
}
.tab-main:hover:not(.active) {
  color: var(--texto);
  background: rgba(255,255,255,0.04);
}

/* TOGGLE FRENTE / DORSO */
.dis-vista-toggle {
  display: flex;
  margin: 0 8px 8px;
  background: #050505;
  border-radius: 10px;
  padding: 3px;
  gap: 3px;
}
.vista-btn {
  flex: 1;
  background: transparent;
  border: none;
  padding: 9px 8px;
  font-size: 12px;
  font-weight: 700;
  color: #888;
  border-radius: 8px;
  cursor: pointer;
  transition: all .15s;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  width: auto;
}
.vista-btn.active {
  background: rgba(0,196,176,0.16);
  color: var(--teal);
  box-shadow: inset 0 0 0 1px rgba(0,196,176,0.3);
}
.vista-btn:hover:not(.active) {
  color: var(--texto);
  background: rgba(255,255,255,0.04);
}

/* CANVAS DE LA CAMISETA */
.dis-stage-canvas {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px 18px;
  min-height: 360px;
}

/* CAPAS DE LA CAMISETA (PNG base + multiply blend) */
.shirt-stage {
  width: 100%;
  max-width: 380px;
  aspect-ratio: 288 / 346;
  display: block;
  filter: drop-shadow(0 12px 28px rgba(0,0,0,0.5));
}
.shirt-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}
.shirt-color,
.shirt-tramas,
.shirt-shadows,
.shirt-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}
.shirt-shadows {
  mix-blend-mode: multiply;
}
.shirt-tramas {
  mix-blend-mode: normal;
}
.shirt-overlay {
  mix-blend-mode: normal;
}

/* ───────── PANEL DE OPCIONES ───────── */
.dis-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.dis-view {
  display: none;
  flex-direction: column;
  gap: 12px;
}
.dis-view.active { display: flex; }

/* CARDS */
.opt-card {
  background: #111;
  border: 1px solid #1f1f1f;
  border-radius: 14px;
  padding: 18px 18px 20px;
}

.opt-title {
  font-size: 11px;
  font-weight: 700;
  color: #777;
  margin: 0 0 14px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
}

/* GRIDS DE OPCIONES */
.opt-grid {
  display: grid;
  gap: 8px;
}
.opt-grid.grid-3 { grid-template-columns: repeat(3, 1fr); }
.opt-grid.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 480px) {
  .opt-grid.grid-4 { grid-template-columns: repeat(3, 1fr); }
}

.opt-btn {
  position: relative;
  background: #1a1a1a;
  border: 2px solid transparent;
  border-radius: 11px;
  padding: 10px 6px 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all .15s;
  min-height: 88px;
}
.opt-btn:hover {
  background: #1f1f1f;
  border-color: rgba(255,255,255,0.06);
}
.opt-btn.active {
  border-color: var(--teal);
  background: rgba(0,196,176,0.08);
  box-shadow: 0 0 0 4px rgba(0,196,176,0.12);
}

.opt-thumb {
  display: block;
  width: 100%;
  max-width: 60px;
  aspect-ratio: 1;
}
.opt-thumb svg {
  width: 100%;
  height: 100%;
}

.opt-thumb-label {
  font-size: 10px;
  color: #888;
  text-align: center;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.2px;
}
.opt-btn.active .opt-thumb-label { color: var(--teal); }

/* Botón con sólo texto (para sponsors) */
.opt-btn-text {
  min-height: 52px;
  font-size: 12px;
  font-weight: 700;
  color: #ccc;
  letter-spacing: 0.4px;
}
.opt-btn-text.active { color: var(--teal); }
.opt-btn-text:hover:not(.active) { color: var(--texto); }

/* CHECK MARKER en active */
.opt-btn::after {
  content: '';
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid #333;
  background: #0b0b0b;
  transition: all .15s;
}
.opt-btn.active::after {
  background: var(--teal);
  border-color: var(--teal);
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3 7l3 3 5-6' stroke='%230b0b0b' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: 11px;
  background-position: center;
  background-repeat: no-repeat;
}

/* ROWS (color rows) */
.opt-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.opt-row-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--texto);
}

.color-pill {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  border: 1px solid #2a2a2a;
  background: #1a1a1a;
  cursor: pointer;
  padding: 4px;
  transition: transform .12s, box-shadow .15s, border-color .15s;
  flex-shrink: 0;
}
.color-pill:hover {
  transform: scale(1.05);
  border-color: var(--teal);
  box-shadow: 0 4px 14px rgba(0,196,176,0.2);
}
.color-pill-dot {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.06);
}

/* INPUTS */
.opt-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  font-size: 14px;
  color: var(--texto);
  background: #1a1a1a;
  outline: none;
  box-sizing: border-box;
  transition: border-color .15s, background .15s;
}
.opt-input::placeholder { color: #555; }
.opt-input:focus {
  border-color: var(--teal);
  background: #0f0f0f;
}

/* TOGGLE */
.opt-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--texto);
}
.opt-toggle input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--teal);
}

/* ───────── ACTIONS BAR (sticky bottom) ───────── */
.dis-actions {
  position: sticky;
  bottom: 16px;
  display: flex;
  gap: 10px;
  background: rgba(11,11,11,0.92);
  backdrop-filter: blur(12px);
  padding: 12px;
  border-radius: 14px;
  border: 1px solid #1f1f1f;
  box-shadow: 0 8px 28px rgba(0,0,0,0.5);
  z-index: 10;
}
.dis-btn-action {
  flex: 1;
  padding: 14px 16px;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .1s, box-shadow .15s, background .15s;
  letter-spacing: 0.3px;
}
.dis-btn-action:hover { transform: translateY(-1px); }
.dis-btn-primary {
  background: var(--lima);
  color: #0b0b0b;
  box-shadow: 0 4px 14px rgba(200,245,53,0.28);
}
.dis-btn-primary:hover { background: #d3ff45; }
.dis-btn-secondary {
  background: rgba(0,196,176,0.1);
  color: var(--teal);
  border: 1px solid rgba(0,196,176,0.3);
}
.dis-btn-secondary:hover {
  background: rgba(0,196,176,0.18);
  border-color: rgba(0,196,176,0.5);
}

/* ───────── COLOR PICKER MODAL ───────── */
.color-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.color-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(6px);
}
.color-modal-content {
  position: relative;
  background: #141414;
  border: 1px solid #2a2a2a;
  border-radius: 16px;
  padding: 22px;
  max-width: 380px;
  width: 100%;
  box-shadow: 0 20px 48px rgba(0,0,0,0.6);
}
.color-modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}
.color-modal-head h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--texto);
  letter-spacing: 0.4px;
}
.color-modal-close {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  font-size: 18px;
  color: #888;
  cursor: pointer;
  line-height: 1;
}
.color-modal-close:hover {
  color: var(--texto);
  border-color: var(--teal);
}
.color-modal-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}
.color-modal-swatch {
  aspect-ratio: 1;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.08);
  cursor: pointer;
  transition: transform .12s, box-shadow .15s;
}
.color-modal-swatch:hover {
  transform: scale(1.12);
  box-shadow: 0 4px 14px rgba(0,196,176,0.32);
  z-index: 1;
}

/* ───────── DESKTOP LAYOUT ───────── */
/* Opciones IZQUIERDA, camiseta DERECHA */
@media (min-width: 880px) {
  .dis-app {
    grid-template-columns: minmax(0, 1fr) minmax(360px, 480px);
    gap: 28px;
    align-items: start;
  }
  .dis-options {
    grid-column: 1;
    grid-row: 1;
  }
  .dis-stage {
    grid-column: 2;
    grid-row: 1 / span 3;
    position: sticky;
    top: 24px;
    padding: 16px;
  }
  .dis-stage-canvas {
    min-height: 480px;
  }
  .shirt-stage {
    max-width: 460px;
  }
  .dis-actions {
    grid-column: 1;
    grid-row: 2;
    position: sticky;
    bottom: 24px;
  }
}

/* MOBILE: orden = stage primero (queda sticky arriba), luego opciones */
@media (max-width: 879px) {
  .dis-app { grid-template-rows: auto auto auto; }
  .dis-stage    { grid-row: 1; }
  .dis-options  { grid-row: 2; }
  .dis-actions  { grid-row: 3; }
}

/* PAGE BG (CREW oscuro) */
body.landing-page {
  background: var(--bg);
  color: var(--texto);
}
