@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #3f2b03;
    --font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --cf-logo-bg-image: none;
    --red-color: #f00;
}

body {
    font-family: var(--font-family);
    background-color: #f8f9fa;
    color: #333;
}

h1 {
    color: var(--primary-color) !important;
}

body.cf-panel-bg {
    position: relative;
    z-index: 0;
}

body.cf-panel-bg::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;

    background-image:
        radial-gradient(circle at center, rgba(255, 255, 255, 0.08) 0%, rgba(0, 0, 0, 0) 62%),
        var(--cf-logo-bg-image);
    background-size: cover, contain;
    background-position: center;
    background-repeat: no-repeat;

    opacity: 0.08;
    filter: brightness(1.35) contrast(1.1);
}

.bg-primary-custom {
    background-color: var(--primary-color) !important;
}

.text-primary-custom {
    color: var(--primary-color) !important;
    font-size: 2rem;
}

.text-primary-panel {
    color: var(--primary-color) !important;
    font-size: 9rem;
}

.text-primary-panel-small {
    color: var(--primary-color) !important;
    font-size: clamp(4rem, 1vw, 9.5rem);
}

.fs-0 {
    font-size: 9rem;
}

.btn-primary-custom {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.btn-primary-custom:hover {
    filter: brightness(70%);
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Estilo para o Painel/Monitor */
.display-large {
    font-size: clamp(31rem, 11vw, 9.5rem);
    font-weight: 900;
}

.cf-number-highlight {
    letter-spacing: 2px;
    line-height: 0.95;
    text-shadow:
        0 14px 34px rgba(0, 0, 0, 0.22),
        0 0 2px rgba(255, 255, 255, 0.55);
    -webkit-text-stroke: 2px rgba(0, 0, 0, 0.25);
}

.display-medium {
    font-size: 4rem;
}

.card-shadow {
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border: none;
    border-radius: 15px;
}

/* Animação para nova chamada */
@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

.new-call {
    animation: blink 1s infinite;
}

.semFila {
    font-size: 2rem !important;
    text-transform: uppercase;
}

/* Responsividade Mobile-First */
@media (max-width: 720px) {
    .display-large {
        font-size: clamp(4.5rem, 7vw, 9rem);
    }
    .display-medium {
        font-size: 2.5rem;
    }
}

.font-white {
    color: white;
}

.font-primary {
    color: var(--primary-color);
}

.font-uppercase {
    text-transform: uppercase;
}

.font-small-caps {
    font-variant: small-caps;
}

.cf-notification-overlay {
    position: fixed;
    inset: 0;
    background: rgba(128, 128, 128, 0.70);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 1990;
}

body.cf-notification-active {
    overflow: hidden;
}

.cf-notification-modal {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 2000;

    width: min(520px, calc(100vw - 24px));
    padding: 18px 18px;

    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.45);
}

.cf-notification-modal--call {
    background: var(--red-color);
    color: #fff;
    animation: cf-alert-blink 2.5s steps(1, end) infinite;
}

.cf-notification-modal--error {
    background: #fff3cd;
    color: #664d03;
}

.cf-notification-modal--called {
    background: var(--primary-color);
    color: #fff;
}

.cf-notification-modal--unavailable {
    background: #fff3cd;
    color: var(--red-color);
}

.cf-fade {
    transition: opacity 240ms ease;
}

.cf-notification-title {
    font-weight: 800;
    letter-spacing: 0.2px;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.cf-notification-text {
    margin: 0;
    font-size: 1.05rem;
}

.cf-ticket-number {
    color: var(--primary-color) !important;
    font-size: clamp(4.75rem, 18vw, 7.5rem) !important;
    font-weight: 900;
    letter-spacing: 2px;
    line-height: 0.95;
}

@keyframes cf-alert-blink {
    0%, 79.999% {
        opacity: 1;
    }
    80%, 100% {
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cf-notification-modal--call {
        animation: none;
    }
}

.cf-panel-center {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}

.cf-panel-side {
    height: 100%;
}

@media (max-width: 991.98px) {
    .cf-panel-side {
        border-left: 0 !important;
        border-inline-start: 0 !important;
        border-top: 1px solid var(--bs-secondary) !important;
        padding-top: 1.5rem;
    }
}

.cf-logo-card {
    max-width: 250px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    min-height: 180px;
}

.cf-company-logo {
    width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.35));
}

.cf-ws-fallback {
    z-index: 2100;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

@media (max-width: 576px) {
    .cf-logo-card {
        max-width: 200px;
        min-height: 140px;
    }
    .cf-company-logo {
        max-height: 180px;
    }
}

.cf-qr-screen {
    height: 100vh;
    width: 100vw;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0;
}

#cf-active-qr {
    width: min(92vw, 92vh);
    height: min(92vw, 92vh);
    object-fit: contain;
    image-rendering: auto;
    user-select: none;
    -webkit-user-drag: none;
    cursor: pointer;
}

body.cf-qrcode-fullscreen {
    overflow: hidden;
    background: #f8f9fa;
}

body.cf-qrcode-fullscreen .cf-qr-screen {
    position: relative;
    box-sizing: border-box;
}

body.cf-qrcode-fullscreen .cf-qr-status-toast {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

@media (max-width: 576px) {
    body.cf-qrcode-fullscreen .cf-qr-screen {
        padding-top: 64px;
    }
}
