
/* =====================================================
   AGROBRUNTEK
   Hoja de estilos principal
   ===================================================== */


/* =====================================================
   1. VARIABLES Y CONFIGURACIÓN GENERAL
   ===================================================== */

:root {
    --agro-primary: #003049;
    --agro-dark: #001f33;
    --agro-accent: #3d7895;
    --agro-light: #e5eef3;

    --agro-text: #243b4a;
    --agro-muted: #687d89;
    --agro-border: #dce6eb;
    --agro-bg: #f3f7f9;
    --agro-white: #ffffff;

    --agro-radius: 14px;
    --agro-shadow: 0 8px 28px rgba(0, 31, 51, .08);
    --agro-transition: all .25s ease;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    color: var(--agro-text);
    background: var(--agro-white);
    font-size: 15px;
    line-height: 1.7;
}

img {
    max-width: 100%;
}

a {
    text-decoration: none;
    transition: var(--agro-transition);
}

section {
    scroll-margin-top: 85px;
}


/* =====================================================
   2. BARRA SUPERIOR
   ===================================================== */

.topbar {
    background: var(--agro-dark);
    color: rgba(255, 255, 255, .85);
    font-size: 12px;
    padding: 8px 0;
}

.topbar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.topbar-content i {
    color: #a8c9da;
    margin-right: 5px;
}

.topbar-contact {
    display: flex;
    align-items: center;
    gap: 22px;
}

.topbar-contact a {
    color: rgba(255, 255, 255, .85);
}

.topbar-contact a:hover {
    color: #ffffff;
}


/* =====================================================
   3. MENÚ PRINCIPAL
   ===================================================== */

.main-navbar {
    background: #ffffff;
    min-height: 82px;
    padding: 10px 0;
    box-shadow: 0 3px 15px rgba(0, 31, 51, .07);
    position: relative;
    z-index: 100;
}

.brand {
    display: flex;
    align-items: center;
    padding: 0;
    margin: 0;
}

.brand-logo {
    display: block;
    width: auto;
    height: 54px;
    max-width: 110px;
    object-fit: contain;
}

.main-navbar .navbar-nav {
    gap: 5px;
}

.main-navbar .nav-link {
    color: var(--agro-text);
    font-size: 13px;
    font-weight: 600;
    padding: 12px 14px !important;
}

.main-navbar .nav-link:hover,
.main-navbar .nav-link.active {
    color: var(--agro-primary);
}

.main-navbar .nav-link.active {
    font-weight: 800;
}

.navbar-toggler {
    border: 1px solid var(--agro-border);
    padding: 7px 10px;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 3px rgba(0, 48, 73, .12);
}

.btn-navbar {
    background: var(--agro-primary);
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    padding: 10px 21px;
    border-radius: 30px;
}

.btn-navbar:hover {
    background: var(--agro-dark);
    color: #ffffff;
    transform: translateY(-2px);
}


/* =====================================================
   4. CARRUSEL PRINCIPAL
   ===================================================== */

.main-carousel {
    width: 100%;
    overflow: hidden;
    background: var(--agro-dark);
}

#agroCarousel {
    position: relative;
}

#agroCarousel .carousel-item {
    position: relative;
    isolation: isolate;
    height: 470px;
    background: var(--agro-dark);
}

#agroCarousel .carousel-item > img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Capa oscura para mejorar la lectura */

#agroCarousel .carousel-item::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(0, 31, 51, .94) 0%,
        rgba(0, 48, 73, .82) 48%,
        rgba(0, 48, 73, .42) 100%
    );
}

/* Textos del carrusel */

#agroCarousel .carousel-caption {
    position: absolute;
    z-index: 2;
    top: 50%;
    bottom: auto;
    left: 12%;
    right: 12%;
    transform: translateY(-50%);
    padding: 20px 0 30px;
    text-align: left;
    color: #ffffff;
}

.hero-kicker {
    display: block;
    color: #c5e1ef;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    margin-bottom: 14px;
}

#agroCarousel .carousel-caption h1 {
    color: #ffffff;
    font-size: clamp(34px, 4vw, 52px);
    font-weight: 800;
    line-height: 1.15;
    max-width: 750px;
    margin: 0 0 18px;
    text-shadow: 0 3px 12px rgba(0, 0, 0, .55);
}

