/********** Ganamarca - Razas Puras | Template CSS **********/
:root {
    --primary: #1B4332;
    --primary-light: #2D6A4F;
    --secondary: #D4A017;
    --secondary-light: #E8C547;
    --light: #FAFAF5;
    --dark: #1C150D;
    --accent: #8B6914;
    --white: #FFFFFF;
    --gray: #6B7280;
    --gray-light: #E5E7EB;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--dark);
    background: var(--light);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Libre Baskerville', serif;
    color: var(--dark);
}

.back-to-top {
    position: fixed;
    display: none;
    right: 30px;
    bottom: 30px;
    z-index: 99;
    animation: floatBtn 3s ease-in-out infinite;
}

@keyframes floatBtn {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.fw-bold { font-weight: 700 !important; }
.fw-medium { font-weight: 600 !important; }
.fw-semi-bold { font-weight: 500 !important; }

/*** Spinner ***/
#spinner {
    opacity: 0;
    visibility: hidden;
    transition: opacity .5s ease-out, visibility 0s linear .5s;
    z-index: 99999;
}

#spinner.show {
    transition: opacity .5s ease-out, visibility 0s linear 0s;
    visibility: visible;
    opacity: 1;
}

#spinner .spinner-border {
    border-color: var(--secondary);
    border-right-color: transparent;
}

/*** Button ***/
.btn {
    transition: all .4s ease;
    font-weight: 600;
    letter-spacing: 0.3px;
    position: relative;
    overflow: hidden;
}

.btn-primary,
.btn-outline-primary:hover {
    color: var(--light);
    background: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(27, 67, 50, 0.3);
}

.btn-secondary,
.btn-outline-secondary:hover {
    color: var(--dark);
    background: var(--secondary);
    border-color: var(--secondary);
}

.btn-secondary:hover {
    background: var(--secondary-light);
    border-color: var(--secondary-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 160, 23, 0.35);
}

.btn-square {
    width: 38px;
    height: 38px;
}

.btn-sm-square { width: 32px; height: 32px; }
.btn-lg-square { width: 48px; height: 48px; }

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: normal;
}

/*** Topbar ***/
.topbar {
    background: var(--dark) !important;
    font-size: 14px;
}

.topbar .btn-link {
    transition: all .3s ease;
}

.topbar .btn-link:hover {
    color: var(--secondary) !important;
    transform: scale(1.15);
}

.topbar .bg-secondary-custom {
    background: var(--secondary);
}

/*** Navbar ***/
.navbar {
    transition: all .4s ease;
    background: rgba(255, 255, 255, 0.97) !important;
    backdrop-filter: blur(10px);
}

.navbar.sticky-top {
    top: -100px;
    transition: .5s;
}

.navbar.shadow-sm {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08) !important;
}

.navbar.navbar-scrolled {
    box-shadow: 0 4px 20px rgba(27, 67, 50, 0.15) !important;
    transition: box-shadow 0.3s ease;
}

.navbar .navbar-brand h1 {
    font-family: 'Libre Baskerville', serif;
    font-size: 2rem;
    color: var(--primary);
    letter-spacing: -0.5px;
    transition: all .3s ease;
}

.navbar .navbar-brand h1:hover {
    color: var(--secondary);
}

.navbar .navbar-brand h1 span {
    color: var(--secondary);
}

.navbar .navbar-nav .nav-link {
    margin-right: 30px;
    padding: 25px 0;
    color: var(--dark);
    font-size: 16px;
    font-weight: 600;
    outline: none;
    position: relative;
    transition: all .3s ease;
}

.navbar .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 18px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--secondary);
    transition: width .3s ease;
}

.navbar .navbar-nav .nav-link:hover::after,
.navbar .navbar-nav .nav-link.active::after {
    width: 100%;
}

.navbar .navbar-nav .nav-link:hover,
.navbar .navbar-nav .nav-link.active {
    color: var(--primary);
}

