/* === THE DEFINITIVE & PROFESSIONAL CSS FOR YOUR WEBSITE (MOBILE-FIRST) === */
:root {
    /* Original Variables */
    --text-primary: #34495e;
    --text-secondary: #6c757d;
    --bg-page: #f8f9fa;
    --bg-card: #ffffff;
    --border-color: #dee2e6;
    --light-gray: #f1f3f5;
    --success: #28a745;
    --warning: #ffc107;
    --danger: #dc3545;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    --radius: 12px;
    --font-sans: 'Segoe UI', system-ui, -apple-system, sans-serif;

    /* Primary Finance Colors - Trust & Stability */
    --primary: #1a3c6e;
    --primary-light: #2a4d7a;
    --primary-dark: #0f2a4a;

    /* Secondary Colors - Professional & Calm */
    --secondary: #2563eb;
    --secondary-light: #3b82f6;
    --secondary-dark: #1d4ed8;

    /* Accent Colors - Financial Indicators */
    --accent-success: #059669;
    --accent-warning: #d97706;
    --accent-danger: #dc2626;
    --accent-info: #0891b2;

    /* Neutral Colors - Professional & Clean */
    --light: #f8fafc;
    --lighter: #ffffff;
    --dark: #1e293b;
    --text: #334155;
    --text-light: #64748b;
    --border: #e2e8f0;

    /* Financial Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    --gradient-secondary: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    --gradient-success: linear-gradient(135deg, var(--accent-success) 0%, #047857 100%);

    /* Sizing & Effects */
    --border-radius: 8px;
    --border-radius-sm: 6px;
    --box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --box-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-page);
    color: var(--text-primary);
    margin: 0;
    padding: 0;
}

/* --- 2. Main Layout Containers --- */
.main-content {
            max-width: 1200px;
            margin: 2rem auto;
            padding: 0 2rem;
        }

.live-dashboard-layout {
    width: 100%;
}

.containerbox {
    max-width: 1200px;
    margin: 0 auto;
}


/* --- 3. Navigation Bar --- */
.navbar {
    background: var(--gradient-primary);
    box-shadow: var(--box-shadow-lg);
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    min-height: 70px;
    border-bottom: 3px solid var(--secondary);
}

.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-success) 0%, var(--secondary) 50%, var(--accent-info) 100%);
    opacity: 0.8;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--lighter);
    font-weight: 700;
    font-size: 1.4rem;
    transition: var(--transition);
}

.navbar-brand:hover {
    transform: translateY(-2px);
}

.logo {
    background: var(--gradient-secondary);
    color: white;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.2rem;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.title {
    color: var(--lighter);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    position: relative;
    animation: slideIn 0.4s ease forwards;
}

.nav-menu a {
    color: var(--lighter);
    text-decoration: none;
    font-weight: 500;
    padding: 0.6rem 1.2rem;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
    display: block;
    font-size: 0.95rem;
    border: 1px solid transparent;
}

.nav-menu a:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--lighter);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.nav-menu a:active {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(0);
}

.country-selector {
    position: relative;
    margin-left: 0.5rem;
}

.country-selector select {
    background: rgba(255, 255, 255, 0.12);
    border: 1.5px solid rgba(255, 255, 255, 0.25);
    border-radius: var(--border-radius-sm);
    color: var(--lighter);
    padding: 0.6rem 2.5rem 0.6rem 1rem;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    appearance: none;
    min-width: 190px;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.country-selector select:hover {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.country-selector select:focus {
    outline: none;
    border-color: var(--secondary-light);
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.country-selector::after {
    content: '▼';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--lighter);
    font-size: 0.7rem;
    pointer-events: none;
    opacity: 0.8;
}

.country-selector select option {
    background: var(--lighter);
    color: var(--dark);
    padding: 0.5rem;
}

.menu-toggle {
    display: none;
    background: rgba(255, 255, 255, 0.1);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    color: var(--lighter);
    cursor: pointer;
    padding: 0.6rem;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.menu-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
}

.menu-toggle svg {
    fill: currentColor;
    width: 20px;
    height: 20px;
}


/* --- 4. Content & Card Styles --- */

.content-card {
    background: var(--lighter);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-lg);
    overflow: hidden;
    margin-bottom: 2rem;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.content-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

.container-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    padding: 1.5rem 2rem;
    border-bottom: 3px solid var(--secondary);
}

.container-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0;
}