#agroCarousel .carousel-caption h1 span {
    display: block;
    color: #b8d9e9;
}

#agroCarousel .carousel-caption p {
    color: #ffffff;
    max-width: 570px;
    font-size: 15px;
    line-height: 1.8;
    margin-bottom: 25px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .7);
}

/* Botones del carrusel */

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.btn-carousel-primary {
    background: var(--agro-primary);
    border: 2px solid var(--agro-primary);
    color: #ffffff;
    font-weight: 700;
    font-size: 13px;
    padding: 12px 23px;
    transition: var(--agro-transition);
}

.btn-carousel-primary:hover {
    background: var(--agro-dark);
    border-color: #ffffff;
    color: #ffffff;
    transform: translateY(-2px);
}

.btn-carousel-contact {
    background: #ffffff;
    border: 2px solid #ffffff;
    color: var(--agro-primary);
    font-weight: 800;
    font-size: 13px;
    padding: 12px 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, .25);
    transition: var(--agro-transition);
}

.btn-carousel-contact i {
    color: var(--agro-primary);
}

.btn-carousel-contact:hover {
    background: var(--agro-light);
    border-color: var(--agro-light);
    color: var(--agro-dark);
    transform: translateY(-2px);
}

/* Controles */

#agroCarousel .carousel-control-prev,
#agroCarousel .carousel-control-next {
    z-index: 3;
    width: 8%;
}

#agroCarousel .carousel-control-prev-icon,
#agroCarousel .carousel-control-next-icon {
    background-color: var(--agro-primary);
    border-radius: 50%;
    background-size: 55%;
    width: 42px;
    height: 42px;
}

#agroCarousel .carousel-indicators {
    z-index: 4;
}

#agroCarousel .carousel-indicators button {
    width: 28px;
    height: 4px;
    border: 0;
    border-radius: 5px;
}


/* =====================================================
   5. SECCIONES GENERALES
   ===================================================== */

.section-padding {
    padding: 85px 0;
}

.section-heading {
    max-width: 720px;
    margin: 0 auto 48px;
}

.section-kicker {
    display: inline-block;
    color: var(--agro-accent);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.section-heading h2,
.section-title {
    color: var(--agro-primary);
    font-size: clamp(27px, 3vw, 36px);
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 15px;
}

.section-heading h2 span,
.section-title span {
    color: var(--agro-accent);
}

.section-heading p {
    color: var(--agro-muted);
    font-size: 14px;
    margin: 0;
}


/* =====================================================
   6. SERVICIOS
   ===================================================== */

.services-section {
    background: var(--agro-bg);
}

.service-card {
    height: 100%;
    background: #ffffff;
    border: 1px solid var(--agro-border);
    border-radius: var(--agro-radius);
    padding: 30px 25px;
    transition: var(--agro-transition);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--agro-shadow);
    border-color: #b8d0dd;
}

.service-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    border-radius: 13px;
    background: var(--agro-light);
    color: var(--agro-primary);
    font-size: 25px;
    margin-bottom: 22px;
}

.service-card h3 {
    color: var(--agro-primary);
    font-size: 17px;
    font-weight: 800;
    margin-bottom: 12px;
}

.service-card p {
    color: var(--agro-muted);
    font-size: 13px;
    line-height: 1.8;
    margin: 0;
}


/* =====================================================
   7. NOSOTROS
   ===================================================== */

.about-section {
    background: #ffffff;
}

.about-image {
    position: relative;
    border-radius: var(--agro-radius);
    overflow: hidden;
    box-shadow: var(--agro-shadow);
}

.about-image img {
    display: block;
    width: 100%;
    height: 390px;
    object-fit: cover;
}

.about-image-label {
    position: absolute;
    left: 20px;
    bottom: 20px;
    background: #ffffff;
    color: var(--agro-primary);
    border-radius: 30px;
    padding: 10px 18px;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(0, 0, 0, .15);
}

.about-image-label i {
    color: var(--agro-accent);
    margin-right: 5px;
}

.about-section p {
    color: var(--agro-muted);
    font-size: 14px;
    line-height: 1.9;
    margin-bottom: 16px;
}

.btn-primary-agro {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--agro-primary);
    color: #ffffff;
    border: 2px solid var(--agro-primary);
    padding: 12px 24px;
    font-size: 13px;
    font-weight: 700;
    transition: var(--agro-transition);
}

