/* General CSS & Variables */
:root {
    --bg-dark: #0a0e17;
    --bg-darker: #06080d;
    --accent: #fba919;
    --accent-hover: #ffb833;
    --text-white: #ffffff;
    --text-muted: #a0aab2;
    --font-main: 'Montserrat', sans-serif;
    
    --card-green: #2c4c3b;
    --card-blue: #1b365d;
    --card-orange: #c87a19;

    /* Color de marca por página; constructora.css / inmobiliaria.css lo sobrescriben */
    --theme-accent: var(--accent);
    --theme-accent-rgb: 251, 169, 25;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-white);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul {
    list-style: none;
}

/* Typography Utilities */
.accent-color {
    color: var(--theme-accent);
}

/* Header */
.main-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    font-weight: 800;
    font-size: 1.5rem;
}

.logo-label {
    display: block;
    line-height: 1;
    letter-spacing: 2px;
    text-transform: uppercase;
    white-space: nowrap;
}

.logo-label-bottom {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--theme-accent);
    margin-left: 6px;
    margin-top: 2px;
}

.opa-logo-img {
    height: 60px; /* Increased default from 50px to 60px for footer scaling */
    width: auto;
    object-fit: contain;
}

.main-header .opa-logo-img {
    height: 90px; /* Specifically made header logo larger */
}

.logo .fa-house {
    color: var(--theme-accent);
    font-size: 1.8rem;
    transform: rotate(-15deg);
}

.logo-text span {
    font-weight: 400;
    margin-right: 5px;
}

.main-nav .nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.main-nav .nav-links > li > a {
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    position: relative;
    padding-bottom: 5px;
}

.main-nav .nav-links > li > a::after {
    content: '';
    position: absolute;
    bottom: 0px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--theme-accent);
    transition: width 0.3s ease;
}

.main-nav .nav-links > li > a.active {
    color: var(--theme-accent);
}

.main-nav .nav-links > li > a.active::after,
.main-nav .nav-links > li > a:hover::after {
    width: 100%;
}

.main-nav .nav-links > li > a:hover {
    color: var(--theme-accent);
}

/* Dropdown styling */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none; /* hidden by default */
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--bg-darker);
    min-width: 220px;
    border-top: 3px solid var(--theme-accent);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    padding: 10px 0;
    border-radius: 0 0 8px 8px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* The active class will be toggled by JS on click */
.dropdown.active .dropdown-menu {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.dropdown-menu li a {
    display: block;
    padding: 10px 20px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.dropdown-menu li a:hover {
    background-color: rgba(255,255,255,0.05);
    color: var(--text-white);
    padding-left: 25px;
}

/* Buttons */
.btn-outline {
    border: 2px solid white;
    padding: 8px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
}

.btn-outline:hover {
    background-color: white;
    color: var(--bg-dark);
}

.btn-outline-large {
    border: 2px solid white;
    padding: 12px 36px;
    border-radius: 50px;
    font-weight: 600;
    display: inline-block;
    margin-top: 30px;
}

.btn-outline-large:hover {
    background-color: white;
    color: var(--bg-dark);
}

.btn-solid {
    background-color: var(--accent);
    color: var(--bg-dark);
    padding: 12px 36px;
    border-radius: 50px;
    font-weight: 700;
    display: inline-block;
}

.btn-solid:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
}

.header-btn {
    padding: 8px 24px !important;
    font-size: 0.9rem;
}

.header-action {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-white);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

/* Hero Section */
.hero-section {
    height: 100vh;
    min-height: 700px;
    background-color: var(--bg-dark);
    background-image: url('../img/hero_bg_hd_architectural.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 0 50px;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(to right, rgba(10,14,23,0.95) 0%, rgba(10,14,23,0.3) 100%);
    z-index: 1;
}

.hero-bg-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    z-index: 0;
    object-fit: cover;
    transition: opacity 1.5s ease-in-out;
}

.hero-content {
    max-width: 800px;
    margin-top: 80px; /* Offset for header */
    position: relative;
    z-index: 2;
}

.hero-overtitle {
    color: var(--accent);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 600px;
    color: #e0e0e0;
}

/* Ecosystem Section */
.ecosystem-section {
    background-color: #f5f5f5; /* Light grey textured look in mockup */
    color: var(--bg-dark);
    padding: 80px 50px;
    text-align: center;
    /* simulated texture */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="4" height="4"><rect width="4" height="4" fill="%23f5f5f5"/><rect width="1" height="1" fill="%23e0e0e0"/></svg>');
}

.ecosystem-section h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 5px;
}

