/* Custom CSS Variables */
:root {
    --primary: #AB8B74;
    --dark: #161616;
    --light: #DDD1B9;
    --cream: #F0E8DB;
    --accent: #C1B6A4;
    --secondary: #AB8B74;
}


/* Tailwind Custom Configuration */
@tailwind base;
@tailwind components;
@tailwind utilities;

/* Custom Font Classes */
.font-marisa {
    font-family: 'Marisa', serif;
}

.font-montserrat {
    font-family: 'Montserrat', sans-serif;
}

/* Custom Color Classes */
.text-primary {
    color: var(--primary);
}

.text-dark {
    color: var(--dark);
}

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

.bg-dark {
    background-color: var(--dark);
}

.bg-light {
    background-color: var(--light);
}

.bg-cream {
    background-color: var(--cream);
}

.bg-accent {
    background-color: var(--accent);
}

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

/* Global Styles */
* {
    scroll-behavior: smooth;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    will-change: scroll-position;
}

/* Optimización del scroll para navegadores webkit */
@media screen and (min-width: 768px) {
    html {
        scroll-behavior: auto;
    }
    
    body {
        scroll-behavior: auto;
    }
    
    * {
        scroll-behavior: auto;
    }
}

/* Hero Background */
.hero-bg {
    background-image: url('img/img-docs/img1.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    filter: grayscale(100%);
    z-index: 1;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('img/img-docs/img1.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: grayscale(100%);
    z-index: 0;
}

.hero-bg > * {
    position: relative;
    z-index: 2;
}



.navbar-fixed {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    height: auto !important;
    z-index: 999999 !important;
    background: rgba(255, 255, 255, 0.75) !important;
    backdrop-filter: blur(15px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(15px) saturate(180%) !important;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    transform: translateZ(0) translateY(0) !important;
    will-change: auto !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}


/* Override ANY potential hiding behaviors */
nav, nav *, .navbar-fixed, .navbar-fixed * {
    transform: translateY(0) !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.nav-link {
    @apply text-gray-700 hover:text-primary transition-colors duration-300 font-medium;
}

.mobile-nav-link {
    @apply block w-full px-3 py-2 hover:text-primary transition-colors duration-300 text-center;
    color: var(--primary);
}

/* Button Styles */
.btn-primary {
    @apply inline-flex items-center px-8 py-3 border border-transparent text-base font-medium rounded-full text-white bg-primary hover:bg-opacity-90 transition-all duration-300 shadow-lg hover:shadow-xl transform hover:-translate-y-1;
}

.btn-secondary {
    @apply inline-flex items-center px-8 py-3 border-2 border-primary text-base font-medium rounded-full text-primary hover:bg-primary hover:text-white transition-all duration-300 shadow-lg hover:shadow-xl transform hover:-translate-y-1;
}

/* Service Card Styles */
.service-card {
    @apply bg-white p-8 rounded-2xl shadow-lg hover:shadow-xl transition-all duration-300 text-center transform hover:-translate-y-2;
}

.service-icon {
    @apply w-16 h-16 mx-auto mb-6 bg-gradient-to-br from-primary to-accent rounded-full flex items-center justify-center;
}

.service-icon i {
    @apply text-white text-2xl;
}

/* Contact Button Styles */
.contact-button {
    @apply flex flex-col items-center gap-4 p-8 bg-white rounded-2xl shadow-lg hover:shadow-xl transition-all duration-300 transform hover:-translate-y-2;
}

.contact-icon {
    @apply w-16 h-16 rounded-full flex items-center justify-center transition-all duration-300;
}

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

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

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

/* Hover Effects */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Gradient Backgrounds */
.gradient-primary {
    background: linear-gradient(135deg, var(--primary), var(--accent));
}

.gradient-dark {
    background: linear-gradient(135deg, var(--dark), var(--primary));
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .service-card {
        padding: 1.5rem;
    }
    
    .contact-button {
        padding: 1.5rem;
    }

    #mobile-menu {
        flex-direction: column;
        align-items: center;
    }
    
    #mobile-menu .px-2 {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .mobile-nav-link {
        margin: 0.25rem 0;
        width: 100%;
        text-align: center;
    }

      
    .hover-underline::after,
    .hover-underline::before {
        content: '';
        position: absolute;
        width: 100%;
        height: 2px;
        background: linear-gradient(to right, #ff0000, #00ffff);
        bottom: -5px;
        left: 0;
        transform: scaleX(0);
        transform-origin: right;
        transition: transform 0.4s ease-out;
    }
      
    .hover-underline::before {
        top: -5px;
        transform-origin: left;
    }
      
    .hover-underline:hover::after,
    .hover-underline:hover::before {
        transform: scaleX(1);
    }
}

/* Presentation Page Mobile Specific */
@media (max-width: 430px) {
    #presentation .text-center {
        padding: 1rem;
        max-width: 100%;
    }
    
    #presentation h1 {
        font-size: 2rem !important;
        line-height: 1.1;
        word-break: break-word;
        hyphens: auto;
    }
    
    #presentation img {
        width: 20rem !important;
        height: 20rem !important;
        margin-bottom: 1rem !important;
    }
}

