/* Reseteo de estilos */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Estilos del cuerpo */
body {
    font-family: 'Arial Black', 'Arial Bold', Gadget, sans-serif;
    background: #f0f0f0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* Dispositivo principal */
.device {
    background: #e8e6dc;
    border-radius: 12px;
    padding: 35px 40px;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    max-width: 320px;
    width: 100%;
    position: relative;
}

.device::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 12px;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
    pointer-events: none;
}

/* Título */
.title {
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: #666;
    margin-bottom: 25px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Fila de switch */
.switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 22px;
    cursor: pointer;
    user-select: none;
}

.switch-row:last-child {
    margin-bottom: 0;
}

/* Etiqueta del switch */
.label {
    font-size: 18px;
    font-weight: 900;
    color: #1a1a1a;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Switch físico tipo toggle */
.switch {
    position: relative;
    width: 48px;
    height: 24px;
    background: #2a2a2a;
    border-radius: 12px;
    box-shadow: 
        inset 0 2px 4px rgba(0, 0, 0, 0.4),
        0 1px 2px rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.switch::before {
    content: '';
    position: absolute;
    inset: 2px;
    background: #1a1a1a;
    border-radius: 10px;
}

.switch-row.active .switch {
    background: #2a2a2a;
}

/* Deslizador del switch */
.slider {
    position: absolute;
    width: 20px;
    height: 20px;
    background: linear-gradient(145deg, #ffffff, #e0e0e0);
    border-radius: 10px;
    top: 2px;
    left: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.3),
        inset 0 1px 1px rgba(255, 255, 255, 0.8);
    z-index: 2;
}

.switch-row.active .slider {
    left: 26px;
    background: linear-gradient(145deg, #f5f5f5, #d0d0d0);
}

/* Área de mensaje */
.message-area {
    margin-top: 30px;
    padding: 18px;
    background: rgba(0, 0, 0, 0.03);
    border-radius: 8px;
    min-height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 2px solid rgba(0, 0, 0, 0.05);
}

.message {
    font-size: 13px;
    font-weight: 700;
    color: #4a4a4a;
    line-height: 1.5;
    letter-spacing: 0.3px;
}

/* Animación de sacudida al intentar activar tercer switch */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-5px); }
    40% { transform: translateX(5px); }
    60% { transform: translateX(-5px); }
    80% { transform: translateX(5px); }
}

.shake {
    animation: shake 0.4s ease-in-out;
}

/* Efecto hover */
.switch-row:hover .label {
    color: #000;
}

.switch-row:hover .switch {
    box-shadow: 
        inset 0 2px 4px rgba(0, 0, 0, 0.5),
        0 1px 2px rgba(255, 255, 255, 0.2);
}

/* Responsive para móviles */
@media (max-width: 400px) {
    .device {
        padding: 30px 25px;
    }

    .label {
        font-size: 16px;
    }

    .switch {
        width: 44px;
        height: 22px;
    }

    .slider {
        width: 18px;
        height: 18px;
    }

    .switch-row.active .slider {
        left: 24px;
    }
}