.container-header h2::before {
    content: '';
    display: block;
    width: 4px;
    height: 24px;
    background: var(--secondary);
    border-radius: 2px;
}

.section {
    padding: 2rem;
    animation: fadeInUp 0.6s ease-out;
}

.section h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.section h2::before {
    content: '';
    display: block;
    width: 6px;
    height: 28px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--accent-success) 100%);
    border-radius: 3px;
}

.subtitle {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    font-weight: 500;
}


/* 4A. Card Input Section */
#card-inputs-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.card-entry {
    background: var(--lighter);
    border: 2px solid var(--border);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    position: relative;
    transition: var(--transition);
    box-shadow: var(--box-shadow);
    animation: slideIn 0.4s ease-out forwards;
}

.card-entry:hover {
    border-color: var(--secondary-light);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--light);
}

.card-header h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.card-header h4::before {
    content: '💳';
    font-size: 1.1rem;
}

.card-footer {
            display: flex;
            justify-content: flex-end;
            padding: 15px 25px 25px;
        }
.delete-btn {
            background: rgba(220, 38, 38, 0.1);
            border: 1.5px solid rgba(220, 38, 38, 0.2);
            border-radius: var(--border-radius-sm);
            padding: 0.75rem 1.5rem;
            cursor: pointer;
            transition: var(--transition);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            font-weight: 500;
            color: var(--accent-danger);
            margin-left: auto;
        }

        .delete-btn:hover {
            background: rgba(220, 38, 38, 0.15);
            border-color: rgba(220, 38, 38, 0.3);
            transform: scale(1.05);
        }

        .delete-btn svg {
            fill: var(--accent-danger);
            transition: var(--transition);
            width: 18px;
            height: 18px;
        }

        .delete-btn:hover svg {
            fill: #b91c1c;
        }

.card-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.limit, .balance {
    width: 100%;
    padding: 1rem 1.25rem 1rem 3rem;
    font-size: 1.1rem;
    font-weight: 500;
    background: var(--lighter);
    border: 2px solid var(--border);
    border-radius: var(--border-radius-sm);
    color: var(--dark);
    transition: var(--transition);
    position: relative;
    background-repeat: no-repeat;
    background-position: left 1rem center;
    background-size: 1.25rem;
    box-sizing: border-box; /* FIX: Prevents overflow */
}

.limit:focus, .balance:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.limit:hover, .balance:hover {
    border-color: var(--secondary-light);
}

.limit {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1'%3E%3C/path%3E%3C/svg%3E");
}

.balance {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 19v-6a2 2 0 00-2-2H5a2 2 0 00-2 2v6a2 2 0 002 2h2a2 2 0 002-2zm0 0V9a2 2 0 012-2h2a2 2 0 012 2v10m-6 0a2 2 0 002 2h2a2 2 0 002-2m0 0V5a2 2 0 012-2h2a2 2 0 012 2v14a2 2 0 01-2 2h-2a2 2 0 01-2-2z'%3E%3C/path%3E%3C/svg%3E");
}

.limit:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%232563eb'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1'%3E%3C/path%3E%3C/svg%3E");
}

.balance:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%232563eb'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 19v-6a2 2 0 00-2-2H5a2 2 0 00-2 2v6a2 2 0 002 2h2a2 2 0 002-2zm0 0V9a2 2 0 012-2h2a2 2 0 012 2v10m-6 0a2 2 0 002 2h2a2 2 0 002-2m0 0V5a2 2 0 012-2h2a2 2 0 012 2v14a2 2 0 01-2 2h-2a2 2 0 01-2-2z'%3E%3C/path%3E%3C/svg%3E");
}


/* 4B. Right Column: Dashboard, Gauge & Breakdown */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
    align-items: center;
}

.gauge-container {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto;
    flex-shrink: 0;
}

.gauge {
    width: 100%;
    height: 100%;
}

#gauge-progress {
    transition: stroke-dashoffset 1s ease-in-out;
    stroke-linecap: round;
}

