/* ============================================
   COUNTRY PAGE OVERLAY — Full Screen, Apple Style
   Nav: position fixed, top:20px, width:calc(100%-80px), border-radius:var(--radius-xl)=24px
   ============================================ */

.country-modal {
    position: fixed;
    inset: 0;
    z-index: 15; /* Below nav z-index:20 so header stays on top */
    background: var(--color-bg-secondary);
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(28px);
    transition:
        opacity 0.42s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.42s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.country-modal.active {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.country-modal-backdrop { display: none; }

/* ---- Hide back button — user navigates via header ---- */
.country-modal-close { display: none !important; }

/* ---- Scrollable body ---- */
.country-modal-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

.country-modal-body::-webkit-scrollbar { width: 5px; }
.country-modal-body::-webkit-scrollbar-track { background: transparent; }
.country-modal-body::-webkit-scrollbar-thumb {
    background: rgba(104, 110, 238, 0.25);
    border-radius: 10px;
}
.country-modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(104, 110, 238, 0.45);
}
[data-theme="dark"] .country-modal-body::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.15);
}

/* ---- Hero — same width as nav pill ---- */
.country-modal-hero {
    position: relative;
    /* Match nav: top:20px + nav height ~72px + 12px gap = 104px total */
    margin: 104px auto 0;
    width: calc(100% - 80px);
    max-width: 1440px;
    /* Height: viewport minus top offset minus some bottom breathing room */
    height: calc(100vh - 130px);
    min-height: 440px;
    border-radius: var(--radius-xl); /* 24px — same as nav */
    overflow: hidden;
    box-shadow:
        0 24px 56px rgba(0, 0, 0, 0.18),
        0 6px 18px rgba(0, 0, 0, 0.1);
}

.country-modal-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.country-modal-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.82) 0%,
        rgba(0, 0, 0, 0.26) 50%,
        rgba(0, 0, 0, 0.04) 100%
    );
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 52px 60px;
}

.country-modal-hero-overlay h1 {
    font-size: clamp(36px, 5vw, 72px);
    font-weight: 900;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    line-height: 1.05;
    margin-bottom: 14px;
    text-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.country-modal-hero-overlay p {
    font-size: clamp(14px, 1.3vw, 17px);
    color: rgba(255, 255, 255, 0.9);
    max-width: 560px;
    line-height: 1.65;
    text-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

/* Scroll chevron */
.country-modal-hero::after {
    content: '';
    position: absolute;
    bottom: 28px;
    left: 50%;
    width: 20px;
    height: 20px;
    border-right: 2px solid rgba(255,255,255,0.6);
    border-bottom: 2px solid rgba(255,255,255,0.6);
    transform: translateX(-50%) rotate(45deg);
    animation: heroChevron 1.8s ease-in-out infinite;
}

@keyframes heroChevron {
    0%, 100% { opacity: 0.4; transform: translateX(-50%) rotate(45deg) translateY(0); }
    50% { opacity: 0.85; transform: translateX(-50%) rotate(45deg) translateY(6px); }
}

/* ---- Main content ---- */
.country-modal-page-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 64px 40px 0;
}

/* ---- Section headers ---- */
.country-modal-header {
    text-align: center;
    margin-bottom: 36px;
}

.country-modal-header h2 {
    font-size: clamp(22px, 2.6vw, 32px);
    font-weight: 800;
    color: var(--color-text-primary);
    margin-bottom: 10px;
    line-height: 1.2;
}

.country-modal-header p {
    font-size: 15px;
    color: var(--color-text-secondary);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ---- Two-column grid ---- */
.country-modal-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 24px;
    align-items: start;
    margin-bottom: 64px;
}

/* ---- Service cards ---- */
.country-services-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.country-service-card {
    background: var(--color-bg-primary);
    border: 1px solid rgba(104, 110, 238, 0.1);
    border-radius: 18px;
    padding: 24px 28px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
}

.country-service-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 36px rgba(104, 110, 238, 0.13);
    border-color: rgba(104, 110, 238, 0.22);
}

[data-theme="dark"] .country-service-card {
    background: var(--color-bg-secondary);
    border-color: rgba(255,255,255,0.07);
}

[data-theme="dark"] .country-service-card:hover {
    background: var(--color-bg-tertiary);
    border-color: rgba(255,255,255,0.12);
    box-shadow: 0 10px 36px rgba(0,0,0,0.3);
}

.service-number { display: none; }
.service-card-header { margin-bottom: 8px; }

.service-card-header h3 {
    font-size: 15px;
    font-weight: 700;
    color: var(--color-text-primary);
    line-height: 1.35;
    margin: 0;
}

.service-description {
    font-size: 14px;
    line-height: 1.65;
    color: var(--color-text-secondary);
    margin: 0 0 14px;
}

