:root {
    /* ========================================
       BRAND COLOR PALETTE
       From: shared/brand_assets/brand_colours copy.png
       ======================================== */

    /* Primary Colors - Cyan/Teal */
    --brand-primary: #3FAEBD;
    --brand-primary-light: #C7E5E9;
    --brand-primary-dark: #2A8A96;
    --brand-primary-hover: #2A8A96;

    /* Secondary Colors - Red */
    --brand-secondary: #BD4040;
    --brand-secondary-light: #F0CFCF;
    --brand-secondary-dark: #9A3333;
    --brand-secondary-hover: #9A3333;

    /* Tertiary Colors - Purple & Yellow */
    --brand-tertiary-purple: #AA40BD;
    --brand-tertiary-purple-light: #EFCEF7;
    --brand-tertiary-yellow: #BC993F;
    --brand-tertiary-yellow-light: #E2D3AF;

    /* Grayscale Palette */
    --color-white: #FFFFFF;
    --color-black: #121212;
    --color-gray-50: #fafafa;
    --color-gray-100: #f5f5f5;
    --color-gray-200: #e0e0e0;
    --color-gray-300: #ccc;
    --color-gray-400: #999;
    --color-gray-500: #666;
    --color-gray-600: #555;
    --color-gray-700: #333;
    --color-gray-800: #222;
    --color-gray-900: #121212;

    /* ========================================
       SEMANTIC COLORS
       ======================================== */

    /* Success Colors */
    --color-success: #3FAEBD;
    --color-success-light: #C7E5E9;
    --color-success-bg: #f0f9f9;
    --color-success-border: #3FAEBD;

    /* Error Colors */
    --color-error: #ef4444;
    --color-error-light: #f8d7da;
    --color-error-bg: #fef2f2;
    --color-error-border: #ef4444;

    /* Warning Colors */
    --color-warning: #f59e0b;
    --color-warning-light: #fef3c7;
    --color-warning-bg: #fffbeb;
    --color-warning-border: #f59e0b;

    /* Info Colors */
    --color-info: var(--brand-primary);
    --color-info-light: var(--brand-primary-light);
    --color-info-bg: #e0f7fa;
    --color-info-border: var(--brand-primary);

    /* Extended Success Colors */
    --color-success-dark: #2A8A96;
    --color-success-darker: #1f6b75;

    /* Extended Error Colors */
    --color-error-dark: #dc3545;
    --color-error-darker: #c82333;

    /* Extended Warning Colors */
    --color-warning-dark: #ff9800;
    --color-warning-darker: #f57c00;

    /* Extended Primary Colors */
    --color-primary-dark: #0D5D6B;
    --color-primary-accent: #00d4ff;
    --color-primary-medium: #359aa7;

    /* Badge Background Colors */
    --badge-blue-bg: #e3f2fd;
    --badge-blue-text: #1976d2;
    --badge-green-bg: #C7E5E9;
    --badge-green-text: #2A8A96;
    --badge-orange-bg: #fff3e0;
    --badge-orange-text: #f57c00;
    --badge-amber-bg: #ffe0b2;
    --badge-amber-text: #e65100;
    --badge-red-bg: #ffebee;
    --badge-red-text: #c62828;
    --badge-purple-bg: #f3e5f5;
    --badge-purple-text: #6a1b9a;

    /* Utility Colors */
    --color-gray-lighter: #f3f3f3;
    --color-gray-mid: #757575;
    --color-success-badge: #3FAEBD;

    /* ========================================
       LEGACY ALIASES (for backward compatibility)
       ======================================== */

    --primary-color: var(--brand-primary);
    --primary-light: var(--brand-primary-light);
    --secondary-color: var(--brand-secondary);
    --secondary-light: var(--brand-secondary-light);
    --yellow: var(--brand-tertiary-yellow);
    --yellow-light: var(--brand-tertiary-yellow-light);
    --text-dark: var(--color-black);
    --text-light: var(--color-gray-500);
    --text-medium: var(--color-gray-600);
    /* Better contrast ratio (7.46:1) for WCAG AA compliance */
    --white: var(--color-white);
    --border-color: var(--color-gray-200);
    --success-color: var(--color-success);
    --error-color: var(--color-error);
    --warning-color: var(--color-warning);

    /* ========================================
       SERVICE CATEGORY COLORS
       Based on brand usage rules
       ======================================== */

    --service-case-flexibility-bg: var(--brand-primary);
    --service-case-flexibility-light: var(--brand-primary-light);
    --service-additional-bg: var(--brand-secondary);
    --service-additional-light: var(--brand-secondary-light);
    --service-workflow-bg: var(--brand-tertiary-purple);
    --service-workflow-light: var(--brand-tertiary-purple-light);
    --service-analytics-bg: var(--brand-tertiary-yellow);
    --service-analytics-light: var(--brand-tertiary-yellow-light);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Screen Reader Only Class */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--color-gray-100);
    min-height: 100vh;
    color: var(--text-dark);
    line-height: 1.6;
    display: flex;
    margin: 0;
}

/* Login Screen Styles */
.login-container {
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-primary-dark) 100%);
    padding: 20px;
}

.login-card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    padding: 40px;
    width: 100%;
    max-width: 420px;
    animation: slideUp 0.4s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-logo {
    width: 120px;
    height: auto;
    margin-bottom: 20px;
}

.login-header h1 {
    font-size: 28px;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-light);
    font-size: 15px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-form .form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.login-form label {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 14px;
}

.login-form input {
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.2s ease;
}

.login-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.login-error {
    background: var(--color-error-bg);
    border: 1px solid var(--color-error-border);
    color: var(--color-error);
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
}

.btn-block {
    width: 100%;
    padding: 14px;
    font-size: 16px;
    font-weight: 600;
    position: relative;
}

/* Modern circular spinner - small size for inline use */
.modern-spinner-small {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(63, 174, 141, 0.2);
    border-radius: 50%;
    border-top-color: #3FAE8D;
    animation: modern-spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    vertical-align: middle;
}

/* Modern circular spinner - large size for loading states */
.modern-spinner-large {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(63, 174, 141, 0.2);
    border-radius: 50%;
    border-top-color: #3FAE8D;
    animation: modern-spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

/* Smooth rotation animation */
@keyframes modern-spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Legacy spinner - keep for backward compatibility */
.spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.6s linear infinite;
    margin-left: 8px;
}

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

.login-hint {
    text-align: center;
    font-size: 13px;
    color: var(--text-light);
    margin-top: 16px;
    padding: 12px;
    background: var(--primary-light);
    border-radius: 8px;
}

#mainApplication {
    display: flex;
    width: 100%;
}

/* Sidebar Navigation */
.sidebar {
    width: 200px;
    background: var(--color-black);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    display: flex;
    flex-direction: column;
    z-index: 1000;
    transition: width 0.3s ease;
}

.sidebar.collapsed {
    width: 60px;
}