.btn-primary-agro:hover {
    background: var(--agro-dark);
    border-color: var(--agro-dark);
    color: #ffffff;
    transform: translateY(-2px);
}


/* =====================================================
   8. PROYECTOS
   ===================================================== */

.projects-section {
    background: var(--agro-bg);
}

.project-card {
    position: relative;
    height: 300px;
    overflow: hidden;
    border-radius: var(--agro-radius);
    background: var(--agro-dark);
    box-shadow: var(--agro-shadow);
}

.project-card img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s ease;
}

.project-card:hover img {
    transform: scale(1.06);
}

.project-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0, 31, 51, .92),
        transparent 70%
    );
}

.project-card-content {
    position: absolute;
    z-index: 2;
    left: 22px;
    right: 22px;
    bottom: 22px;
    color: #ffffff;
}

.project-card-content span {
    display: block;
    color: #b8d9e9;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.project-card-content h3 {
    color: #ffffff;
    font-size: 19px;
    font-weight: 800;
    margin: 0;
}


/* =====================================================
   9. CONTACTO
   ===================================================== */

.contact-section {
    background: #ffffff;
}

.contact-info {
    padding: 15px 10px 15px 0;
}

.contact-info h3 {
    color: var(--agro-primary);
    font-size: 23px;
    font-weight: 800;
    margin-bottom: 12px;
}

.contact-info > p {
    color: var(--agro-muted);
    font-size: 14px;
    margin-bottom: 30px;
}

.contact-info-item {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--agro-text);
    margin-bottom: 23px;
}

.contact-info-item:hover {
    color: var(--agro-accent);
}

.contact-info-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    border-radius: 12px;
    background: var(--agro-light);
    color: var(--agro-primary);
    font-size: 21px;
}

.contact-info-item small {
    display: block;
    color: var(--agro-muted);
    font-size: 11px;
    margin-bottom: 2px;
}

.contact-info-item strong {
    display: block;
    color: var(--agro-primary);
    font-size: 14px;
    font-weight: 700;
}

.contact-form {
    background: var(--agro-bg);
    border: 1px solid var(--agro-border);
    border-radius: var(--agro-radius);
    padding: 32px;
}

.contact-form .form-label {
    color: var(--agro-primary);
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 7px;
}

.contact-form .form-control,
.contact-form .form-select {
    min-height: 46px;
    border: 1px solid var(--agro-border);
    border-radius: 8px;
    background-color: #ffffff;
    color: var(--agro-text);
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    padding: 11px 13px;
}

.contact-form textarea.form-control {
    min-height: 115px;
    resize: vertical;
}

.contact-form .form-control:focus,
.contact-form .form-select:focus {
    border-color: var(--agro-accent);
    box-shadow: 0 0 0 3px rgba(61, 120, 149, .12);
}

.contact-form .btn-primary-agro {
    min-height: 48px;
}


/* =====================================================
   10. MAPA
   ===================================================== */

.location-section {
    background: var(--agro-bg);
    padding: 75px 0;
}

.location-section .section-heading {
    margin-bottom: 30px;
}

.map-container {
    overflow: hidden;
    border-radius: var(--agro-radius);
    border: 1px solid var(--agro-border);
    box-shadow: var(--agro-shadow);
    background: #ffffff;
}

.map-container iframe {
    display: block;
    width: 100%;
    border: 0;
}


/* =====================================================
   11. FOOTER
   ===================================================== */

.main-footer {
    background: var(--agro-dark);
    color: rgba(255, 255, 255, .75);
    padding: 55px 0 20px;
}

.footer-logo {
    display: block;
    max-width: 135px;
    max-height: 85px;
    object-fit: contain;
    margin-bottom: 18px;
}

.main-footer h4 {
    color: #ffffff;
    font-size: 15px;
    font-weight: 800;
    margin-bottom: 18px;
}

.main-footer p {
    color: rgba(255, 255, 255, .68);
    font-size: 13px;
    line-height: 1.8;
}

.main-footer ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.main-footer ul li {
    margin-bottom: 10px;
}

.main-footer ul a {
    color: rgba(255, 255, 255, .72);
    font-size: 13px;
}

.main-footer ul a:hover {
    color: #ffffff;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .13);
    margin-top: 35px;
    padding-top: 18px;
    text-align: center;
}