.ecosystem-section .subtitle {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 60px;
    font-weight: 500;
}

.flow-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 15px;
    max-width: 1200px;
    margin: 0 auto 50px;
    flex-wrap: wrap;
}

.flow-step {
    flex: 1;
    min-width: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.icon-circle {
    width: 70px;
    height: 70px;
    border: 3px solid var(--accent);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8rem;
    color: var(--bg-dark);
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.flow-step:hover .icon-circle {
    transform: scale(1.1);
    background-color: var(--accent);
    color: white;
}

.flow-step h3 {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.flow-step p {
    font-size: 0.8rem;
    color: #666;
}

.flow-arrow {
    color: var(--accent);
    font-size: 1.5rem;
    margin-top: 25px;
}

/* Why OPA Section (Replaced Alert Box) */
.why-opa-box {
    background-color: rgba(251,169,25,0.1);
    border: 1px solid var(--accent);
    padding: 40px;
    border-radius: 12px;
    margin: 0 auto;
    max-width: 1000px;
    text-align: center;
}

.why-opa-box h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 10px;
    color: var(--bg-dark);
}

.why-subtitle {
    font-size: 1rem;
    color: #444;
    max-width: 800px;
    margin: 0 auto 30px;
}

.why-cards {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
}

.why-card {
    flex: 1;
    border-radius: 12px;
    padding: 35px 25px;
    text-align: left;
}

.light-card {
    background-color: rgba(200, 122, 25, 0.25);
    color: var(--bg-dark);
}

.dark-card {
    background-color: rgba(10, 14, 23, 0.9); /* Dark background (black/dark-grey) transparent */
    color: white;
}

.why-card h4 {
    font-size: 1.1rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 25px;
}

.why-card ul li {
    font-size: 0.95rem;
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 500;
}

.light-card ul li i {
    color: #666;
    margin-top: 3px;
}

.dark-card ul li i {
    color: var(--accent);
    margin-top: 3px;
}

.why-footer {
    font-size: 1rem;
    font-weight: 700;
    color: var(--bg-dark);
}

/* Companies Section */
.companies-section {
    padding: 80px 50px;
    text-align: center;
    background-color: var(--bg-dark);
}

.companies-section h2 {
    font-size: 2.5rem;
    font-weight: 800;
}

.companies-section .subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 60px;
}

.companies-carousel-wrapper {
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 60px;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: var(--bg-dark);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 100;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-btn:hover {
    background-color: var(--accent);
    border-color: var(--accent);
    color: var(--bg-dark);
}

.prev-btn { left: 0; }
.next-btn { right: 0; }

.cards-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    height: 450px;
}

.company-card {
    flex: 1;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1), transform 0.4s ease;
    cursor: pointer;
}

.company-card.active {
    flex: 4;
    cursor: default;
}

.company-card:hover:not(.active) {
    transform: translateY(-5px);
}

.card-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 15px;
    z-index: 10;
    text-align: center;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
}

.card-logo {
    font-weight: 800;
    font-size: 1.2rem;
}

.card-logo .opa-logo-img {
    height: 40px;
}

.card-title-small {
    font-size: 0.7rem;
    letter-spacing: 2px;
    font-weight: 600;
}

.card-image-wrapper {
    position: absolute;
    top: 0; 
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.card-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

/* Dim inactive cards */
.company-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2;
    transition: opacity 0.5s ease;
    pointer-events: none;
}
.company-card.active::after {
    opacity: 0;
}

