/**
 * YouDo Core - Frontend Styles
 */

/* Общие стили */
.youdo-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Стили для форм */
.youdo-form {
    background: #ffffff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.youdo-form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.youdo-form-input,
.youdo-form-textarea,
.youdo-form-select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
}

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

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

/* Кнопки */
.youdo-btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    text-decoration: none;
}

.youdo-btn-primary {
    background: #3b82f6;
    color: #ffffff;
}

.youdo-btn-primary:hover {
    background: #2563eb;
    color: #ffffff;
}

.youdo-btn-success {
    background: #10b981;
    color: #ffffff;
}

.youdo-btn-success:hover {
    background: #059669;
    color: #ffffff;
}

.youdo-btn-danger {
    background: #ef4444;
    color: #ffffff;
}

.youdo-btn-danger:hover {
    background: #dc2626;
    color: #ffffff;
}

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

/* Карточки заданий */
.youdo-task-card {
    background: #ffffff;
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.youdo-task-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.youdo-task-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #1f2937;
}

.youdo-task-title a {
    color: #1f2937;
    text-decoration: none;
}

.youdo-task-title a:hover {
    color: #3b82f6;
}

.youdo-task-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 12px;
    color: #6b7280;
    font-size: 14px;
}

.youdo-task-description {
    color: #4b5563;
    margin-bottom: 16px;
    line-height: 1.6;
}

.youdo-task-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

/* Бейджи статусов */
.youdo-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

/* Фильтры */
.youdo-filters {
    background: #f9fafb;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 24px;
}

.youdo-filters-row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-end;
}

.youdo-filter-group {
    flex: 1;
    min-width: 200px;
}

/* Сообщения */
.youdo-message {
    padding: 16px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.youdo-message-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.youdo-message-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #ef4444;
}

.youdo-message-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #3b82f6;
}

/* Загрузка */
.youdo-loading {
    text-align: center;
    padding: 40px;
}

.youdo-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f4f6;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: youdo-spin 1s linear infinite;
}

@keyframes youdo-spin {
    to { transform: rotate(360deg); }
}

/* Личный кабинет */
.youdo-dashboard-nav {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 2px solid #e5e7eb;
}

.youdo-dashboard-nav-item {
    padding: 12px 24px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s;
    color: #6b7280;
    text-decoration: none;
}

.youdo-dashboard-nav-item:hover {
    color: #3b82f6;
}

.youdo-dashboard-nav-item.active {
    color: #3b82f6;
    border-bottom-color: #3b82f6;
}

/* Адаптивность */
@media (max-width: 768px) {
    .youdo-container {
        padding: 10px;
    }

    .youdo-form {
        padding: 20px;
    }

    .youdo-filters-row {
        flex-direction: column;
    }

    .youdo-filter-group {
        width: 100%;
    }

    .youdo-task-footer {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}

/* Скрыть элементы */
.youdo-hidden {
    display: none !important;
}

/* Список откликов */
.youdo-bids-list {
    margin-top: 24px;
}

.youdo-bid-item {
    background: #f9fafb;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 16px;
    border: 1px solid #e5e7eb;
}

.youdo-bid-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.youdo-bid-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.youdo-bid-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

.youdo-bid-info h4 {
    margin: 0;
    font-weight: 600;
}

.youdo-bid-price {
    font-size: 18px;
    font-weight: 700;
    color: #3b82f6;
}

.youdo-bid-comment {
    color: #4b5563;
    line-height: 1.6;
    margin-bottom: 12px;
}

.youdo-bid-actions {
    display: flex;
    gap: 8px;
}