.sidebar-header {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-logo {
    width: 80px;
    height: auto;
    transition: width 0.3s ease;
}

.sidebar.collapsed .sidebar-logo {
    width: 35px;
}

.toggle-sidebar {
    background: none;
    border: none;
    color: var(--color-gray-400);
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.toggle-sidebar:hover {
    color: var(--primary-color);
}

.toggle-sidebar svg {
    width: 20px;
    height: 20px;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 15px 0;
}

.menu-item {
    margin: 8px 12px;
}

.menu-item a {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    gap: 12px;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
}

.menu-text {
    transition: opacity 0.3s ease;
}

.sidebar.collapsed .menu-text {
    opacity: 0;
    display: none;
}

.menu-item a:hover,
.menu-item button.menu-parent:hover {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.95);
    transform: translateX(2px);
}

.menu-item.active>a,
.menu-item.active>button.menu-parent {
    background: rgba(63, 174, 189, 0.15);
    color: #3FAEBD;
    font-weight: 600;
    border-left: 3px solid #3FAEBD;
}

.menu-icon {
    flex-shrink: 0;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Icon animation on hover */
.menu-item a:hover .menu-icon,
.menu-item button.menu-parent:hover .menu-icon {
    transform: scale(1.1);
}

/* Focus states for keyboard navigation */
.menu-item a:focus,
.menu-item button.menu-parent:focus {
    outline: 2px solid #3FAEBD;
    outline-offset: 2px;
}

.submenu li a:focus {
    outline: 2px solid #3FAEBD;
    outline-offset: 2px;
}

.menu-item.has-children {
    position: relative;
}

.menu-item.has-children .menu-parent {
    width: 100%;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    border-radius: 8px;
}

.menu-item.has-children .chevron {
    margin-left: auto;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transform: rotate(0deg);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.menu-item.has-children.open .chevron {
    transform: rotate(90deg);
}

.submenu {
    list-style: none;
    margin: 0;
    padding-left: 32px;
    background: var(--color-black);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease;
}

.menu-item.has-children.open .submenu {
    max-height: 400px;
    opacity: 1;
    border-left: 2px solid rgba(63, 174, 189, 0.3);
    margin-left: 12px;
}

.submenu li {
    margin: 4px 0;
}

.submenu li a {
    display: block;
    padding: 10px 16px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    letter-spacing: 0.3px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 6px;
}

.submenu li a:hover {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(2px);
}

.submenu li a.active {
    color: #3FAEBD;
    font-weight: 600;
    background: rgba(63, 174, 189, 0.1);
}

.sidebar.collapsed .submenu {
    display: none;
}

/* Main Wrapper - Content Area */
.main-wrapper {
    margin-left: 200px;
    flex: 1;
    min-height: 100vh;
    width: calc(100% - 200px);
    transition: margin-left 0.3s ease, width 0.3s ease;
}

.sidebar.collapsed~.main-wrapper {
    margin-left: 60px;
    width: calc(100% - 60px);
}

/* Employer View Wrapper */
.employer-view-wrapper {
    margin-left: 200px;
    flex: 1;
    min-height: 100vh;
    width: calc(100% - 200px);
    background: var(--color-gray-100);
    transition: margin-left 0.3s ease, width 0.3s ease;
}

.sidebar.collapsed~.employer-view-wrapper {
    margin-left: 60px;
    width: calc(100% - 60px);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    background: var(--white);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
}

.logo .arrow {
    color: var(--secondary-color);
}

.beta-badge {
    background: var(--primary-color);
    color: var(--white);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* Progress Bar */
.progress-container {
    background: var(--white);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.progress-bar {
    height: 8px;
    background: var(--primary-light);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 30px;
}

.progress-fill {
    height: 100%;
    background: var(--primary-color);
    width: 14.28%;
    /* 100% / 7 steps */
    transition: width 0.5s ease;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.step.active,
.step.completed {
    opacity: 1;
}

.step.completed {
    cursor: pointer;
    transition: all 0.2s ease;
}

.step.completed:hover {
    opacity: 1;
    transform: scale(1.05);
}

.step.completed:hover .step-number {
    background: var(--primary-color);
    color: var(--white);
    box-shadow: 0 2px 8px rgba(63, 174, 189, 0.4);
}

.step.completed:hover .step-label {
    color: var(--primary-color);
    font-weight: 600;
}

.step-number {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--border-color);
    color: var(--text-light);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background: var(--primary-color);
    color: var(--white);
}

.step.completed .step-number {
    background: var(--success-color);
    color: var(--white);
}

.step-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-light);
}

.step.active .step-label {
    color: var(--primary-color);
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .step {
        font-size: 11px;
    }

    .step-number {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
}

/* Main Content */
main {
    background: var(--white);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    min-height: 500px;
}

.form-step {
    display: none;
    position: relative;
}

.form-step.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

/* Import Demo Data Button */
.import-data-btn {
    position: absolute;
    top: 10px;
    right: 200px;
    background: var(--white);
    border: 2px solid var(--border-color);
    color: var(--text-dark);
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    z-index: 100;
    white-space: nowrap;
}

.import-data-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(63, 174, 189, 0.15);
}

.import-data-btn:active {
    transform: translateY(0);
}

/* Auto Fill Demo Data Button */
.auto-fill-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--white);
    border: 2px solid var(--border-color);
    color: var(--text-dark);
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    z-index: 100;
    white-space: nowrap;
}

.auto-fill-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(63, 174, 189, 0.15);
}

.auto-fill-btn:active {
    transform: translateY(0);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h2 {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--primary-color);
}

.step-description {
    color: var(--text-light);
    margin-bottom: 16px;
    font-size: 14px;
}

/* Forms */
.visa-form {
    margin-top: 30px;
}

.form-group {
    margin-bottom: 25px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

@media (max-width: 1024px) {
    .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Form Elements */
.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--brand-neutral-gray800);
    font-size: 14px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="tel"],
select,
textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--brand-neutral-gray300);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s ease;
    background-color: var(--brand-neutral-white);
    color: var(--brand-neutral-gray900);
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(63, 174, 189, 0.15);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    line-height: 1.5;
}

.btn-primary {
    background-color: var(--brand-primary);
    color: var(--brand-neutral-white);
}

.btn-primary:hover {
    background-color: var(--brand-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(63, 174, 189, 0.2);
}

.btn-secondary {
    background-color: var(--brand-neutral-white);
    color: var(--brand-neutral-gray700);
    border: 1px solid var(--brand-neutral-gray300);
}

.btn-secondary:hover {
    background-color: var(--brand-neutral-gray50);
    border-color: var(--brand-neutral-gray400);
}

.btn-block {
    width: 100%;
}

/* Card & Container Styles */
.login-card {
    background: var(--brand-neutral-white);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    width: 100%;
    max-width: 440px;
}

.login-header h1 {
    color: var(--brand-primary-dark);
    font-size: 28px;
    margin-bottom: 8px;
    font-weight: 700;
}

.login-header p {
    color: var(--brand-neutral-gray500);
    font-size: 16px;
    margin-bottom: 32px;
}

/* Progress Bar */
.progress-container {
    margin-bottom: 40px;
    padding: 0 20px;
}

.progress-bar {
    height: 6px;
    background-color: var(--brand-neutral-gray200);
    border-radius: 3px;
    margin-bottom: 16px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--brand-primary) 0%, var(--brand-tertiary-purple) 100%);
    transition: width 0.4s ease;
}

.step-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--brand-neutral-gray500);
    margin-top: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.step.active .step-label {
    color: var(--brand-primary);
}


.activity-box.allowed {
    background: var(--color-success-bg);
    border-color: var(--color-success-border);
}

.activity-box.not-allowed {
    background: var(--color-error-bg);
    border-color: var(--color-error-border);
}

.activity-box h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 600;
}

.activity-box.allowed h3 {
    color: var(--color-success);
}

.activity-box.not-allowed h3 {
    color: var(--color-error);
}

.activity-box ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.activity-box li {
    padding: 8px 0;
    font-size: 14px;
    line-height: 1.6;
}

.activity-box.allowed li::before {
    content: "✓ ";
    color: var(--color-success);
    font-weight: bold;
    margin-right: 8px;
}

.activity-box.not-allowed li::before {
    content: "✗ ";
    color: var(--color-error);
    font-weight: bold;
    margin-right: 8px;
}

/* Responsive: Stack on mobile */
@media (max-width: 768px) {
    .activity-boxes {
        grid-template-columns: 1fr;
    }
}

/* Tooltip Component */
.info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--white);
    font-size: 14px;
    font-weight: 600;
    cursor: help;
    margin-left: 8px;
    position: relative;
    vertical-align: middle;
    transition: all 0.2s ease;
}

.info-icon:hover {
    background: var(--brand-primary-hover);
    transform: scale(1.1);
}

.info-icon:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.tooltip {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--text-dark);
    color: var(--white);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
    white-space: normal;
    max-width: 300px;
    width: max-content;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
}

.tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--text-dark);
}

.tooltip-wrapper:hover .tooltip,
.tooltip-wrapper:focus-within .tooltip,
.info-icon:focus+.tooltip {
    opacity: 1;
    visibility: visible;
}

/* Ensure tooltip doesn't overflow on mobile */
@media (max-width: 768px) {
    .tooltip {
        max-width: 250px;
        left: auto;
        right: 0;
        transform: none;
    }

    .tooltip::after {
        left: auto;
        right: 20px;
        transform: none;
    }
}

/* Buttons */
.form-actions {
    margin-top: 40px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.btn {
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--brand-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 174, 189, 0.3);
}

.btn-primary:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-light);
}

.btn-secondary:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
    min-width: 70px;
    white-space: nowrap;
}

.btn-icon {
    font-size: 18px;
}