.gauge-text-group {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

#gauge-text {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-dark);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.gauge-label {
    font-size: 1rem;
    color: var(--text-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
}

.summary-list {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
}

.summary-list li {
    background: var(--light);
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: var(--border-radius-sm);
    border-left: 4px solid var(--primary); /* Merged from --primary-blue */
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    box-shadow: var(--box-shadow);
    animation: slideInUp 0.6s ease-out forwards;
}

.summary-list li:hover {
    transform: translateX(5px);
    border-left-color: var(--accent-success);
}

.summary-list li:nth-child(2) { border-left-color: var(--accent-info); }
.summary-list li:nth-child(3) { border-left-color: var(--accent-warning); }
.summary-list li:last-child { border-bottom: none; }

.summary-list li strong {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-dark);
}

#rating-text {
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

.rating-excellent { background: linear-gradient(135deg, var(--accent-success) 0%, #047857 100%); color: white; }
.rating-good { background: linear-gradient(135deg, var(--accent-info) 0%, #0e7490 100%); color: white; }
.rating-fair { background: linear-gradient(135deg, var(--accent-warning) 0%, #b45309 100%); color: white; }
.rating-poor { background: linear-gradient(135deg, var(--accent-danger) 0%, #b91c1c 100%); color: white; }

.card-breakdown-area {
    margin-top: 20px;
    padding: 0 2rem 2rem 2rem;
}

.card-breakdown-area h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin: 16px 0 1.5rem 0;
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--light);
}

.card-breakdown-area h3::before {
    content: '💳';
    font-size: 1.2rem;
}

#card-breakdown-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.card-detail, .breakdown-card { /* Merging .card-detail into .breakdown-card */
    background: var(--lighter);
    border: 2px solid var(--border);
    border-radius: var(--border-radius-sm);
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    box-shadow: var(--box-shadow);
    margin-bottom: 8px; /* From .card-detail */
    animation: slideInUp 0.6s ease-out forwards;
}

.breakdown-card:hover {
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.card-detail.good { background: rgba(52, 199, 89, 0.1); }
.card-detail.fair { background: rgba(255, 198, 0, 0.1); }
.card-detail.poor { background: rgba(255, 59, 48, 0.1); }

.card-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.card-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
}

.card-details h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin: 0 0 0.25rem 0;
}

.card-details .card-utilization {
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
}

.card-stats {
    text-align: right;
}

.card-limit {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.25rem;
}

.card-balance {
    font-size: 1rem;
    color: var(--text-light);
    font-weight: 500;
}

.utilization-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

.badge-excellent { background: rgba(5, 150, 105, 0.1); color: var(--accent-success); }
.badge-good { background: rgba(8, 145, 178, 0.1); color: var(--accent-info); }
.badge-warning { background: rgba(217, 119, 6, 0.1); color: var(--accent-warning); }
.badge-danger { background: rgba(220, 38, 38, 0.1); color: var(--accent-danger); }


/* 4C. Other Components & Content Typography */
.premium-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem; /* Added gap for spacing */
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

.premium-list li {
    background: #fff;
    border-radius: 12px;
    padding: 15px 20px 15px 45px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    position: relative;
    cursor: pointer;
}

.premium-list li:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.premium-list li::before {
    content: '✔';
    color: var(--secondary); /* Merged from --primary-blue */
    font-weight: bold;
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
}

.result-box {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 2px solid var(--border);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-top: 1rem;
    animation: slideInUp 0.5s ease-out;
    border-left: 4px solid var(--accent-success);
}

.result-box.success { border-left-color: var(--accent-success); background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%); }
.result-box.info { border-left-color: var(--accent-info); background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%); }
.result-box.warning { border-left-color: var(--accent-warning); background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%); }

.result-box h5 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.result-box h5::before { content: '📈'; }
.result-content { color: var(--text); line-height: 1.6; }

.result-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary); /* Merged from --primary-blue */
    display: block;
}

details {
    background: var(--lighter);
    border: 1px solid var(--border); /* Merged from --light */
    border-radius: var(--border-radius-sm);
    margin: 1rem 0;
    transition: var(--transition);
    overflow: hidden;
}

details:hover {
    border-color: var(--secondary-light);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow);
}

details[open] {
    background: white;
    border-color: var(--secondary);
}

summary {
    padding: 1.5rem;
    font-weight: 600;
    cursor: pointer;
    color: var(--primary);
    font-size: 1.1rem;
    position: relative;
    list-style: none;
    transition: var(--transition);
}

