/* 
 * Front Page Styles
 * Color variables exist in style.css
 */

/* General Typography & Spacing */
body .section-subtitle {
    display: block;
    font-family: var(--font-primary);
    color: var(--color-accent);
    font-size: 14px;
    letter-spacing: 3px;
    font-weight: 600;
    margin-bottom: 15px;
    text-transform: uppercase;
}

body .section-title {
    font-family: var(--font-secondary) !important;
    font-size: 2.8rem !important;
    font-weight: 400 !important;
    line-height: 1.2 !important;
    margin-bottom: 0;
    color: var(--color-text);
}

/* SECTION 1: HERO */
.section-hero {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    color: #fff;
    overflow: hidden;
}

.hero-slider {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
}

.hero-slide {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s ease-in-out, visibility 1s ease-in-out;
    display: flex;
    align-items: center;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 0;
    transform: scale(1.05);
    transition: transform 10s ease-out;
}

.hero-slide.active .hero-bg {
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(90deg, rgba(17,17,16,0.9) 0%, rgba(17,17,16,0.4) 50%, rgba(17,17,16,0.1) 100%);
    z-index: 1;
}

.hero-indicators {
    position: absolute;
    left: 40px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.hero-indicators .indicator {
    background: transparent;
    border: none;
    outline: none;
    font-family: inherit;
    padding: 0;
    color: rgba(255,255,255,0.3);
    font-size: 12px;
    position: relative;
    padding-left: 20px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.hero-indicators .indicator::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 1px;
    background-color: rgba(255,255,255,0.3);
    transition: width 0.3s ease, background-color 0.3s ease;
}

.hero-indicators .indicator.active {
    color: var(--color-accent);
}

.hero-indicators .indicator.active::before {
    width: 15px;
    background-color: var(--color-accent);
}

.hero-content-wrapper {
    position: relative;
    z-index: 3;
    padding-left: 100px; /* space for indicators */
    width: 100%;
}

.hero-content {
    max-width: 600px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease 0.4s, transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1) 0.4s;
}

.hero-slide.active .hero-content {
    opacity: 1;
    transform: translateY(0);
}

body .hero-title {
    font-family: var(--font-secondary) !important;
    font-size: 4rem !important;
    font-weight: 300 !important;
    line-height: 1.1 !important;
    margin-bottom: 20px;
    color: var(--color-text);
}

body .hero-title .highlight {
    color: var(--color-accent);
    font-weight: 600;
}

body .hero-subtitle {
    font-family: var(--font-secondary) !important;
    font-size: 1.15rem !important;
    color: var(--color-text-muted);
    margin-bottom: 40px;
    font-weight: 300 !important;
    line-height: 1.6 !important;
}

.hero-actions {
    display: flex;
    gap: 20px;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    color: var(--color-text);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 12px 24px;
    font-family: var(--font-primary);
    font-weight: 500;
    font-size: 14px;
    letter-spacing: 1px;
    transition: all var(--transition-speed) ease;
}

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

