/* Extracted from an inline <style> in: application/views/esim/destination.php
   Edit here; every view listed links this file. */
                        :root {
                            --bg-primary: #ffffff;
                            --bg-secondary: #fff7f2;
                            --bg-tertiary: #ffe9de;
                            --text-primary: #1a1a1a;
                            --text-secondary: #6b7280;
                            --text-tertiary: #9ca3af;
                            --border-light: #fde1d3;
                            --border-medium: #f7c9ae;
                            --accent-primary: #e35000;
                            --accent-hover: #cc4700;
                            --accent-light: #ffe9de;
                            --success: #10b981;
                            --danger: #ef4444;
                            --shadow-sm: 0 1px 2px rgba(227, 80, 0, 0.06);
                            --shadow-md: 0 4px 10px rgba(227, 80, 0, 0.10);
                            --radius: 12px;
                            --radius-sm: 8px;
                        }

                        .api-error-box {
                            margin: 2rem 0;
                            padding: 1.5rem;
                            background: rgba(239, 68, 68, 0.05);
                            border: 1px solid rgba(239, 68, 68, 0.2);
                            border-left: 4px solid #ef4444;
                            border-radius: var(--radius);
                        }

                        .api-error-box h3 {
                            color: #dc2626;
                            margin-bottom: 0.5rem;
                            font-size: 15px;
                            font-weight: 600;
                        }

                        .api-error-box p {
                            color: var(--text-secondary);
                            font-size: 14px;
                            margin-bottom: 0.8rem;
                            line-height: 1.6;
                        }

                        .api-error-box a {
                            color: var(--accent-primary);
                            text-decoration: none;
                            font-weight: 500;
                        }

                        .api-error-box a:hover {
                            text-decoration: underline;
                        }

                        .api-error-toggle {
                            display: inline-block;
                            color: var(--text-secondary);
                            cursor: pointer;
                            font-size: 13px;
                            margin-top: 0.5rem;
                            user-select: none;
                            transition: color 0.2s;
                        }

                        .api-error-toggle:hover {
                            color: var(--text-primary);
                        }

                        .api-error-detail {
                            display: none;
                            margin-top: 1rem;
                            padding: 1rem;
                            background: var(--bg-secondary);
                            border-radius: var(--radius-sm);
                            overflow: auto;
                            font-size: 12px;
                            color: var(--text-secondary);
                            max-height: 300px;
                            line-height: 1.5;
                        }

                        .flash-msg {
                            margin: 2rem 0 1rem;
                            padding: 12px 16px;
                            border-radius: var(--radius-sm);
                            font-size: 14px;
                            font-weight: 500;
                            animation: slideIn 0.3s ease;
                        }

                        .flash-success {
                            background: rgba(16, 185, 129, 0.1);
                            border: 1px solid rgba(16, 185, 129, 0.3);
                            border-left: 4px solid #10b981;
                            color: #059669;
                        }

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

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

                        /* ===== LAYOUT ===== */
                        .esim-layout {
                            display: grid;
                            grid-template-columns: 280px minmax(0, 1fr);
                            gap: 24px;
                            margin: 2rem 0 0;
                            align-items: start;
                        }

                        .esim-sidebar {
                            position: sticky;
                            top: 20px;
                            background: var(--bg-primary);
                            border: 1px solid var(--border-light);
                            border-radius: var(--radius);
                            padding: 18px;
                            box-shadow: var(--shadow-sm);
                        }

                        .sidebar-title {
                            font-size: 16px;
                            font-weight: 700;
                            color: var(--text-primary);
                            margin-bottom: 14px;
                        }

                        .sidebar-group+.sidebar-group {
                            margin-top: 16px;
                        }

                        .sidebar-label {
                            display: block;
                            font-size: 13px;
                            font-weight: 600;
                            color: var(--text-secondary);
                            margin-bottom: 8px;
                        }

                        .sidebar-input,
                        .sidebar-select {
                            appearance: none;
                            width: 100%;
                            padding: 12px 14px;
                            border: 1px solid var(--border-light);
                            background: var(--bg-secondary);
                            border-radius: var(--radius-sm);
                            color: var(--text-primary);
                            font-size: 14px;
                            transition: all 0.2s ease;
                        }

                        .sidebar-input::placeholder {
                            color: var(--text-tertiary);
                        }

                        .sidebar-input:focus,
                        .sidebar-select:focus {
                            outline: none;
                            border-color: var(--accent-primary);
                            background: var(--bg-primary);
                            box-shadow: 0 0 0 3px var(--accent-light);
                        }

                        .sidebar-actions {
                            display: flex;
                            flex-direction: column;
                            gap: 10px;
                            margin-top: 18px;
                        }

                        .sidebar-btn {
                            display: inline-flex;
                            align-items: center;
                            justify-content: center;
                            min-height: 44px;
                            padding: 0 16px;
                            border-radius: var(--radius-sm);
                            border: 1px solid var(--border-light);
                            background: var(--bg-primary);
                            color: var(--text-primary);
                            text-decoration: none;
                            font-size: 14px;
                            font-weight: 600;
                            transition: all 0.2s ease;
                            cursor: pointer;
                        }

                        .sidebar-btn:hover {
                            border-color: var(--border-medium);
                            background: var(--bg-secondary);
                        }

                        .sidebar-btn.primary {
                            background: var(--accent-primary);
                            border-color: var(--accent-primary);
                            color: #fff;
                        }

                        .sidebar-btn.primary:hover {
                            opacity: .95;
                        }

                        .sidebar-note {
                            margin-top: 14px;
                            font-size: 12px;
                            color: var(--text-tertiary);
                            line-height: 1.6;
                        }

                        .sidebar-checkbox-list {
                            max-height: 400px;
                            overflow-y: auto;
                            padding: 8px;
                            border: 1px solid var(--border-light);
                            background: var(--bg-secondary);
                            border-radius: var(--radius-sm);
                        }

                        .sidebar-country-search {
                            margin-bottom: 10px;
                        }

                        .sidebar-autocomplete {
                            display: none;
                            margin-top: -4px;
                            margin-bottom: 10px;
                            border: 1px solid var(--border-light);
                            background: var(--bg-primary);
                            border-radius: var(--radius-sm);
                            box-shadow: var(--shadow-md);
                            overflow: hidden;
                            max-height: 260px;
                            overflow-y: auto;
                        }

                        .sidebar-autocomplete.is-open {
                            display: block;
                        }

                        .sidebar-autocomplete-item {
                            display: flex;
                            align-items: center;
                            justify-content: space-between;
                            gap: 10px;
                            width: 100%;
                            border: 0;
                            background: transparent;
                            padding: 10px 12px;
                            color: var(--text-primary);
                            font-size: 13px;
                            text-align: left;
                            cursor: pointer;
                        }

                        .sidebar-autocomplete-item:hover,
                        .sidebar-autocomplete-item.is-selected {
                            background: var(--bg-secondary);
                        }

                        .sidebar-autocomplete-code {
                            color: var(--text-tertiary);
                            font-size: 11px;
                            font-weight: 700;
                            letter-spacing: 0.06em;
                        }

                        .sidebar-checkbox-item {
                            display: flex;
                            align-items: center;
                            gap: 8px;
                            min-height: 34px;
                            padding: 6px 8px;
                            border-radius: 7px;
                            color: var(--text-primary);
                            font-size: 13px;
                            cursor: pointer;
                        }

                        .sidebar-checkbox-item:hover {
                            background: #fff;
                        }

                        .sidebar-checkbox-item input {
                            width: 16px;
                            height: 16px;
                            margin: 0;
                            accent-color: var(--accent-primary);
                            flex: 0 0 auto;
                        }

                        .sidebar-checkbox-item span {
                            min-width: 0;
                            overflow: hidden;
                            text-overflow: ellipsis;
                            white-space: nowrap;
                        }

                        .sidebar-selected-summary {
                            margin-top: 10px;
                            padding: 9px 10px;
                            border-radius: var(--radius-sm);
                            background: #fff;
                            border: 1px solid var(--border-light);
                            color: var(--text-secondary);
                            font-size: 12px;
                            line-height: 1.5;
                        }

                        .sidebar-selected-summary strong {
                            color: var(--text-primary);
                            font-weight: 700;
                        }

                        .esim-content {
                            min-width: 0;
                        }

                        #mainGrid {
                            display: block;
                        }

                        .empty {
                            text-align: center;
                            padding: 4rem 2rem;
                            background: var(--bg-secondary);
                            border-radius: var(--radius);
                            border: 1px dashed var(--border-light);
                        }

                        .empty-icon {
                            font-size: 3rem;
                            margin-bottom: 1rem;
                        }

                        .empty h3 {
                            color: var(--text-primary);
                            font-size: 18px;
                            margin-bottom: 0.5rem;
                        }

                        .empty p {
                            color: var(--text-secondary);
                            font-size: 14px;
                        }

                        .country-grid {
                            display: grid;
                            grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
                            gap: 10px;
                        }

                        .country-grid.country-grid-filtered {
                            grid-template-columns: repeat(2, minmax(0, 1fr));
                        }

                        .country-card {
                            display: flex;
                            align-items: center;
                            height: 100%;
                            min-height: 86px;
                            gap: 10px;
                            padding: 20px 12px 16px;
                            background: var(--bg-primary);
                            border: 1px solid var(--border-light);
                            border-radius: var(--radius);
                            text-decoration: none;
                            color: inherit;
                            transition: border-color .18s, box-shadow .18s, transform .18s;
                            animation: slideUp 0.5s ease;
                            position: relative;
                            overflow: hidden;
                        }

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

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

                        .country-card::before {
                            content: '';
                            position: absolute;
                            inset: 0;
                            background: var(--accent-primary);
                            opacity: 0;
                            transition: opacity 0.18s ease;
                            pointer-events: none;
                        }

                        .country-card:hover {
                            border-color: var(--accent-primary);
                            box-shadow: 0 4px 20px rgba(227, 80, 0, .08);
                            transform: translateY(-2px);
                        }

                        .country-card:hover::before {
                            opacity: .04;
                        }

                        .country-card>* {
                            position: relative;
                            z-index: 1;
                        }

                        .card-flag {
                            width: 48px;
                            height: 48px;
                            border-radius: 50%;
                            overflow: hidden;
                            border: 1.5px solid var(--border-light);
                            background: var(--bg-secondary);
                            flex-shrink: 0;
                            display: flex;
                            align-items: center;
                            justify-content: center;
                            transition: border-color .18s;
                        }
                        .card-flag.is-multi{
                             width: 80px;
                            height: 80px;
                        }

                        .country-card:hover .card-flag {
                            border-color: var(--accent-primary);
                        }

                        .card-flag img {
                            width: 100%;
                            height: 100%;
                            object-fit: cover;
                        }

                        .card-multi-badge {
                            font-size: 11px;
                            font-weight: 600;
                            color: #6366f1;
                            margin-bottom: 4px;
                            margin-top: 2px;
                        }

                        .card-body {
                            min-width: 0;
                            flex: 1;
                            padding: 0 !important;
                        }

                        .card-name {
                            font-size: 16px;
                            font-weight: 700;
                            color: var(--text-primary);
                            line-height: 1.3;
                        }

                        .card-code {
                            font-size: 11px;
                            color: var(--text-tertiary);
                            text-transform: uppercase;
                            letter-spacing: 0.06em;
                            font-weight: 700;
                            margin-top: 2px;
                        }

                        .card-bottom {
                            display: flex;
                            flex-direction: column;
                            gap: 0.8rem;
                            padding-top: 1rem;
                            border-top: 1px solid var(--border-light);
                            margin-top: auto;
                        }

                        .card-footer {
                            display: flex;
                            align-items: center;
                            justify-content: space-between;
                            gap: 10px;
                            margin-top: 2px;
                            margin-left: 0;
                            padding-top: 0;
                            border-top: none;
                            flex-shrink: 0;
                        }

                        .card-price-wrap {
                            display: flex;
                            flex-direction: row;
                            gap: 4px;
                            align-items: baseline;
                        }

                        .card-price-wrap small {
                            font-size: 14px;
                            color: var(--text-tertiary);
                            text-transform: none;
                            line-height: 1.2;
                        }

                        .card-price {
                            font-size: 16px;
                            font-weight: 600;
                            color: var(--accent-primary);
                            line-height: 1.2;
                        }

                        .card-pkgs {
                            font-size: 12px;
                            color: var(--text-secondary);
                        }

                        .card-action {
                            display: none;
                        }

                        .country-card:hover .card-action {
                            transform: none;
                        }

                        .card-action:hover {
                            background: var(--accent-primary);
                            box-shadow: 0 4px 10px var(--accent-hover);
                        }

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

                            .esim-sidebar {
                                position: static;
                                padding: 14px;
                            }

                            .sidebar-title {
                                margin-bottom: 10px;
                            }

                            .sidebar-checkbox-list {
                                display: none;
                            }

                            .sidebar-country-search {
                                margin-bottom: 8px;
                            }

                            .sidebar-actions {
                                display: grid;
                                grid-template-columns: 1fr 1fr;
                                gap: 8px;
                                margin-top: 12px;
                            }

                            .sidebar-note {
                                display: none;
                            }

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

                        @media (max-width: 768px) {
                            .country-grid {
                                grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
                            }
                        }

                        @media (max-width: 480px) {
                            .country-grid {
                                grid-template-columns: repeat(2, 1fr);
                                gap: 8px;
                            }

                            .country-card {
                                min-height: 76px;
                                padding: 14px 10px;
                                gap: 8px;
                            }

                            .card-flag {
                                width: 32px;
                                height: 32px;
                            }

                            .card-name,
                            .card-price {
                                font-size: 14px;
                            }

                            .card-price-wrap small {
                                font-size: 12px;
                            }
                        }

                        .card-flag-stack {
                            display: flex;
                            align-items: center;
                        }

                        .card-flag-stack img {
                            width: 36px;
                            height: 36px;
                            border-radius: 50%;
                            border: 2px solid #fff;
                            object-fit: cover;
                            margin-left: -10px;
                            background: #f3f4f6;
                            box-shadow: 0 1px 3px rgba(0, 0, 0, .1);
                        }

                        .card-flag-stack img:first-child {
                            margin-left: 0;
                        }

                        .card-flag-stack .flag-code {
                            width: 36px;
                            height: 36px;
                            border-radius: 50%;
                            border: 2px solid #fff;
                            object-fit: cover;
                            margin-left: -10px;
                            background: #f3f4f6;
                            box-shadow: 0 1px 3px rgba(0, 0, 0, .1);
                        }

                        .flag-more {
                            width: 36px;
                            height: 36px;
                            border-radius: 50%;
                            background: var(--accent-light);
                            color: var(--accent-primary);
                            font-size: 10px;
                            font-weight: 700;
                            display: flex;
                            align-items: center;
                            justify-content: center;
                            margin-left: -10px;
                            border: 2px solid #fff;
                        }

                        .card-countries-preview {
                            display: flex;
                            flex-wrap: wrap;
                            gap: 4px;
                            margin: 5px 0 4px;
                        }

                        .ctry-chip {
                            display: inline-block;
                            padding: 2px 7px;
                            background: var(--bg-tertiary);
                            border: 1px solid var(--border-light);
                            border-radius: 100px;
                            font-size: 11px;
                            color: var(--text-secondary);
                            white-space: nowrap;
                        }

                        .ctry-chip-more {
                            background: var(--accent-light);
                            border-color: transparent;
                            color: var(--accent-primary);
                            font-weight: 600;
                        }
                    