/* Assessment Results */
/* Collapsible Assessment Sections */
.collapsible-section {
    margin-bottom: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--primary-light);
    cursor: pointer;
    user-select: none;
    transition: background 0.2s ease;
}

.section-header:hover {
    background: rgba(63, 174, 189, 0.15);
}

.section-header h3 {
    margin: 0;
    font-size: 15px;
    color: var(--primary-color);
    font-weight: 600;
}

.section-arrow {
    font-size: 12px;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.section-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.section-content.expanded {
    max-height: 2000px;
}

.assessment-card {
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--white) 100%);
    border: none;
    border-radius: 0;
    padding: 16px;
    margin-bottom: 0;
}

.assessment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.assessment-icon {
    width: 35px;
    height: 35px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.assessment-title {
    flex: 1;
}

.assessment-title h3 {
    color: var(--primary-color);
    margin-bottom: 3px;
    font-size: 18px;
}

.visa-type {
    display: inline-block;
    background: var(--primary-color);
    color: var(--white);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.assessment-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.detail-item {
    padding: 10px;
    background: var(--white);
    border-radius: 6px;
}

.detail-label {
    font-size: 11px;
    color: var(--text-light);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

.ai-insights {
    margin-top: 0;
    padding: 16px;
    background: var(--white);
    border-left: none;
    border-radius: 0;
}

.ai-insights h4 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 16px;
    display: none;
}

.insight-item {
    padding: 8px 0;
    border-bottom: 1px solid rgba(63, 174, 189, 0.2);
    font-size: 14px;
}

.insight-item:last-child {
    border-bottom: none;
}

.insight-item h5 {
    font-size: 14px;
    margin-bottom: 4px;
}

.insight-item p {
    font-size: 13px;
    line-height: 1.4;
}

.document-requirements {
    margin-top: 0;
    padding: 16px;
}

.document-requirements h4 {
    color: var(--primary-color);
    margin-bottom: 12px;
    font-size: 16px;
    display: none;
}

.document-requirements ul {
    list-style: none;
    padding: 0;
}

.document-requirements li {
    padding: 12px;
    background: var(--white);
    margin-bottom: 8px;
    border-radius: 8px;
    border-left: 3px solid var(--primary-color);
}

.document-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

@media (max-width: 1024px) {
    .document-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .document-list {
        grid-template-columns: 1fr;
    }
}

.doc-preview-item {
    background: var(--white);
    padding: 12px;
    border-radius: 8px;
    border-left: 3px solid var(--primary-color);
    transition: all 0.2s ease;
}

.doc-preview-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.doc-preview-header {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 8px;
}

.doc-preview-icon {
    color: var(--primary-color);
    font-size: 18px;
    font-weight: bold;
    flex-shrink: 0;
}

.doc-preview-content h5 {
    margin: 0 0 4px 0;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
}

.doc-preview-description {
    margin: 0;
    color: var(--text-light);
    font-size: 12px;
    line-height: 1.4;
}

.learn-more-btn {
    background: var(--primary-light);
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    margin-bottom: 12px;
}

.learn-more-btn:hover {
    background: var(--primary-color);
    color: var(--white);
}

.learn-more-btn:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.learn-more-btn .info-icon {
    background: transparent;
    color: inherit;
    margin: 0;
    width: auto;
    height: auto;
    font-size: 16px;
}

.doc-details {
    padding: 16px;
    background: var(--primary-light);
    border-radius: 6px;
    margin-top: 12px;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.doc-details h6 {
    margin: 0 0 10px 0;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
}

.doc-details ul {
    margin: 0;
    padding-left: 20px;
}

.doc-details li {
    margin-bottom: 6px;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-dark);
}

/* Document Upload - Progress Bar */
.document-progress-container {
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    position: sticky;
    top: 20px;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.3s ease;
}

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

.progress-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.progress-percentage {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-color);
}

.progress-bar-track {
    height: 8px;
    background: var(--primary-light);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 16px;
}

.progress-bar-fill {
    height: 100%;
    background: var(--primary-color);
    border-radius: 4px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-checkmarks {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.progress-check {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--white);
    transition: all 0.3s ease;
}

.progress-check.verified {
    background: var(--success-color);
    animation: checkmarkPop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes checkmarkPop {
    0% {
        transform: scale(0);
        opacity: 0;
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Document Upload - Accordion Layout */
.document-checklist {
    display: grid;
    gap: 12px;
}

.document-accordion {
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.document-accordion.uploaded {
    border-color: var(--success-color);
    background: var(--color-success-bg);
}

.document-accordion.error {
    border-color: var(--error-color);
    background: var(--color-error-bg);
}

.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    cursor: pointer;
    background: var(--white);
    transition: all 0.2s ease;
    user-select: none;
}

.accordion-header:hover {
    background: var(--primary-light);
}

.accordion-header:focus {
    outline: none;
}

.accordion-header:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: -3px;
}

.accordion-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.accordion-arrow {
    font-size: 12px;
    color: var(--text-light);
    transition: transform 0.3s ease;
    display: inline-block;
}

.accordion-arrow.expanded {
    transform: rotate(90deg);
}

.document-title {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-dark);
}

.document-status {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.document-status.pending {
    background: var(--yellow-light);
    color: var(--yellow);
}

.document-status.uploaded {
    background: var(--color-success-light);
    color: var(--success-color);
}

.document-status.error {
    background: var(--color-error-light);
    color: var(--error-color);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.accordion-content.expanded {
    max-height: 1000px;
    padding: 0 20px 20px 20px;
}

.document-description {
    color: var(--text-light);
    font-size: 14px;
    margin-bottom: 16px;
    line-height: 1.5;
}

.requirements-section {
    margin-bottom: 16px;
}

.requirements-section h6 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.document-requirements-list {
    font-size: 13px;
    color: var(--text-light);
    margin: 0;
    padding-left: 20px;
    list-style-type: disc;
}

.document-requirements-list li {
    margin-bottom: 6px;
    line-height: 1.4;
}

.upload-area {
    margin-top: 12px;
}

.upload-zone {
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-zone:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.upload-zone.dragover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.upload-zone:focus {
    outline: none;
}

.upload-zone:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
    border-color: var(--primary-color);
}

.upload-zone p {
    margin: 0;
    font-size: 14px;
    color: var(--text-dark);
}

.upload-hint {
    margin-top: 6px !important;
    font-size: 12px !important;
    color: var(--text-light) !important;
}

.upload-icon {
    font-size: 32px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.upload-btn {
    margin-top: 10px;
}

.file-input {
    display: none;
}

.uploaded-file {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: var(--white);
    border-radius: 8px;
    margin-top: 10px;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.file-icon {
    font-size: 24px;
}

.file-details {
    flex: 1;
}

.file-name {
    font-weight: 600;
    color: var(--text-dark);
}

.file-size {
    font-size: 12px;
    color: var(--text-light);
}

.validation-status {
    padding: 15px;
    border-radius: 8px;
    margin-top: 10px;
}

.validation-status.validating {
    background: var(--yellow-light);
    color: var(--yellow);
}

.validation-status.success {
    background: var(--color-success-light);
    color: var(--success-color);
}

.validation-status.error {
    background: var(--color-error-light);
    color: var(--error-color);
}

.validation-errors {
    margin-top: 10px;
}

.validation-errors ul {
    padding-left: 20px;
    margin-top: 10px;
}

.validation-errors li {
    margin-bottom: 5px;
}

/* Application Summary */
.application-summary {
    margin-top: 16px;
}

.application-two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.summary-column {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.summary-section {
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 0;
}

.summary-section h3 {
    color: var(--primary-color);
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--primary-light);
    font-size: 15px;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.summary-item {
    padding: 8px;
    background: var(--primary-light);
    border-radius: 4px;
}

.summary-label {
    font-size: 10px;
    color: var(--text-light);
    margin-bottom: 3px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.summary-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.3;
}

/* Draft Ready Screen */
.success-screen {
    padding: 40px 20px;
    max-width: 700px;
    margin: 0 auto;
}

.draft-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    margin: 0 auto 24px;
    box-shadow: 0 10px 30px rgba(63, 174, 189, 0.3);
    animation: scaleIn 0.5s ease;
}

.success-icon {
    width: 100px;
    height: 100px;
    background: var(--success-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    margin: 0 auto 30px;
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
    }

    to {
        transform: scale(1);
    }
}

.success-screen h2 {
    color: var(--text-dark);
    border: none;
    margin-bottom: 12px;
    text-align: center;
}

.draft-subtitle {
    color: var(--text-light);
    font-size: 16px;
    margin-bottom: 32px;
    text-align: center;
    line-height: 1.6;
}

.success-screen p {
    font-size: 16px;
    color: var(--text-light);
    text-align: center;
}

.next-steps-container {
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 32px;
}

.next-steps-container h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 18px;
    text-align: center;
    border: none;
}

.next-steps-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.next-step-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 16px;
    background: var(--primary-light);
    border-radius: 8px;
}

.step-number {
    min-width: 32px;
    height: 32px;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
}

.step-content strong {
    display: block;
    color: var(--text-dark);
    margin-bottom: 4px;
    font-size: 15px;
}

.step-content p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

.success-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.draft-note {
    background: var(--yellow-light);
    border-left: 4px solid var(--yellow);
    border-radius: 6px;
    padding: 12px 16px;
}

.draft-note p {
    margin: 0;
    font-size: 14px;
    color: var(--text-dark);
    line-height: 1.5;
    text-align: left;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 1000;
}

.loading-overlay.active {
    display: flex;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid var(--primary-light);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

#loadingMessage {
    margin-top: 20px;
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    main {
        padding: 20px;
    }

    h2 {
        font-size: 24px;
    }

    .progress-steps {
        flex-wrap: wrap;
    }

    .step {
        flex: 0 0 calc(33.333% - 10px);
        margin-bottom: 20px;
    }

    .step-label {
        font-size: 10px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .assessment-details {
        grid-template-columns: 1fr;
    }

    .summary-grid {
        grid-template-columns: 1fr;
    }

    .application-two-column {
        grid-template-columns: 1fr;
    }

    .summary-section {
        padding: 14px;
    }

    .summary-section h3 {
        font-size: 16px;
    }
}

@media (max-width: 1024px) and (min-width: 769px) {
    .summary-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Split-Screen Auto-Fill Feature */
.split-screen-container {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 20px;
    height: 600px;
    margin: 20px 0;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
}

.instructions-panel {
    background: var(--white);
    padding: 20px;
    overflow-y: auto;
    border-right: 1px solid var(--border-color);
}

.instructions-panel h3 {
    color: var(--primary-color);
    margin-bottom: 12px;
    font-size: 18px;
}

.instructions-panel>p {
    color: var(--text-medium);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.form-panel {
    background: var(--color-gray-100);
    position: relative;
    overflow: hidden;
}

.iframe-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--white) 100%);
}

.placeholder-content {
    text-align: center;
    padding: 40px;
}

.placeholder-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.placeholder-content h3 {
    color: var(--primary-color);
    margin-bottom: 12px;
}

.placeholder-content p {
    color: var(--text-medium);
    margin-bottom: 10px;
}

.placeholder-note {
    color: var(--text-light) !important;
    font-size: 12px !important;
}

.auto-fill-controls {
    display: flex;
    gap: 10px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.auto-fill-controls .btn {
    flex: 1;
    min-width: 100px;
    font-size: 13px;
    padding: 10px 16px;
}

.auto-fill-progress {
    margin: 20px 0;
    padding: 16px;
    background: var(--primary-light);
    border-radius: 8px;
}

.auto-fill-progress h4 {
    color: var(--primary-color);
    font-size: 14px;
    margin-bottom: 12px;
}

.progress-bar-inline {
    height: 8px;
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-bar-inline .progress-bar-fill {
    height: 100%;
    background: var(--primary-color);
    border-radius: 10px;
    transition: width 0.3s ease;
}

#autoFillStatus {
    font-size: 13px;
    color: var(--text-medium);
    font-weight: 500;
    margin: 0;
}

.field-mapping {
    margin-top: 20px;
}

.field-mapping h4 {
    font-size: 14px;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.field-mapping ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.field-mapping li {
    padding: 10px 12px;
    margin: 6px 0;
    background: var(--white);
    border-radius: 6px;
    border-left: 3px solid var(--border-color);
    font-size: 13px;
    transition: all 0.3s ease;
}

.field-mapping li.completed {
    border-left-color: var(--success-color);
    background: var(--primary-light);
}

.field-mapping li strong {
    color: var(--text-dark);
    display: block;
    margin-bottom: 4px;
}

.field-status {
    float: right;
    font-size: 16px;
}

.btn-icon {
    margin-right: 6px;
}

@media (max-width: 1024px) {
    .split-screen-container {
        grid-template-columns: 1fr;
        height: auto;
    }

    .instructions-panel {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        order: 2;
    }

    .form-panel {
        order: 1;
        height: 500px;
    }
}

/* ==================== EMPLOYER VIEW STYLES ==================== */

.employer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px;
}

.employer-header {
    margin-bottom: 30px;
}

.employer-header h1 {
    font-size: 32px;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.header-subtitle {
    color: var(--text-light);
    font-size: 16px;
}

/* Statistics Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    padding: 24px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.stat-card h3 {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.stat-card p {
    color: var(--text-light);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Applications Table */
.table-container {
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.table-header h2 {
    font-size: 20px;
    color: var(--text-dark);
    border: none;
    padding: 0;
    margin: 0;
}

.table-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.search-input {
    padding: 10px 16px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    width: 250px;
    transition: border-color 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.applications-table {
    width: 100%;
    border-collapse: collapse;
}

.applications-table thead {
    background: var(--primary-light);
}

.applications-table th {
    padding: 16px 24px;
    text-align: left;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.applications-table td {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
    color: var(--text-dark);
}

.applications-table tbody tr:hover {
    background: var(--color-gray-50);
}

.row-highlight {
    animation: rowPulse 2s ease;
    background: rgba(63, 174, 189, 0.15) !important;
}

@keyframes rowPulse {
    0% {
        background: rgba(63, 174, 189, 0.3);
    }

    50% {
        background: rgba(63, 174, 189, 0.05);
    }

    100% {
        background: rgba(63, 174, 189, 0.15);
    }
}

.empty-state {
    text-align: center;
    padding: 60px 20px !important;
}

.empty-state p {
    color: var(--text-light);
    font-size: 16px;
}

.empty-state-subtitle {
    font-size: 14px !important;
    margin-top: 8px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-pending {
    background: var(--yellow-light);
    color: var(--yellow);
}

.status-approved {
    background: var(--primary-light);
    color: var(--primary-color);
}

.status-rejected {
    background: var(--secondary-light);
    color: var(--secondary-color);
}

.status-draft {
    background: var(--color-gray-200);
    color: var(--color-gray-500);
}

.employer-section {
    display: none;
}

.employer-section.active {
    display: block;
}

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

.lifecycle-card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lifecycle-card h3 {
    font-size: 16px;
    color: var(--text-dark);
}

.lifecycle-card .metric-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
}

.status-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    background: var(--color-gray-200);
    color: var(--color-gray-700);
}

.status-chip.info {
    background: var(--primary-light);
    color: var(--primary-color);
}

.status-chip.warning {
    background: rgba(255, 193, 7, 0.2);
    color: var(--color-warning);
}

.status-chip.critical {
    background: rgba(244, 67, 54, 0.2);
    color: var(--color-error);
}

.lifecycle-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.table-scroll {
    overflow-x: auto;
    border-radius: 12px;
}

.lifecycle-table th,
.lifecycle-table td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
    font-size: 13px;
}

.lifecycle-table thead {
    background: var(--primary-light);
}

.lifecycle-table tbody tr:hover {
    background: var(--color-gray-50);
}

.lifecycle-table .highlight-row {
    background: rgba(244, 67, 54, 0.08);
}

.analytics-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.analytics-panel {
    background: var(--white);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.analytics-panel h3 {
    font-size: 18px;
    margin-bottom: 16px;
}

.chart-container {
    position: relative;
    min-height: 320px;
}

.urgent-tasks {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.urgent-task-item {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px 16px;
    background: var(--color-gray-50);
}

.urgent-task-title {
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.urgent-task-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    color: var(--text-light);
}

.urgent-task-item .btn-link {
    margin-top: 8px;
    font-size: 13px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.urgent-task-item .btn-link:hover {
    text-decoration: underline;
}

.lifecycle-filter-bar {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.lifecycle-filter-bar select,
.lifecycle-filter-bar button {
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--white);
    font-size: 13px;
}

.lifecycle-filter-bar button {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.lifecycle-filter-bar button:hover {
    opacity: 0.85;
}

.empty-analytics-state {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-light);
}

.empty-analytics-state strong {
    display: block;
    margin-bottom: 8px;
    color: var(--text-dark);
}

@media (max-width: 1100px) {
    .analytics-layout {
        grid-template-columns: 1fr;
    }

    .lifecycle-overview {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .lifecycle-filter-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .lifecycle-filter-bar select,
    .lifecycle-filter-bar button {
        width: 100%;
    }
}

/* Action Buttons in Table */
.table-actions .btn {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Responsive Design for Employer View */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .table-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .table-actions {
        width: 100%;
        flex-direction: column;
    }

    .search-input {
        width: 100%;
    }
}

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

    .applications-table {
        font-size: 12px;
    }

    .applications-table th,
    .applications-table td {
        padding: 12px 16px;
    }
}

/* Responsive Sidebar */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .sidebar.mobile-open {
        transform: translateX(0);
    }

    .main-wrapper,
    .employer-view-wrapper {
        margin-left: 0;
        width: 100%;
    }
}

/* Footer Bar */
.app-footer {
    position: fixed;
    bottom: 0;
    left: 200px;
    right: 0;
    height: 50px;
    background: var(--color-black);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    z-index: 900;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.footer-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.footer-link {
    color: var(--color-white);
    text-decoration: none;
    font-size: 13px;
    font-weight: 400;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--primary-color);
}

.footer-branding {
    color: var(--color-white);
    font-size: 13px;
    font-weight: 400;
}

/* Video Guide Placeholder */
.video-guide-placeholder {
    position: fixed;
    bottom: 70px;
    left: 20px;
    width: 180px;
    height: 120px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    z-index: 950;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-guide-placeholder:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.video-thumbnail {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-primary-dark) 100%);
    position: relative;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    gap: 10px;
}

.video-text {
    color: var(--color-white);
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    line-height: 1.3;
}

.play-button {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 16px;
    padding-left: 3px;
}

/* Adjust main content to account for footer */
.main-wrapper,
.employer-view-wrapper {
    padding-bottom: 70px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .app-footer {
        left: 0;
        padding: 0 15px;
    }

    .footer-links {
        gap: 15px;
    }

    .footer-link,
    .footer-branding {
        font-size: 11px;
    }

    .video-guide-placeholder {
        width: 140px;
        height: 95px;
        bottom: 60px;
        left: 10px;
    }

    .video-text {
        font-size: 11px;
    }

    .play-button {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
}

.modal[style*="display: flex"] {
    display: flex !important;
}

.modal-content {
    background-color: var(--color-white);
    margin: 5% auto;
    padding: 0;
    border: 1px solid var(--brand-primary);
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--brand-primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    color: var(--color-black);
    font-size: 24px;
}

/* View Application Modal */
.view-app-modal {
    display: none;
    position: fixed;
    z-index: 10001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    justify-content: center;
    align-items: center;
}

.view-app-modal-content {
    background-color: var(--color-white);
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.view-app-modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--brand-primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.view-app-modal-header h2 {
    margin: 0;
    color: var(--color-black);
    font-size: 24px;
}

.view-app-modal-body {
    padding: 20px;
}

.app-details-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.detail-item.full-width {
    grid-column: 1 / -1;
}

.detail-item strong {
    color: var(--color-gray-400);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-item span {
    color: var(--color-black);
    font-size: 14px;
}

.letters-section {
    margin-top: 30px;
    padding: 20px;
    background-color: var(--brand-primary-light);
    border-radius: 8px;
    border-left: 4px solid var(--brand-primary);
}

.letters-section h3 {
    margin: 0 0 15px 0;
    color: var(--color-black);
    font-size: 18px;
}

.letters-section p {
    margin: 0 0 15px 0;
    color: var(--color-black);
    font-size: 14px;
}

.letter-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.letter-buttons .btn {
    flex: 1;
    min-width: 200px;
}

.view-app-modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--color-gray-700);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

@media (max-width: 768px) {
    .app-details-grid {
        grid-template-columns: 1fr;
    }

    .letter-buttons {
        flex-direction: column;
    }

    .letter-buttons .btn {
        width: 100%;
    }
}

/* Case Manager Autocomplete */
.case-manager-autocomplete {
    position: relative;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="%23888" stroke-width="2"><circle cx="11" cy="11" r="8"/><path d="m21 21-4.35-4.35"/></svg>');
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px !important;
}

.email-autofilled {
    background-color: var(--color-success) !important;
    border-color: var(--color-success) !important;
}

.input-hint {
    display: block;
    font-size: 12px;
    margin-top: 5px;
    color: var(--color-success);
}

/* Style datalist dropdown (limited browser support) */
datalist {
    display: none;
}

option {
    background-color: var(--color-white);
    color: var(--color-black);
    padding: 8px;
}

/* Visual feedback for autocomplete */
.case-manager-autocomplete:focus {
    border-color: var(--color-success);
    box-shadow: 0 0 0 2px rgba(63, 174, 189, 0.2);
}

.modal-close {
    background: none;
    border: none;
    color: var(--color-gray-400);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: var(--color-white);
}

.modal-body {
    padding: 20px;
    color: var(--color-gray-300);
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--color-gray-700);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.btn-danger {
    background-color: var(--color-error-dark);
    color: var(--color-white);
}

.btn-danger:hover {
    background-color: var(--color-error-darker);
}

.btn-warning {
    background-color: var(--color-warning-dark);
    color: var(--color-white);
}

.btn-warning:hover {
    background-color: var(--color-warning-darker);
}

/* Action Button and Dropdown */
#actionButtonContainer {
    display: inline-flex;
    align-items: center;
}

.action-button-wrapper {
    position: relative;
    display: inline-block;
}

.action-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--color-white);
    border: 1px solid var(--brand-primary);
    border-radius: 4px;
    min-width: 150px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 100;
    margin-top: 5px;
}

.dropdown-item {
    display: block;
    width: 100%;
    padding: 12px 16px;
    background: none;
    border: none;
    color: var(--color-black);
    text-align: left;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--brand-primary-light);
    color: var(--color-black);
}

.dropdown-item:first-child {
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
}

.dropdown-item:last-child {
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
}

/* Checkbox Styles */
.applications-table th input[type="checkbox"],
.applications-table td input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.applications-table th input[type="checkbox"] {
    margin: 0;
}

.applications-table td input[type="checkbox"] {
    margin: 0 auto;
    display: block;
}

/* Editable Case Manager Cell */
.case-manager-cell {
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.case-manager-cell:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.case-manager-cell.editing {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 4px;
}

.case-manager-cell input {
    width: 100%;
    background-color: var(--color-white);
    border: 1px solid var(--brand-primary);
    color: var(--color-black);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 14px;
}

.case-manager-cell input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Automation Progress UI */
.automation-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.automation-progress-content {
    background: linear-gradient(135deg, var(--brand-primary-light) 0%, var(--color-white) 100%);
    padding: 40px;
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--brand-primary);
}

.automation-progress-content h2 {
    color: var(--color-primary-dark);
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 600;
}

.automation-subtitle {
    color: var(--color-primary-dark);
    margin: 0 0 30px 0;
    font-size: 16px;
}

.progress-status {
    margin-bottom: 30px;
}

.progress-bar-container {
    width: 100%;
    height: 30px;
    background-color: var(--color-gray-200);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 15px;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--color-primary-accent));
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    font-weight: bold;
}

.automation-progress-content #automationCurrentStep {
    color: var(--brand-primary-dark);
    font-size: 16px;
    text-align: center;
    margin: 10px 0;
    min-height: 24px;
    font-weight: 500;
}

.next-steps-checklist {
    background-color: rgba(63, 174, 189, 0.1);
    border: 2px solid var(--color-success-badge);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.next-steps-checklist h3 {
    color: var(--color-success-badge);
    margin: 0 0 15px 0;
    font-size: 22px;
}

.next-steps-checklist p {
    color: var(--color-success-darker);
    margin: 0 0 15px 0;
    font-weight: 500;
}

.next-steps-checklist ul {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.next-steps-checklist li {
    color: var(--color-success-darker);
    padding: 8px 0;
    font-size: 16px;
    border-bottom: 1px solid rgba(63, 174, 189, 0.15);
    font-weight: 500;
}

.next-steps-checklist li:last-child {
    border-bottom: none;
}

/* Profile Button & Dropdown */
.profile-button-container {
    position: fixed;
    top: 20px;
    right: 30px;
    z-index: 1100;
}

.profile-button {
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    color: white;
}

.profile-button:hover {
    background: var(--color-primary-medium);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

.profile-button:active {
    transform: translateY(0);
}

.profile-icon {
    width: 24px;
    height: 24px;
}

.profile-dropdown {
    position: absolute;
    top: 60px;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    width: 300px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.profile-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-header {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.profile-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--color-primary-accent));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.profile-avatar svg {
    width: 28px;
    height: 28px;
}

.profile-info {
    flex: 1;
    min-width: 0;
}

.profile-name {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-email {
    font-size: 13px;
    color: var(--text-light);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0 15px;
}

.profile-details {
    padding: 15px 20px;
}

.profile-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
}

.detail-label {
    color: var(--text-light);
    font-weight: 500;
}

.detail-value {
    color: var(--text-dark);
    font-weight: 400;
    text-align: right;
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-actions {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.profile-action-btn {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    transition: all 0.2s ease;
}

.profile-action-btn:hover {
    background: var(--color-gray-50);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.profile-action-btn.logout-btn:hover {
    background: var(--color-error-bg);
    border-color: var(--secondary-color);
    color: var(--secondary-color);
}

.profile-action-btn svg {
    width: 16px;
    height: 16px;
}

/* Edit Profile Modal */
.edit-profile-modal {
    max-width: 550px;
    width: 90%;
    background-color: white !important;
    margin: auto;
}

.edit-profile-modal .modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--color-primary-accent));
    color: white;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 8px 8px 0 0;
}

.edit-profile-modal .modal-header h2 {
    margin: 0;
    font-size: 24px;
    color: white;
}

.edit-profile-modal .close-modal {
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: transform 0.2s ease;
}

.edit-profile-modal .close-modal:hover {
    transform: scale(1.2);
}

.edit-profile-modal .modal-body {
    padding: 30px;
    max-height: 60vh;
    overflow-y: auto;
}

.edit-profile-modal .modal-footer {
    padding: 20px 30px;
    background: var(--color-gray-50);
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    border-radius: 0 0 8px 8px;
}

.edit-profile-modal .form-group {
    margin-bottom: 20px;
}

.edit-profile-modal .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-dark);
    font-size: 14px;
}

.edit-profile-modal .form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.edit-profile-modal .form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(63, 174, 189, 0.1);
}

/* ==================== TAX REPORTS VIEW ==================== */

.reports-controls {
    background: white;
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    margin-bottom: 24px;
}

.report-filter-section {
    display: flex;
    gap: 16px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.report-filter-section .form-group {
    flex: 1;
    min-width: 200px;
    margin-bottom: 0;
}

.report-filter-section label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--color-gray-700);
    font-size: 14px;
}

.report-filter-section .form-input {
    width: 100%;
}

.report-preview-section {
    background: white;
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.report-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--color-gray-200);
}

.report-preview-header h3 {
    margin: 0;
    color: var(--badge-blue-text);
    font-size: 20px;
}

.report-meta {
    display: flex;
    gap: 20px;
    font-size: 14px;
    color: var(--color-gray-500);
}

.report-meta span {
    padding: 6px 12px;
    background: var(--color-gray-100);
    border-radius: 4px;
}

.employer-info-section {
    background: var(--color-gray-50);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 24px;
}

.employer-info-section h4 {
    margin: 0 0 16px 0;
    color: var(--color-gray-700);
    font-size: 16px;
}

.employer-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}

.report-actions {
    margin-top: 24px;
    display: flex;
    gap: 16px;
    align-items: center;
}

.report-actions button {
    display: flex;
    align-items: center;
}

.download-status {
    font-size: 14px;
    font-weight: 500;
    padding: 8px 12px;
    border-radius: 4px;
}

.empty-reports-state {
    background: white;
    padding: 60px 24px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    text-align: center;
    color: var(--color-gray-500);
}

.empty-reports-state p {
    margin: 0;
    font-size: 16px;
}

/* HMRC Category Badges */
.hmrc-category-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

.hmrc-category-badge.category-1 {
    background: var(--badge-blue-bg);
    color: var(--badge-blue-text);
}

.hmrc-category-badge.category-2 {
    background: var(--badge-green-bg);
    color: var(--badge-green-text);
}

.hmrc-category-badge.category-3 {
    background: var(--badge-orange-bg);
    color: var(--badge-orange-text);
}

.hmrc-category-badge.category-4 {
    background: var(--badge-amber-bg);
    color: var(--badge-amber-text);
}

.hmrc-category-badge.category-5 {
    background: var(--badge-red-bg);
    color: var(--badge-red-text);
}

.hmrc-category-badge.category-6 {
    background: var(--badge-purple-bg);
    color: var(--badge-purple-text);
}

/* DTA Badges */
.dta-badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--badge-green-bg);
    color: var(--badge-green-text);
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.no-dta-badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--color-gray-100);
    color: var(--color-gray-mid);
    border-radius: 4px;
    font-size: 12px;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid var(--color-gray-lighter);
    border-top: 4px solid var(--badge-blue-text);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .report-filter-section {
        flex-direction: column;
    }

    .report-filter-section .form-group {
        width: 100%;
    }

    .report-preview-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .report-meta {
        flex-direction: column;
        gap: 8px;
    }

    .employer-info-grid {
        grid-template-columns: 1fr;
    }

    .report-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