summary:hover {
    background: rgba(52, 152, 219, 0.05);
}

summary::after {
    content: '+';
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    color: var(--secondary);
    transition: var(--transition);
}

details[open] summary::after {
    content: '−';
    color: var(--accent-danger); /* Merged from --accent */
}

details p {
    padding: 0 1.5rem 1.5rem 1.5rem;
    margin: 0;
    color: var(--text);
    border-top: 1px solid var(--border); /* Merged from --light */
    padding-top: 1.5rem;
}

.card-content {
    padding: 3rem;
}

.content-intro {
    margin-bottom: 2.5rem;
}

.intro-highlight {
    color: var(--primary);
    font-size: 1.3rem;
    font-weight: 600;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
    border-left: 4px solid var(--secondary);
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    padding: 1.5rem;
    border-radius: 0 var(--border-radius-sm) var(--border-radius-sm) 0;
}

.content-paragraph {
    margin-bottom: 1.8rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text);
    position: relative;
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0;
}

.content-paragraph strong {
    color: var(--primary);
    font-weight: 700;
    background: linear-gradient(120deg, rgba(37, 99, 235, 0.1) 0%, rgba(37, 99, 235, 0.1) 100%);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
}

.content-paragraph em {
    color: var(--accent-success);
    font-style: italic;
    font-weight: 600;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.feature-card {
    background: var(--light);
    padding: 2rem;
    border-radius: var(--border-radius-sm);
    border-left: 4px solid var(--secondary);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateX(5px);
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
}

.feature-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.feature-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.feature-description {
    color: var(--text);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* 4D. Simulators & Action Plans */
.simulator {
    padding: 2rem;
    border-bottom: 1px solid var(--border);
}

.simulator:last-child { border-bottom: none; }

.simulator h4 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.simulator h4::before { content: '🔮'; font-size: 1.2rem; }

.simulator p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-size: 1rem;
    line-height: 1.6;
}

.simulator-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    align-items: center; /* Vertically align items */
}

/* NEW: Styles for Simulator Form Elements */
.simulator-grid .select-wrapper {
    position: relative;
    width: 100%;
}

.simulator-grid .select-wrapper::after {
    content: '▼';
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 0.8rem;
    pointer-events: none;
}

.simulator-grid select,
.simulator-grid input {
    width: 100%;
    padding: 0.875rem 1.25rem;
    font-size: 1rem;
    font-weight: 500;
    background-color: var(--lighter);
    border: 2px solid var(--border);
    border-radius: var(--border-radius-sm);
    color: var(--dark);
    transition: var(--transition);
    box-sizing: border-box;
}

.simulator-grid select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 2.5rem; /* Make space for arrow */
    cursor: pointer;
}

.simulator-grid select:focus,
.simulator-grid input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
/* End of New Simulator Styles */

#action-plan-section {
    display: flex;
    flex-direction: column;
}

.action-plan-box {
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.plan-category {
    background: var(--lighter);
    border: 2px solid var(--border);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    animation: slideInUp 0.5s ease-out forwards;
}

.plan-category:hover {
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.plan-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--light);
}

.plan-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%); /* Merged from --primary-blue */
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
}

.plan-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin: 0;
}

.plan-steps {
    list-style: none;
    padding: 0;
    margin: 0;
}

.plan-step {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--light);
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.plan-step:last-child { border-bottom: none; }

.step-number {
    background: var(--accent-success);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.step-content {
    flex: 1;
    color: var(--text);
    line-height: 1.5;
}

.step-highlight {
    background: linear-gradient(120deg, rgba(37, 99, 235, 0.1) 0%, rgba(37, 99, 235, 0.05) 100%);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 600;
    color: var(--secondary); /* Merged from --primary-blue */
    border-bottom: 2px solid var(--primary-light);
}


/* --- 5. Buttons & CTAs --- */
.btn {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-primary {
    background-color: var(--primary-dark);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #0069d9;
}

/* Button in simulator should have same height as inputs */
.simulator-grid .btn-primary {
    padding: 0.875rem 1.25rem;
    height: 100%;
    font-size: 1rem;
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
}

.btn-secondary:active {
    transform: translateY(0);
}

.button-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cta-section {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    text-align: center;
    margin-top: 2rem;
    border: 1px solid var(--border);
}

.cta-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
}

.cta-description {
    color: var(--text-light);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: linear-gradient(135deg, var(--success) 0%, #2ecc71 100%);
    color: white;
    text-decoration: none;
    padding: 1.25rem 2.5rem;
    border-radius: var(--border-radius);
    font-weight: 700;
    font-size: 1.2rem;
    transition: var(--transition);
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.3);
    margin: 2rem 0 1rem 0;
}

.cta-button:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 30px rgba(39, 174, 96, 0.4);
}

