/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: var(--background);
    z-index: 1;
}

.hero-background {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.hero-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 58% center;
    filter: saturate(0.82) contrast(0.92) brightness(0.72);
    opacity: 0.74;
}

.hero-overlay {
    background:
        linear-gradient(90deg, rgba(24, 58, 61, 0.94) 0%, rgba(24, 58, 61, 0.82) 34%, rgba(24, 58, 61, 0.42) 64%, rgba(24, 58, 61, 0.2) 100%),
        linear-gradient(180deg, rgba(35, 35, 35, 0.12) 0%, rgba(24, 58, 61, 0.1) 45%, rgba(24, 58, 61, 0.42) 100%);
}

.hero-content {
    position: relative;
    z-index: 10;
    padding-top: clamp(3rem, 8vh, 6rem);
}

.hero-heading {
    max-width: 8.8ch;
    font-size: clamp(4rem, 8.6vw, 7.4rem);
    letter-spacing: 0;
    line-height: 0.92 !important;
}

.hero-lead {
    max-width: 31rem;
    color: rgba(216, 208, 197, 0.68);
    font-size: clamp(1rem, 1.35vw, 1.18rem);
    line-height: 1.65;
}

.hero-actions .btn {
    min-width: 240px;
    border-color: rgba(216, 208, 197, 0.72);
    color: rgba(216, 208, 197, 0.92);
    letter-spacing: 0.18em;
}

.hero-actions .btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background-color: transparent;
}

.hero-branding {
    letter-spacing: 0.3em;
}

.line-height-tight {
    line-height: 0.95 !important;
}

.hero-tagline p {
    font-size: 0.875rem;
    color: rgba(216, 208, 197, 0.6);
}

.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-text {
    font-size: 0.75rem;
    color: rgba(216, 208, 197, 0.34);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    display: block;
    margin-bottom: 1rem;
}

.scroll-line {
    width: 1px;
    height: 4rem;
    background-color: rgba(166, 138, 100, 0.6);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; height: 4rem; }
    50% { opacity: 0.4; height: 3rem; }
}

/* Services Section */
.services-header .lead {
    color: rgba(216, 208, 197, 0.64);
    font-size: clamp(1rem, 1.6vw, 1.16rem);
    line-height: 1.8;
}

.service-card {
    border: 1px solid rgba(216, 208, 197, 0.05);
    background-color: rgba(35, 35, 35, 0.5);
    display: flex;
    flex-direction: column;
    min-height: 100%;
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(10px);
}

.service-card--featured {
    border-color: rgba(166, 138, 100, 0.32);
    background:
        linear-gradient(180deg, rgba(166, 138, 100, 0.1), transparent 42%),
        rgba(35, 35, 35, 0.62);
}

.service-card:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
    background-color: rgba(35, 35, 35, 0.8);
}