/* ========================================
   UTILITY CLASSES FOR INLINE STYLING REPLACEMENT
   ======================================== */

.form-section-description {
    color: var(--color-gray-500);
    font-size: 14px;
}

.modal-delete-title {
    margin-top: 0;
    color: var(--color-error);
}

.modal-info-title {
    margin-top: 0;
    color: var(--badge-blue-text);
}

.modal-text-secondary {
    margin: 15px 0;
    font-size: 14px;
    color: var(--color-gray-500);
}

.modal-hint-text {
    margin-top: 5px;
    font-size: 12px;
    color: var(--color-gray-500);
}

.btn-delete {
    padding: 10px 20px;
    border: none;
    background: var(--color-error);
    color: var(--color-white);
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.btn-primary-action {
    padding: 10px 20px;
    border: none;
    background: var(--badge-blue-text);
    color: var(--color-white);
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

/* ==================== APPENDIX 4 DASHBOARD STYLES ==================== */

/* Dashboard Layout */
.appendix4-dashboard {
    position: relative;
    min-height: 100vh;
    background-color: #f5f5f5;
    padding: 0 !important;
}

/* Dashboard Header */
.appendix4-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background-color: white;
    border-bottom: 1px solid #e0e0e0;
    margin-left: 466px;
    /* 186px (nav) + 280px (filters) */
}

.appendix4-header h1 {
    font-size: 28px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
}

.powered-by {
    font-size: 14px;
    color: #666;
}

.brand-name {
    color: #3FAEBD;
    font-weight: 600;
}

/* Left Sidebar Filters */
.appendix4-filters {
    position: fixed;
    left: 186px;
    /* Account for main navigation width */
    top: 0;
    width: 280px;
    height: 100vh;
    background-color: white;
    border-right: 1px solid #e0e0e0;
    padding: 24px 20px;
    overflow-y: auto;
    z-index: 50;
}

.filter-group {
    margin-bottom: 24px;
}

.filter-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.filter-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
    background-color: white;
    cursor: pointer;
    transition: border-color 0.2s;
}