.navbar .dropdown-toggle::after {
    border: none;
    content: "\f107";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    vertical-align: middle;
    margin-left: 8px;
}

.navbar .dropdown-menu {
    border: none;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.navbar .dropdown-item {
    font-weight: 500;
    padding: 10px 20px;
    transition: all .3s ease;
}

.navbar .dropdown-item:hover {
    background: var(--primary);
    color: var(--light);
}

@media (max-width: 991.98px) {
    .navbar .navbar-nav .nav-link {
        margin-right: 0;
        padding: 10px 0;
    }
    .navbar .navbar-nav {
        border-top: 1px solid var(--gray-light);
    }
    .navbar .navbar-nav .nav-link::after {
        bottom: 6px;
    }
}

@media (min-width: 992px) {
    .navbar .nav-item .dropdown-menu {
        display: block;
        border: none;
        margin-top: 0;
        top: 150%;
        opacity: 0;
        visibility: hidden;
        transition: .4s ease;
    }
    .navbar .nav-item:hover .dropdown-menu {
        top: 100%;
        visibility: visible;
        opacity: 1;
    }
}

/*** Carousel / Hero ***/
.carousel-caption {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(27, 67, 50, 0.65) 0%, rgba(28, 21, 13, 0.5) 100%);
    z-index: 1;
}

.carousel-item img {
    filter: brightness(0.8);
    transition: transform 8s ease;
}

.carousel-item.active img {
    transform: scale(1.05);
}

.carousel-control-prev,
.carousel-control-next {
    width: 8%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 3.2rem;
    height: 3.2rem;
    border-radius: 50%;
    background-color: var(--secondary);
    border: 4px solid var(--secondary);
    transition: all .3s ease;
}

.carousel-control-prev-icon:hover,
.carousel-control-next-icon:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    transform: scale(1.1);
}

@media (max-width: 768px) {
    #header-carousel .carousel-item {
        position: relative;
        min-height: 400px;
    }
    #header-carousel .carousel-item img {
        position: absolute;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

/*** Page Header ***/
.page-header {
    background: linear-gradient(135deg, rgba(27, 67, 50, 0.85) 0%, rgba(28, 21, 13, 0.7) 100%),
                url(../img/banner.jpg) center center no-repeat;
    background-size: cover;
    position: relative;
}

.page-header .breadcrumb-item+.breadcrumb-item::before {
    color: var(--secondary);
}

.page-header .breadcrumb-item,
.page-header .breadcrumb-item a {
    font-size: 18px;
    color: var(--light);
    transition: color .3s ease;
}

.page-header .breadcrumb-item a:hover {
    color: var(--secondary);
}

.page-header .breadcrumb-item.active {
    color: var(--secondary);
}

/*** Section Title ***/
.section-title {
    position: relative;
    display: inline-block;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    font-size: 14px;
    color: var(--primary) !important;
}

.section-title::before {
    position: absolute;
    content: "";
    width: calc(100% + 80px);
    height: 2px;
    top: 5px;
    left: -40px;
    background: var(--secondary);
    z-index: -1;
}

.section-title::after {
    position: absolute;
    content: "";
    width: calc(100% + 120px);
    height: 2px;
    bottom: 6px;
    left: -60px;
    background: var(--secondary);
    z-index: -1;
}

.section-title.text-start::before {
    width: calc(100% + 40px);
    left: 0;
}

.section-title.text-start::after {
    width: calc(100% + 60px);
    left: 0;
}

/*** About ***/
.about-experience {
    position: absolute;
    width: 100%;
    height: 100%;
    right: -35px;
    bottom: -35px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--secondary), var(--accent)) !important;
    transition: transform .3s ease;
}

.about-experience:hover {
    transform: translate(-3px, -3px);
}

.about-experience h1 {
    color: var(--dark);
}

