/* ============================================
   LAYOUT - HEADER, FOOTER, SEÇÕES
   ============================================ */

/* ============================================
   HEADER
   ============================================ */

.header {
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--primary-color-dark) 100%);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: clamp(0.875rem, 2.5vw, 1.5625rem) 0;
    width: 100%;
    max-width: 100%;
    transition: box-shadow var(--transition-base);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    overflow-x: hidden;
}

.header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(212, 175, 55, 0.3) 50%, transparent 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
}

.header.scrolled::after {
    opacity: 1;
}

.header__content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: clamp(1.5rem, 4vw, 3rem);
    flex-wrap: nowrap;
    min-width: 0;
    overflow: visible;
    position: relative;
}

.header__logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    min-width: 0;
    padding-right: clamp(1rem, 2.5vw, 2rem);
    position: relative;
    z-index: 2;
}

.header__logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: opacity 0.3s;
}

.header__logo a:hover {
    opacity: 0.9;
}

.header__logo a:focus-visible {
    outline: 3px solid var(--color-white);
    outline-offset: 4px;
    border-radius: 4px;
}

.header__logo-img {
    max-height: clamp(9rem, 18vw, 11rem);
    width: auto;
    max-width: min(100%, clamp(300px, 50vw, 400px));
    height: auto;
    object-fit: contain;
    transition: transform var(--transition-base);
    display: block;
}

.header__logo-img:hover {
    transform: scale(1.02);
}

.header__navbar {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: center;
    min-width: 0;
    margin: 0 auto;
    padding: 0 clamp(1rem, 2.5vw, 2rem);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    pointer-events: none;
    max-width: calc(100% - 400px);
    overflow: visible;
    min-height: fit-content;
}

/* Esconder navbar em mobile */
@media (max-width: 767px) {
    .header__navbar {
        display: none;
    }
}

.header__navbar .nav-menu {
    pointer-events: auto;
}

.header__actions {
    display: flex;
    align-items: center;
    gap: clamp(0.5rem, 1.5vw, 0.9375rem);
    flex-shrink: 0;
    min-width: 0;
    margin-left: auto;
    padding-left: clamp(1rem, 2.5vw, 2rem);
    position: relative;
    z-index: 2;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: clamp(0.75rem, 2vw, 1.5rem);
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    overflow: visible;
}

/* Permite quebra do último item em resoluções intermediárias */
.nav-menu li:last-child {
    flex-shrink: 1;
    min-width: fit-content;
}

.nav-menu__link {
    text-decoration: none;
    color: var(--color-white);
    font-weight: 500;
    font-size: clamp(0.875rem, 1.5vw, 1rem);
    transition: color var(--transition-base), background-color var(--transition-base), transform var(--transition-base);
    position: relative;
    white-space: nowrap;
    padding: clamp(0.375rem, 0.75vw, 0.625rem) clamp(0.5rem, 1.2vw, 0.875rem);
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    max-width: 100%;
}

.nav-menu__link:hover {
    color: var(--color-white);
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.nav-menu__link:active {
    transform: translateY(0);
}

.nav-menu__link:focus-visible {
    color: var(--color-white);
    background-color: rgba(247, 247, 247, 0.1);
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    outline: 3px solid var(--color-white);
    outline-offset: 2px;
}

.nav-menu__link::after {
    content: '';
    position: absolute;
    bottom: clamp(0.125rem, 0.3vw, 0.25rem);
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    transition: width var(--transition-base);
    border-radius: 2px;
    box-shadow: 0 2px 4px rgba(212, 175, 55, 0.4);
}

.nav-menu__link:hover::after,
.nav-menu__link--active::after {
    width: calc(100% - 1rem);
}

.nav-menu__link--active {
    color: var(--color-white);
    background-color: rgba(255, 255, 255, 0.05);
    font-weight: 600;
}


/* ============================================
   HERO SECTION
   ============================================ */

.hero {
    position: relative;
    color: white;
    padding: clamp(4rem, 12vw, 7rem) 0;
    text-align: center;
    overflow: hidden;
    min-height: clamp(22rem, 55vh, 40rem);
    display: flex;
    align-items: center;
    width: 100%;
    isolation: isolate;
}

.hero__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero__bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 15%;
    min-height: 100%;
    max-width: 100%;
    display: block;
    /* Fallback para navegadores não-WebKit */
    image-rendering: crisp-edges;
    /* Versão WebKit */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.hero__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(3, 34, 52, 0.88) 0%, rgba(3, 34, 52, 0.78) 50%, rgba(2, 26, 40, 0.85) 100%);
    z-index: 1;
}

.hero__content {
    position: relative;
    z-index: 2;
    max-width: min(90%, clamp(600px, 50vw, 800px));
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    width: 100%;
}