.filter-select:hover {
    border-color: #3FAEBD;
}

.filter-select:focus {
    outline: none;
    border-color: #3FAEBD;
    box-shadow: 0 0 0 3px rgba(63, 174, 189, 0.1);
}

.filter-select[multiple] {
    padding: 8px;
}

.filter-hint {
    display: block;
    font-size: 11px;
    color: #888;
    margin-top: 4px;
}

/* Main Content Area */
.appendix4-content {
    margin-left: 466px;
    /* 186px (nav) + 280px (filters) */
    padding: 24px 40px;
}

/* Metric Cards */
.metric-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.metric-card {
    padding: 32px 28px;
    border-radius: 12px;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

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

.metric-card-dark {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
}

.metric-card-teal {
    background: linear-gradient(135deg, #3FAEBD 0%, #2d8a96 100%);
}

.metric-value {
    font-size: 52px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 12px;
}

.metric-label {
    font-size: 15px;
    font-weight: 400;
    opacity: 0.95;
    letter-spacing: 0.3px;
}

/* Category Breakdown Cards */
.category-cards {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}

.category-card {
    background-color: white;
    padding: 20px 16px;
    border-radius: 10px;
    border: 1px solid #e0e0e0;
    text-align: center;
    transition: all 0.2s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-color: #3FAEBD;
}

.category-label {
    font-size: 13px;
    font-weight: 600;
    color: #666;
    margin-bottom: 12px;
    line-height: 1.3;
}

.category-count {
    font-size: 36px;
    font-weight: 700;
    color: #2c3e50;
}

/* Map Section */
.map-section {
    background-color: white;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
}

.stay-category-filter {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stay-category-filter label {
    font-size: 13px;
    font-weight: 500;
    color: #666;
}

.filter-pill {
    padding: 6px 14px;
    background-color: #3FAEBD;
    color: white;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

.map-container {
    height: 400px;
    position: relative;
    background-color: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
}

.map-container canvas {
    width: 100% !important;
    height: 100% !important;
}

.azure-map {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

/* Chart Section */
.chart-section {
    background-color: white;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.chart-filter {
    display: flex;
    align-items: center;
    gap: 10px;
}

.chart-filter label {
    font-size: 13px;
    font-weight: 500;
    color: #666;
}

.filter-select-inline {
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 13px;
    color: #333;
    background-color: white;
    cursor: pointer;
}

.chart-info {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.chart-info-label {
    font-size: 13px;
    font-weight: 600;
    color: #666;
}

.chart-legend {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.legend-value {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    min-width: 30px;
}

.legend-bar {
    flex: 1;
    height: 12px;
    background-color: #f0f0f0;
    border-radius: 6px;
    position: relative;
    overflow: hidden;
    max-width: 200px;
}

.legend-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #3FAEBD 0%, #2d8a96 100%);
    border-radius: 6px;
    transition: width 0.3s ease;
}

.legend-max {
    font-size: 13px;
    color: #888;
    min-width: 30px;
    text-align: right;
}

.chart-container {
    position: relative;
    height: 450px;
}

.chart-container canvas {
    max-height: 400px;
}

/* Dashboard Actions */
.dashboard-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 0;
}

.btn-secondary {
    padding: 12px 24px;
    border: 1px solid #ddd;
    background-color: white;
    color: #333;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
}

.btn-secondary:hover {
    background-color: #f8f9fa;
    border-color: #3FAEBD;
    color: #3FAEBD;
}

.export-status {
    font-size: 14px;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 1400px) {
    .category-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .appendix4-filters {
        width: 240px;
        left: 186px;
    }

    .appendix4-header,
    .appendix4-content {
        margin-left: 426px;
        /* 186px (nav) + 240px (filters) */
    }

    .metric-cards {
        grid-template-columns: 1fr;
    }

    .category-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .appendix4-filters {
        width: 100%;
        position: static;
        height: auto;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
    }

    .appendix4-header,
    .appendix4-content {
        margin-left: 0;
    }

    .category-cards {
        grid-template-columns: 1fr;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}

/* ========================================
   Step 7: Automation Styles
   ======================================== */

/* Automation Selection Container */
.automation-selection-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px;
}

/* Automation Cards Grid */
.automation-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

/* Individual Automation Card */
.automation-card {
    background: #ffffff;
    border: 2px solid var(--color-gray-200);
    border-radius: 12px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.automation-card:hover {
    border-color: var(--brand-primary);
    box-shadow: 0 8px 24px rgba(63, 174, 189, 0.15);
    transform: translateY(-4px);
}

.automation-card-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.automation-icon {
    font-size: 48px;
    line-height: 1;
}

.automation-card-header h3 {
    color: var(--brand-primary-dark);
    font-size: 20px;
    font-weight: 600;
    margin: 0;
}

.automation-description {
    color: var(--color-gray-700);
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.automation-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--color-gray-200);
}

.automation-duration,
.automation-portal {
    font-size: 13px;
    color: var(--color-gray-600);
    display: flex;
    align-items: center;
    gap: 5px;
}

.automation-requirements,
.automation-features {
    margin-bottom: 15px;
}

.automation-requirements strong,
.automation-features strong {
    display: block;
    color: var(--brand-primary-dark);
    font-size: 14px;
    margin-bottom: 8px;
}

.automation-requirements ul,
.automation-features ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.automation-requirements li,
.automation-features li {
    font-size: 13px;
    color: var(--color-gray-700);
    padding: 4px 0;
    padding-left: 20px;
    position: relative;
}

.automation-requirements li:before {
    content: "•";
    position: absolute;
    left: 8px;
    color: var(--brand-primary);
    font-weight: bold;
}

.automation-features li {
    padding-left: 0;
}

.automation-select-btn {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-dark));
    color: var(--color-white);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.automation-select-btn:hover {
    background: linear-gradient(135deg, var(--brand-primary-dark), var(--brand-primary-hover));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 174, 189, 0.3);
}

/* Loading and Error States */
.loading-automations {
    text-align: center;
    padding: 60px 20px;
    color: var(--color-gray-600);
}

.loading-automations p {
    margin-top: 15px;
    font-size: 16px;
}

.no-automations-message {
    text-align: center;
    padding: 60px 20px;
    background: #ffffff;
    border: 2px dashed var(--color-gray-300);
    border-radius: 12px;
}

.no-automations-message p {
    color: var(--color-gray-700);
    font-size: 16px;
    margin: 10px 0;
}

/* Automation Status Container (Progress Section) */
.automation-status-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.progress-status {
    margin-bottom: 30px;
}

.progress-bar-container {
    width: 100%;
    height: 30px;
    background: var(--color-gray-200);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 15px;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--brand-primary), var(--brand-primary-dark));
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    color: var(--color-white);
    font-weight: 600;
    font-size: 14px;
}

#automationCurrentStep {
    text-align: center;
    font-size: 16px;
    color: var(--color-gray-700);
    font-weight: 500;
    margin: 10px 0;
}

.govuk-completion-message {
    background: linear-gradient(135deg, var(--brand-primary-light) 0%, var(--color-white) 100%);
    border: 2px solid var(--brand-primary);
    border-radius: 12px;
    padding: 30px;
    margin-top: 30px;
    text-align: center;
}

.govuk-completion-message h3 {
    color: var(--brand-primary-dark);
    font-size: 24px;
    margin-bottom: 15px;
}

.govuk-completion-message>p {
    color: var(--brand-primary-dark);
    font-size: 16px;
    margin-bottom: 20px;
}

.completion-checklist {
    background: var(--color-white);
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    text-align: left;
}

.completion-checklist p {
    font-weight: 600;
    color: var(--color-gray-700);
    margin-bottom: 12px;
}

.completion-checklist ul {
    list-style: none;
    padding-left: 0;
}

.completion-checklist li {
    padding: 8px 0;
    font-size: 15px;
    color: var(--color-gray-600);
}

#proceedToVFSBtn {
    margin-top: 20px;
    font-size: 16px;
    padding: 14px 30px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-dark));
    border: none;
    transition: all 0.3s ease;
}