@media (min-width: 431px) and (max-width: 640px) {
    #presentation h1 {
        font-size: 2.5rem !important;
    }
    
    #presentation img {
        width: 24rem !important;
        height: 24rem !important;
    }
}

/* Extra responsive adjustments */
@media (max-width: 320px) {
    #presentation h1 {
        font-size: 1.75rem !important;
        padding: 0 0.5rem;
    }
    
    #presentation img {
        width: 18rem !important;
        height: 18rem !important;
    }
}

/* Ensure no horizontal overflow */
body, html {
    overflow-x: hidden !important;
    max-width: 100vw;
}

#presentation {
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

/* Video styling for nosotras section */
.video-container video {
    object-fit: cover;
    transform: scale(0.85);
}

/* Video mobile width adjustments */
@media (max-width: 1023px) {
    .video-container {
        margin-left: -1rem;
        margin-right: -1rem;
        width: calc(100% + 2rem);
    }
}

@media (max-width: 767px) {
    .video-container {
        margin-left: -2rem;
        margin-right: -2rem;
        width: calc(100% + 4rem);
    }
}

@media (max-width: 640px) {
    .video-container {
        margin-left: -1rem;
        margin-right: -1rem;
        width: calc(100% + 2rem);
    }
}

/* Custom Video Overlay Styling */
.play-button-container {
    position: relative;
}

.play-button {
    display: flex;
    align-items: center;
    justify-center: center;
    width: 80px;
    height: 80px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    transform: scale(1);
}

.play-button:hover {
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
}

.play-button i {
    transform: translateX(2px); /* Slight offset for visual balance */
}

#video-overlay {
    backdrop-filter: blur(2px);
    transition: all 0.3s ease;
}

/* Video title styling */
#video-overlay h3 {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    letter-spacing: 0.05em;
    line-height: 1.2;
}

.hover-underline {
    position: relative;
    display: inline-block;
  }
  
  .hover-underline::after,
  .hover-underline::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, #AB8B74, #DDD1B9);
    bottom: -5px;
    left: 0;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s ease-out;
  }
  
  .hover-underline::before {
    top: -5px;
    transform-origin: left;
  }
  
  .hover-underline:hover::after,
  .hover-underline:hover::before {
    transform: scaleX(1);
  }

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* Loading Animation */
.loading {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.loading.loaded {
    opacity: 1;
    transform: translateY(0);
}

/* Language Switcher Styles */
.language-btn {
    @apply px-3 py-1 text-sm font-medium text-gray-600 hover:text-primary transition-colors duration-300 cursor-pointer;
}

.language-btn.active {
    @apply text-primary font-semibold;
}

.language-btn:hover {
    @apply text-primary;
}

/* Focus States for Accessibility */
.nav-link:focus,
.btn-primary:focus,
.btn-secondary:focus,
.contact-button:focus,
.language-btn:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Presentation Page Animations */
.tracking-in-expand-fwd {
    -webkit-animation: tracking-in-expand-fwd 1.5s cubic-bezier(0.165, 0.840, 0.440, 1.000) both;
            animation: tracking-in-expand-fwd 1.5s cubic-bezier(0.165, 0.840, 0.440, 1.000) both;
}

@-webkit-keyframes tracking-in-expand-fwd {
  0% {
    letter-spacing: -0.5em;
    -webkit-transform: translateZ(-700px);
            transform: translateZ(-700px);
    opacity: 0;
  }
  40% {
    opacity: 0.6;
  }
  100% {
    -webkit-transform: translateZ(0);
            transform: translateZ(0);
    opacity: 1;
  }
}

@keyframes tracking-in-expand-fwd {
  0% {
    letter-spacing: -0.5em;
    -webkit-transform: translateZ(-700px);
            transform: translateZ(-700px);
    opacity: 0;
  }
  40% {
    opacity: 0.6;
  }
  100% {
    -webkit-transform: translateZ(0);
            transform: translateZ(0);
    opacity: 1;
  }
}

.animate-fade-in {
    animation: fadeIn 1s ease-in-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Print Styles */
@media print {
    .no-print {
        display: none !important;
    }
}