/*** Service ***/
.service-item {
    position: relative;
    border-radius: 12px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.06);
    transition: transform .3s ease, box-shadow .3s ease;
}

.service-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
}

.service-item .service-img {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 12px;
    overflow: hidden;
    z-index: -1;
}

.service-item .service-img img {
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    object-fit: cover;
    border-radius: 12px;
}

.service-item .service-img::before {
    position: absolute;
    content: "";
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 12px;
    z-index: 1;
}

.service-item .service-img::after {
    position: absolute;
    content: "";
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: var(--light);
    transition: .5s ease-out;
    z-index: 2;
}

.service-item:hover .service-img::after {
    width: 0;
    left: auto;
    right: 0;
}

.service-item .service-text .service-icon {
    width: 130px;
    height: 130px;
    padding: 12px;
    margin-top: -65px;
    margin-bottom: 35px;
    background: var(--white);
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 5px 40px rgba(0, 0, 0, 0.1);
}

.service-item .service-text h5,
.service-item .service-text p {
    transition: .5s;
}

.service-item:hover .service-text h5,
.service-item:hover .service-text p {
    color: var(--light);
}

.service-item .service-text .btn {
    color: var(--dark);
    background: var(--white);
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.15);
    transition: all .3s ease;
}

.service-item .service-text .btn:hover {
    color: var(--dark);
    background: var(--secondary);
    transform: scale(1.1);
}

/*** Product ***/
.product-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.06);
    transition: transform .3s ease, box-shadow .3s ease;
}

.product-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
}

.product-item .product-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(27, 67, 50, 0.85), rgba(139, 105, 20, 0.7));
    opacity: 0;
    padding-top: 60px;
    transition: .5s;
}

.product-item:hover .product-overlay {
    opacity: 1;
    padding-top: 0;
}

.product-item .product-overlay .btn {
    transition: all .3s ease;
}

.product-item .product-overlay .btn:hover {
    transform: scale(1.15);
    background: var(--secondary-light) !important;
}

/*** Team ***/
.team-item {
    position: relative;
    text-align: center;
    border-radius: 12px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.06);
    transition: transform .3s ease, box-shadow .3s ease;
    background: var(--white);
}

.team-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
}

.team-item img {
    transition: transform .4s ease;
    border-radius: 10px;
}

.team-item:hover img {
    transform: scale(1.03);
}

.team-item .btn {
    border-color: var(--gray-light);
    transition: all .3s ease;
}

.team-item .btn:hover {
    background: var(--primary);
    color: var(--light);
    border-color: var(--primary);
    transform: translateY(-3px);
}

/*** Testimonial ***/
.testimonial-img {
    position: relative;
    min-height: 400px;
}

.testimonial-img::after {
    position: absolute;
    content: "\f10d";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    font-size: 200px;
    color: rgba(139, 105, 20, 0.08);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
}

.testimonial-img img {
    position: absolute;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--secondary);
    transition: transform .3s ease;
}

.testimonial-img img:hover {
    transform: scale(1.15);
    z-index: 2;
}

.testimonial-img img:nth-child(1) { top: 0; left: 0; }
.testimonial-img img:nth-child(2) { top: 60%; left: 20%; }
.testimonial-img img:nth-child(3) { top: 20%; left: 60%; }
.testimonial-img img:nth-child(4) { bottom: 0; right: 0; }

.testimonial-img img.animated.pulse {
    animation-duration: 2s;
}

.testimonial-carousel .owl-item img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--secondary);
}

.testimonial-carousel .owl-nav {
    margin-top: 30px;
    display: flex;
}

.testimonial-carousel .owl-nav .owl-prev,
.testimonial-carousel .owl-nav .owl-next {
    margin-right: 15px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--dark);
    background: var(--secondary);
    border-radius: 50%;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    font-size: 22px;
    transition: .3s;
}

.testimonial-carousel .owl-nav .owl-prev:hover,
.testimonial-carousel .owl-nav .owl-next:hover {
    background: var(--primary);
    color: var(--light);
    transform: scale(1.1);
}