#proceedToVFSBtn:hover {
    background: linear-gradient(135deg, var(--brand-primary-dark), var(--brand-primary-hover));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 174, 189, 0.3);
}

/* ========================================
   VFS Global Styles
   ======================================== */

.vfs-instructions-container {
    margin-top: 40px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    animation: slideDown 0.5s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.vfs-header {
    background: linear-gradient(135deg, var(--brand-secondary) 0%, var(--brand-secondary-dark) 100%);
    color: var(--color-white);
    padding: 25px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.vfs-logo {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 1px;
}

.vfs-est {
    font-size: 12px;
    opacity: 0.9;
    font-weight: 400;
    margin-left: 10px;
}

.vfs-countries {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
}

.country-flag {
    font-size: 24px;
}

.country-name {
    font-weight: 500;
}

.arrow {
    font-size: 20px;
    color: var(--brand-tertiary-yellow);
}

.vfs-content {
    padding: 35px;
}

.vfs-alert {
    background: var(--brand-tertiary-yellow-light);
    border-left: 4px solid var(--brand-tertiary-yellow);
    padding: 15px 20px;
    margin-bottom: 25px;
    border-radius: 4px;
    font-size: 15px;
    color: var(--color-gray-800);
}

.vfs-title {
    font-size: 28px;
    color: var(--brand-secondary-dark);
    margin-bottom: 15px;
    font-weight: 700;
}

.vfs-subtitle {
    font-size: 16px;
    color: var(--color-gray-700);
    margin-bottom: 20px;
}

.vfs-info-section {
    margin: 25px 0;
    line-height: 1.7;
    color: var(--color-gray-600);
}

.vfs-info-section p {
    margin-bottom: 15px;
}

.vfs-action-buttons {
    display: flex;
    gap: 15px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.vfs-btn {
    padding: 14px 28px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.vfs-btn-primary {
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-dark));
    color: var(--color-white);
}

.vfs-btn-primary:hover {
    background: linear-gradient(135deg, var(--brand-primary-dark), var(--brand-primary-hover));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(63, 174, 189, 0.3);
}

.vfs-btn-secondary {
    background: var(--color-gray-200);
    color: var(--brand-primary-dark);
}

.vfs-btn-secondary:hover {
    background: var(--color-gray-300);
}

.vfs-cta-box {
    background: linear-gradient(135deg, var(--brand-primary-light) 0%, var(--color-white) 100%);
    border: 2px solid var(--brand-primary);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    margin: 35px 0 25px;
}

.vfs-cta-box h4 {
    color: var(--brand-primary-dark);
    font-size: 22px;
    margin-bottom: 15px;
}

.vfs-cta-box p {
    color: var(--brand-primary-dark);
    margin-bottom: 20px;
    font-size: 15px;
}

.btn-large {
    font-size: 18px;
    padding: 16px 40px;
    display: inline-block;
    text-decoration: none;
}

.vfs-footer {
    border-top: 1px solid var(--color-gray-200);
    padding-top: 20px;
    margin-top: 30px;
    text-align: center;
    color: var(--color-gray-500);
}

/* Responsive Styles for Step 7 */
@media (max-width: 768px) {
    .automation-selection-container {
        padding: 20px;
    }

    .automation-cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .automation-card {
        padding: 20px;
    }

    .automation-icon {
        font-size: 36px;
    }

    .automation-card-header h3 {
        font-size: 18px;
    }

    .automation-status-container {
        padding: 20px;
    }

    .govuk-completion-message {
        padding: 20px;
    }

    .govuk-completion-message h3 {
        font-size: 20px;
    }

    .vfs-header {
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
    }

    .vfs-content {
        padding: 20px;
    }

    .vfs-title {
        font-size: 24px;
    }

    .vfs-action-buttons {
        flex-direction: column;
    }

    .vfs-btn {
        width: 100%;
    }

    .vfs-cta-box {
        padding: 20px;
    }

    .btn-large {
        font-size: 16px;
        padding: 14px 30px;
    }
}

/* ============================================================================
   BING MAPS - Interactive World Map Styles
   ============================================================================ */

/* Map Header with Controls */
.map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 15px;
}

.map-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

/* Map Controls (Metric Selector) */
.map-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.map-controls label {
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    white-space: nowrap;
}

#mapMetricSelector {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: white;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 200px;
}

