.visa-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    box-sizing: border-box;
}

.visa-dashboard * {
    box-sizing: border-box;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
}

.stat-card h3 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 16px;
}

.status-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 500;
}

.status-visa_approved {
    background: #4caf50;
    color: white;
}

.status-visa_rejected {
    background: #f44336;
    color: white;
}

.status-documents_submitted {
    background: #ff9800;
    color: white;
}

.progress-steps {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.step {
    flex: 1;
    min-width: 120px;
    padding: 10px;
    text-align: center;
    background: #f5f5f5;
    border-radius: 5px;
    font-size: 14px;
}

.step.completed {
    background: #4caf50;
    color: white;
}

.step.current {
    background: #2e7d32;
    color: white;
}

.dashboard-sections {
    display: grid;
    gap: 30px;
}

.section {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-width: 0; /* Prevents CSS Grid blowout */
}

.section h3 {
    margin: 0 0 20px 0;
    color: #333;
}

.action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.btn,
.btn-primary,
.btn-danger {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s;
}

.btn {
    background: #4caf50;
    color: white;
}

.btn-primary {
    background: #4caf50;
    color: white;
}

.btn-danger {
    background: #f44336;
    color: white;
}

.btn:hover,
.btn-primary:hover,
.btn-danger:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.documents-table,
.payments-table {
    width: 100%;
    border-collapse: collapse;
}

.documents-table th,
.payments-table th,
.documents-table td,
.payments-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.documents-table th,
.payments-table th {
    background: #f5f5f5;
    font-weight: 600;
}

/* Auth Forms */
.visa-auth-container,
.visa-form-container {
    width: 90%;
    max-width: 500px;
    margin: 50px auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.visa-form-container {
    max-width: 800px; /* Form container can be wider for docs */
    padding: 20px;
}

.visa-tabs {
    display: flex;
    border-bottom: 1px solid #e0e0e0;
}

.tab-btn {
    flex: 1;
    padding: 15px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
    color: #2196f3;
}

.tab-btn.active {
    background: #2196f3;
    color: white;
}

.visa-tab-content {
    display: none;
    padding: 30px;
}

.visa-tab-content.active {
    display: block;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #444;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
    background-color: #fff;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

/* Universal Select/Dropdown Styling Fix */
.visa-dashboard select, 
.visa-auth-container select, 
.visa-form-container select,
.visa-ticket-booking select,
.visa-interview-container select,
.modal-content select,
.form-group select,
.form-section select,
select.form-control,
select.payment-method-select {
    box-sizing: border-box !important;
    width: 100% !important;
    height: 48px !important;
    line-height: 48px !important;
    padding: 0 15px !important;
    font-size: 16px !important;
    color: #333 !important;
    border-radius: 8px !important;
    border: 1px solid #ddd !important;
    background-color: #fff !important;
    -webkit-appearance: auto !important;
    -moz-appearance: auto !important;
    appearance: auto !important;
}

.form-group input::placeholder,
.form-group select::placeholder {
    color: #aaa;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #007b5e;
    box-shadow: 0 0 5px rgba(0, 123, 94, 0.2);
}

/* Select2 overrides to match standard inputs */
.form-group .select2-container--default .select2-selection--single {
    height: auto;
    padding: 11px 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    background-color: #fff;
    display: flex;
    align-items: center;
}

.form-group .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 100%;
    right: 10px;
}

.form-group .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: normal;
    padding-left: 0;
    color: #333;
}

.form-group .select2-container--default.select2-container--open .select2-selection--single {
    border-color: #007b5e;
    box-shadow: 0 0 5px rgba(0, 123, 94, 0.2);
}

button[type="submit"] {
    width: 100%;
    padding: 14px;
    background: #007b5e; /* match the green in screenshot */
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
    margin-top: 10px;
}

button[type="submit"]:hover {
    background: #00604a;
}

button[type="submit"]:disabled {
    background: #73b3a2;
    cursor: not-allowed;
}

.visa-message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 5px;
}

.visa-message .error {
    background: #ffebee;
    color: #c62828;
    padding: 10px;
    border-radius: 5px;
}

