:root {
    --bg-color: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --accent-primary: #38bdf8;
    --accent-secondary: #818cf8;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --danger: #ef4444;
    --success: #22c55e;
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Outfit', sans-serif;
    background: #000;
    color: var(--text-main);
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

/* Admin interface backgrounds */
body:has(.admin-container) {
    background: var(--bg-color);
    background-image: 
        radial-gradient(at 0% 0%, hsla(253,16%,7%,1) 0, transparent 50%), 
        radial-gradient(at 50% 0%, hsla(225,39%,30%,1) 0, transparent 50%), 
        radial-gradient(at 100% 0%, hsla(339,49%,30%,1) 0, transparent 50%);
    background-attachment: fixed;
}

/* Loader & Splash */
.loader-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    z-index: 999999;
}

.splash-img {
    width: min(280px, 70vw);
    height: auto;
    object-fit: contain;
    animation: splashBounce 1.2s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
    will-change: transform, opacity;
}

@keyframes splashBounce {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
    70% {
        transform: scale(0.9);
    }
    85% {
        transform: scale(1.03);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Common Components */
.btn {
    padding: 12px 24px;
    border-radius: 12px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary { background: var(--accent-primary); color: #000; }
.btn-accent { background: var(--accent-secondary); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-success { background: var(--success); color: #fff; }
.btn-warning { background: #f59e0b; color: #fff; }

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    filter: brightness(1.1);
}

.card {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2rem;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

@media (max-width: 768px) {
    .card {
        padding: 0;
        border-radius: 16px;
        overflow: hidden;
    }
    
    .card-header {
        padding: 1rem 1.2rem;
        cursor: pointer;
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        user-select: none;
        background: rgba(255, 255, 255, 0.03);
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .card-header h2 {
        margin: 0;
        font-size: 1.1rem;
    }

    .card-content {
        padding: 1.2rem;
        transition: opacity 0.3s ease;
    }

    .card-content.collapsed {
        display: none !important;
    }

    .toggle-icon {
        transition: transform 0.3s ease;
        color: var(--accent-primary);
        font-size: 1rem;
    }
}

/* Regular state (Desktop) - always expanded */
@media (min-width: 769px) {
    .card-header {
        display: block;
        padding: 1.2rem 1.2rem 0.5rem;
        cursor: default;
    }
    .toggle-icon { display: none; }
    .card-content {
        display: block !important;
        max-height: none !important;
        opacity: 1 !important;
        padding: 1.2rem;
    }
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.9);
    backdrop-filter: blur(12px);
    z-index: 99999; /* Máxima prioridad para móviles */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.modal-content.glass {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
    border-radius: 24px;
    padding: 2.5rem;
    max-width: 450px;
    width: 100%;
    text-align: center;
    transform: scale(1);
    animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes scaleIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-primary);
}

.modal-content p {
    color: var(--text-main);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.btn-secondary { background: rgba(255,255,255,0.1); color: #fff; }
.btn-secondary:hover { background: rgba(255,255,255,0.15); }

.btn-icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    aspect-ratio: 1 / 1;
    padding: 0;
    border-radius: 50%;
    margin-right: 0; /* Espacio manejado por gap en el padre */
    font-size: 1.2rem;
}

/* User Guide Extra Styles */
.guide-large {
    max-width: 800px !important;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    padding: 0 !important;
    overflow: hidden;
}

.guide-header {
    padding: 1.5rem 2rem;
    background: rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
}

.guide-body {
    padding: 2rem;
    overflow-y: auto;
    text-align: left !important;
    flex: 1;
}

.guide-body section {
    margin-bottom: 2rem;
}

.guide-body h3 {
    color: var(--accent-primary);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.guide-body p, .guide-body li {
    color: var(--text-main);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.guide-body ul, .guide-body ol {
    padding-left: 1.5rem;
}

.guide-divider {
    border: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--glass-border), transparent);
    margin: 1.5rem 0;
}

.btn-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    opacity: 0.6;
    transition: 0.3s;
}

.btn-close:hover { opacity: 1; }

.modal-actions {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--glass-border);
    background: rgba(255,255,255,0.05);
}

/* Admin Styles */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 180px 2rem 2rem; /* Espacio para el header fijo */
    width: 100%;
}

@media (max-width: 600px) {
    .admin-container {
        padding: 210px 0.8rem 80px; /* Mas espacio en móvil */
    }
}

@media (max-width: 600px) {
    .admin-container {
        padding: 1rem 0.8rem;
    }
}

.admin-header-v2 {
    text-align: center;
    margin-bottom: 0;
    padding: 1rem 1rem;
    animation: fadeInDown 0.6s ease-out;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    max-width: 100vw;
    z-index: 1000;
    backdrop-filter: blur(25px);
    background: rgba(15, 23, 42, 0.85);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.admin-header-v2 h1 {
    font-size: 1.8rem;
    margin-bottom: -5px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: transparent !important;
    font-weight: 800;
    display: inline-block;
    width: auto;
}

@media (max-width: 600px) {
    .admin-header-v2 h1 {
        font-size: 1.8rem !important;
    }
}

.admin-desc {
    color: var(--text-muted);
    margin-bottom: 0.2rem;
    line-height: 1.1;
    font-size: 0.75rem;
}

.badge {
    font-size: 0.9rem;
    padding: 4px 12px;
    background: rgba(255,255,255,0.1);
    border-radius: 20px;
    color: var(--text-main);
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

@media (max-width: 900px) {
    .admin-grid { 
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Beneficiary & Scanner Styles */
.beneficiary-box {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 2rem;
    border-radius: 20px;
    text-align: center;
    width: 100%;
    max-width: 350px;
    margin-bottom: 1.5rem;
    animation: fadeInScale 0.5s ease-out;
}

.beneficiary-box h3 {
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.prize-content {
    margin: 1rem 0;
}

.beneficiary-name {
    font-size: 1.2rem;
    color: #4ade80;
    margin-bottom: 0.5rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.prize-msg {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(to bottom, #ffffff, #a1a1aa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.ready-to-redeem {
    margin-top: 0.5rem;
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 400;
}

/* Staff Scanner Page */
.scanner-container {
    padding: 2rem;
    max-width: 600px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.scanner-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.qr-reader {
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: #000;
}

.scanner-result {
    margin-top: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    text-align: center;
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@media (max-width: 480px) {
    .beneficiary-box {
        padding: 1.5rem;
    }
    .scanner-container {
        padding: 1rem;
    }
}

/* Table responsiveness - Card conversion for mobile */
/* Scanner Translation & Styling (CSS-based to avoid breaking JS) */
#html5-qrcode-button-camera-permission { 
    font-size: 0 !important; 
    padding: 10px 20px !important;
    background: var(--accent-primary) !important;
    color: #000 !important;
    border-radius: 8px !important;
    cursor: pointer !important;
}
#html5-qrcode-button-camera-permission::after { 
    content: "Solicitar Permiso de Cámara"; 
    font-size: 0.9rem !important;
    font-weight: 600;
}

#html5-qrcode-anchor-scan-type-change {
    display: none !important;
}

#html5-qrcode-button-camera-start {
    font-size: 0 !important;
    background: var(--success) !important;
    color: #fff !important;
    padding: 8px 16px !important;
    border-radius: 8px !important;
}
#html5-qrcode-button-camera-start::after { content: "Iniciar Escaneo"; font-size: 0.9rem !important; }

#html5-qrcode-button-camera-stop {
    font-size: 0 !important;
    background: var(--danger) !important;
    color: #fff !important;
    padding: 8px 16px !important;
    border-radius: 8px !important;
}
#html5-qrcode-button-camera-stop::after { content: "Detener Escaneo"; font-size: 0.9rem !important; }

#html5-qrcode-select-camera {
    background: rgba(0,0,0,0.4) !important;
    color: #fff !important;
    border: 1px solid var(--glass-border) !important;
    border-radius: 8px !important;
    padding: 5px !important;
}

.table-wrapper {
    width: 100%;
    margin-top: 1rem;
}

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

/* Table responsiveness - Optimized compact view */
.table-wrapper {
    width: 100%;
    margin-top: 1rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
    background: rgba(0,0,0,0.2);
}

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

@media (max-width: 600px) {
    th, td {
        padding: 0.6rem 0.4rem;
        font-size: 0.8rem;
    }
    
    .btn-sm {
        padding: 6px 10px;
        font-size: 0.7rem;
    }

    .qr-info code {
        font-size: 0.7rem;
    }

    .qr-preview-canvas canvas {
        width: 40px !important;
        height: 40px !important;
    }
}

@media (max-width: 600px) {
    .card {
        padding: 1.2rem;
    }
}

.card-section {
    margin-bottom: 2rem;
}

.divider {
    border: 0;
    height: 1px;
    background: var(--glass-border);
    margin: 2rem 0;
}

.generator-section-layout {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 1rem;
}

.generator-actions {
    display: flex;
    gap: 1rem;
}

@media (max-width: 600px) {
    .generator-actions {
        flex-wrap: wrap;
        gap: 0.8rem;
    }
    .generator-actions .btn {
        flex: 1 1 140px; /* Force wrap but try to fill space */
        min-width: 140px;
    }
}

.form-group-inline {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.form-group-inline label {
    margin-bottom: 0;
    white-space: nowrap;
}

.form-group-inline input {
    width: 80px;
    padding: 8px 12px;
}

.form-group { margin-bottom: 1.5rem; }

.form-group-row {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    margin-bottom: 1.5rem;
}

.form-group-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

.form-group-toggle {
    margin-bottom: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 60px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.ref-hint {
    font-size: 0.8rem;
    color: var(--accent-primary);
    margin-left: 8px;
    font-weight: 400;
    opacity: 0.8;
}

.form-group-toggle label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.form-group-toggle input[type="checkbox"] {
    width: 24px;
    height: 24px;
    cursor: pointer;
}

input, textarea {
    width: 100%;
    background: rgba(0,0,0,0.4);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px 16px;
    color: #fff;
}

input[type="range"] {
    background: transparent;
    padding: 10px 10px;
    flex: 1;
    min-width: 0; /* Allow shrinking on mobile */
}

.range-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0,0,0,0.2);
    padding: 5px 10px;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
}

.btn-step {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--accent-primary);
    background: rgba(56, 189, 248, 0.1);
    color: var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 800;
    cursor: pointer;
    transition: 0.2s;
    user-select: none;
}

.btn-step:hover {
    background: var(--accent-primary);
    color: #000;
}

.btn-step:active {
    transform: scale(0.9);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

th {
    text-align: left;
    padding: 1rem;
    color: var(--text-muted);
    border-bottom: 1px solid var(--glass-border);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--glass-border);
    vertical-align: middle;
}

/* Badges de Estado mejorados */
.status-badge {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    display: inline-block;
}

.status-unused { 
    background: rgba(34, 197, 94, 0.15); 
    color: #4ade80; 
    border: 1px solid rgba(34, 197, 94, 0.4);
}

.status-used { 
    background: rgba(239, 68, 68, 0.15); 
    color: #f87171; 
    border: 1px solid rgba(239, 68, 68, 0.4);
}

/* Flyer & Poster Styles - Fix: Enforce 9:16 Aspect Ratio */
.flyer-container {
    background: #000;
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    overflow-y: auto; /* Permite scroll vertical si la pantalla es muy pequeña para el flyer */
}

.flyer-poster {
    position: relative;
    width: 90vw; /* Base width */
    max-width: 450px; /* Tamaño máximo razonable */
    aspect-ratio: 9 / 16;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    overflow: hidden;
    background: #000;
}

.poster-background {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 1;
}

.poster-background img {
    width: 100%; height: 100%;
    object-fit: cover; /* Cambiado a cover para llenar el 9:16 perfectamente */
}

.poster-overlay {
    position: absolute; /* Superpuesto al fondo */
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 2;
    display: flex;
    flex-direction: column;
    padding: 20px;
    pointer-events: none;
}

.poster-center {
    position: absolute;
    z-index: 3;
    pointer-events: auto;
}

.flyer-footer {
    position: absolute;
    width: 100%;
    z-index: 3;
    text-align: center;
    pointer-events: none;
}

.qr-display-box {
    background: #fff;
    padding: 10px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
    width: fit-content;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.qr-display-box canvas {
    display: block;
    width: 240px !important;
    height: 240px !important;
    border-radius: 4px;
}

.qr-instruction {
    font-size: 0.7rem;
    color: #000;
    margin: 0;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.8;
}

.status-box {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
}

.status-content {
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 24px;
    text-align: center;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    animation: fadeIn 0.3s ease-out;
}

.status-content h2 {
    font-size: 1.4rem;
    margin-bottom: 8px;
}

.flyer-text-footer {
    font-size: 2.2rem; /* Tamaño grande */
    font-weight: 800;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.admin-actions-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem; /* Reducido de 0.8rem */
    margin-top: 0.2rem;
    flex-wrap: nowrap;
}

/* Paginación */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 2rem;
    padding: 1rem;
}

.page-info {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.btn-page {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,0.05);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
}

.btn-page:hover:not(:disabled) {
    background: var(--accent-primary);
    color: black;
    border-color: var(--accent-primary);
}

.btn-page:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    backdrop-filter: blur(15px);
    background: rgba(15, 23, 42, 0.7);
    padding: 12px 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 100;
}

footer p {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.admin-container {
    padding-bottom: 80px; /* Espacio para el footer fijo */
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-overlay {
    z-index: 100000 !important;
}

/* Visibility checkboxes styling in admin panel */
.visibility-checks {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
    background: rgba(0, 0, 0, 0.2);
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
}

.check-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.82rem;
    color: var(--text-muted);
    user-select: none;
    transition: color 0.2s ease;
}

.check-label:hover {
    color: var(--text-main);
}

.check-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--accent-primary);
    margin: 0;
}

/* Success & Validation layout adjustments */
.poster-center {
    position: absolute;
    z-index: 3;
    pointer-events: auto;
    width: 90%;
    max-width: 360px;
}

.status-box {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
}

.status-content {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(15px);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    padding: 28px 24px;
    text-align: center;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    overflow-wrap: break-word;
    word-wrap: break-word;
    word-break: break-word;
    width: 100%;
}

.success-icon {
    font-size: 2.2rem;
    color: #4ade80;
    background: rgba(74, 222, 128, 0.15);
    border: 2px solid #4ade80;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 5px;
    box-shadow: 0 4px 15px rgba(74, 222, 128, 0.2);
}

.error-icon {
    font-size: 2.2rem;
    color: #f87171;
    background: rgba(248, 113, 113, 0.15);
    border: 2px solid #f87171;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 5px;
    box-shadow: 0 4px 15px rgba(248, 113, 113, 0.2);
}

.prize-msg {
    font-size: 1.35rem !important;
    font-weight: 700 !important;
    line-height: 1.4 !important;
    color: #fff !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    margin: 12px 0 6px !important;
    overflow-wrap: break-word;
    word-wrap: break-word;
    word-break: break-word;
    -webkit-text-fill-color: initial !important;
    background: none !important;
}

/* ── Promotion Bar (compact) ──────────────────────────────────── */
.promo-bar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 6px 12px;
    background: rgba(124, 58, 237, 0.08);
    border: 1px solid rgba(124, 58, 237, 0.3);
    border-radius: 12px;
    margin-bottom: 4px;
    margin-top: 6px;
}

.promo-bar .promo-select-wrap {
    flex-shrink: 0;
    min-width: 130px;
    max-width: 180px;
    position: relative;
    display: flex;
    align-items: center;
}

.promo-select-icon {
    position: absolute;
    left: 10px;
    color: #7c3aed;
    font-size: 0.75rem;
    pointer-events: none;
    z-index: 1;
}

.promo-select {
    width: 100%;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(124, 58, 237, 0.35);
    border-radius: 8px;
    padding: 7px 28px 7px 28px;
    color: #f1f5f9;
    font-size: 0.82rem;
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%237c3aed' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
}

.promo-select:focus { border-color: #7c3aed; }
.promo-select option { background: #1e293b; color: #f1f5f9; }

.promo-bar-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.promo-name-input {
    flex: 1;
    min-width: 120px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 7px 12px;
    color: #f1f5f9;
    font-size: 0.85rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 500;
    outline: none;
    transition: border-color 0.2s;
    width: auto;
}

.promo-name-input::placeholder { color: #475569; }
.promo-name-input:focus {
    border-color: rgba(124, 58, 237, 0.6);
    background: rgba(0, 0, 0, 0.4);
}

@media (max-width: 480px) {
    .promo-bar { gap: 6px; padding: 8px 10px; }
    .promo-bar .promo-select-wrap { max-width: 100%; flex: 1 1 100%; }
    .promo-name-input { flex: 1 1 100%; }
}

#delete-promo-btn {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

#delete-promo-btn:hover:not(:disabled) {
    background: rgba(239, 68, 68, 0.28);
    border-color: #f87171;
}

#delete-promo-btn:disabled {
    cursor: not-allowed;
}
