﻿/* Estilos generales y variables */
:root {
    --primary-color: #FF6B6B;
    --secondary-color: #4ECDC4;
    --accent-color: #667eea;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --card-bg: white;
    --border-radius-lg: 20px;
    --border-radius-md: 15px;
    --shadow-light: 0 10px 40px rgba(0,0,0,0.1);
}

/* Sección de Reglas del Evento */
.rules-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

    .rules-header h2 {
        font-size: 1.5rem;
        font-weight: 700;
        color: var(--text-color);
    }

.btn-add {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

    .btn-add:hover {
        background: #5469d4;
    }

/* Lista de reglas */
.rules-list {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.rule-item {
    background: var(--light-bg);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .rule-item:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }

.rule-content {
    flex-grow: 1;
}

    .rule-content h4 {
        font-size: 1.1rem;
        color: var(--primary-color);
        margin-bottom: 0.2rem;
    }

    .rule-content p {
        font-size: 0.9rem;
        color: #666;
    }

.rule-actions {
    display: flex;
    gap: 0.5rem;
}

    .rule-actions button {
        background: none;
        border: none;
        cursor: pointer;
        font-size: 1rem;
        color: #999;
        transition: color 0.2s ease;
    }

        .rule-actions button:hover {
            color: var(--accent-color);
        }

        .rule-actions button.btn-edit:hover {
            color: var(--secondary-color);
        }

        .rule-actions button.btn-delete:hover {
            color: var(--primary-color);
        }

/* Modal y formulario */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    padding-top: 60px;
}

.modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 600px;
    position: relative;
    box-shadow: var(--shadow-light);
}

    .modal-content h3 {
        font-family: 'Poppins', sans-serif;
        color: var(--accent-color);
        margin-bottom: 1rem;
    }

.close-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 15px;
    right: 25px;
}

    .close-btn:hover,
    .close-btn:focus {
        color: var(--primary-color);
    }

.form-group {
    margin-bottom: 1rem;
}

    .form-group label {
        display: block;
        margin-bottom: 0.5rem;
        font-weight: 600;
    }

    .form-group input, .form-group textarea {
        width: 100%;
        padding: 0.75rem;
        border: 1px solid #ccc;
        border-radius: 8px;
        font-size: 1rem;
        transition: border-color 0.3s ease;
    }

        .form-group input:focus, .form-group textarea:focus {
            outline: none;
            border-color: var(--accent-color);
        }

.btn-submit {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background 0.3s ease;
}

    .btn-submit:hover {
        background: #5469d4;
    }

.empty-state {
    text-align: center;
    padding: 2rem;
    color: #888;
}