.card-content {
    margin-top: auto;
    position: relative;
    z-index: 3;
    padding: 30px 20px;
    /* Hide content on inactive cards */
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
}

.company-card.active .card-content {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    transition-delay: 0.3s;
}

.card-green .card-content {
    background: linear-gradient(to top, var(--card-green) 40%, rgba(44,76,59,0.8) 80%, transparent);
}
.card-blue .card-content {
    background: linear-gradient(to top, var(--card-blue) 40%, rgba(27,54,93,0.8) 80%, transparent);
}
.card-orange .card-content {
    background: linear-gradient(to top, var(--card-orange) 40%, rgba(200,122,25,0.8) 80%, transparent);
}

.card-content p {
    font-size: 0.9rem;
    margin-bottom: 15px;
    color: rgba(255,255,255,1);
}

.card-features {
    list-style: none;
    margin-bottom: 25px;
    padding: 0;
    text-align: left;
}

.card-features li {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-features li i {
    color: var(--accent);
}

.card-orange .card-features li i {
    color: var(--bg-dark);
}

/* Button Split */
.btn-split {
    display: flex;
    border: 1px solid rgba(255,255,255,0.6);
    border-radius: 50px;
    overflow: hidden;
    width: fit-content;
    margin: 0 auto;
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    position: relative;
    z-index: 20;
}

.btn-split:hover {
    background-color: rgba(255,255,255,0.1);
    border-color: white;
}

.btn-split .btn-text {
    padding: 8px 25px;
    border-right: 1px solid rgba(255,255,255,0.6);
}

.btn-split .btn-icon {
    padding: 8px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-split-dark {
    color: var(--bg-dark);
    border-color: rgba(10,14,23,0.4);
}

.btn-split-dark .btn-text {
    border-color: rgba(10,14,23,0.4);
}

.btn-split-dark:hover {
    background-color: rgba(10,14,23,0.1);
    border-color: var(--bg-dark);
}

/* Projects Section */
.projects-section {
    background-color: var(--bg-darker);
    padding: 80px 50px;
    border-top: 1px solid rgba(255,255,255,0.1);
    position: relative;
    overflow: hidden;
}

/* Decorative circles — projects (dark flat zone) */
.projects-section::before {
    content: '';
    position: absolute;
    top: -90px;
    right: -70px;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: rgba(27,54,93,0.15);
    pointer-events: none;
}
.projects-section::after {
    content: '';
    position: absolute;
    bottom: -80px;
    left: 30px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(251,169,25,0.05);
    pointer-events: none;
}

.opa-logo-projects {
    position: absolute;
    top: 40px;
    left: 50px;
    height: 60px;
    width: auto;
    object-fit: contain;
    z-index: 10;
}

.projects-header {
    text-align: center;
    margin-bottom: 50px;
}

.projects-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 10px;
}

.projects-header p {
    color: var(--text-muted);
}

.projects-grid {
    display: flex;
    gap: 40px;
}

.projects-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.projects-subtitle {
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 25px;
    color: white;
    letter-spacing: 1px;
}

.carousel-container {
    position: relative;
    width: 100%;
    max-width: 500px;
}

.carousel-images {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    gap: 8px;
    height: 350px;
    width: 100%;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.project-slide {
    flex: 1;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
}

.project-slide.active {
    flex: 5;
    cursor: default;
}

.project-slide::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.project-slide.active::after {
    opacity: 0;
}

.project-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tour-badge {
    position: absolute;
    bottom: 80px;
    right: 20px;
    background: rgba(0,0,0,0.7);
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255,255,255,0.3);
    z-index: 5;
}

.carousel-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.nav-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.nav-btn:hover {
    color: var(--accent);
}

/* Investors Section */
.investors-section {
    padding: 100px 50px;
    background: linear-gradient(rgba(10,14,23,0.95), rgba(10,14,23,0.7)), url('../img/hero_bg_hd_architectural.jpg') center/cover;
    text-align: left;
    display: flex;
    align-items: center;
}

.investors-content {
    max-width: 600px;
}

.investors-section h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.1;
}

