/* PB Stripe Routing — Region Gate Styles */

/* ─── Overlay ─────────────────────────────────────────────── */
#pb-region-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(10, 8, 6, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.4s ease;
}

#pb-region-overlay.pb-hidden {
    display: none;
}

#pb-region-overlay.pb-fade-out {
    opacity: 0;
    pointer-events: none;
}

/* ─── Modal card ──────────────────────────────────────────── */
#pb-region-modal {
    background: #faf8f4;
    border-radius: 4px;
    padding: 48px 40px 44px;
    max-width: 480px;
    width: calc(100% - 40px);
    text-align: center;
    box-shadow: 0 32px 80px rgba(0,0,0,0.4);
    animation: pb-modal-rise 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes pb-modal-rise {
    from { transform: translateY(24px); opacity: 0; }
    to   { transform: translateY(0);   opacity: 1; }
}

/* ─── Logo / site name ────────────────────────────────────── */
.pb-modal-logo {
    margin-bottom: 28px;
}

.pb-modal-logo img {
    max-height: 60px;
    width: auto;
}

.pb-modal-logo h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
    letter-spacing: 0.02em;
    color: #1a1410;
}

/* ─── Headline ────────────────────────────────────────────── */
.pb-modal-headline {
    font-size: 1.35rem;
    font-weight: 600;
    color: #1a1410;
    margin: 0 0 8px;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.pb-modal-sub {
    font-size: 0.9rem;
    color: #7a6f65;
    margin: 0 0 32px;
}

/* ─── Region choice buttons ───────────────────────────────── */
.pb-region-choices {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.pb-choice-btn {
    background: #fff;
    border: 1.5px solid #e4ddd5;
    border-radius: 4px;
    padding: 20px 16px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
    text-align: center;
}

.pb-choice-btn:hover {
    border-color: #c4a882;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

.pb-choice-btn:active {
    transform: translateY(0);
}

.pb-choice-flag {
    font-size: 2rem;
    line-height: 1;
    display: block;
}

.pb-choice-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1410;
    display: block;
}

.pb-choice-currency {
    font-size: 0.78rem;
    color: #9a8f85;
    display: block;
}

/* ─── Persistent region switcher ─────────────────────────── */
#pb-region-switcher {
    position: fixed;
    top: 12px;
    right: 16px;
    z-index: 9999;
    display: flex;
    gap: 4px;
    background: rgba(255,255,255,0.95);
    border: 1px solid #e4ddd5;
    border-radius: 20px;
    padding: 3px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    backdrop-filter: blur(4px);
}

.pb-region-btn {
    background: transparent;
    border: none;
    border-radius: 16px;
    padding: 4px 10px;
    font-size: 0.75rem;
    font-weight: 500;
    color: #7a6f65;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}

.pb-region-btn:hover {
    background: #f0ebe4;
    color: #1a1410;
}

.pb-region-btn.active {
    background: #1a1410;
    color: #faf8f4;
}

/* ─── Cart cleared notice ─────────────────────────────────── */
.pb-cart-cleared-notice {
    background: #fff8ed;
    border-left: 3px solid #c4a882;
    padding: 10px 14px;
    margin-bottom: 16px;
    font-size: 0.85rem;
    color: #5a4f45;
    border-radius: 0 4px 4px 0;
}

/* ─── Mobile ──────────────────────────────────────────────── */
@media ( max-width: 480px ) {
    #pb-region-modal {
        padding: 36px 24px 32px;
    }

    .pb-region-choices {
        grid-template-columns: 1fr;
    }

    #pb-region-switcher {
        top: auto;
        bottom: 16px;
        right: 50%;
        transform: translateX(50%);
    }
}