.btn-secondary .icon-plus {
    margin-left: 8px;
    border: 1px solid currentColor;
    border-radius: 50%;
    width: 18px; height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.scroll-indicator-wrapper {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: rgba(255,255,255,0.4);
    font-size: 10px;
    letter-spacing: 2px;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background-color: rgba(255,255,255,0.2);
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

.scroll-line::before {
    content: '';
    position: absolute;
    top: -100%; left: 0; width: 100%; height: 100%;
    background-color: var(--color-text);
    animation: scrollDown 2s infinite ease-in-out;
}

@keyframes scrollDown {
    0% { top: -100%; }
    100% { top: 100%; }
}

/* SECTION 2: SERVICIOS */
.section-servicios {
    padding: 100px 0;
    background-color: var(--color-bg);
}

.servicios-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 60px;
}

.servicios-header .sh-left { flex: 0 0 50%; }
.servicios-header .sh-right { flex: 0 0 40%; }
.servicios-header .sh-right p {
    color: var(--color-text-muted);
    font-size: 15px;
    margin: 0;
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    border-top: 1px solid rgba(255,255,255,0.05);
    border-left: 1px solid rgba(255,255,255,0.05);
}

.servicio-card {
    grid-column: span 1;
    border-right: 1px solid rgba(255,255,255,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding: 40px 20px;
    position: relative;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    background-color: transparent;
    overflow: hidden;
}

.servicio-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at center, rgba(212,175,55,0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.servicio-card:hover {
    background-color: #1a1a19;
    transform: translateY(-5px);
    border-color: rgba(212, 175, 55, 0.3);
    box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    z-index: 2;
}

.servicio-card:hover::before {
    opacity: 1;
}

.servicio-card > * {
    position: relative;
    z-index: 1;
}

.srv-icon {
    color: var(--color-accent);
    margin-bottom: 30px;
    transition: transform 0.4s ease;
}
.servicio-card:hover .srv-icon {
    transform: scale(1.1) translateY(-5px);
}
.srv-icon svg { width: 32px; height: 32px; }

body .servicio-card h3 {
    font-size: 1.5rem !important;
    font-weight: 500 !important;
    margin-bottom: 15px;
    line-height: 1.3 !important;
    color: var(--color-text);
}
.servicio-card:hover h3 {
    color: var(--color-accent);
}

body .servicio-card p {
    font-size: 15px;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 20px;
}

.srv-plus {
    position: absolute;
    bottom: 20px; right: 20px;
    color: var(--color-accent);
    font-size: 24px;
    font-weight: 300;
    transition: all 0.4s ease;
}
.servicio-card:hover .srv-plus {
    transform: rotate(90deg) scale(1.2);
}

/* Fix grid to 6 columns if space allows, or 3 on smaller screens */
@media(min-width: 1025px) {
    .servicio-card { padding: 40px 15px; }
}
@media(max-width: 1024px) {
    .servicios-grid { grid-template-columns: repeat(3, 1fr); }
    .servicio-card { grid-column: span 1; }
}

/* SECTION 3: PROYECTOS DESTACADOS */
.section-proyectos {
    padding: 100px 0;
    background-color: #151514;
    overflow: hidden;
}

.proyectos-layout {
    display: flex;
    align-items: center;
    gap: 50px;
}

.proyectos-info {
    flex: 0 0 300px;
}

.link-arrow {
    display: inline-flex;
    align-items: center;
    color: var(--color-accent);
    font-size: 13px;
    letter-spacing: 1px;
    font-weight: 500;
    transition: all 0.3s ease;
}
.link-arrow .arrow-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px; height: 24px;
    border-radius: 50%;
    border: 1px solid var(--color-accent);
    margin-left: 10px;
    transition: transform 0.3s ease;
}
.link-arrow:hover {
    color: #fff;
}
.link-arrow:hover .arrow-circle {
    transform: translateX(5px);
    background-color: var(--color-accent);
    color: #111;
}

.proyectos-slider-container {
    flex: 1;
    position: relative;
}

.slider-controls {
    position: absolute;
    top: -60px; right: 0;
    display: flex; gap: 10px;
}
.slider-controls button {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 36px; height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}
.slider-controls button:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.proyectos-track {
    display: flex;
    gap: 20px;
    transition: transform 0.5s ease;
}

.proyecto-slide {
    flex: 0 0 400px;
    position: relative;
    cursor: pointer;
    overflow: hidden; /* for image zoom */
    border-radius: 4px;
}

.ps-img {
    width: 100%; height: 300px;
    background-size: cover;
    background-position: center;
    filter: brightness(0.6);
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    transform: scale(1);
}

.proyecto-slide:hover .ps-img {
    filter: brightness(0.9);
    transform: scale(1.05);
}

.ps-content {
    position: absolute;
    bottom: 20px; left: 20px; right: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-end;
    z-index: 2;
}

body .ps-content h3 {
    width: 100%;
    font-size: 1.5rem !important;
    margin-bottom: 10px;
    font-weight: 500 !important;
    color: var(--color-text);
    transition: transform 0.3s ease;
}

body .ps-content p {
    font-size: 14px;
    color: var(--color-text-muted);
    margin: 0;
    line-height: 1.6;
    transition: transform 0.3s ease;
}

.proyecto-slide:hover .ps-content h3,
.proyecto-slide:hover .ps-content p {
    transform: translateY(-5px);
}

.ps-arrow {
    color: var(--color-accent);
    border: 1px solid var(--color-accent);
    border-radius: 50%;
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    transition: all 0.3s ease;
}

.proyecto-slide:hover .ps-arrow {
    background-color: var(--color-accent);
    color: #111;
    transform: translateX(5px);
}

/* SECTION 4: SIMULACIÓN */
.section-simulacion {
    padding: 100px 0;
}

.simulacion-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
}
.simulacion-header .sh-left { flex: 0 0 50%; }
.simulacion-header .sh-right { flex: 0 0 40%; color: var(--color-text-muted); font-size: 15px; }

.ba-slider-wrapper {
    position: relative;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    height: 500px;
    overflow: hidden;
    user-select: none;
}

.ba-slider {
    position: relative;
    width: 100%;
    height: 100%;
}

.ba-img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
}