.investors-subtitle {
    color: #e0e0e0;
    margin-bottom: 35px;
    font-size: 1.1rem;
    max-width: 500px;
}

/* Features Bottom */
.features-section {
    display: flex;
    background-color: var(--text-white);
    color: var(--bg-dark);
    padding: 60px 50px;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 20px;
}

.feature-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    border-right: 1px solid #ddd;
}

.feature-item:last-child {
    border-right: none;
}

.feature-item i {
    font-size: 2.5rem;
    color: var(--card-blue);
    margin-bottom: 15px;
}

.feature-item h4 {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--card-blue);
    margin-bottom: 10px;
}

.feature-item p {
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.4;
    color: #555;
}

/* Footer */
.main-footer {
    background-color: var(--bg-darker);
    padding: 60px 50px 20px;
    border-top: 2px solid var(--theme-accent);
}

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 50px;
}

.footer-brand .logo {
    margin-bottom: 15px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links h4, .footer-contact h4, .footer-social h4 {
    font-size: 1.1rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.links-grid {
    display: flex;
    gap: 40px;
}

.links-grid ul li {
    margin-bottom: 10px;
}

.links-grid ul li a {
    color: var(--text-muted);
    font-size: 0.9rem;
}
.links-grid ul li a:hover {
    color: var(--theme-accent);
}

.footer-contact ul li {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: white;
}

.social-icons a:hover {
    background-color: var(--theme-accent);
    transform: translateY(-3px);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.legal-links a {
    margin-left: 20px;
}
.legal-links a:hover {
    color: white;
}

/* ============================================================
   Responsive
   ============================================================ */

/* ---- Tablet (<=992px) ---- */
@media (max-width: 992px) {
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }

    .hero-content h1 {
        font-size: 3rem;
    }

    .projects-grid {
        flex-direction: column;
        gap: 60px;
    }

    .investors-section h2 {
        font-size: 2rem;
    }

    .why-cards {
        flex-wrap: wrap;
    }

    .why-card {
        flex: 1 1 260px;
    }
}

/* ---- Mobile nav (hamburger) — kicks in before layout starts breaking (<=860px) ---- */
@media (max-width: 860px) {
    .nav-toggle {
        display: block;
        z-index: 1100;
    }

    .main-header {
        padding: 16px 20px;
    }

    .main-header .opa-logo-img {
        height: 55px;
    }

    .logo-label-bottom {
        white-space: normal;
        max-width: 150px;
        font-size: 0.62rem;
        line-height: 1.25;
    }

    .header-action {
        gap: 10px;
    }

    .header-btn {
        padding: 8px 14px !important;
        font-size: 0.75rem;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: 0;
        width: min(320px, 80vw);
        height: 100vh;
        background: var(--bg-darker);
        padding: 100px 30px 30px;
        transform: translateX(100%);
        transition: transform 0.35s ease;
        overflow-y: auto;
        z-index: 1050;
        box-shadow: -10px 0 40px rgba(0,0,0,0.5);
    }

    .main-nav.active {
        transform: translateX(0);
    }

    .main-nav .nav-links {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        width: 100%;
    }

    .main-nav .nav-links > li {
        width: 100%;
    }

    .main-nav .nav-links > li > a {
        display: block;
        padding: 12px 0;
        width: 100%;
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }

    .dropdown-menu {
        position: static;
        display: none;
        opacity: 1;
        transform: none;
        box-shadow: none;
        border-radius: 0;
        border-top: none;
        background: rgba(255,255,255,0.04);
        padding: 4px 0;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-menu li a {
        padding: 10px 16px;
    }
}

/* ---- Mobile (<=768px) ---- */
@media (max-width: 768px) {
    .flow-arrow {
        display: none;
    }

    /* Section paddings */
    .hero-section {
        padding: 0 24px;
    }
    .ecosystem-section,
    .companies-section,
    .projects-section,
    .investors-section,
    .features-section {
        padding: 60px 24px;
    }
    .why-opa-box {
        padding: 30px 20px;
    }

    /* Typography */
    .hero-content h1 {
        font-size: 2.3rem;
    }
    .hero-content p {
        font-size: 1.05rem;
    }
    .ecosystem-section h2,
    .companies-section h2,
    .projects-header h2 {
        font-size: 1.9rem;
    }
    .why-opa-box h2 {
        font-size: 1.5rem;
    }
    .investors-section h2 {
        font-size: 1.7rem;
    }
    .investors-section {
        text-align: center;
        justify-content: center;
    }
    .investors-content {
        margin: 0 auto;
    }

    /* why-cards: stack */
    .why-cards {
        flex-direction: column;
    }

    /* Companies carousel: vertical accordion instead of horizontal squeeze */
    .companies-carousel-wrapper {
        padding: 0;
    }
    .cards-container {
        flex-direction: column;
        height: auto;
        gap: 12px;
    }
    .company-card {
        flex: none;
        min-height: 90px;
        transition: min-height 0.5s ease;
    }
    .company-card.active {
        min-height: 480px;
    }
    .company-card .card-content {
        max-height: 0;
        overflow: hidden;
        padding-top: 0;
        padding-bottom: 0;
        margin-top: 70px;
    }
    .company-card.active .card-content {
        max-height: 1000px;
        padding-top: 30px;
        padding-bottom: 30px;
    }
    .carousel-btn {
        display: none;
    }

    /* Projects: stack columns, project-slide accordion becomes vertical */
    .carousel-images {
        flex-direction: column;
        height: 480px;
    }
    .project-slide {
        flex: 1;
    }
    .project-slide.active {
        flex: 5;
    }

    .main-footer {
        padding: 50px 24px 20px;
    }
    .footer-content {
        grid-template-columns: 1fr;
    }
    .footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    .legal-links a:first-child {
        margin-left: 0;
    }

    /* Projects section logo: static + centered so it doesn't overlap the heading */
    .opa-logo-projects {
        position: static;
        display: block;
        margin: 0 auto 20px;
        height: 44px;
    }

}

/* ---- Small phones (<=480px) ---- */
@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.9rem;
    }
    .flow-container {
        gap: 25px;
    }
    .why-card {
        padding: 28px 20px;
    }
    .whatsapp-float {
        width: 52px;
        height: 52px;
        bottom: 16px;
        right: 16px;
    }
    .whatsapp-float i {
        font-size: 1.6rem;
    }
    .quicknav-fab {
        bottom: 16px;
        left: 16px;
    }
    .quicknav-toggle {
        width: 52px;
        height: 52px;
        font-size: 1.2rem;
    }
    .quicknav-label {
        font-size: 0.78rem;
    }
}

/* ============================
   Contact Section (CRM lead capture)
   ============================ */
.contact-section {
    padding: 100px 50px;
    background-color: var(--bg-darker);
}

.contact-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px;
}