.service-price-row {
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-price {
    font-size: 21px;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.service-order-btn { display: none; }

/* ---- Info sidebar — NO emoji icons ---- */
.country-info-sidebar {
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: sticky;
    top: 24px;
}

.country-info-card {
    background: var(--color-bg-primary);
    border: 1px solid rgba(104, 110, 238, 0.1);
    border-radius: 18px;
    padding: 20px 22px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.country-info-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(104, 110, 238, 0.12);
    border-color: rgba(104, 110, 238, 0.18);
}

[data-theme="dark"] .country-info-card {
    background: var(--color-bg-secondary);
    border-color: rgba(255,255,255,0.07);
}

/* Hide emoji icon, replace with accent bar */
.country-info-icon {
    display: none;
}

/* Accent left border instead of emoji */
.country-info-card {
    border-left: 3px solid var(--color-primary);
}

.country-info-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: var(--color-text-muted);
    margin-bottom: 4px;
}

.country-info-value {
    font-size: 22px;
    font-weight: 800;
    color: var(--color-text-primary);
    margin-bottom: 3px;
    line-height: 1.15;
}

.country-info-description {
    font-size: 12px;
    color: var(--color-text-muted);
    line-height: 1.4;
}

/* ---- FAQ ---- */
.country-modal-faq-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px 64px;
}

.modal-faq-list { display: flex; flex-direction: column; }

.modal-faq-category {
    background: var(--color-bg-primary);
    border: 1px solid rgba(104, 110, 238, 0.09);
    border-radius: 22px;
    padding: 6px 28px;
    box-shadow: var(--shadow-sm);
    margin-top: 20px;
}

[data-theme="dark"] .modal-faq-category {
    background: var(--color-bg-secondary);
    border-color: rgba(255,255,255,0.07);
}

.modal-faq-item { border-bottom: 1px solid rgba(104, 110, 238, 0.07); }
[data-theme="dark"] .modal-faq-item { border-bottom-color: rgba(255,255,255,0.05); }
.modal-faq-item:last-child { border-bottom: none; }

.modal-faq-question {
    width: 100%;
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 0;
    background: transparent; border: none; cursor: pointer;
    text-align: left; font-size: 15px; font-weight: 600;
    color: var(--color-text-primary);
    transition: color 0.2s ease, padding-left 0.2s ease;
    gap: 14px; line-height: 1.4; font-family: inherit;
}

.modal-faq-question:hover { color: var(--color-primary); padding-left: 4px; }
.modal-faq-question span { flex: 1; }

.modal-faq-icon {
    width: 18px; height: 18px; flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--color-primary);
}

.modal-faq-item.active .modal-faq-icon { transform: rotate(180deg); }

.modal-faq-answer {
    height: 0; overflow: hidden;
    transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-faq-answer p {
    color: var(--color-text-secondary);
    line-height: 1.7; font-size: 14px;
    margin: 0 0 16px !important;
}

/* ---- Footer CTA — WA + TG buttons + email ---- */
.country-modal-footer {
    max-width: 1200px;
    margin: 0 auto;
    padding: 44px 40px 56px;
    text-align: center;
    border-top: 1px solid rgba(104, 110, 238, 0.09);
}

[data-theme="dark"] .country-modal-footer { border-top-color: rgba(255,255,255,0.06); }

.country-modal-footer p {
    font-size: 15px;
    color: var(--color-text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.country-modal-cta {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

/* Override: replace single btn with two contact buttons */
.modal-cta-btn { display: none; }

/* WA & TG buttons injected via JS */
.country-modal-footer .modal-contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 600;
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s ease;
    font-family: inherit;
}

.country-modal-footer .modal-contact-btn svg {
    width: 20px; height: 20px; flex-shrink: 0;
}

.country-modal-footer .modal-wa-btn {
    background: #25D366;
    color: white;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.35);
}

.country-modal-footer .modal-wa-btn:hover {
    background: #20bb5a;
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(37, 211, 102, 0.45);
}

.country-modal-footer .modal-tg-btn {
    background: #2AABEE;
    color: white;
    box-shadow: 0 6px 20px rgba(42, 171, 238, 0.35);
}

.country-modal-footer .modal-tg-btn:hover {
    background: #1a9bd8;
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(42, 171, 238, 0.45);
}

.country-modal-footer .modal-email-link {
    display: block;
    margin-top: 16px;
    font-size: 14px;
    color: var(--color-text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

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

/* ---- Other countries — Apple framed carousel ---- */
.other-countries-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px 72px;
}

.other-countries-header { text-align: center; margin-bottom: 22px; }

.other-countries-header h3 {
    font-size: clamp(18px, 2vw, 26px);
    font-weight: 800;
    color: var(--color-text-primary);
    margin-bottom: 6px;
}

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

/* Apple-style frame */
.other-countries-scroll-wrapper {
    background: var(--color-bg-primary);
    border: 1px solid rgba(104, 110, 238, 0.1);
    border-radius: 24px;
    box-shadow: var(--shadow-md);
    overflow: hidden; /* clips cards at edges */
    padding: 20px 0 20px 24px; /* left padding only, right clips */
    cursor: grab;
    position: relative;
}

[data-theme="dark"] .other-countries-scroll-wrapper {
    background: var(--color-bg-secondary);
    border-color: rgba(255,255,255,0.07);
    box-shadow: 0 8px 32px rgba(0,0,0,0.28);
}

.other-countries-scroll-wrapper:active { cursor: grabbing; }

/* Fade-out gradient on right edge */
.other-countries-scroll-wrapper::after {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0;
    width: 80px;
    background: linear-gradient(to right, transparent, var(--color-bg-primary));
    pointer-events: none;
    z-index: 1;
    border-radius: 0 24px 24px 0;
}

[data-theme="dark"] .other-countries-scroll-wrapper::after {
    background: linear-gradient(to right, transparent, var(--color-bg-secondary));
}

.other-countries-grid {
    display: flex;
    gap: 14px;
    width: fit-content;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    padding-right: 80px; /* space before fade */
    scroll-behavior: smooth;
}

.other-countries-grid::-webkit-scrollbar { display: none; }

.other-country-card {
    position: relative;
    width: 190px;
    height: 260px;
    border-radius: 18px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    isolation: isolate;
}

.other-country-card:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 16px 36px rgba(104, 110, 238, 0.18);
    z-index: 2;
}

.other-country-card img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
    position: relative; z-index: 0;
}

.other-country-card:hover img { transform: scale(1.04); }

.other-country-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.88) 0%, rgba(0,0,0,0.42) 40%, rgba(0,0,0,0.08) 70%, rgba(0,0,0,0) 100%);
    display: flex; align-items: flex-end;
    padding: 16px; z-index: 1;
}

