/* Feedback System - Frontend Styles */

/* ================================
   Animated Feedback Button
   ================================ */

.feedback-button-container {
    display: inline-block;
    margin: 20px 0;
}

.feedback-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 10px;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    animation: pulse 2s ease-in-out infinite;
}

.feedback-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.feedback-button:hover::before {
    width: 300px;
    height: 300px;
}

.feedback-button:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.6);
    animation: none;
}

.feedback-button:active {
    transform: translateY(-1px) scale(1.02);
}

.feedback-button-icon {
    font-size: 16px;
    position: relative;
    z-index: 1;
    animation: bounce 2s ease-in-out infinite;
}

.feedback-button-text {
    position: relative;
    z-index: 1;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    }

    50% {
        box-shadow: 0 10px 40px rgba(102, 126, 234, 0.7), 0 0 0 10px rgba(102, 126, 234, 0.1);
    }
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

/* ================================
   Modal Styles
   ================================ */

.feedback-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feedback-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.feedback-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
}

.feedback-modal-content {
    position: relative;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.feedback-modal.active .feedback-modal-content {
    transform: scale(1);
}

/* Custom Scrollbar */
.feedback-modal-content::-webkit-scrollbar {
    width: 8px;
}

.feedback-modal-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.feedback-modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 4px;
}

.feedback-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.feedback-modal-close:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.feedback-modal-close:active {
    transform: scale(0.95);
}

.feedback-modal-close svg {
    stroke-width: 2.5;
}

/* ================================
   Modal Header
   ================================ */

.feedback-modal-header {
    text-align: center;
    margin-bottom: 32px;
}

.feedback-modal-title {
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 8px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feedback-modal-subtitle {
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* ================================
   Feedback Type Selector
   ================================ */

.feedback-type-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
    transition: opacity 0.3s ease, max-height 0.3s ease;
    overflow: hidden;
}

.feedback-type-selector.hidden {
    opacity: 0;
    max-height: 0;
    margin-bottom: 0;
    pointer-events: none;
}

.feedback-type-option {
    position: relative;
    cursor: pointer;
}

.feedback-type-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.feedback-type-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.feedback-type-option:hover .feedback-type-label {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(102, 126, 234, 0.5);
    transform: translateY(-2px);
}

.feedback-type-option input[type="radio"]:checked+.feedback-type-label {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
    border-color: #667eea;
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
}

.feedback-type-icon {
    font-size: 28px;
}

.feedback-type-text {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    text-align: center;
}

/* ================================
   Selected Type Display
   ================================ */

.feedback-selected-type {
    display: none;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15) 0%, rgba(118, 75, 162, 0.15) 100%);
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    margin-bottom: 20px;
}

.feedback-selected-type.active {
    display: flex;
}

.feedback-selected-type-icon {
    font-size: 28px;
}

.feedback-selected-type-info {
    flex: 1;
}

.feedback-selected-type-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.feedback-selected-type-name {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
}

.feedback-back-btn {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.feedback-back-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(-3px);
}

/* ================================
   Form Styles
   ================================ */

.feedback-form-group {
    margin-bottom: 24px;
    transition: opacity 0.3s ease, max-height 0.3s ease;
}

.feedback-form-group.hidden {
    opacity: 0;
    max-height: 0;
    margin: 0;
    overflow: hidden;
    pointer-events: none;
}

.feedback-form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 8px;
}

.feedback-form-textarea,
.feedback-form-input {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s ease;
    resize: vertical;
}

.feedback-form-textarea:focus,
.feedback-form-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.feedback-form-textarea::placeholder,
.feedback-form-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

/* ================================
   Form Actions
   ================================ */

.feedback-form-actions {
    margin-top: 32px;
    display: flex;
    justify-content: center;
}

.feedback-form-submit {
    max-width: 250px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.feedback-form-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.feedback-form-submit:active {
    transform: translateY(0);
}

.feedback-form-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.feedback-submit-icon {
    font-size: 20px;
}

/* ================================
   Messages
   ================================ */

.feedback-form-message {
    margin-top: 16px;
    padding: 14px 18px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    display: none;
    animation: slideIn 0.3s ease;
}

.feedback-form-message.success {
    display: block;
    background: rgba(52, 199, 89, 0.2);
    border: 2px solid rgba(52, 199, 89, 0.5);
    color: #34c759;
}

.feedback-form-message.error {
    display: block;
    background: rgba(255, 59, 48, 0.2);
    border: 2px solid rgba(255, 59, 48, 0.5);
    color: #ff3b30;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================================
   Responsive Design
   ================================ */

@media (max-width: 768px) {
    .feedback-button-container {
        margin: 15px 0;
    }

    .feedback-button {
        padding: 6px 16px;
        font-size: 12px;
    }

    .feedback-button-icon {
        font-size: 14px;
    }

    .feedback-button-text {
        font-size: 12px;
    }

    .feedback-modal-content {
        padding: 28px 20px;
        border-radius: 20px;
        width: 95%;
    }

    .feedback-modal-title {
        font-size: 24px;
    }

    .feedback-modal-subtitle {
        font-size: 14px;
    }

    .feedback-type-selector {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .feedback-type-icon {
        font-size: 24px;
    }

    .feedback-type-text {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .feedback-button-container {
        margin: 10px 0;
        width: 100%;
        max-width: 100%;
    }

    .feedback-button {
        padding: 6px 14px;
        font-size: 11px;
        width: auto;
        max-width: 100%;
        justify-content: center;
    }

    .feedback-button-icon {
        font-size: 13px;
    }

    .feedback-button-text {
        font-size: 11px;
        letter-spacing: 0.5px;
    }

    .feedback-modal-content {
        width: 95%;
        padding: 24px 16px;
    }

    .feedback-type-selector {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .feedback-type-label {
        padding: 12px 8px;
    }

    .feedback-form-submit {
        max-width: 100%;
        padding: 16px 24px;
        font-size: 15px;
    }
}