/* Interview Styles */
.visa-interview-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.interview-setup video,
.interview-controls video {
    width: 100%;
    max-width: 640px;
    background: #000;
    border-radius: 10px;
    margin-bottom: 20px;
}

.timer {
    font-size: 24px;
    font-weight: bold;
    text-align: center;
    margin: 20px 0;
}

.question-box {
    background: #f5f5f5;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    text-align: center;
}

.question-box h3 {
    margin: 0 0 10px 0;
    color: #333;
}

#current-question {
    font-size: 18px;
    color: #2196f3;
    font-weight: 500;
}

/* Modal */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 20px;
    width: 90%;
    max-width: 500px;
    border-radius: 10px;
    position: relative;
}

.close {
    position: absolute;
    right: 20px;
    top: 10px;
    font-size: 28px;
    cursor: pointer;
}

/* Responsive */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

@media (max-width: 1024px) {
    .dashboard-stats {
        grid-template-columns: 1fr;
    }

    .progress-steps {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }

    .step {
        width: 100%;
        box-sizing: border-box;
    }

    .action-buttons {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .btn,
    .btn-primary,
    .btn-danger {
        width: 100%;
        text-align: center;
        box-sizing: border-box;
        margin-top: 5px !important;
    }

    .documents-table,
    .payments-table {
        min-width: 600px; /* Prevent table squishing, enables horizontal scroll */
    }
}

@media (max-width: 480px) {
    .visa-dashboard {
        padding: 10px;
        font-size: 14px;
        line-height: 1.4;
    }
    
    .visa-dashboard h2 {
        font-size: 20px !important;
    }

    .stat-card {
        padding: 15px;
    }

    .stat-card h3 {
        font-size: 14px;
    }

    .status-badge {
        font-size: 12px;
        padding: 4px 8px;
    }

    .section {
        padding: 15px;
        gap: 20px;
    }

    .section h3 {
        font-size: 18px;
        margin-bottom: 15px;
    }

    .step {
        font-size: 12px;
        padding: 8px;
    }

    .btn, .btn-primary, .btn-danger {
        font-size: 13px !important;
        padding: 8px 15px !important;
    }

    .visa-message, .payment-status-message {
        font-size: 13px !important;
        padding: 12px !important;
        line-height: 1.5;
    }

    .visa-message strong {
        font-size: 15px !important;
    }

    .documents-table th, .payments-table th,
    .documents-table td, .payments-table td {
        padding: 8px;
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    /* Global Container Fixes for Mobile (Overriding Inline Styles) */
    div[class*="-container"], 
    div[class*="-page"], 
    .visa-ticket-booking, 
    .payment-card, 
    .visa-notice, 
    .reservation-box, 
    .modal-content, 
    .ticket-details-summary, 
    .manual-payment-details,
    form {
        padding: 20px !important;
        margin: 15px auto !important;
        box-sizing: border-box !important;
        width: 100% !important;
    }

    h1, h2 { 
        font-size: 22px !important; 
        margin-bottom: 15px !important; 
        line-height: 1.3 !important; 
    }
    
    h3 { 
        font-size: 18px !important; 
        margin-bottom: 10px !important; 
    }
    
    p { 
        font-size: 15px !important; 
        line-height: 1.5 !important; 
    }

    div[style*="font-size:60px"], 
    div[style*="font-size: 60px"], 
    div[style*="font-size:50px"], 
    div[style*="font-size: 50px"] {
        font-size: 40px !important; 
        margin-bottom: 10px !important;
    }

    .form-row, 
    div[style*="grid-template-columns"] {
        display: flex !important; 
        flex-direction: column !important; 
        gap: 15px !important;
    }

    button, .btn, .btn-primary, .btn-danger, .btn-reserve, .btn-confirm, .btn-confirm-final, a.btn-primary {
        padding: 14px 20px !important; 
        font-size: 16px !important; 
        width: 100% !important; 
        box-sizing: border-box !important; 
        text-align: center !important;
        display: block !important;
    }
}