/* ============================================
   VISA CHECKER – Complete Styles
   ============================================ */

/* Box-sizing reset */
*, *::before, *::after { box-sizing: border-box; }

/* Prevent horizontal scroll */
body { overflow-x: hidden; }

/* Dropdown */
.vc-dropdown { position: relative; width: 100%; }

.vc-dropdown-display {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.vc-dropdown-display:hover {
    border-color: #7c3aed;
}

.vc-dropdown-display.has-value {
    border-color: #7c3aed;
    background: #faf5ff;
}

.vc-dropdown-flag { font-size: 24px; min-width: 24px; display: flex; align-items: center; }
.vc-dropdown-text { flex: 1; color: #6b7280; }
.vc-dropdown-display.has-value .vc-dropdown-text { color: #111827; font-weight: 600; }
.vc-dropdown-arrow { transition: transform 0.2s; color: #9ca3af; }

.vc-dropdown-panel {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    z-index: 1000;
    max-height: 360px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.vc-dropdown-search-wrap { padding: 12px; border-bottom: 1px solid #f3f4f6; }

.vc-dropdown-search {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 16px;
    outline: none;
    box-sizing: border-box;
}

.vc-dropdown-search:focus { border-color: #7c3aed; box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1); }

.vc-dropdown-options {
    overflow-y: auto;
    max-height: 280px;
    overscroll-behavior: contain;
}

.vc-dropdown-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    cursor: pointer;
    font-size: 15px;
    transition: background 0.1s;
}

.vc-dropdown-option:hover,
.vc-dropdown-option.highlighted { background: #f5f3ff; }
.vc-dropdown-option.selected { background: #ede9fe; font-weight: 600; }
.vc-dropdown-empty { padding: 20px; text-align: center; color: #9ca3af; }

/* Stats */
.vc-power-card {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    margin-bottom: 24px;
}

.vc-power-header { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.vc-power-flag { font-size: 48px; }
.vc-power-title { font-size: 28px; font-weight: 700; color: #111827; margin: 0; }

.vc-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.vc-stat-box {
    text-align: center;
    padding: 20px 12px;
    border-radius: 12px;
    background: #f9fafb;
}

.vc-stat-icon { margin-bottom: 8px; display: flex; justify-content: center; }
.vc-stat-number { display: block; font-size: 36px; font-weight: 800; margin-bottom: 4px; }
.vc-stat-label { font-size: 13px; color: #6b7280; text-transform: uppercase; letter-spacing: 0.5px; }

.vc-stat-free .vc-stat-number { color: #16a34a; }
.vc-stat-required .vc-stat-number { color: #dc2626; }
.vc-stat-evisa .vc-stat-number { color: #2563eb; }
.vc-stat-voa .vc-stat-number { color: #ea580c; }

/* Progress Bar */
.vc-power-rank { margin-top: 16px; }
.vc-progress-bar { width: 100%; height: 8px; background: #e5e7eb; border-radius: 4px; margin: 8px 0; overflow: hidden; }
.vc-progress-fill { height: 100%; background: linear-gradient(90deg, #7c3aed, #a78bfa); border-radius: 4px; transition: width 1.5s ease-out; }
.vc-access-text { font-size: 14px; color: #7c3aed; font-weight: 600; }

/* Dummy Ticket CTA */
.vc-dummy-cta {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #faf5ff, #ede9fe);
    border: 1px solid #c4b5fd;
    border-radius: 12px;
    margin-top: 20px;
    color: #5b21b6;
    text-decoration: none;
    font-size: 15px;
    transition: background 0.2s;
}
.vc-dummy-cta:hover { background: linear-gradient(135deg, #ede9fe, #ddd6fe); }

/* Filter Tabs */
.vc-filter-section { margin-bottom: 24px; }

.vc-filter-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.vc-tab {
    padding: 8px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    transition: all 0.2s;
    font-family: inherit;
}

.vc-tab:hover { border-color: #7c3aed; color: #7c3aed; }
.vc-tab.active { background: #7c3aed; color: white; border-color: #7c3aed; }

/* Search Input with Icon */
.vc-search-wrap {
    position: relative;
}

.vc-search-wrap .vc-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #9ca3af;
    pointer-events: none;
}

.vc-search-wrap .vc-search-input {
    padding-left: 42px;
}

.vc-search-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    font-size: 16px;
    outline: none;
    box-sizing: border-box;
}
.vc-search-input:focus { border-color: #7c3aed; box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1); }

/* Cards Grid */
.vc-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    width: 100%;
    overflow: hidden;
}

.vc-card {
    display: block;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px;
    text-decoration: none;
    color: #111827;
    transition: all 0.2s;
    min-width: 0;
}

.vc-card:hover { border-color: #7c3aed; box-shadow: 0 4px 12px rgba(124, 58, 237, 0.1); transform: translateY(-2px); }

.vc-card-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.vc-card-flag { font-size: 28px; }

.vc-card-badge {
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: white;
    white-space: nowrap;
}

.vc-card-name { font-weight: 600; font-size: 15px; margin-bottom: 4px; }
.vc-card-days { font-size: 13px; color: #16a34a; font-weight: 500; }
.vc-card-dummy { font-size: 12px; color: #7c3aed; margin-top: 4px; }

/* Explore Top Passports */
.vc-explore-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    text-decoration: none;
    color: #111827;
    transition: all 0.2s;
}
.vc-explore-card:hover { border-color: #7c3aed; box-shadow: 0 4px 12px rgba(124, 58, 237, 0.1); }
.vc-explore-rank { font-weight: 800; color: #7c3aed; font-size: 14px; min-width: 28px; }
.vc-explore-flag { font-size: 24px; }
.vc-explore-name { flex: 1; font-weight: 600; font-size: 15px; }
.vc-explore-count { font-size: 13px; color: #16a34a; font-weight: 500; }

/* Spinner */
.vc-spinner {
    width: 24px; height: 24px;
    border: 3px solid #e5e7eb;
    border-top-color: #7c3aed;
    border-radius: 50%;
    animation: vc-spin 0.7s linear infinite;
}
@keyframes vc-spin { to { transform: rotate(360deg); } }

/* SEO Text */
.vc-seo-text { margin-top: 40px; padding: 24px; background: #f9fafb; border-radius: 12px; }
.vc-seo-text h2 { font-size: 20px; margin: 0 0 12px; }
.vc-seo-text p { font-size: 15px; line-height: 1.6; color: #4b5563; margin: 0 0 12px; }
.vc-seo-text a { color: #7c3aed; }

/* Destination cards on country page */
.vc-dest-card {
    display: block;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px;
    text-decoration: none;
    color: #111827;
    transition: all 0.2s;
    min-width: 0;
}
.vc-dest-card:hover { border-color: #7c3aed; box-shadow: 0 4px 12px rgba(124, 58, 237, 0.1); transform: translateY(-2px); }

/* Flag Icon Sizes */
.vc-opt-flag-icon { font-size: 20px; border-radius: 2px; line-height: 1; }
.vc-card-flag-icon { font-size: 28px; border-radius: 4px; line-height: 1; }
.vc-explore-flag-icon { font-size: 24px; border-radius: 3px; line-height: 1; }

/* Flag-icons Library Overrides */
.fi { display: inline-block; vertical-align: middle; }
.fi.fis { border-radius: 3px; }

/* Dark Mode */
[data-theme="dark"] .vc-dropdown-display { background: #130f24; border-color: #2a2040; }
[data-theme="dark"] .vc-dropdown-display.has-value { background: #2d1b69; border-color: #7c3aed; }
[data-theme="dark"] .vc-dropdown-display.has-value .vc-dropdown-text { color: #e5e7eb; }
[data-theme="dark"] .vc-dropdown-text { color: #9ca3af; }
[data-theme="dark"] .vc-dropdown-panel { background: #130f24; border-color: #2a2040; }
[data-theme="dark"] .vc-dropdown-search { background: #0c0818; border-color: #2a2040; color: #e5e7eb; }
[data-theme="dark"] .vc-dropdown-option:hover,
[data-theme="dark"] .vc-dropdown-option.highlighted { background: #2a2040; }
[data-theme="dark"] .vc-dropdown-option.selected { background: #2d1b69; }

[data-theme="dark"] .vc-power-card { background: #130f24; box-shadow: 0 4px 24px rgba(0,0,0,0.3); }
[data-theme="dark"] .vc-power-title { color: #f3f4f6; }
[data-theme="dark"] .vc-stat-box { background: #0c0818; }
[data-theme="dark"] .vc-stat-label { color: #9ca3af; }

[data-theme="dark"] .vc-tab { background: #130f24; border-color: #2a2040; color: #d1d5db; }
[data-theme="dark"] .vc-tab:hover { border-color: #7c3aed; color: #a78bfa; }
[data-theme="dark"] .vc-tab.active { background: #7c3aed; color: white; }

[data-theme="dark"] .vc-search-input { background: #130f24; border-color: #2a2040; color: #e5e7eb; }
[data-theme="dark"] .vc-search-wrap .vc-search-icon { color: #6b7280; }

[data-theme="dark"] .vc-card,
[data-theme="dark"] .vc-dest-card { background: #130f24; border-color: #2a2040; color: #e5e7eb; }
[data-theme="dark"] .vc-card:hover,
[data-theme="dark"] .vc-dest-card:hover { border-color: #7c3aed; }
[data-theme="dark"] .vc-card-name { color: #f3f4f6; }

[data-theme="dark"] .vc-explore-card { background: #130f24; border-color: #2a2040; color: #e5e7eb; }
[data-theme="dark"] .vc-explore-card:hover { border-color: #7c3aed; }

[data-theme="dark"] .vc-dummy-cta { background: linear-gradient(135deg, #2d1b69, #1e1b4b); border-color: #5b21b6; color: #c4b5fd; }
[data-theme="dark"] .vc-seo-text { background: #0c0818; }
[data-theme="dark"] .vc-seo-text h2 { color: #f3f4f6; }
[data-theme="dark"] .vc-seo-text p { color: #9ca3af; }

[data-theme="dark"] .vc-progress-bar { background: #2a2040; }

/* RESPONSIVE */
@media (max-width: 1024px) {
    .vc-cards-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .vc-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .vc-cards-grid { grid-template-columns: repeat(2, 1fr); }
    .vc-stat-number { font-size: 28px; }
    .vc-power-title { font-size: 22px; }
    .vc-power-card { padding: 20px; }

    /* Filter tabs: horizontal scroll */
    .vc-filter-tabs {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 6px;
        padding-bottom: 4px;
    }
    .vc-filter-tabs::-webkit-scrollbar { display: none; }
    .vc-tab { flex-shrink: 0; white-space: nowrap; font-size: 13px; padding: 6px 12px; }

    /* Dropdown – mobile full-width bottom sheet */
    .vc-dropdown-panel {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        max-height: 70vh;
        border-radius: 16px 16px 0 0;
        z-index: 9999;
    }
}

@media (max-width: 640px) {
    /* Route Header (Passport → Destination) */
    .vc-route-header {
        flex-direction: column;
        gap: 12px;
    }
    .vc-route-header .vc-route-arrow {
        transform: rotate(90deg);
    }
}

@media (max-width: 480px) {
    .vc-cards-grid { grid-template-columns: 1fr; }
    .vc-stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .vc-dropdown-display { padding: 12px 14px; font-size: 15px; }
    .vc-dropdown-panel { max-height: 300px; }

    .vc-stat-box { padding: 14px 8px; }
    .vc-stat-number { font-size: 24px; }
    .vc-stat-label { font-size: 11px; }

    .vc-power-card { padding: 16px; border-radius: 12px; }
    .vc-power-header { flex-direction: column; text-align: center; gap: 8px; }
    .vc-power-title { font-size: 20px; }

    .vc-dummy-cta { flex-direction: column; text-align: center; gap: 8px; padding: 14px 16px; }

    .vc-card { width: 100%; min-width: 0; }
}

/* iOS zoom prevention: inputs must be 16px+ */
.vc-search-input,
.vc-dropdown-search {
    font-size: 16px !important;
}

/* Dropdowns: Equal height */
.vc-dropdown-display {
    min-height: 52px;
}

@media (max-width: 767px) {
    #passport-dropdown,
    #destination-dropdown {
        width: 100%;
    }
    .vc-dropdown-display {
        min-height: 48px;
        font-size: 15px;
    }
}

/* Detail Page: Share buttons wrap on very small screens */
@media (max-width: 380px) {
    .share-bar-wrap {
        flex-wrap: wrap;
        gap: 6px;
    }
}