/*** Banner / Parallax ***/
.banner {
    background: linear-gradient(135deg, rgba(27, 67, 50, 0.85), rgba(28, 21, 13, 0.7));
    position: relative;
    overflow: hidden;
}

.banner::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(212, 160, 23, 0.1);
    top: -100px;
    right: -100px;
}

.banner::after {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: rgba(212, 160, 23, 0.08);
    bottom: -50px;
    left: -50px;
}

.banner .btn {
    position: relative;
    z-index: 1;
}

/*** Features / Stats ***/
.feature-stat-box {
    transition: transform .3s ease;
}

.feature-stat-box:hover {
    transform: translateY(-5px);
}

.bg-primary {
    background-color: var(--primary) !important;
}

.bg-secondary {
    background-color: var(--secondary) !important;
}

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

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

/*** Gallery ***/
.gallery-item {
    position: relative;
    overflow: hidden;
}

.gallery-item img {
    transition: transform .5s ease, filter .5s ease;
}

.gallery-item:hover img {
    transform: scale(1.08);
    filter: brightness(0.85);
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 60%, rgba(27, 67, 50, 0.4));
    opacity: 0;
    transition: opacity .4s ease;
}

.gallery-item:hover::after {
    opacity: 1;
}

/*** WhatsApp Float Button ***/
.whatsapp-float {
    position: fixed;
    bottom: 90px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    z-index: 99;
    box-shadow: 0 5px 25px rgba(37, 211, 102, 0.4);
    transition: all .3s ease;
    animation: floatWp 3s ease-in-out infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 35px rgba(37, 211, 102, 0.5);
    color: var(--white);
}

@keyframes floatWp {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/*** Footer ***/
.footer {
    background: var(--dark) !important;
    color: #A09890;
}

.footer h5 {
    position: relative;
    padding-bottom: 12px;
}

.footer h5::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--secondary);
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: #A09890;
    font-weight: normal;
    text-transform: capitalize;
    transition: .3s;
}

.footer .btn.btn-link::before {
    position: relative;
    content: "\f105";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 10px;
}

.footer .btn.btn-link:hover {
    color: var(--secondary);
    padding-left: 5px;
}

/*** Copyright ***/
.copyright {
    background: var(--secondary) !important;
    color: var(--dark) !important;
}

.copyright a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
}

/*** Contact ***/
.contact-icon-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--dark);
}

.form-floating input,
.form-floating textarea {
    border: 2px solid var(--gray-light);
    border-radius: 10px;
    transition: all .3s ease;
}

.form-floating input:focus,
.form-floating textarea:focus {
    border-color: var(--secondary);
    box-shadow: 0 0 0 0.2rem rgba(212, 160, 23, 0.15);
}

/*** Animations ***/
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-on-scroll {
    opacity: 0;
}

.animate-on-scroll.visible {
    animation: fadeInUp 0.8s ease forwards;
}

/*** Stats Counter Section ***/
.stat-card {
    background: var(--white);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.05);
    transition: transform .3s ease, box-shadow .3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.1);
}

.stat-card .stat-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--secondary);
}

.stat-card .stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary);
    font-family: 'Libre Baskerville', serif;
}

/*** CTA Section ***/
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 16px;
    padding: 3rem 2rem;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: rgba(212, 160, 23, 0.08);
    border-radius: 50%;
    top: -150px;
    right: -100px;
}

.cta-section .btn {
    position: relative;
    z-index: 1;
}

/*** Responsive ***/
@media (max-width: 768px) {
    .carousel-caption h1 {
        font-size: 2rem !important;
    }
    
    .carousel-caption p {
        font-size: 1rem !important;
    }
    
    .whatsapp-float {
        bottom: 70px;
        right: 15px;
        width: 50px;
        height: 50px;
        font-size: 24px;
    }
}
