/* ==========================================================================
   Comi-K Entradas — frontend
   ========================================================================== */

.comik-tk {
	display: grid;
	grid-template-columns: 1fr 340px;
	gap: 28px;
	background: #14110f;
	border: 1px solid rgba(244, 239, 230, 0.1);
	border-radius: 18px;
	padding: 28px;
	color: #f4efe6;
	font-family: inherit;
}
@media (max-width: 820px) {
	.comik-tk { grid-template-columns: 1fr; }
}

.comik-tk__head { grid-column: 1 / -1; border-bottom: 1px solid rgba(244, 239, 230, 0.1); padding-bottom: 18px; margin-bottom: 6px; }
.comik-tk__title { font-family: Georgia, serif; font-size: 1.7rem; margin: 0 0 8px; color: #f4efe6; }
.comik-tk__meta { display: flex; flex-wrap: wrap; gap: 16px; color: #a89e90; font-size: 0.9rem; margin: 0; }

/* Mapa */
.comik-tk__map { overflow-x: auto; }
.comik-tk__stage {
	text-align: center;
	background: linear-gradient(135deg, #d4a94e, #b8892f);
	color: #1a1206; font-weight: 700; letter-spacing: 0.25em; text-transform: uppercase;
	font-size: 12px; padding: 10px; border-radius: 8px;
	max-width: 280px; margin: 4px auto 30px;
}
.comik-tk__zone { margin-bottom: 26px; }
.comik-tk__zone-label {
	font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
	color: #d4a94e; margin-bottom: 12px; font-weight: 600;
}
.comik-tk__row { display: flex; gap: 6px; justify-content: center; align-items: center; margin-bottom: 7px; }
.comik-tk__row-label { color: #7d7466; font-size: 11px; width: 22px; text-align: right; margin-right: 6px; }

.comik-tk__seat {
	width: 30px; height: 30px;
	border: none; border-radius: 8px 8px 4px 4px;
	background: #d4a94e; color: #1a1206;
	font-size: 10px; font-weight: 700;
	cursor: pointer;
	transition: transform 0.15s, background 0.2s, box-shadow 0.2s;
	display: inline-flex; align-items: center; justify-content: center;
}
.comik-tk__seat:hover:not(:disabled) { transform: translateY(-3px) scale(1.08); box-shadow: 0 6px 14px rgba(212, 169, 78, 0.4); }
.comik-tk__seat.is-sel { background: #9e2b25; color: #fff; box-shadow: 0 0 0 2px #f4efe6; }
.comik-tk__seat.is-vendido, .comik-tk__seat.is-reservado { background: #3a332c; color: #6a6258; cursor: not-allowed; }

.comik-tk__legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 20px; justify-content: center; font-size: 0.8rem; color: #a89e90; }
.comik-tk__legend span { display: inline-flex; align-items: center; gap: 6px; }
.comik-tk__sw { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }
.comik-tk__sw--libre { background: #d4a94e; }
.comik-tk__sw--sel { background: #9e2b25; }
.comik-tk__sw--vendido { background: #3a332c; }

.comik-tk__loading, .comik-tk__error { color: #a89e90; text-align: center; padding: 40px 0; }
.comik-tk__error { color: #e08b7f; }

/* Carrito */
.comik-tk__cart { background: #1b1613; border: 1px solid rgba(244, 239, 230, 0.08); border-radius: 14px; padding: 22px; align-self: start; }
.comik-tk__cart h4 { font-family: Georgia, serif; font-size: 1.2rem; margin: 0 0 16px; color: #f4efe6; }
.comik-tk__cart-list { list-style: none; margin: 0 0 16px; padding: 0; min-height: 60px; }
.comik-tk__cart-item { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid rgba(244, 239, 230, 0.07); font-size: 0.92rem; }
.comik-tk__cart-empty { color: #7d7466; font-size: 0.9rem; }
.comik-tk__total { display: flex; justify-content: space-between; align-items: center; padding: 16px 0; border-top: 2px solid rgba(212, 169, 78, 0.3); margin-bottom: 18px; }
.comik-tk__total strong { font-family: Georgia, serif; font-size: 1.5rem; color: #d4a94e; }

.comik-tk__buyer label { display: block; margin-bottom: 14px; font-size: 0.85rem; color: #a89e90; }
.comik-tk__buyer input { width: 100%; margin-top: 6px; padding: 12px 14px; background: #14110f; border: 1px solid rgba(244, 239, 230, 0.12); border-radius: 10px; color: #f4efe6; font-family: inherit; font-size: 0.95rem; }
.comik-tk__buyer input:focus { outline: none; border-color: #d4a94e; }

.comik-tk__pay {
	width: 100%; padding: 15px; border: none; border-radius: 100px;
	background: linear-gradient(135deg, #e8c883, #d4a94e 55%, #b8892f);
	color: #1a1206; font-weight: 700; font-size: 1rem; font-family: inherit;
	cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
	display: inline-flex; align-items: center; justify-content: center;
}
.comik-tk__pay:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 12px 28px -10px rgba(212, 169, 78, 0.6); }
.comik-tk__pay:disabled { opacity: 0.45; cursor: not-allowed; }
.comik-tk__secure { font-size: 0.76rem; color: #7d7466; margin: 14px 0 0; text-align: center; }

/* Casilla de aceptación de condiciones */
.comik-tk__terms {
	display: flex; align-items: flex-start; gap: 10px; margin: 4px 0 16px;
	font-size: 0.8rem; color: #a89e90; line-height: 1.5; cursor: pointer;
}
.comik-tk__terms input[type="checkbox"] {
	flex: 0 0 auto; width: 18px; height: 18px; margin: 1px 0 0;
	accent-color: #d4a94e; cursor: pointer;
}
.comik-tk__terms a { color: #d4a94e; text-decoration: underline; }
.comik-tk__terms a:hover { color: #e8c883; }

/* Páginas legales (condiciones y cancelación) */
.comik-legal { color: #c9c0b2; line-height: 1.7; font-size: 0.96rem; }
.comik-legal h2 {
	font-family: Georgia, serif; color: #d4a94e; font-size: 1.25rem;
	margin: 30px 0 12px; font-weight: 600;
}
.comik-legal h2:first-child { margin-top: 0; }
.comik-legal p { margin: 0 0 16px; }
.comik-legal ul, .comik-legal ol { margin: 0 0 16px; padding-left: 22px; }
.comik-legal li { margin-bottom: 8px; }
.comik-legal a { color: #d4a94e; text-decoration: underline; }
.comik-legal strong { color: #f4efe6; }
.comik-legal__meta { color: #7d7466; font-size: 0.78rem; margin-top: 30px; }

/* =========================================================
   VALIDADOR / CHECK-IN
   ========================================================= */
.comik-checkin { max-width: 460px; margin: 0 auto; text-align: center; font-family: inherit; color: #f4efe6; }
.comik-checkin__title { font-family: Georgia, serif; font-size: 1.6rem; margin-bottom: 20px; }
.comik-checkin__scanner { position: relative; width: 100%; aspect-ratio: 1; background: #14110f; border-radius: 16px; overflow: hidden; margin-bottom: 18px; border: 1px solid rgba(244, 239, 230, 0.1); }
.comik-checkin__scanner video { width: 100%; height: 100%; object-fit: cover; }
.comik-checkin__frame { position: absolute; inset: 18%; border: 3px solid #d4a94e; border-radius: 14px; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, 0.4); pointer-events: none; }
.comik-checkin__manual { display: flex; gap: 8px; margin-bottom: 16px; }
.comik-checkin__manual input { flex: 1; padding: 13px 15px; background: #1b1613; border: 1px solid rgba(244, 239, 230, 0.12); border-radius: 10px; color: #f4efe6; font-family: monospace; font-size: 1rem; text-transform: uppercase; }
.comik-checkin__manual .comik-tk__pay { width: auto; padding: 13px 24px; }
.comik-checkin__result { min-height: 60px; }
.comik-checkin__status { padding: 18px; border-radius: 12px; font-weight: 700; font-size: 1.05rem; background: #3a332c; }
.comik-checkin__status.is-ok { background: #1c4028; color: #7fe0a0; }
.comik-checkin__status.is-warn { background: #40351c; color: #e0c87f; }
.comik-checkin__status.is-bad { background: #401c1c; color: #e08b7f; }
.comik-checkin__hint { font-size: 0.82rem; color: #7d7466; margin-top: 16px; }

/* =========================================================
   PÁGINA DE GRACIAS
   ========================================================= */
body.comik-thanks-page { background: #0c0a09; color: #f4efe6; }
.comik-thanks { max-width: 560px; margin: 0 auto; padding: 60px 24px; text-align: center; }
.comik-thanks__badge { width: 84px; height: 84px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 44px; margin: 0 auto 24px; font-weight: 700; }
.comik-thanks__badge--ok { background: #1c4028; color: #7fe0a0; }
.comik-thanks__badge--warn { background: #40351c; color: #e0c87f; }
.comik-thanks h1 { font-size: 2.2rem; margin: 0 0 12px; }
.comik-thanks__sub { color: #a89e90; margin: 0 0 28px; }
.comik-thanks__info { background: #14110f; border: 1px solid rgba(244, 239, 230, 0.1); border-radius: 14px; padding: 20px; margin-bottom: 28px; display: flex; flex-direction: column; gap: 6px; }
.comik-thanks__info strong { font-size: 1.2rem; color: #d4a94e; }
.comik-thanks__info span { color: #a89e90; font-size: 0.9rem; }
.comik-thanks__tickets { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; }
.comik-thanks__ticket { background: #14110f; border: 1px solid rgba(244, 239, 230, 0.1); border-radius: 14px; padding: 20px; }
.comik-thanks__ticket img { border-radius: 10px; background: #fff; padding: 6px; }
.comik-thanks__seat { margin: 12px 0 6px; font-weight: 600; color: #f4efe6; }
.comik-thanks__ticket code { color: #7d7466; font-size: 0.8rem; letter-spacing: 1px; }
.comik-thanks__total { color: #d4a94e; font-weight: 600; margin: -8px 0 24px; }
.comik-thanks__btn { display: inline-flex !important; justify-content: center; border: 0; cursor: pointer; text-decoration: none; }
.comik-thanks__acciones { display: flex; flex-direction: column; gap: 12px; margin-top: 24px; }
.comik-isla__cuerpo .comik-thanks { padding: 16px 4px 40px; }
/* --- Escáner: caja táctil, estados y respaldo jsQR --- */
.comik-checkin__tap {
	position: absolute; inset: 0; z-index: 2;
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
	width: 100%; border: 0; background: #14110f; color: #d4a94e;
	font: inherit; font-weight: 700; cursor: pointer; text-align: center; padding: 24px;
}
.comik-checkin__tap:hover { background: #1b1613; }
.comik-checkin__tap-ico { font-size: 2.6rem; line-height: 1; }
.comik-checkin__tap small { color: #7d7466; font-weight: 400; font-size: 0.8rem; }
.comik-checkin__scanner.is-live .comik-checkin__tap,
.comik-checkin__scanner.is-loading .comik-checkin__tap { display: none; }
.comik-checkin__scanner.is-loading video { opacity: 0.35; }
.comik-checkin__scanner.is-error { border-color: rgba(224, 139, 127, 0.45); }
.comik-checkin__scanner.is-error video { opacity: 0.12; }
.comik-checkin__scanner.is-error .comik-checkin__tap { background: #171310; }

/* =========================================================
   GALERÍA DE EVENTOS (estilo elenco) + ISLA DE DETALLE
   ========================================================= */
.comik-gal { padding: 10px 0 30px; }
.comik-gal__head { text-align: center; margin-bottom: 34px; }
.comik-gal__eyebrow { color: #d4a94e; font-size: 0.78rem; letter-spacing: 0.22em; text-transform: uppercase; margin-bottom: 8px; }
.comik-gal__titulo { font-family: Georgia, 'Times New Roman', serif; font-size: clamp(1.8rem, 4vw, 2.6rem); color: #f4efe6; }
.comik-gal__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 26px; }
.comik-gal__card {
	background: #14110f; border: 1px solid rgba(244, 239, 230, 0.09); border-radius: 16px; overflow: hidden;
	cursor: pointer; display: flex; flex-direction: column;
	transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}
.comik-gal__card:hover, .comik-gal__card:focus-visible { transform: translateY(-6px); border-color: rgba(212, 169, 78, 0.5); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45); outline: none; }
.comik-gal__media { aspect-ratio: 4 / 5; background: #1b1613; position: relative; overflow: hidden; }
.comik-gal__media::after { content: ""; position: absolute; inset: 0; box-shadow: inset 0 -60px 60px -30px rgba(12, 10, 9, 0.7); pointer-events: none; }
.comik-gal__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.7s ease, filter 0.5s; filter: grayscale(0.25); display: block; }
.comik-gal__card:hover .comik-gal__media img { transform: scale(1.06); filter: grayscale(0); }
.comik-gal__marca { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: Georgia, serif; font-size: 1.7rem; color: #d4a94e; letter-spacing: 0.04em; }
.comik-gal__card-title { font-family: Georgia, serif; font-size: 1.08rem; color: #f4efe6; padding: 14px 16px 6px; line-height: 1.3; }
.comik-gal__card-meta { list-style: none; padding: 0 16px; display: grid; gap: 3px; font-size: 0.82rem; color: #a99f8f; }
.comik-gal__card-precio { padding: 10px 16px 0; color: #d4a94e; font-size: 0.95rem; }
.comik-gal__card-precio strong { font-size: 1.05rem; }
.comik-gal__more {
	display: block; margin: 12px 16px 16px; text-align: center;
	padding: 9px 14px; border: 1px solid rgba(212, 169, 78, 0.55); border-radius: 9px;
	color: #d4a94e; font-size: 0.85rem; font-weight: 700; letter-spacing: 0.04em;
	transition: background 0.3s, color 0.3s;
}
.comik-gal__card:hover .comik-gal__more { background: #d4a94e; color: #14100c; }
.comik-gal__vacio { text-align: center; color: #a99f8f; max-width: 560px; margin: 0 auto; line-height: 1.7; padding: 20px 0 40px; }

/* Isla de detalle (sinopsis + plano + pago) */
body.comik-isla-lock { overflow: hidden; }
.comik-isla { position: fixed; inset: 0; z-index: 9500; display: none; }
.comik-isla.is-open { display: block; }
.comik-isla__fondo { position: absolute; inset: 0; background: rgba(8, 6, 5, 0.82); }
.comik-isla__panel {
	position: relative; z-index: 1; max-width: 980px; margin: 3vh auto;
	background: #14110f; border: 1px solid rgba(212, 169, 78, 0.35); border-radius: 18px;
	max-height: 94vh; overflow: auto; box-shadow: 0 30px 90px rgba(0, 0, 0, 0.6);
}
.comik-isla__close {
	position: absolute; top: 12px; right: 12px; z-index: 2;
	width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(212, 169, 78, 0.5);
	background: rgba(20, 17, 15, 0.9); color: #d4a94e; font-size: 1.1rem; cursor: pointer;
	transition: background 0.3s, color 0.3s;
}
.comik-isla__close:hover { background: #d4a94e; color: #14100c; }
.comik-isla__cuerpo { padding: 30px 30px 34px; }
.comik-isla__hero { display: flex; gap: 28px; margin-bottom: 24px; }
.comik-isla__media { flex: 0 0 220px; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; border: 1px solid rgba(212, 169, 78, 0.3); background: #1b1613; position: relative; }
.comik-isla__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.comik-isla__marca { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: Georgia, serif; font-size: 1.8rem; color: #d4a94e; }
.comik-isla__info { flex: 1; min-width: 0; }
.comik-isla__title { font-family: Georgia, serif; font-size: clamp(1.5rem, 3vw, 2.1rem); color: #f4efe6; margin-bottom: 6px; }
.comik-isla__sub { color: #d4a94e; font-size: 0.95rem; margin-bottom: 14px; }
.comik-isla__meta { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 26px; color: #d4a94e; font-size: 0.95rem; }
.comik-isla__meta strong { color: #f4efe6; }
.comik-isla__sinopsis { border-top: 1px solid rgba(244, 239, 230, 0.1); padding-top: 18px; margin-bottom: 22px; }
.comik-isla__sinopsis h3, .comik-isla__compra h3 { font-family: Georgia, serif; color: #d4a94e; font-size: 1.05rem; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 10px; }
.comik-isla__sinopsis p { color: #cfc6b8; line-height: 1.75; }
.comik-isla__cargando, .comik-isla__error { text-align: center; color: #a99f8f; padding: 40px 0; }
.comik-isla__error { color: #e08b7f; }
@media (max-width: 720px) {
	.comik-isla__hero { flex-direction: column; }
	.comik-isla__media { flex-basis: auto; width: 190px; margin: 0 auto; }
	.comik-isla__cuerpo { padding: 22px 18px 26px; }
	.comik-isla__panel { margin: 0; border-radius: 0; max-height: 100vh; }
}

/* =========================================================
   AVISO GRANDE DE VALIDACIÓN (verde/rojo)
   ========================================================= */
.comik-aviso { position: fixed; inset: 0; z-index: 10500; display: none; align-items: center; justify-content: center; background: rgba(8, 6, 5, 0.85); padding: 20px; cursor: pointer; }
.comik-aviso.is-open { display: flex; }
.comik-aviso__caja {
	min-width: min(92vw, 460px); padding: 44px 36px 30px; border-radius: 22px; text-align: center;
	border: 2px solid; box-shadow: 0 30px 90px rgba(0, 0, 0, 0.65);
	animation: comik-aviso-in 0.25s ease-out;
}
.comik-aviso.is-ok .comik-aviso__caja { background: #0d2b1b; border-color: #34c77b; }
.comik-aviso.is-err .comik-aviso__caja { background: #2c1210; border-color: #e05a4b; }
.comik-aviso__icono { display: block; font-size: 3.2rem; line-height: 1; margin-bottom: 10px; font-weight: 700; }
.comik-aviso.is-ok .comik-aviso__icono, .comik-aviso.is-ok .comik-aviso__titulo { color: #4ade80; }
.comik-aviso.is-err .comik-aviso__icono, .comik-aviso.is-err .comik-aviso__titulo { color: #ff6b5c; }
.comik-aviso__titulo { font-family: Georgia, serif; font-size: clamp(1.9rem, 7vw, 3rem); font-weight: 700; letter-spacing: 0.04em; margin-bottom: 10px; }
.comik-aviso__detalle { color: #f4efe6; font-size: 1.05rem; line-height: 1.5; }
.comik-aviso__pista { color: rgba(244, 239, 230, 0.45); font-size: 0.78rem; margin-top: 18px; }
@keyframes comik-aviso-in { from { opacity: 0; transform: scale(0.92); } }
@media (prefers-reduced-motion: reduce) { .comik-aviso__caja { animation: none; } }
