/* OYT Customer Dashboard Styles */

.oyt-customer-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Header */
.oyt-dashboard-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.oyt-dashboard-header h2 {
    margin: 0 0 10px 0;
    font-size: 2.5em;
    font-weight: 700;
}

.oyt-dashboard-header p {
    margin: 0;
    font-size: 1.1em;
    opacity: 0.9;
}

/* Customer Search */
.oyt-customer-search {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    margin-bottom: 30px;
    text-align: center;
}

.search-form {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.phone-input {
    padding: 15px 20px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 16px;
    width: 250px;
    transition: all 0.3s ease;
}

.phone-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-btn {
    padding: 15px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.search-help {
    color: #666;
    font-size: 14px;
}

/* Loading */
.oyt-loading {
    text-align: center;
    padding: 40px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    margin-bottom: 30px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Customer Info */
.oyt-customer-info {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    overflow: hidden;
}

/* Customer Profile */
.customer-profile {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-avatar {
    font-size: 3em;
    background: rgba(255,255,255,0.2);
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-details h3 {
    margin: 0 0 10px 0;
    font-size: 1.8em;
    font-weight: 700;
}

.profile-details p {
    margin: 5px 0;
    opacity: 0.9;
    font-size: 1.1em;
}

/* Tabs */
.dashboard-tabs {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #e1e5e9;
    overflow-x: auto;
}

.tab-btn {
    padding: 15px 25px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    transition: all 0.3s ease;
    white-space: nowrap;
    border-bottom: 3px solid transparent;
}

.tab-btn:hover {
    background: #e9ecef;
    color: #333;
}

.tab-btn.active {
    background: white;
    color: #667eea;
    border-bottom-color: #667eea;
}

/* Tab Content */
.tab-content {
    padding: 30px;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* Overview Stats */
.overview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.stat-icon {
    font-size: 2.5em;
    margin-bottom: 15px;
}

.stat-info h4 {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-info span {
    font-size: 2em;
    font-weight: 700;
    color: #333;
}

/* Recent Activity */
.recent-activity {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
}

.recent-activity h4 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 1.3em;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.activity-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.activity-icon {
    font-size: 1.5em;
    width: 40px;
    text-align: center;
}

.activity-details h5 {
    margin: 0 0 5px 0;
    font-size: 14px;
    color: #333;
}

.activity-details p {
    margin: 0;
    font-size: 12px;
    color: #666;
}

.activity-amount {
    margin-left: auto;
    font-weight: 600;
    color: #667eea;
}

/* Lists */
.vehicles-list, .orders-list, .appointments-list, .campaigns-list {
    display: grid;
    gap: 15px;
}

.list-item {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
}

.list-item:hover {
    background: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.list-item h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 1.1em;
}

.list-item p {
    margin: 5px 0;
    color: #666;
    font-size: 14px;
}

.list-item .status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.status.completed { background: #d4edda; color: #155724; }
.status.pending { background: #fff3cd; color: #856404; }
.status.cancelled { background: #f8d7da; color: #721c24; }

/* Balance */
.balance-info {
    display: grid;
    gap: 30px;
}

.balance-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
}

.balance-card h4 {
    margin: 0 0 15px 0;
    font-size: 1.2em;
    opacity: 0.9;
}

.balance-amount {
    font-size: 3em;
    font-weight: 700;
}

.balance-history {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
}

.balance-history h4 {
    margin: 0 0 20px 0;
    color: #333;
}

.transaction-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: white;
    border-radius: 8px;
    margin-bottom: 10px;
}

.transaction-info h5 {
    margin: 0 0 5px 0;
    font-size: 14px;
    color: #333;
}

.transaction-info p {
    margin: 0;
    font-size: 12px;
    color: #666;
}

.transaction-amount {
    font-weight: 600;
    font-size: 1.1em;
}

.transaction-amount.positive { color: #28a745; }
.transaction-amount.negative { color: #dc3545; }

/* Error */
.oyt-error {
    background: #f8d7da;
    color: #721c24;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 30px;
}

.error-icon {
    font-size: 2em;
    margin-bottom: 10px;
}

/* No Data */
.no-data {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 40px;
}

/* Responsive */
@media (max-width: 768px) {
    .oyt-customer-dashboard {
        padding: 10px;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .phone-input {
        width: 100%;
    }
    
    .dashboard-tabs {
        flex-wrap: wrap;
    }
    
    .tab-btn {
        flex: 1;
        min-width: 120px;
    }
    
    .overview-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    
    .activity-item {
        flex-direction: column;
        text-align: center;
    }
    
    .activity-amount {
        margin-left: 0;
        margin-top: 10px;
    }
}

@media (max-width: 480px) {
    .overview-stats {
        grid-template-columns: 1fr;
    }
    
    .dashboard-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        width: 100%;
    }
}

/* Profile Actions */
.profile-actions {
    margin-left: auto;
}

.edit-btn {
    padding: 10px 20px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.3);
}

/* Vehicles Header */
.vehicles-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.vehicles-header h4 {
    margin: 0;
    color: #333;
    font-size: 1.2em;
}

.add-btn {
    padding: 10px 20px;
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.add-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 123, 255, 0.3);
}

/* Add Vehicle Form */
.add-vehicle-form {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    margin-top: 20px;
    border: 2px solid #e1e5e9;
}

.add-vehicle-form h4 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 1.3em;
    font-weight: 600;
}

.add-vehicle-form .form-group {
    margin-bottom: 20px;
}

.add-vehicle-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.add-vehicle-form .form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e1e5e9;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #e1e5e9;
}

.modal-header h3 {
    margin: 0;
    color: #333;
    font-size: 1.3em;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: #f0f0f0;
    color: #333;
}

.modal-body {
    padding: 25px;
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e1e5e9;
}

.btn-cancel {
    padding: 12px 24px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-cancel:hover {
    background: #5a6268;
}

.btn-save {
    padding: 12px 24px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.3);
}

.btn-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Success Message */
.oyt-success {
    background: #d4edda;
    color: #155724;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 20px;
    border: 1px solid #c3e6cb;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.success-icon {
    font-size: 20px;
}

/* Mobile Responsive for Modals */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .vehicles-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .profile-actions {
        margin-left: 0;
        margin-top: 15px;
    }
} 