.cta-button:active {
    transform: translateY(-1px);
}


/* --- 6. Accessibility & Scrollbar --- */
.nav-menu a:focus-visible,
.menu-toggle:focus-visible,
.country-selector select:focus-visible {
    outline: 2px solid var(--secondary-light);
    outline-offset: 2px;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light);
}

::-webkit-scrollbar-thumb {
    background: var(--secondary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-light);
}

/* --- 7. Animations --- */
@keyframes slideIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Animation Delays */
.nav-menu li:nth-child(1) { animation-delay: 0.1s; }
.nav-menu li:nth-child(2) { animation-delay: 0.15s; }
.nav-menu li:nth-child(3) { animation-delay: 0.2s; }
.nav-menu li:nth-child(4) { animation-delay: 0.25s; }

.section:nth-child(2) { animation-delay: 0.1s; }
.section:nth-child(3) { animation-delay: 0.2s; }
.section:nth-child(4) { animation-delay: 0.3s; }
.section:nth-child(5) { animation-delay: 0.4s; }
.section:nth-child(6) { animation-delay: 0.5s; }

.card-entry:nth-child(1) { animation-delay: 0.1s; }
.card-entry:nth-child(2) { animation-delay: 0.2s; }
.card-entry:nth-child(3) { animation-delay: 0.3s; }
.card-entry:nth-child(4) { animation-delay: 0.4s; }

.content-paragraph:nth-child(1) { animation-delay: 0.2s; }
.content-paragraph:nth-child(2) { animation-delay: 0.4s; }
.content-paragraph:nth-child(3) { animation-delay: 0.6s; }

.summary-list li:nth-child(1) { animation-delay: 0.1s; }
.summary-list li:nth-child(2) { animation-delay: 0.2s; }
.summary-list li:nth-child(3) { animation-delay: 0.3s; }

.plan-category:nth-child(1) { animation-delay: 0.1s; }
.plan-category:nth-child(2) { animation-delay: 0.2s; }
.plan-category:nth-child(3) { animation-delay: 0.3s; }


/* --- 8. RESPONSIVE DESIGN --- */

/* For Tablets (and small desktops) */
@media (max-width: 1024px) {
    .live-dashboard-layout {
        display: block; /* Default flow */
    }
}

@media (max-width: 968px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .simulator-grid {
        grid-template-columns: 1fr;
    }
}


/* For Mobile */
@media (max-width: 768px) {
    body {
        padding: 0;
    }

    .navbar {
        padding: 0.75rem 1rem;
    }

    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--primary);
        flex-direction: column;
        padding: 1.5rem;
        gap: 0;
        box-shadow: var(--box-shadow-lg);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
        backdrop-filter: blur(20px);
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-menu li:last-child {
        border-bottom: none;
    }

    .nav-menu a {
        padding: 1rem 1.5rem;
        width: 100%;
        text-align: left;
    }

    .country-selector {
        width: 100%;
        margin: 0.5rem 0 0 0;
    }

    .country-selector select {
        width: 100%;
        min-width: auto;
        background: rgba(255, 255, 255, 0.15);
    }

    .title {
        font-size: 1.2rem;
    }

    .main-content, .section, .card-content {
        padding: 1.5rem;
    }

    .container-header {
        padding: 1.25rem 1.5rem;
    }

    .dashboard-grid {
        padding: 1.5rem;
    }

    .card-breakdown-area {
        padding: 1.5rem;
    }

    .breakdown-card {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .card-stats {
        text-align: center;
    }

    .card-body {
        grid-template-columns: 1fr;
    }

    .premium-list li {
        padding: 12px 16px 12px 40px;
    }
    
    .premium-list li::before {
        font-size: 1.1rem;
        left: 12px;
    }

    .gauge-container {
        width: 180px;
        height: 180px;
    }

    #gauge-text {
        font-size: 2rem;
    }

    .simulator, .action-plan-box {
        padding: 1.5rem;
    }

    .result-stats {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 0.6rem 1rem;
        min-height: 65px;
    }

    .logo {
        width: 38px;
        height: 38px;
        font-size: 1.1rem;
        border-radius: 8px;
    }

    .title {
        font-size: 1.1rem;
    }

    .main-content, .section, .card-content {
        padding: 1.5rem 1rem;
    }

    .country-selector select {
        font-size: 0.85rem;
        padding: 0.7rem 2.5rem 0.7rem 1rem;
    }

    .dashboard-grid, .card-breakdown-area, .simulator, .action-plan-box {
        padding: 1.25rem;
    }

    .summary-list li {
        flex-direction: column;
        gap: 0.5rem;
    }

    .gauge-container {
        width: 150px;
        height: 150px;
    }

    #gauge-text {
        font-size: 1.75rem;
    }

    .card-entry, .plan-category {
        padding: 1.25rem;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
}