.service-card__topline {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.service-number {
    font-size: 0.75rem;
    color: var(--accent);
    letter-spacing: 0.2em;
}

.service-badge {
    border: 1px solid rgba(166, 138, 100, 0.34);
    color: rgba(216, 208, 197, 0.72);
    font-size: 0.62rem;
    letter-spacing: 0.16em;
    padding: 0.42rem 0.6rem;
    text-transform: uppercase;
}

.service-card h3 {
    color: var(--foreground);
    font-size: clamp(1.6rem, 2.4vw, 2rem);
    line-height: 1.08;
}

.service-description {
    color: rgba(216, 208, 197, 0.66);
    font-size: 0.96rem;
    line-height: 1.75;
}

.service-features li {
    align-items: flex-start;
    border-top: 1px solid rgba(216, 208, 197, 0.055);
    color: rgba(216, 208, 197, 0.58);
    display: flex;
    font-size: 0.84rem;
    gap: 0.75rem;
    line-height: 1.55;
    padding-top: 0.78rem;
}

.service-features li::before {
    background-color: var(--accent);
    border-radius: 50%;
    content: "";
    flex: 0 0 auto;
    margin-top: 0.58rem;
    width: 3px;
    height: 3px;
}

.service-price {
    border-color: rgba(216, 208, 197, 0.1) !important;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 1.35rem;
    letter-spacing: 0.02em;
    line-height: 1;
}

/* Contact Section */
.form-group label {
    font-size: 0.7rem;
    color: rgba(216, 208, 197, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.z-max { z-index: 100000 !important; }

.menu-toggle {
    cursor: pointer;
    width: 40px;
    height: 40px;
    position: relative;
}

.hamburger {
    width: 24px;
    height: 14px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.hamburger span {
    display: block;
    width: 100%;
    height: 1px;
    background: var(--accent);
    position: absolute;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.hamburger span:first-child { top: 0; }
.hamburger span:last-child { bottom: 0; }

.menu-active .hamburger span:first-child {
    transform: rotate(45deg);
    top: 6px;
}

.menu-active .hamburger span:last-child {
    transform: rotate(-45deg);
    bottom: 7px;
}

.mobile-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background-color: #183A3D !important;
    z-index: 99999 !important; /* Extremely high to stay on top */
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex !important;
    align-items: center;
    justify-content: center;
}

.mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-overlay ul {
    gap: 5vh !important; /* Proportional vertical spacing */
}

.mobile-overlay .nav-link {
    color: #D8D0C5;
    transition: color 0.3s ease;
}

.mobile-overlay .nav-link:hover {
    color: var(--accent);
}

@media (max-width: 991px) {
    /* Hero Padding Adjustment back to normal since header is compact now */
    .hero {
        padding-top: 100px !important;
    }
}

.brand-logo {
    transition: all 0.4s ease;
    color: var(--accent);
}

.brand-logo.vertical {
    flex-direction: column !important;
    text-align: center;
    gap: 1rem !important;
}

.brand-logo.vertical .logo-text {
    align-items: center;
}

.brand-logo .logo-name {
    font-size: 1.1rem;
    line-height: 1;
    color: #D8D0C5;
    white-space: nowrap;
}

.brand-logo .logo-specialty {
    font-size: 0.65rem;
    letter-spacing: 0.4em;
    line-height: 1.8;
    margin-top: 0.2rem;
}

.navbar-brand {
    font-weight: 400;
}

.nav-link {
    transition: color 0.3s ease;
}

@media (max-width: 576px) {
    .navbar-brand {
        font-size: 1.1rem !important;
        letter-spacing: 0.05em;
    }
    
.header-mobile-grid {
    display: grid !important;
    grid-template-columns: repeat(12, 1fr);
    justify-content: center;
    gap: 1.5rem 0 !important;
    font-size: 0.6rem !important;
    letter-spacing: 0.2em !important;
    width: 100%;
}

.header-mobile-grid li {
    text-align: center;
    white-space: nowrap;
}

.header-mobile-grid li:nth-child(-n+3) { grid-column: span 4; }
.header-mobile-grid li:nth-child(n+4) { grid-column: span 3; }

.main-header {
    backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(216, 208, 197, 0.03);
}

.nav-link {
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-branding .logo-name {
    font-size: 1.5rem;
}

.footer-branding .logo-specialty {
    font-size: 0.8rem;
    letter-spacing: 0.6em;
}

.social-icon i {
    width: 18px;
    height: 18px;
}

.form-control {
    background-color: transparent !important;
    border: none !important;
    border-bottom: 1px solid rgba(216, 208, 197, 0.2) !important;
    border-radius: 0 !important;
    padding: 0.75rem 0 !important;
    color: var(--foreground) !important;
    transition: border-color 0.4s ease !important;
}

@media (max-width: 768px) {
    .hero-heading { font-size: clamp(3.2rem, 17vw, 5.6rem) !important; }
    .hero-subtitle h2 { font-size: 12vw !important; }
    
    .methodology-lines p {
        font-size: 2rem !important;
    }
    
    .bg-drift {
        font-size: 25vw !important;
    }
    
    .contact-email {
        font-size: 1.5rem !important;
    }
}

.form-control:focus {
    box-shadow: none !important;
    border-color: var(--accent) !important;
}

.form-control::placeholder {
    color: rgba(216, 208, 197, 0.1) !important;
}

.contact-email {
    color: #D8D0C5;
    transition: all 0.4s ease;
    word-break: break-all;
}

.contact-email:hover {
    color: var(--accent);
    padding-left: 0.5rem;
}

.bg-text-overlay {
    overflow: hidden;
    background-color: #183A3D;
}

/* FAQ Accordion Refinements */
.custom-accordion .accordion-button {
    box-shadow: none !important;
    border: none;
}

.custom-accordion .accordion-button:not(.collapsed) {
    color: var(--accent) !important;
}

.custom-accordion .accordion-button::after {
    filter: invert(1) sepia(21%) saturate(674%) hue-rotate(345deg) brightness(89%) contrast(85%);
    background-size: 1rem;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-accordion .accordion-button:hover {
    padding-left: 0.5rem !important;
    color: var(--accent) !important;
}

.custom-accordion .accordion-item {
    transition: all 0.4s ease;
}

/* Methodology Section */
.methodology {
    background-color: #183A3D;
}

.h-px {
    height: 1px;
}

/* Portfolio / Archive */
.portfolio-card {
    transition: all 0.5s ease;
}

.portfolio-masonry {
    margin: 0 auto !important;
    width: 100% !important;
    visibility: hidden; /* Hide until Masonry initializes to prevent flash */
}

.portfolio-masonry.is-initialized {
    visibility: visible;
}

.portfolio-item-wrap,
.grid-sizer {
    width: 25% !important; /* 4 colunas em telas grandes */
    padding: 10px;
}

@media (max-width: 1400px) {
    .portfolio-item-wrap,
    .grid-sizer {
        width: 33.333% !important; /* 3 colunas em telas mÃ©dias */
    }
}

@media (max-width: 991px) {
    .portfolio-item-wrap,
    .grid-sizer {
        width: 50% !important; /* 2 colunas em tablets */
    }
}

@media (max-width: 576px) {
    .portfolio-item-wrap,
    .grid-sizer {
        width: 50% !important; /* MantÃ©m 2 colunas em mobile para nÃ£o ficar gigante */
        padding: 5px;
    }
}

.portfolio-item-wrap {
    float: left;
}

.portfolio-card-v2 {
    position: relative;
    overflow: hidden;
    background-color: #232323;
}

.portfolio-card-v2 img {
    width: 100% !important;
    height: auto !important;
    max-height: 700px; /* Limit extremely tall images */
    object-fit: cover;
    display: block;
}

.aspect-4-5 { aspect-ratio: 4/5; }
.aspect-square { aspect-ratio: 1/1; }

.portfolio-card-v2:hover .portfolio-overlay-v2 {
    opacity: 1;
}

.portfolio-overlay-v2 {
    background: linear-gradient(to top, rgba(35, 35, 35,0.8), transparent);
}

.portfolio-card-v2:hover img {
    transform: scale(1.1);
}

.cursor-pointer { cursor: pointer; }

/* Philosophy */
.philosophy {
    background-color: var(--background);
    position: relative;
    z-index: 1;
}

.bg-drift {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    font-size: 12vw;
    color: rgba(216, 208, 197, 0.02);
    white-space: nowrap;
    z-index: -1;
    pointer-events: none;
    user-select: none;
}

/* Background Text Overlay (General) */
.bg-text-overlay {
    position: relative;
    background-color: #183A3D;
    padding: 5rem 0;
    overflow: hidden;
    z-index: 1;
}

.bg-text-overlay p {
    font-size: 18vw;
    color: rgba(216, 208, 197, 0.02);
    line-height: 0.8;
    margin: 0;
    letter-spacing: -0.05em;
    text-align: center;
    position: relative;
    z-index: -1;
}

/* Header Adjustments */
.main-header {
    background: transparent !important;
    transition: all 0.3s ease;
}

.navbar {
    padding: 1.5rem 0;
}
/* Methodology Refinements */
.line-height-tight { line-height: 1.1; }
.grayscale-hover {
    filter: grayscale(1);
    transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.grayscale-hover:hover {
    filter: grayscale(0);
}
.methodology-visual img {
    transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.methodology-visual:hover img {
    transform: scale(1.05);
}
.py-10 { padding-top: 8rem; padding-bottom: 8rem; }

@media (max-width: 991px) {
    .py-10 { padding-top: 5rem; padding-bottom: 5rem; }
}

/* Contact Form Refinements */
.form-control-custom {
    display: block;
    width: 100%;
    padding: 1rem 0;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: var(--foreground);
    background-color: transparent;
    background-clip: padding-box;
    border: none;
    border-bottom: 1px solid rgba(216, 208, 197, 0.1);
    border-radius: 0;
    transition: border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
}

.form-control-custom:focus {
    border-color: var(--accent);
}

select.form-control-custom {
    background-color: #232323 !important;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23A68A64' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    padding-right: 2.5rem !important;
}

select.form-control-custom option {
    background-color: #232323;
    color: #D8D0C5;
    padding: 1rem;
}

/* Custom Dropdown for Luxury Feel */
.custom-dropdown {
    position: relative;
    user-select: none;
}

.dropdown-trigger {
    border-bottom: 1px solid rgba(216, 208, 197, 0.1) !important;
}

.dropdown-menu-custom {
    top: 100%;
    left: 0;
    box-shadow: 0 10px 30px rgba(35, 35, 35,0.5);
    transition: all 0.3s ease;
    max-height: 250px;
    overflow-y: auto;
}

.dropdown-item-custom {
    color: rgba(216, 208, 197, 0.6);
    font-size: 0.9rem;
}

.dropdown-item-custom:hover {
    background-color: rgba(166, 138, 100, 0.1) !important;
    color: var(--accent) !important;
}

.text-accent {
    color: var(--accent) !important;
}

/* Modal Responsiveness */
@media (max-width: 576px) {
    #whatsappModal .modal-dialog {
        margin: 0.5rem;
    }
    
    #whatsappModal .modal-content {
        border: none;
    }

    #whatsappModal .modal-body {
        padding: 1.5rem !important;
    }

    #whatsappModal .modal-title {
        font-size: 1.5rem !important;
    }

    .dropdown-item-custom {
        padding: 1.25rem !important; /* Larger hit area for mobile */
        font-size: 1rem !important;
    }
}

.form-control-custom::placeholder {
    color: rgba(216, 208, 197, 0.05);
}

.contact-form-card {
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-form-card:hover {
    border-color: rgba(166, 138, 100, 0.3) !important;
}

/* Custom Checkbox LGPD */
.custom-check .form-check-input {
    border-radius: 0;
    margin-top: 0.3rem;
}

.custom-check .form-check-input:checked {
    background-color: var(--accent);
    border-color: var(--accent);
}

.custom-check .form-check-input:focus {
    box-shadow: none;
    border-color: var(--accent);
}

.scroll-arrow-icon {
    animation: bounce-scroll 2s infinite;
}

@keyframes bounce-scroll {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-8px); }
    60% { transform: translateY(-4px); }
}

@media (max-width: 1200px) {
    .hero-background img {
        object-position: 65% center;
    }
}

/* Hero Mobile Optimization */
@media (max-width: 768px) {
    .hero {
        height: 100vh !important;
        padding-top: 110px;
        padding-bottom: 20px;
        display: flex !important;
        align-items: center;
    }

    .hero-content {
        padding-top: 0;
        width: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        height: 100%;
    }

    .hero-background img {
        object-position: 80% center !important;
    }

    .hero-overlay {
        background: linear-gradient(90deg, rgba(24, 58, 61, 0.98) 0%, rgba(24, 58, 61, 0.85) 50%, rgba(24, 58, 61, 0.4) 100%) !important;
    }

    .hero-branding {
        font-size: 0.6rem !important;
        margin-bottom: 1vh !important;
    }

    .hero-title h1 {
        font-size: clamp(1.8rem, 8vh, 2.5rem) !important;
        line-height: 1.1 !important;
        margin-bottom: 2vh !important;
    }

    .hero-heading {
        max-width: 7.6ch;
        font-size: clamp(3.2rem, 16vw, 5.25rem) !important;
        line-height: 0.94 !important;
        margin-bottom: 2vh !important;
    }

    .hero-content p.lead {
        font-size: clamp(0.85rem, 3vh, 0.95rem) !important;
        margin-bottom: 3vh !important;
        line-height: 1.4;
        max-width: 100% !important;
    }

    .hero-actions .btn {
        width: 100%;
        text-align: center;
        padding: clamp(0.75rem, 2vh, 1rem) !important;
        font-size: 0.8rem !important;
    }

    .scroll-indicator {
        position: absolute !important;
        bottom: 2vh !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        margin-top: 0;
    }

    .scroll-text {
        font-size: 0.55rem !important;
        margin-bottom: 0.5vh !important;
    }
}

/* Ultra-short screens optimization (e.g. mobile landscape or small phones) */
@media (max-height: 600px) and (max-width: 768px) {
    .hero {
        padding-top: 80px !important;
    }

    .hero-title h1 {
        font-size: 1.6rem !important;
        margin-bottom: 0.5rem !important;
    }

    .hero-heading {
        font-size: 2.45rem !important;
        margin-bottom: 0.5rem !important;
    }

    .hero-content p.lead {
        font-size: 0.8rem !important;
        margin-bottom: 1rem !important;
    }

    .hero-actions .btn {
        padding: 0.5rem !important;
        font-size: 0.75rem !important;
    }

    .scroll-text {
        display: none !important;
    }

    .scroll-indicator {
        bottom: 0.5rem !important;
    }
}