.contact-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 15px;
}

.contact-header p {
    color: var(--text-muted);
    font-size: 1.05rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
    align-items: stretch;
}

.contact-form {
    background-color: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-width: 0;
}

.form-row {
    display: flex;
    gap: 18px;
    min-width: 0;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
    background-color: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--text-white);
    font-family: var(--font-main);
    font-size: 0.95rem;
    width: 100%;
    max-width: 100%;
}

.form-file-input {
    padding: 10px 12px;
    font-size: 0.85rem;
}

.form-group select option {
    background-color: var(--bg-dark);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--theme-accent);
    background-color: rgba(255,255,255,0.08);
}

.form-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.contact-form button[type="submit"] {
    border: none;
    cursor: pointer;
    font-family: var(--font-main);
    align-self: flex-start;
    margin-top: 8px;
}

.contact-form button[type="submit"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.form-status {
    font-size: 0.9rem;
    min-height: 20px;
    font-weight: 600;
}

.form-status.success,
.form-status.error {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 0.95rem;
    animation: form-status-in 0.3s ease;
}

.form-status.success::before,
.form-status.error::before {
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.form-status.success {
    color: var(--theme-accent);
    background-color: rgba(var(--theme-accent-rgb), 0.12);
    border: 1px solid rgba(var(--theme-accent-rgb), 0.35);
}

.form-status.success::before {
    content: '\f058'; /* fa-circle-check */
}

.form-status.error {
    color: #e05555;
    background-color: rgba(224, 85, 85, 0.12);
    border: 1px solid rgba(224, 85, 85, 0.35);
}

.form-status.error::before {
    content: '\f06a'; /* fa-circle-exclamation */
}

@keyframes form-status-in {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

.contact-side {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-info-card {
    background: linear-gradient(135deg, var(--theme-accent), var(--bg-dark));
    border-radius: 16px;
    padding: 32px;
    flex: 1;
}

.contact-info-card h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: #ffffff;
}

.contact-info-card ul {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-info-card ul li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: rgba(255,255,255,0.9);
}

.contact-info-card ul li i {
    color: #ffffff;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

.contact-whatsapp-card {
    background-color: #1ebe57;
    border-radius: 16px;
    padding: 28px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    color: white;
}

.contact-whatsapp-card .whatsapp-icon i {
    font-size: 2.2rem;
}

.contact-whatsapp-card h4 {
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.contact-whatsapp-card p {
    font-size: 0.85rem;
    opacity: 0.9;
    margin-bottom: 14px;
}

.contact-whatsapp-card a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: white;
    color: #1ebe57;
    font-weight: 700;
    padding: 8px 18px;
    border-radius: 50px;
    font-size: 0.9rem;
}

.contact-whatsapp-card a:hover {
    background-color: var(--bg-dark);
    color: white;
}

@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 768px) {
    .contact-section {
        padding: 60px 24px;
    }
    .contact-header h2 {
        font-size: 1.9rem;
    }
    .contact-form {
        padding: 28px 22px;
    }
    .form-row {
        flex-direction: column;
        gap: 18px;
    }
}

/* ============================
   Floating WhatsApp Button
   ============================ */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.35);
    z-index: 2000;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.whatsapp-float i {
    color: white;
    font-size: 2rem;
}

.whatsapp-float:hover {
    transform: scale(1.08);
    background-color: #1ebe57;
}

/* ============================
   Floating Quick Navigation
   ============================ */
.quicknav-fab {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.quicknav-menu {
    display: flex;
    flex-direction: column-reverse;
    gap: 12px;
    margin-bottom: 14px;
    visibility: hidden;
    pointer-events: none;
}

.quicknav-fab.active .quicknav-menu {
    visibility: visible;
    pointer-events: auto;
}

.quicknav-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 18px 8px 8px;
    border-radius: 50px;
    color: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,0.35);
    opacity: 0;
    transform: translateX(-16px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.quicknav-fab.active .quicknav-item {
    opacity: 1;
    transform: translateX(0);
}

.quicknav-item .quicknav-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.quicknav-label {
    font-size: 0.85rem;
    font-weight: 700;
    white-space: nowrap;
}

.quicknav-item.current {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.quicknav-item-inicio { background-color: var(--accent); }
.quicknav-item-constructora { background-color: #25a968; }
.quicknav-item-concept { background-color: #3d72b4; }
.quicknav-item-inmobiliaria { background-color: #c9a227; }
.quicknav-item-nosotros { background-color: #1b365d; }

.quicknav-toggle {
    width: 60px;
    height: 60px;
    border: none;
    border-radius: 50%;
    background-color: var(--accent);
    color: var(--bg-dark);
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.35);
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.quicknav-toggle:hover {
    transform: scale(1.08);
    background-color: var(--accent-hover);
}

.quicknav-fab.active .quicknav-toggle i {
    transform: rotate(90deg);
}

.quicknav-toggle i {
    transition: transform 0.25s ease;
}