#mapMetricSelector:hover {
    border-color: #9ca3af;
}

#mapMetricSelector:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Map Container */
.map-container {
    position: relative;
    width: 100%;
    height: 500px;
    border-radius: 8px;
    overflow: hidden;
    background: #f3f4f6;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Map Element (kept for backward compatibility) */
.bing-map,
.azure-map {
    width: 100%;
    height: 100%;
    position: relative;
}

/* Map Loading Indicator */
.map-loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    z-index: 10;
    transition: opacity 0.3s;
}

.map-loading.hidden {
    opacity: 0;
    pointer-events: none;
}

.map-loading .spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.map-loading span {
    font-size: 16px;
    font-weight: 500;
}

/* Map Error State */
.map-error {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    padding: 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 400px;
}

.map-error-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.map-error-title {
    font-size: 18px;
    font-weight: 600;
    color: #dc2626;
    margin-bottom: 10px;
}

.map-error-message {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
}

/* Country Detail Modal Enhancements */
.country-stat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.country-stat-card {
    padding: 16px;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

.country-stat-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6b7280;
    margin-bottom: 6px;
    font-weight: 600;
}

.country-stat-value {
    font-size: 28px;
    font-weight: 700;
    color: #1f2937;
}

.country-stat-value.pending {
    color: #f59e0b;
}

