/* =============================================
   Q&A System - Frontend Styles
   ============================================= */

/* --- Форма добавления вопроса --- */
.mqas-form-wrapper {
    max-width: 700px;
    margin: 30px 0;
    padding: 30px;
    background: #f9f9fb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.mqas-form-wrapper h3 {
    font-size: 24px;
    margin-top: 0;
    margin-bottom: 25px;
    color: #1e293b;
    font-weight: 600;
}

.mqas-form-wrapper label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    color: #334155;
    font-size: 15px;
}

.mqas-form-wrapper textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s ease;
    background: white;
    color: #1e293b;
    resize: vertical;
    box-sizing: border-box;
}

.mqas-form-wrapper textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.mqas-form-wrapper textarea#question {
    min-height: 80px;
}

.mqas-form-wrapper textarea#answer {
    min-height: 150px;
}

.mqas-form-wrapper input[type="submit"] {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    padding: 12px 32px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(59, 130, 246, 0.25);
    margin-top: 5px;
}

.mqas-form-wrapper input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(59, 130, 246, 0.35);
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
}

.mqas-form-wrapper input[type="submit"]:active {
    transform: translateY(0);
}

.mqas-form-wrapper p {
    margin-bottom: 20px;
}

/* --- Сообщения --- */
.mqas-success {
    background: #ecfdf5;
    border: 2px solid #34d399;
    padding: 20px 25px;
    border-radius: 8px;
    color: #065f46;
    font-weight: 500;
    margin: 20px 0;
}

.mqas-error {
    background: #fef2f2;
    border: 2px solid #f87171;
    padding: 20px 25px;
    border-radius: 8px;
    color: #991b1b;
    font-weight: 500;
    margin: 20px 0;
}

.mqas-info {
    background: #eff6ff;
    border: 2px solid #60a5fa;
    padding: 20px 25px;
    border-radius: 8px;
    color: #1e3a8a;
    font-weight: 500;
    margin: 20px 0;
}

/* --- Список опубликованных вопросов --- */
.mqas-questions-list {
    max-width: 800px;
    margin: 30px 0;
}

.mqas-questions-list .mqas-single {
    background: #ffffff;
    padding: 25px 30px;
    margin-bottom: 25px;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.mqas-questions-list .mqas-single:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

.mqas-questions-list .mqas-single h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 20px;
    color: #1e293b;
    font-weight: 600;
    line-height: 1.4;
}

.mqas-questions-list .mqas-single h3 a {
    color: #1e293b;
    text-decoration: none;
    transition: color 0.3s ease;
}

.mqas-questions-list .mqas-single h3 a:hover {
    color: #3b82f6;
}

.mqas-questions-list .mqas-answer {
    padding: 20px;
    background: #f8fafc;
    border-left: 4px solid #3b82f6;
    border-radius: 6px;
    color: #334155;
    line-height: 1.7;
    font-size: 15px;
}

.mqas-questions-list .mqas-answer p:last-child {
    margin-bottom: 0;
}

.mqas-questions-list .mqas-meta {
    color: #94a3b8;
    font-size: 13px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #f1f5f9;
}

.mqas-questions-list .mqas-meta .author-name {
    font-weight: 600;
    color: #475569;
}

/* --- Медиа-запросы для адаптива --- */
@media (max-width: 768px) {
    .mqas-form-wrapper {
        padding: 20px;
    }
    
    .mqas-questions-list .mqas-single {
        padding: 20px;
    }
    
    .mqas-questions-list .mqas-single h3 {
        font-size: 18px;
    }
    
    .mqas-form-wrapper input[type="submit"] {
        width: 100%;
        justify-content: center;
    }
}