.hero__title {
    font-size: clamp(1.75rem, 5.5vw, 3.25rem);
    font-weight: 800;
    margin-bottom: clamp(1.25rem, 3vw, 1.5rem);
    line-height: 1.2;
    overflow-wrap: break-word;
    hyphens: none;
    max-width: 100%;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    letter-spacing: -0.02em;
    padding: 0 clamp(0.5rem, 2vw, 1rem);
}

.hero__subtitle {
    font-size: clamp(1.125rem, 2.8vw, 1.375rem);
    margin-bottom: clamp(2rem, 5vw, 3rem);
    opacity: 0.96;
    font-weight: 400;
    line-height: 1.65;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
    max-width: min(90%, clamp(500px, 45vw, 700px));
    margin-left: auto;
    margin-right: auto;
    padding: 0 clamp(0.5rem, 2vw, 1rem);
    overflow-wrap: break-word;
}

/* Botão do hero - branco com texto azul */
.hero .btn--primary {
    background: var(--color-white);
    color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.hero .btn--primary:hover {
    background: var(--color-white-hover-light);
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.hero .btn--primary:active {
    transform: translateY(-1px);
}

.hero .btn--primary:focus-visible {
    box-shadow: 0 0 0 3px var(--primary-color), 0 4px 15px rgba(3, 34, 52, 0.3);
}

/* ============================================
   SEÇÕES
   ============================================ */

.section {
    padding: clamp(3rem, 8vw, 6.5rem) 0;
    position: relative;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.section--light {
    background: var(--bg-white);
}

.section--dark {
    background: var(--bg-light);
}

.section--primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-color-dark) 100%);
    color: white;
    position: relative;
}

.section--primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.1) 50%, transparent 100%);
}

/* Grids - melhorados para fluidez total */
.grid {
    display: grid;
    gap: clamp(1.5rem, 4vw, 2.5rem);
    grid-auto-rows: min-content;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.grid--servicos,
.grid--beneficios,
.grid--depoimentos {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: clamp(1.5rem, 4vw, 2.5rem);
    align-items: stretch;
}

.grid--features {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
    gap: clamp(1.5rem, 3vw, 1.875rem);
    align-items: stretch;
}

/* Sobre Escritório */
.sobre-wrapper {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(2rem, 5vw, 3.125rem);
    align-items: center;
    margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* Layout de duas colunas em telas médias e grandes */
@media (min-width: 768px) {
    .sobre-wrapper {
        grid-template-columns: 1fr 1fr;
    }
    
    .sobre-image {
        order: 0;
    }
}

.sobre-text {
    margin-bottom: 0;
    min-width: 0;
}

.sobre-text p {
    font-size: clamp(0.9375rem, 1.8vw, 1.0625rem);
    line-height: 1.8;
    color: var(--text-light);
    margin-bottom: clamp(1.25rem, 3vw, 1.5rem);
    word-wrap: break-word;
    text-align: justify;
    text-align-last: left;
}

.sobre-text p:last-child {
    margin-bottom: 0;
}

.sobre-image {
    width: 100%;
    height: 100%;
    min-height: clamp(18rem, 45vw, 28rem);
    max-height: clamp(28rem, 60vh, 40rem);
    overflow: hidden;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: box-shadow var(--transition-base);
    position: relative;
}

.sobre-image:hover {
    box-shadow: var(--shadow-hover);
}

.sobre-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    transition: transform var(--transition-slow);
    min-height: 100%;
    display: block;
}

.sobre-image:hover img {
    transform: scale(1.05);
}

/* Contato */
.contato-subtitle {
    font-size: clamp(1.0625rem, 2.2vw, 1.25rem);
    max-width: min(90%, clamp(500px, 45vw, 750px));
    margin: 0 auto clamp(2rem, 5vw, 3rem);
    opacity: 0.98;
    line-height: 1.85;
    overflow-wrap: break-word;
    padding: 0 var(--spacing-sm);
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.contato-cta {
    margin-top: clamp(1rem, 2.5vw, 2rem);
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Seções CTA - menos padding para aproximar os botões */
.section--cta {
    padding: clamp(1.5rem, 4vw, 2.5rem) 0;
}

/* Localização */
.localizacao-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(2rem, 5vw, 3rem);
    align-items: start;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.localizacao-mapa {
    width: 100%;
    height: clamp(22rem, 55vh, 32rem);
    min-height: clamp(18rem, 45vh, 20rem);
    max-height: clamp(28rem, 60vh, 40rem);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    position: relative;
    transition: box-shadow var(--transition-base);
}

@supports not (aspect-ratio: 16 / 9) {
    .localizacao-mapa {
        padding-bottom: 56.25%;
        height: 0;
    }
}

@supports (aspect-ratio: 16 / 9) {
    .localizacao-mapa {
        aspect-ratio: 16 / 9;
        padding-bottom: 0;
        height: clamp(22rem, 55vh, 32rem);
    }
}

/* Garantir que o iframe seja responsivo */
.localizacao-mapa iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    min-height: 100%;
}

.localizacao-mapa:hover {
    box-shadow: var(--shadow-hover);
}


/* ============================================
   FOOTER
   ============================================ */

.footer {
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--primary-color-dark) 100%);
    color: white;
    padding: clamp(3.5rem, 8vw, 5rem) 0 clamp(1.5rem, 3.5vw, 2rem);
    position: relative;
    overflow: hidden;
    margin-top: clamp(2rem, 5vw, 4rem);
    width: 100%;
    max-width: 100%;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.1) 50%, transparent 100%);
}

