/* ============================================
   HERO ANIMAÇÃO - VÍDEO VOLVO FH 540 + FREADA
   ============================================ */
.rua-hero-animacao {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99999;
    background: #000;
    overflow: hidden;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.rua-hero-animacao.rua-hero--saindo {
    opacity: 0;
    transform: scale(1.05);
}

/* ---- Vídeo fullscreen ---- */
.rua-hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 1;
}

/* ---- Overlay escuro ---- */
.rua-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 2;
    transition: background 0.8s ease;
}

.rua-hero-overlay--dark {
    background: rgba(0, 0, 0, 0.55);
}

/* ---- Flash de freada ---- */
.rua-hero-flash {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 3;
    opacity: 0;
    pointer-events: none;
}

.rua-hero-flash--active {
    animation: rua-flash-boom 0.4s ease-out;
}

@keyframes rua-flash-boom {
    0% { opacity: 0.7; }
    100% { opacity: 0; }
}

/* ---- Shake de freada ---- */
.rua-hero--shake {
    animation: rua-shake 0.6s ease;
}

@keyframes rua-shake {
    0%, 100% { transform: translate(0); }
    10% { transform: translate(-6px, 2px); }
    20% { transform: translate(5px, -2px); }
    30% { transform: translate(-4px, 1px); }
    40% { transform: translate(3px, -1px); }
    50% { transform: translate(-2px, 1px); }
    60% { transform: translate(1px, 0); }
}

/* ---- Bordão ---- */
.rua-bordao {
    position: absolute;
    top: 35%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 20;
    text-align: center;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
    pointer-events: none;
}

.rua-bordao--visible {
    opacity: 1;
    transform: translate(-50%, -55%);
}

.rua-bordao {
    background: rgba(255, 255, 255, 0.92);
    padding: 1.5rem 2.5rem;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.rua-bordao__chofer {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 800;
    color: #D4A017;
    text-transform: uppercase;
    letter-spacing: 4px;
    text-shadow: none;
    margin-bottom: 0.5rem;
}

.rua-bordao__texto {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1rem, 3vw, 2rem);
    font-weight: 600;
    color: #1a1a1a;
    text-shadow: none;
}

.rua-bordao__texto strong {
    color: #D4A017;
    font-weight: 800;
}

/* ---- Subtexto ---- */
.rua-bordao-sub {
    position: absolute;
    bottom: 25%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
    text-align: center;
    opacity: 0;
    transition: opacity 0.8s ease;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.92);
    padding: 1rem 2rem;
    border-radius: 10px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.rua-bordao-sub--visible {
    opacity: 1;
}

.rua-bordao-sub span {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(0.9rem, 2.2vw, 1.2rem);
    font-weight: 600;
    color: #1a1a1a;
    letter-spacing: 2px;
    text-transform: uppercase;
    text-shadow: none;
}

.rua-bordao-sub__acoes {
    color: #D4A017 !important;
    font-size: clamp(1.1rem, 2.2vw, 1.4rem) !important;
    font-weight: 800 !important;
}

/* ---- Tela de boas-vindas ---- */
.rua-hero-start {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 50;
    background: #000;
    cursor: default;
}

/* Foto centralizada em 9:16 */
.rua-hero-start__bg {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    height: 100%;
    aspect-ratio: 9/16;
    max-width: 100%;
}

.rua-hero-start__foto {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    display: block;
}

/* Overlay suave na foto */
.rua-hero-start__overlay {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    height: 100%;
    aspect-ratio: 9/16;
    max-width: 100%;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.1) 0%,
        rgba(0,0,0,0) 30%,
        rgba(0,0,0,0.2) 70%,
        rgba(0,0,0,0.6) 100%
    );
    z-index: 1;
}