.footer-bottom p {
    margin: 0;
    font-size: 11px;
}


/* =====================================================
   12. BOTÓN FLOTANTE WHATSAPP
   ===================================================== */

.whatsapp-float {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #25d366;
    color: #ffffff;
    font-size: 29px;
    box-shadow: 0 5px 18px rgba(0, 0, 0, .2);
    transition: var(--agro-transition);
}

.whatsapp-float:hover {
    color: #ffffff;
    background: #1ebc59;
    transform: translateY(-4px);
}


/* =====================================================
   13. RESPONSIVE - TABLETS
   ===================================================== */

@media (max-width: 991px) {

    .main-navbar .navbar-collapse {
        padding: 15px 0 8px;
    }

    .main-navbar .navbar-nav {
        align-items: stretch !important;
        gap: 0;
    }

    .main-navbar .nav-link {
        padding: 10px 5px !important;
    }

    .main-navbar .nav-item.ms-lg-3 {
        margin: 10px 0 0 !important;
    }

    .btn-navbar {
        display: inline-block;
        text-align: center;
    }

    #agroCarousel .carousel-item {
        height: 410px;
    }

    #agroCarousel .carousel-caption {
        left: 10%;
        right: 10%;
    }

    #agroCarousel .carousel-caption h1 {
        font-size: 38px;
    }

    .section-padding {
        padding: 70px 0;
    }

    .about-image img {
        height: 350px;
    }
}


/* =====================================================
   14. RESPONSIVE - CELULARES
   ===================================================== */

@media (max-width: 575px) {

    html {
        scroll-padding-top: 70px;
    }

    .topbar {
        padding: 7px 0;
        font-size: 10px;
    }

    .topbar-content {
        justify-content: center;
        flex-wrap: wrap;
        gap: 4px;
    }

    .topbar-contact {
        display: none;
    }

    .main-navbar {
        min-height: 68px;
        padding: 8px 0;
    }

    .brand-logo {
        height: 48px;
        max-width: 90px;
    }

    .main-navbar .navbar-collapse {
        padding-top: 12px;
    }

    #agroCarousel .carousel-item {
        height: 400px;
    }

    #agroCarousel .carousel-item > img {
        object-position: center;
    }

    #agroCarousel .carousel-item::before {
        background: linear-gradient(
            90deg,
            rgba(0, 31, 51, .96),
            rgba(0, 48, 73, .82)
        );
    }

    #agroCarousel .carousel-caption {
        left: 9%;
        right: 9%;
        padding: 10px 0 28px;
    }

    .hero-kicker {
        font-size: 9px;
        letter-spacing: 1.2px;
        margin-bottom: 10px;
    }

    #agroCarousel .carousel-caption h1 {
        font-size: 29px;
        line-height: 1.2;
        margin-bottom: 13px;
    }

    #agroCarousel .carousel-caption p {
        font-size: 12px;
        line-height: 1.6;
        margin-bottom: 17px;
    }

    .hero-actions {
        gap: 8px;
    }

    .btn-carousel-primary,
    .btn-carousel-contact {
        padding: 10px 13px;
        font-size: 11px;
    }

    #agroCarousel .carousel-control-prev,
    #agroCarousel .carousel-control-next {
        width: 7%;
    }

    #agroCarousel .carousel-control-prev-icon,
    #agroCarousel .carousel-control-next-icon {
        width: 28px;
        height: 28px;
    }

    .section-padding {
        padding: 58px 0;
    }

    .section-heading {
        margin-bottom: 32px;
    }

    .section-heading h2,
    .section-title {
        font-size: 27px;
    }

    .service-card {
        padding: 25px 22px;
    }

    .about-image img {
        height: 260px;
    }

    .project-card {
        height: 260px;
    }

    .contact-form {
        padding: 22px 17px;
    }

    .contact-info {
        padding: 0;
    }

    .location-section {
        padding: 55px 0;
    }

    .map-container iframe {
        height: 300px;
    }

    .whatsapp-float {
        width: 50px;
        height: 50px;
        right: 15px;
        bottom: 15px;
        font-size: 25px;
    }
}


/* =====================================================
   15. ACCESIBILIDAD Y MOVIMIENTO
   ===================================================== */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: .01ms !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
    }
}
