/* ============================================================================
   GOOGLE PREFERRED SOURCES — popup + botão do rodapé
   Markup: includes/preferred-source.php e includes/_footer.php
   Mesmo visual do aviso de cookies; popup no canto direito, acima do WhatsApp.
   ============================================================================ */
.box-preferred-source.hide {
    display: none;
}

.box-preferred-source {
    position: fixed;
    text-align: left;
    right: 24px;
    bottom: 104px;
    z-index: 9998;
    width: 340px;
    max-width: calc(100% - 48px);
    padding: 22px 22px 18px;
    background: #fff;
    color: #333;
    border: 1px solid #e6e6ee;
    border-radius: 14px;
    box-shadow: 0 18px 50px rgba(8, 0, 58, .18);
    animation: preferred-source-in .35s ease-out;
}

.btn-close-preferred-source {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    background: #f4f5fb;
    border: 0;
    border-radius: 50%;
    color: #333;
    cursor: pointer;
}

.btn-close-preferred-source:hover {
    background: #e6e6ee;
}

.preferred-source-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-bottom: 12px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}

.title-preferred-source {
    margin: 0 0 6px;
    padding-right: 28px;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--main);
}

.msg-preferred-source {
    margin: 0 0 16px;
    font-size: 14px;
    line-height: 1.6;
    color: #555;
}

.preferred-source-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
}

.btn-add-preferred-source {
    display: block;
    padding: 11px 16px;
    background: var(--main);
    border: 2px solid var(--main);
    border-radius: 30px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: background .2s;
}

.btn-add-preferred-source:hover {
    background: var(--main-strong);
    border-color: var(--main-strong);
    color: #fff;
}

.btn-dismiss-preferred-source {
    padding: 6px;
    background: none;
    border: 0;
    font: inherit;
    font-size: 13px;
    color: #666;
    text-decoration: underline;
    cursor: pointer;
}

.btn-dismiss-preferred-source:hover {
    color: var(--main);
}

.btn-close-preferred-source:focus-visible,
.btn-add-preferred-source:focus-visible,
.btn-dismiss-preferred-source:focus-visible,
.btn-preferred-source:focus-visible {
    outline: 3px solid var(--secondary);
    outline-offset: 2px;
}

/* Botão do rodapé: pill branco com o "G" colorido */
.btn-preferred-source {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    padding: 9px 16px;
    background: #fff;
    border: 1px solid #dadce0;
    border-radius: 30px;
    color: #3c4043;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
    transition: box-shadow .2s, border-color .2s;
}

.btn-preferred-source:hover {
    border-color: #c6c9ce;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
    color: #3c4043;
}

.google-g-icon {
    flex-shrink: 0;
}

@keyframes preferred-source-in {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .box-preferred-source {
        animation: none;
    }
}

@media (max-width: 640px) {
    .box-preferred-source {
        left: 12px;
        right: 12px;
        bottom: 118px;
        width: auto;
        max-width: none;
    }
}
