/**
 * Estilos para el Sistema de Sugerencias
 * UGT-CLM-UGR Granada
 */

/* ====================================
   BOTÓN FLOTANTE
   ==================================== */

.suggestions-floating-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #E30613, #c00510);
    color: white;
    border: none;
    border-radius: 50%;
    box-shadow: 0 8px 25px rgba(227, 6, 19, 0.4);
    cursor: pointer;
    font-size: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9998;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    animation: pulse-float 2s infinite;
}

.suggestions-floating-btn:hover {
    transform: scale(1.1) rotate(10deg);
    box-shadow: 0 12px 35px rgba(227, 6, 19, 0.6);
}

.suggestions-floating-btn:active {
    transform: scale(0.95);
}

/* Tooltip del botón flotante */
.suggestions-floating-btn::before {
    content: "Sugerencias";
    position: absolute;
    right: 80px;
    background: #333;
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    font-size: 14px;
    font-weight: 500;
}

.suggestions-floating-btn:hover::before {
    opacity: 1;
}

@keyframes pulse-float {
    0%, 100% {
        box-shadow: 0 8px 25px rgba(227, 6, 19, 0.4);
    }
    50% {
        box-shadow: 0 8px 35px rgba(227, 6, 19, 0.7);
    }
}

/* ====================================
   MODAL
   ==================================== */

.suggestions-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.suggestions-modal-content {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

.suggestions-modal-header {
    background: linear-gradient(135deg, #E30613, #c00510);
    color: white;
    padding: 25px 30px;
    border-radius: 20px 20px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.suggestions-modal-header h2 {
    margin: 0;
    font-size: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.suggestions-close-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.suggestions-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.suggestions-modal-body {
    padding: 30px;
}

.suggestions-intro {
    color: #666;
    margin-bottom: 25px;
    line-height: 1.6;
    font-size: 15px;
}

/* ====================================
   FORMULARIO
   ==================================== */

.suggestions-form .form-group {
    margin-bottom: 20px;
}

.suggestions-form label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.suggestions-form label i {
    color: #E30613;
}

.suggestions-form input[type="text"],
.suggestions-form input[type="email"],
.suggestions-form select,
.suggestions-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s;
    box-sizing: border-box;
}

.suggestions-form input[type="text"]:focus,
.suggestions-form input[type="email"]:focus,
.suggestions-form select:focus,
.suggestions-form textarea:focus {
    outline: none;
    border-color: #E30613;
    box-shadow: 0 0 0 3px rgba(227, 6, 19, 0.1);
}

.suggestions-form textarea {
    resize: vertical;
    min-height: 120px;
}

.suggestions-form small {
    display: block;
    margin-top: 5px;
    color: #999;
    font-size: 12px;
}

/* Checkbox anónimo */
.checkbox-group {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    border: 2px solid #e0e0e0;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600 !important;
    margin-bottom: 5px !important;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #E30613;
}

.checkbox-label span {
    flex: 1;
}

/* Transición para campos personales */
#personal-fields {
    transition: all 0.3s ease;
    overflow: hidden;
}

/* ====================================
   BOTONES
   ==================================== */

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.btn-primary,
.btn-secondary {
    flex: 1;
    padding: 14px 20px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #E30613, #c00510);
    color: white;
    box-shadow: 0 4px 15px rgba(227, 6, 19, 0.3);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(227, 6, 19, 0.4);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-secondary {
    background: #f8f9fa;
    color: #666;
    border: 2px solid #e0e0e0;
}

.btn-secondary:hover {
    background: #e9ecef;
    border-color: #d0d0d0;
}

/* ====================================
   MENSAJES
   ==================================== */

.suggestions-message {
    margin-top: 20px;
    padding: 25px 30px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    line-height: 1.6;
    text-align: center;
    animation: slideDown 0.4s ease, pulse 0.5s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.suggestions-message.success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    color: #155724;
    border: 3px solid #28a745;
}

.suggestions-message.error {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    color: #721c24;
    border: 3px solid #dc3545;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
}

/* ====================================
   ANIMACIONES
   ==================================== */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* ====================================
   RESPONSIVE
   ==================================== */

@media (max-width: 768px) {
    .suggestions-floating-btn {
        width: 60px;
        height: 60px;
        font-size: 24px;
        bottom: 20px;
        right: 20px;
    }

    .suggestions-floating-btn::before {
        display: none;
    }

    .suggestions-modal-content {
        max-height: 95vh;
        border-radius: 15px;
    }

    .suggestions-modal-header {
        padding: 20px;
        border-radius: 15px 15px 0 0;
    }

    .suggestions-modal-header h2 {
        font-size: 20px;
    }

    .suggestions-modal-body {
        padding: 20px;
    }

    .form-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}

/* Accesibilidad */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