.other-country-name {
    font-size: 13px; font-weight: 800; color: white;
    text-transform: uppercase; letter-spacing: 0.06em;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    position: relative; z-index: 2; line-height: 1.2;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1100px) {
    .country-modal-hero { width: calc(100% - 60px); }
    .country-modal-hero-overlay { padding: 40px 44px; }
    .country-modal-page-content { padding: 52px 28px 0; }
    .country-modal-faq-section { padding-left: 28px; padding-right: 28px; }
    .country-modal-footer { padding-left: 28px; padding-right: 28px; }
    .other-countries-section { padding-left: 28px; padding-right: 28px; }
    .country-modal-content-wrapper { grid-template-columns: 1fr 240px; }
}

@media (max-width: 900px) {
    .country-modal-content-wrapper { grid-template-columns: 1fr; }
    .country-info-sidebar {
        order: -1; position: static;
        display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
    }
    .country-info-card { border-left: none; border-top: 3px solid var(--color-primary); }
    .country-modal-hero { height: calc(65vh - 90px); margin-top: 96px; }
}

@media (max-width: 768px) {
    .country-modal-hero {
        width: calc(100% - 32px);
        margin-top: 92px;
        height: calc(58vh - 80px);
        min-height: 300px;
        border-radius: 18px;
    }
    .country-modal-hero-overlay { padding: 28px 24px; }
    .country-modal-page-content { padding: 40px 20px 0; }
    .country-modal-faq-section { padding-left: 20px; padding-right: 20px; }
    .country-modal-footer { padding-left: 20px; padding-right: 20px; }
    .other-countries-section { padding-left: 20px; padding-right: 20px; }
    .country-info-sidebar { display: none !important; }
    .other-countries-scroll-wrapper { border-radius: 18px; padding: 16px 0 16px 16px; }
    .other-country-card { width: 150px; height: 210px; border-radius: 14px; }
}

@media (max-width: 480px) {
    .country-modal-hero {
        width: calc(100% - 24px);
        margin-top: 88px;
        height: calc(52vh - 70px);
        min-height: 260px;
        border-radius: 14px;
    }
    .country-modal-hero-overlay { padding: 20px 20px; }
    .country-modal-page-content { padding: 32px 16px 0; }
    .country-modal-faq-section { padding-left: 16px; padding-right: 16px; }
    .country-modal-footer { padding-left: 16px; padding-right: 16px; }
    .other-countries-section { padding-left: 16px; padding-right: 16px; }
    .other-countries-scroll-wrapper { border-radius: 14px; padding: 14px 0 14px 14px; }
    .other-country-card { width: 130px; height: 180px; border-radius: 12px; }
    .country-modal-footer .modal-contact-btn { padding: 12px 22px; font-size: 14px; }
}
