/* yo/css/pages/master-dashboard.css - Fixed */

.dashboard-wrapper {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    padding: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Sidebar */
.dashboard-sidebar {
    background: white;
    border-radius: 16px;
    padding: 0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.master-profile-card {
    padding: 30px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--green) 0%, #0da558 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
    overflow: hidden;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    margin: 0 0 5px 0;
    font-size: 20px;
    color: #333;
}

.profile-profession {
    color: #666;
    font-size: 14px;
    margin: 0 0 15px 0;
}

.profile-rating {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.profile-rating .stars {
    color: #FFD700;
    font-size: 16px;
}

.profile-rating .review-count {
    font-size: 12px;
    color: #999;
}

/* Navigation */
.dashboard-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.dashboard-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 30px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
    position: relative;
}

.dashboard-nav .nav-link:hover {
    background: #f8f9fa;
    color: var(--green);
}

.dashboard-nav .nav-link.active {
    background: linear-gradient(90deg, rgba(16,195,108,0.1) 0%, transparent 100%);
    color: var(--green);
    border-left-color: var(--green);
    font-weight: 600;
}

.dashboard-nav .nav-link i {
    width: 20px;
    font-size: 18px;
}

.badge {
    background: var(--green);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: bold;
    margin-left: auto;
}

/* Main Content */
.dashboard-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    min-height: 600px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-content h2 {
    margin: 0 0 25px 0;
    color: #333;
    font-size: 28px;
}

.tab-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    gap: 20px;
    align-items: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.stat-icon {
    font-size: 36px;
    color: var(--green);
    width: 50px;
    text-align: center;
}

.stat-info {
    flex: 1;
}

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    margin-bottom: 5px;
}

.stat-label {
    color: #666;
    font-size: 14px;
}

/* Recent Section */
.recent-section {
    margin-top: 30px;
}

.recent-section h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 22px;
}

.orders-preview {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.order-preview-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 4px solid var(--green);
    transition: all 0.3s ease;
}

.order-preview-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.order-info h4 {
    margin: 0 0 5px 0;
    font-size: 16px;
    color: #333;
}

.order-info p {
    margin: 0 0 5px 0;
    color: #666;
    font-size: 14px;
}

.order-date {
    font-size: 12px;
    color: #999;
}

/* Orders */
.order-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid #e0e0e0;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: var(--green);
    color: var(--green);
}

.filter-btn.active {
    background: var(--green);
    color: white;
    border-color: var(--green);
}

.orders-list,
.reviews-list,
.services-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.order-card,
.review-card,
.service-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    border-left: 4px solid var(--green);
}

.order-header,
.review-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 15px;
}

.order-header h4,
.review-header h4 {
    margin: 0 0 5px 0;
    font-size: 18px;
    color: #333;
}

.order-client {
    color: #666;
    font-size: 14px;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 5px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-pending { background: #FFF3CD; color: #856404; }
.status-confirmed { background: #CCE5FF; color: #004085; }
.status-in_progress { background: #D1ECF1; color: #0C5460; }
.status-completed { background: #D4EDDA; color: #155724; }
.status-cancelled { background: #F8D7DA; color: #721C24; }

.order-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.detail-row {
    display: flex;
    gap: 10px;
}

.detail-label {
    font-weight: 600;
    color: #666;
    min-width: 100px;
}

.price {
    color: var(--green);
    font-weight: 700;
    font-size: 16px;
}

.order-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 15px;
}

.order-actions label {
    font-weight: 600;
    color: #666;
}

.status-select {
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    background: white;
    transition: border-color 0.3s ease;
}

.status-select:focus {
    outline: none;
    border-color: var(--green);
}

/* Reviews */
.review-rating {
    color: #FFD700;
    font-size: 16px;
    margin-top: 5px;
}

.review-date {
    font-size: 12px;
    color: #999;
}

.review-service {
    color: #666;
    font-size: 14px;
    margin: 10px 0 5px 0;
    font-style: italic;
}

.review-comment {
    color: #555;
    line-height: 1.6;
    margin: 10px 0 0 0;
}

/* Services */
.service-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.service-info h4 {
    margin: 0 0 5px 0;
    font-size: 18px;
    color: #333;
}

.service-info p {
    color: #666;
    font-size: 14px;
    margin: 0;
}

.service-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.service-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--green);
}

.btn-delete {
    background: #f44336;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn-delete:hover {
    background: #d32f2f;
    transform: scale(1.05);
}

/* Settings Form */
.settings-form {
    max-width: 600px;
}

.form-section {
    margin-bottom: 30px;
}

.form-section h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e0e0e0;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--green);
}

.form-group input[readonly] {
    background: #f5f5f5;
    cursor: not-allowed;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

#photoPreview {
    margin-top: 10px;
}

#photoPreview img {
    max-width: 200px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.btn-primary,
.btn-save {
    background: var(--green);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.btn-primary:hover,
.btn-save:hover {
    background: #0da558;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 195, 108, 0.3);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
}

.modal-content {
    background: white;
    margin: 10% auto;
    padding: 30px;
    border-radius: 16px;
    max-width: 500px;
    position: relative;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}

.modal-content h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 24px;
}

.close {
    position: absolute;
    right: 15px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #333;
}

/* Messages */
.loading,
.empty-message,
.error-message {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 16px;
}

.empty-message {
    color: #666;
}

.error-message {
    color: #f44336;
}

/* Notification */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 10000;
    animation: slideIn 0.3s ease;
    font-weight: 600;
}

.notification.success {
    background: #10C36C;
    color: white;
}

.notification.error {
    background: #f44336;
    color: white;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive */
@media (max-width: 1024px) {
    .dashboard-wrapper {
        grid-template-columns: 1fr;
    }
    
    .dashboard-sidebar {
        position: static;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .dashboard-wrapper {
        padding: 15px;
    }
    
    .dashboard-content {
        padding: 20px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .order-filters {
        flex-wrap: wrap;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .order-header,
    .review-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .service-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .service-actions {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 480px) {
    .tab-content h2 {
        font-size: 22px;
    }
    
    .stat-value {
        font-size: 24px;
    }
    
    .modal-content {
        margin: 20% 15px;
        padding: 20px;
    }
}