.ba-before {
    width: 50%; /* initial state */
    border-right: 2px solid var(--color-accent);
    z-index: 2;
}

.ba-label {
    position: absolute;
    top: 20px;
    padding: 5px 15px;
    background-color: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 12px;
    letter-spacing: 1px;
}
.label-before { left: 20px; }
.label-after { right: 20px; }

.ba-handle {
    position: absolute;
    top: 0; left: 50%;
    width: 40px; height: 100%;
    margin-left: -20px;
    z-index: 3;
    cursor: ew-resize;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ba-handle-arrows {
    width: 40px; height: 40px;
    background-color: var(--color-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: space-around;
    color: #111;
    font-weight: bold;
    font-size: 12px;
    padding: 0 5px;
}

.simulacion-tabs {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.tab-btn {
    background: none;
    border: none;
    color: var(--color-text-muted);
    font-size: 12px;
    letter-spacing: 1px;
    padding: 15px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn:hover, .tab-btn.active {
    color: var(--color-accent);
    border-bottom-color: var(--color-accent);
}

/* SECTION 5: NUESTRO PROCESO */
.section-proceso {
    padding: 100px 0;
    background-color: #151514;
}

.proceso-title-area {
    margin-bottom: 60px;
}

.proceso-timeline {
    position: relative;
    display: flex;
    justify-content: space-between;
}

.timeline-line {
    position: absolute;
    top: 25px; left: 5%; right: 5%;
    height: 1px;
    background-color: rgba(255,255,255,0.1);
    z-index: 1;
}

.tl-step {
    position: relative;
    z-index: 2;
    flex: 1;
    text-align: center;
    padding: 0 10px;
}

.tl-number {
    width: 50px; height: 50px;
    margin: 0 auto 20px;
    background-color: #151514;
    border: 1px solid var(--color-accent);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: var(--color-accent);
    font-family: var(--font-primary);
    font-size: 18px;
}

body .tl-step h3 {
    font-size: 1.5rem !important;
    font-weight: 500 !important;
    margin-bottom: 15px;
    color: var(--color-text);
}

body .tl-step p {
    font-size: 13px;
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* SECTION 6: POR QUÉ ELEGIR PDI */
.section-por-que {
    padding: 100px 0;
}

.pq-layout {
    display: flex;
    gap: 50px;
}

.pq-title {
    flex: 0 0 300px;
}

.pq-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.pq-item {
    text-align: left;
    padding: 20px;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.pq-item:hover {
    background-color: rgba(255,255,255,0.02);
    border-color: rgba(212,175,55,0.2);
    transform: translateY(-5px);
}

.pq-icon {
    color: var(--color-accent);
    margin-bottom: 20px;
    transition: transform 0.3s ease;
}

.pq-item:hover .pq-icon {
    transform: scale(1.15) rotate(5deg);
    filter: drop-shadow(0 0 8px rgba(212,175,55,0.5));
}

.pq-item h3 {
    font-size: 16px;
    margin-bottom: 10px;
}

.pq-item p {
    font-size: 13px;
    color: var(--color-text-muted);
    line-height: 1.5;
}

/* SECTION 7: ARQUITECTOS */
.section-arquitectos {
    padding: 100px 0;
    background-color: #151514;
}

.arq-layout {
    display: flex;
    align-items: center;
    gap: 40px;
}

.arq-text {
    flex: 0 0 30%;
}

.arq-images {
    flex: 0 0 40%;
    display: flex;
    gap: 15px;
    height: 400px;
}

.arq-img-1, .arq-img-2 {
    width: 50%;
    object-fit: cover;
    opacity: 0.8;
}

.arq-img-2 {
    margin-top: 40px;
}

.arq-benefits {
    flex: 0 0 30%;
    padding-left: 20px;
}

.arq-benefits p {
    color: var(--color-text-muted);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.benefit-list {
    list-style: none;
    padding: 0; margin: 0;
}

.benefit-list li {
    display: flex;
    align-items: center;
    font-size: 14px;
    margin-bottom: 15px;
}

.benefit-list .check {
    color: var(--color-accent);
    margin-right: 15px;
    font-size: 16px;
}

/* SECTION 8: TESTIMONIOS */
.section-testimonios {
    padding: 100px 0;
}

.test-layout {
    display: flex;
    align-items: center;
    gap: 50px;
}

.test-title-area {
    flex: 0 0 250px;
}

.test-slider-wrapper {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.test-track {
    display: flex;
    gap: 30px;
    transition: transform 0.4s ease;
}

.test-card {
    flex: 0 0 350px;
    background-color: rgba(255,255,255,0.02);
    padding: 30px;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.test-card:hover {
    background-color: rgba(255,255,255,0.04);
    border-color: rgba(212,175,55,0.3);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.test-card .quote {
    font-size: 14px;
    color: #ccc;
    font-style: italic;
    line-height: 1.6;
    margin-bottom: 20px;
}

.author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author img {
    width: 50px; height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.author h4 {
    margin: 0;
    font-size: 14px;
    color: #fff;
}

.author span {
    font-size: 12px;
    color: var(--color-text-muted);
}

.test-controls {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.test-controls button {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 36px; height: 36px;
    border-radius: 50%;
    cursor: pointer;
}
.test-controls button:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

/* RESPONSIVE FIXES */
@media(max-width: 1024px) {
    .servicios-header, .simulacion-header, .proyectos-layout, .pq-layout, .arq-layout, .test-layout {
        flex-direction: column;
        align-items: flex-start;
    }
    .proyectos-slider-container { width: 100%; overflow: hidden; margin-top: 40px; }
    .slider-controls { top: -40px; }
    .proceso-timeline { flex-direction: column; gap: 40px; }
    .timeline-line { display: none; }
    .pq-grid { grid-template-columns: repeat(2, 1fr); }
    .arq-images { width: 100%; }
}
@media(max-width: 768px) {
    .hero-title { font-size: 42px; }
    .hero-content-wrapper { padding-left: 0; text-align: center; }
    .hero-indicators { display: none; }
    .hero-actions { justify-content: center; }
    .servicios-grid { grid-template-columns: 1fr; }
    .pq-grid { grid-template-columns: 1fr; }
    .arq-images { flex-direction: column; height: auto; }
    .arq-img-1, .arq-img-2 { width: 100%; margin-top: 0; }
    .ba-slider-wrapper { height: 300px; }
}