.footer__content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
    gap: clamp(2rem, 5vw, 3rem);
    margin-bottom: clamp(2rem, 5vw, 3rem);
    grid-auto-rows: min-content;
    position: relative;
    z-index: 1;
    width: 100%;
}

.footer__section {
    min-width: 0;
    width: 100%;
}

.footer__section:first-child {
    max-width: 100%;
}

.footer__section h3 {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    margin-bottom: clamp(1rem, 2.5vw, 1.25rem);
    color: var(--color-white);
    font-weight: 700;
    letter-spacing: -0.02em;
    position: relative;
    padding-bottom: clamp(0.75rem, 2vw, 1rem);
}

.footer__section h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: clamp(2.5rem, 6vw, 3.5rem);
    height: 3px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.4), transparent);
    border-radius: 2px;
}

.footer__section h4 {
    font-size: clamp(1.125rem, 2.5vw, 1.25rem);
    margin-bottom: clamp(1rem, 2.5vw, 1.25rem);
    color: white;
    font-weight: 600;
    letter-spacing: -0.01em;
    position: relative;
    padding-bottom: clamp(0.5rem, 1.5vw, 0.75rem);
}

.footer__section h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: clamp(2rem, 5vw, 2.5rem);
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.footer__section p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: clamp(0.75rem, 2vw, 1rem);
    font-size: clamp(0.875rem, 1.5vw, 0.9375rem);
    overflow-wrap: break-word;
    line-height: 1.7;
}

.footer__address {
    font-style: normal;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: clamp(0.5rem, 1.5vw, 0.75rem);
}

.footer__address p {
    display: flex;
    align-items: center;
    gap: clamp(0.5rem, 1.5vw, 0.75rem);
    color: rgba(255, 255, 255, 0.85);
    margin: 0;
}

.footer__address-icon {
    width: clamp(1rem, 2vw, 1.125rem);
    height: clamp(1rem, 2vw, 1.125rem);
    flex-shrink: 0;
    opacity: 0.8;
    stroke: currentColor;
    fill: none;
}

.footer__phone {
    font-size: clamp(0.9375rem, 1.75vw, 1.0625rem);
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    gap: clamp(0.5rem, 1.5vw, 0.75rem);
    margin-top: clamp(0.5rem, 1.5vw, 0.75rem);
}

.footer__phone-icon {
    width: clamp(1rem, 2vw, 1.125rem);
    height: clamp(1rem, 2vw, 1.125rem);
    flex-shrink: 0;
    opacity: 0.8;
    stroke: currentColor;
    fill: none;
}

.footer__section ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: clamp(0.625rem, 1.75vw, 0.875rem);
}

.footer__section ul li {
    margin: 0;
    position: relative;
    padding-left: clamp(1rem, 2.5vw, 1.25rem);
}

.footer__section ul li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: rgba(255, 255, 255, 0.5);
    font-size: clamp(0.75rem, 1.5vw, 0.875rem);
    transition: all 0.3s ease;
}

.footer__section ul li:hover::before {
    color: rgba(255, 255, 255, 0.9);
    transform: translateX(3px);
}

.footer__section ul li a,
.footer__link {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: clamp(0.875rem, 1.5vw, 0.9375rem);
    transition: color var(--transition-base), transform var(--transition-base);
    overflow-wrap: break-word;
    display: inline-block;
    line-height: 1.6;
}

.footer__section ul li a:hover,
.footer__link:hover {
    color: var(--color-white);
    transform: translateX(3px);
}

.footer__link:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 4px;
    border-radius: 4px;
    padding: 2px 4px;
}

.footer__phone a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: color var(--transition-base), text-shadow var(--transition-base);
    font-weight: 600;
}

.footer__phone a:hover {
    color: var(--color-white);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.footer__phone a:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 4px;
    border-radius: 4px;
    padding: 2px 4px;
}

.footer__bottom {
    text-align: center;
    padding-top: clamp(2rem, 4vw, 2.5rem);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
    font-size: clamp(0.8125rem, 1.5vw, 0.875rem);
    overflow-wrap: break-word;
    position: relative;
    z-index: 1;
}

.footer__bottom::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: clamp(3rem, 8vw, 5rem);
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
}

