/* ============================================
   MESSAGES PAGE STYLES
   ============================================ */

.message-compose {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(16, 185, 129, 0.05) 100%);
    border: 2px solid rgba(16, 185, 129, 0.3);
    margin-bottom: 3rem;
    padding: 2rem;
}

.message-compose h3 {
    color: #10b981;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.message-compose form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.message-compose .form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.message-compose label {
    color: #10b981;
    font-weight: 600;
    font-size: 0.95rem;
}

.message-compose input,
.message-compose textarea {
    padding: 0.8rem 1rem;
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.message-compose input:focus,
.message-compose textarea:focus {
    outline: none;
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.2);
}

.message-compose textarea {
    resize: vertical;
    min-height: 120px;
}

/* Messages Container */
.messages-container {
    margin-top: 3rem;
}

.messages-container h2 {
    color: #10b981;
    margin-bottom: 2rem;
    font-size: 1.5rem;
}

/* Messages List */
.messages-list {
    display: grid;
    gap: 1.5rem;
}

.message-card {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.3) 0%, rgba(16, 185, 129, 0.1) 100%);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.message-card:hover {
    border-color: #10b981;
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.15);
    transform: translateY(-2px);
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 1rem;
}

.message-title {
    color: #10b981;
    font-size: 1.2rem;
    font-weight: 600;
    word-break: break-word;
}

.message-author {
    color: #999;
    font-size: 0.9rem;
}

.message-time {
    color: #666;
    font-size: 0.85rem;
}

.message-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-edit {
    padding: 0.5rem 1rem;
    background: none;
    border: 1px solid rgba(16, 185, 129, 0.5);
    color: #10b981;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.btn-edit:hover {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.message-content {
    color: #e0e0e0;
    line-height: 1.6;
    word-break: break-word;
    white-space: pre-wrap;
}

.message-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #10b981;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 2rem;
    color: #999;
}

.empty-state-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.3s ease;
}

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

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

.modal-content {
    background: linear-gradient(135deg, rgb(20, 40, 80) 0%, rgb(15, 30, 60) 100%);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(16, 185, 129, 0.3);
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    position: relative;
    animation: slideIn 0.3s ease;
}

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

.modal-close {
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 1.5rem;
    cursor: pointer;
    color: #999;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #10b981;
}

.modal-content h3 {
    color: #10b981;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.modal-content form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.modal-content .form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.modal-content label {
    color: #10b981;
    font-weight: 600;
}

.modal-content input,
.modal-content textarea {
    padding: 0.8rem 1rem;
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
}

.modal-content input:focus,
.modal-content textarea:focus {
    outline: none;
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    .message-compose {
        padding: 1.5rem;
    }

    .message-card {
        padding: 1rem;
    }

    .message-header {
        flex-direction: column;
    }

    .modal-content {
        width: 95%;
    }
}