.how-it-works-section {
    background: var(--bg-page);
    padding: 5rem 2rem;
    position: relative;
    overflow: hidden;
}

.how-it-works-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--success) 0%, var(--warning) 50%, var(--danger) 100%);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Section Header */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.3rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Process Steps */
.process-steps {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    margin-bottom: 5rem;
    position: relative;
}

.process-step {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    position: relative;
}

.step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    box-shadow: var(--shadow);
    border: 4px solid var(--bg-card);
    position: relative;
    z-index: 2;
}

.step-connector {
    width: 3px;
    height: 120px;
    background: linear-gradient(180deg, var(--primary) 0%, transparent 100%);
    margin-top: 1rem;
    border-radius: 2px;
}

.process-step:last-child .step-connector {
    display: none;
}

.step-content {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    flex: 1;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.step-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary);
}

.step-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.step-icon {
    width: 70px;
    height: 70px;
    background: var(--primary);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.step-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.step-content p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.step-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.feature-tag {
    background: var(--light-gray);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid var(--border-color);
}

/* Benefits Grid */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.benefit-card {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.benefit-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary);
}

.benefit-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.benefit-icon {
    width: 80px;
    height: 80px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
    box-shadow: var(--shadow);
}

.benefit-card h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.benefit-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* CTA Section */
.cta-section {
    background: var(--primary);
    border-radius: var(--radius);
    padding: 4rem;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-content h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    background: var(--success);
    color: white;
    border: none;
    padding: 1.25rem 3rem;
    border-radius: var(--border-radius-sm);
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
    background: #218838;
}

/* Responsive Design */
@media (max-width: 968px) {
    .how-it-works-section {
        padding: 3rem 1.5rem;
    }
    
    .section-header h2 {
        font-size: 2.5rem;
    }
    
    .process-step {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
    
    .step-indicator {
        flex-direction: row;
        gap: 1rem;
    }
    
    .step-connector {
        width: 120px;
        height: 3px;
        margin-top: 0;
    }
    
    .step-content {
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    .section-header h2 {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1.1rem;
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-section {
        padding: 3rem 1.5rem;
    }
    
    .cta-content h3 {
        font-size: 2rem;
    }
    
    .step-number {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    .step-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .how-it-works-section {
        padding: 2rem 1rem;
    }
    
    .step-content {
        padding: 1.5rem;
    }
    
    .benefit-card {
        padding: 2rem 1.5rem;
    }
    
    .cta-button {
        width: 100%;
        justify-content: center;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.process-step {
    animation: fadeInUp 0.6s ease-out forwards;
}

.process-step:nth-child(1) { animation-delay: 0.1s; }
.process-step:nth-child(2) { animation-delay: 0.2s; }
.process-step:nth-child(3) { animation-delay: 0.3s; }
.process-step:nth-child(4) { animation-delay: 0.4s; }

.benefit-card {
    animation: fadeInUp 0.6s ease-out forwards;
}

.benefit-card:nth-child(1) { animation-delay: 0.5s; }
.benefit-card:nth-child(2) { animation-delay: 0.6s; }
.benefit-card:nth-child(3) { animation-delay: 0.7s; }