/* Lado esquerdo - frase em itálico na área preta */
.rua-hero-start__left {
    position: absolute;
    top: 0;
    left: 0;
    width: calc(50% - 28vh);
    height: 100%;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.rua-hero-start__frase {
    font-family: Georgia, 'Times New Roman', serif;
    font-style: italic;
    font-size: 1.3rem;
    color: #C8B88A;
    line-height: 1.6;
    text-align: center;
    max-width: 250px;
}

/* Centro - nome sobre a foto (parte inferior) */
.rua-hero-start__center {
    position: absolute;
    bottom: 8%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    text-align: center;
    width: 100%;
}

.rua-hero-start__bemvindo {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.1rem;
    font-weight: 300;
    color: #fff;
    margin: 0;
    line-height: 1.4;
    text-shadow: 0 2px 10px rgba(0,0,0,0.7);
}

.rua-hero-start__bemvindo strong {
    font-size: 1.6rem;
    color: #D4A017;
    display: block;
    font-weight: 700;
}

/* Lado direito - convite + botões na área preta */
.rua-hero-start__right {
    position: absolute;
    top: 0;
    right: 0;
    width: calc(50% - 28vh);
    height: 100%;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    gap: 1.5rem;
}

.rua-hero-start__convite {
    font-family: 'Open Sans', sans-serif;
    font-size: 1.02rem;
    font-weight: 700;
    color: rgba(255,255,255,0.85);
    line-height: 1.7;
    text-align: center;
    max-width: 400px;
}

.rua-hero-start__entrar {
    animation: rua-pulse-start 2s ease infinite;
    cursor: pointer;
    text-align: center;
    color: #fff;
}

.rua-hero-start__icon {
    font-size: 2rem;
    margin-bottom: 0.3rem;
    color: #D4A017;
}

.rua-hero-start__entrar p {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.rua-hero-start__pular {
    background: none;
    border: 1px solid rgba(255,255,255,0.25);
    color: rgba(255,255,255,0.4);
    font-family: 'Open Sans', sans-serif;
    font-size: 0.7rem;
    padding: 0.4rem 1.2rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s;
    letter-spacing: 1px;
}

.rua-hero-start__pular:hover {
    border-color: rgba(255,255,255,0.5);
    color: rgba(255,255,255,0.7);
}

/* Mobile: empilhar tudo verticalmente */
@media (max-width: 768px) {
    .rua-hero-start__left,
    .rua-hero-start__right {
        position: static;
        width: 100%;
        height: auto;
        padding: 1rem;
    }
    .rua-hero-start {
        display: flex;
        flex-direction: column;
        overflow-y: auto;
    }
    .rua-hero-start__bg {
        position: relative;
        left: 0;
        transform: none;
        width: 100%;
        aspect-ratio: 9/16;
        max-height: 60vh;
    }
    .rua-hero-start__overlay {
        left: 0;
        transform: none;
        width: 100%;
        aspect-ratio: auto;
        height: 60vh;
    }
    .rua-hero-start__center {
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        padding: 1rem;
    }
    .rua-hero-start__frase {
        font-size: 1rem;
    }
}

@keyframes rua-pulse-start {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.85; }
}

/* ---- Popup de captura ---- */
.rua-hero-popup {
    position: absolute;
    top: 0;
    right: 0;
    width: auto;
    height: 100%;
    z-index: 25;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 2rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.rua-hero-popup--visible {
    opacity: 1;
    pointer-events: all;
}

.rua-hero-popup__card {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 1.5rem;
    max-width: 340px;
    width: 340px;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: rua-popup-entra 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    transform: scale(0.8) translateX(20px);
}

@keyframes rua-popup-entra {
    to { transform: scale(1) translateX(0); }
}

.rua-hero-popup__fechar {
    position: absolute;
    top: 10px;
    right: 14px;
    background: none;
    border: none;
    font-size: 1.8rem;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    padding: 4px 8px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.rua-hero-popup__fechar:hover {
    color: #333;
    background: #f0f0f0;
}

.rua-hero-popup__icon {
    margin-bottom: 0.75rem;
}

.rua-hero-popup__titulo {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.15rem;
    font-weight: 800;
    color: #4A7A5C;
    margin-bottom: 0.5rem;
}

.rua-hero-popup__texto {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

.rua-hero-popup__form {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.rua-hero-popup__input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-family: 'Open Sans', sans-serif;
    font-size: 0.95rem;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.rua-hero-popup__input:focus {
    outline: none;
    border-color: #25D366;
    box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.15);
}

.rua-hero-popup__input::placeholder {
    color: #bbb;
}

.rua-hero-popup__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem;
    background: #25D366;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rua-hero-popup__btn:hover {
    background: #1DA851;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
}

.rua-hero-popup__privacidade {
    font-size: 0.7rem;
    color: #aaa;
    margin-top: 0.75rem;
}

/* ---- Botão pular ---- */
.rua-skip-hero {
    position: absolute;
    bottom: 5%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 30;
    background: rgba(255, 255, 255, 0.92);
    border: none;
    color: #1a1a1a;
    padding: 0.75rem 2rem;
    border-radius: 25px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    display: none; /* aparece depois que começa */
}

.rua-skip-hero--visible {
    display: block;
}

.rua-skip-hero:hover {
    background: #fff;
    color: #000;
    transform: translateX(-50%) translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* ---- Responsivo ---- */
@media (max-width: 768px) {
    .rua-bordao {
        white-space: normal;
        width: 90%;
    }

    .rua-bordao__chofer {
        font-size: 1.8rem;
        letter-spacing: 2px;
    }

    .rua-bordao__texto {
        font-size: 1rem;
    }

    .rua-bordao-sub {
        bottom: 15%;
        width: 90%;
    }

    .rua-hero-start__icon {
        font-size: 2.5rem;
    }

    .rua-hero-start__content p {
        font-size: 1rem;
    }
}

/* ---- Quando animação termina ---- */
.rua-hero-done .rua-header {
    animation: rua-fadeInDown 0.5s ease;
}

@keyframes rua-fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}