.country-stat-value.approved {
    color: #10b981;
}

.country-stat-value.rejected {
    color: #ef4444;
}

.country-stat-value.urgent {
    color: #dc2626;
}

.country-detail-section {
    margin-bottom: 24px;
}

.country-detail-section:last-child {
    margin-bottom: 0;
}

.country-detail-section h4 {
    font-size: 16px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-breakdown-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.status-breakdown-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}

.status-breakdown-label {
    font-size: 14px;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-badge {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-badge.pending {
    background: #f59e0b;
}

.status-badge.approved {
    background: #10b981;
}

.status-badge.rejected {
    background: #ef4444;
}

.status-badge.draft {
    background: #6b7280;
}

.status-breakdown-value {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

/* Modal Button Styles */
.btn-secondary-action {
    padding: 10px 20px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-secondary-action:hover {
    background: #f3f4f6;
    border-color: #5568d3;
    color: #5568d3;
}

#closeCountryDetailBtn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Responsive Map Styles */
@media (max-width: 768px) {
    .map-container {
        height: 400px;
    }

    .map-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .map-controls {
        width: 100%;
    }

    #mapMetricSelector {
        width: 100%;
    }

    .country-stat-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        margin: 10% auto !important;
        width: 95% !important;
    }

    .modal-footer {
        flex-direction: column;
    }

    .modal-footer button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .map-container {
        height: 300px;
    }

    .map-loading span {
        font-size: 14px;
    }
}
/* ==================== SETTINGS VIEW STYLES ==================== */

/* Settings View Wrapper */
.settings-view-wrapper {
    margin-left: 200px;
    flex: 1;
    min-height: 100vh;
    width: calc(100% - 200px);
    background: var(--color-gray-100);
    transition: margin-left 0.3s ease, width 0.3s ease;
    padding-bottom: 70px;
}

.sidebar.collapsed~.settings-view-wrapper {
    margin-left: 60px;
    width: calc(100% - 60px);
}

.settings-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 30px;
}

.settings-header {
    margin-bottom: 30px;
}

.settings-header h1 {
    font-size: 32px;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.settings-header .header-subtitle {
    color: var(--color-gray-500);
    font-size: 16px;
}

.settings-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.settings-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.settings-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--color-gray-200);
}

.settings-card-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 8px 0;
}

.settings-card-description {
    font-size: 14px;
    color: var(--color-gray-500);
    margin: 0;
}

.settings-form {
    padding: 24px;
}

.settings-form .form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.settings-form .form-group {
    display: flex;
    flex-direction: column;
}

.settings-form .form-group label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.settings-form .form-control {
    padding: 10px 14px;
    border: 1px solid var(--color-gray-300);
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.settings-form .form-control:focus {
    outline: none;
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(63, 174, 189, 0.15);
}

.settings-form .form-control::placeholder {
    color: var(--color-gray-400);
}

.settings-form textarea.form-control {
    resize: vertical;
    min-height: 60px;
}

.settings-form-actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 16px;
    border-top: 1px solid var(--color-gray-200);
    margin-top: 4px;
}

/* Responsive adjustments for Settings */
@media (max-width: 992px) {
    .settings-form .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .settings-view-wrapper {
        margin-left: 0;
        width: 100%;
    }

    .settings-container {
        padding: 20px;
    }

    .settings-header h1 {
        font-size: 24px;
    }

    .settings-form .form-row {
        grid-template-columns: 1fr;
    }

    .settings-form {
        padding: 16px;
    }
}

/* Settings card header with auto-fill button */
.settings-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.settings-card-header-content {
    flex: 1;
}

.settings-card .auto-fill-btn {
    flex-shrink: 0;
    padding: 8px 16px;
    font-size: 13px;
    background: var(--color-gray-100);
    border: 1px solid var(--color-gray-300);
    border-radius: 6px;
    color: var(--color-gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.settings-card .auto-fill-btn:hover {
    background: var(--brand-primary);
    border-color: var(--brand-primary);
    color: white;
}
