/* ========================================
   Custom Styles - Ingrid Breve Landing Page
   ======================================== */

/* Fonts */
.font-playfair {
    font-family: 'Playfair Display', serif;
}

.font-poppins {
    font-family: 'Poppins', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Smooth Scrolling for Anchor Links */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* Navigation Animations */
.nav-link {
    position: relative;
    display: inline-block;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: #e68da5;
    transition: width 0.3s ease;
}

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

/* CTA Button Pulse Animation */
@keyframes pulse-shadow {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(225, 29, 72, 0.7);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(225, 29, 72, 0);
    }
}

.cta-button {
    animation: pulse-shadow 2s infinite;
}

/* Service Cards Hover Effect */
.service-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-8px);
}

/* Gallery Item Hover Effect */
.gallery-item {
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.05);
}

/* WhatsApp Float Button Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

#whatsapp-float {
    animation: float 3s ease-in-out infinite;
}

#whatsapp-float:hover {
    animation: none;
}

/* Social Icons Hover */
.social-icon {
    transition: transform 0.3s ease, color 0.3s ease;
}

.social-icon:hover {
    transform: scale(1.2) rotate(5deg);
}

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Classe inicial para elementos que serão animados */
.animate-fade-in {
    opacity: 0;
}

/* Animação aplicada quando elemento entra no viewport */
.fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

/* Loading States for Images */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.3s;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #e68da5 0%, #907e8e 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #e68da5;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #907e8e;
}

/* Mobile Menu Transition */
#mobile-menu {
    transition: max-height 0.3s ease-in-out, opacity 0.3s ease-in-out;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

#mobile-menu.active {
    max-height: 500px;
    opacity: 1;
}

/* Section Padding Adjustments */
section {
    scroll-margin-top: 80px;
}

/* Performance Optimizations */
.will-change-transform {
    will-change: transform;
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Styles for Accessibility */
a:focus,
button:focus {
    outline: 2px solid #e68da5;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    header,
    #whatsapp-float,
    .cta-button,
    footer {
        display: none;
    }

    body {
        font-size: 12pt;
        color: #000;
        background: #fff;
    }
}

/* Responsive Typography */
@media (max-width: 640px) {
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.25rem;
    }
}

/* Dark Mode Support (Future Enhancement) */
@media (prefers-color-scheme: dark) {
    /* Uncomment when implementing dark mode
    body {
        background-color: #111827;
        color: #f3f4f6;
    }
    */
}

/* Loading Spinner for Future Use */
.spinner {
    border: 3px solid rgba(225, 29, 72, 0.1);
    border-top: 3px solid #e68da5;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Placeholder Shimmer Effect */
.shimmer {
    background: linear-gradient(
        90deg,
        rgba(225, 29, 72, 0.05) 0%,
        rgba(225, 29, 72, 0.15) 50%,
        rgba(225, 29, 72, 0.05) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Image Aspect Ratio Containers */
.aspect-ratio-16-9 {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
}

.aspect-ratio-4-3 {
    position: relative;
    padding-bottom: 75%; /* 4:3 aspect ratio */
}

.aspect-ratio-1-1 {
    position: relative;
    padding-bottom: 100%; /* 1:1 aspect ratio */
}

.aspect-ratio-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Smooth Transitions */
a, button, .transition {
    transition: all 0.3s ease;
}

/* Selection Color */
::selection {
    background-color: #e68da5;
    color: white;
}

::-moz-selection {
    background-color: #e68da5;
    color: white;
}

/* ========================================
   Services Carousel Styles
   ======================================== */

/* Carousel Track - Grid Layout with Horizontal Scrolling */
.services-carousel-track {
    display: grid;
    grid-template-rows: repeat(2, auto); /* Default: 2 rows for tablet/desktop */
    grid-auto-flow: column;
    gap: 2rem;
    transition: transform 0.5s ease-in-out;
    will-change: transform;
    width: max-content;
}

/* Responsive Grid Layouts - Define column widths based on viewport */
/* Desktop: 3 columns visible, each card width is calculated from container */
@media (min-width: 1024px) {
    #services-carousel-wrapper {
        max-width: 1152px; /* Tailwind max-w-6xl */
        margin: 0 auto;
    }

    .services-carousel-track .service-card {
        width: calc((1152px - 4rem) / 3);
        min-width: calc((1152px - 4rem) / 3);
    }
}

/* Tablet: 2 columns visible */
@media (min-width: 768px) and (max-width: 1023px) {
    #services-carousel-wrapper {
        max-width: 768px;
        margin: 0 auto;
    }

    .services-carousel-track .service-card {
        width: calc((768px - 2rem) / 2);
        min-width: calc((768px - 2rem) / 2);
    }
}

/* Mobile: 1 column visible, 1 row (1 card at a time) */
@media (max-width: 767px) {
    #services-carousel-wrapper {
        max-width: calc(100vw - 2rem);
        margin: 0 auto;
    }

    .services-carousel-track {
        grid-template-rows: repeat(1, auto); /* Mobile: only 1 row */
    }

    .services-carousel-track .service-card {
        width: calc(100vw - 2rem);
        min-width: calc(100vw - 2rem);
    }
}

/* Carousel Indicators */
.carousel-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #d1d5db;
    transition: all 0.3s ease;
    cursor: pointer;
}

.carousel-indicator:hover {
    background-color: #9ca3af;
    transform: scale(1.2);
}

.carousel-indicator.active {
    background-color: #e68da5;
    width: 24px;
    border-radius: 5px;
}

/* Navigation Button Hover Effects */
#services-prev,
#services-next {
    transform: translateY(-50%);
}

#services-prev:hover,
#services-next:hover {
    transform: translateY(-50%);
    background-color: #db6e8e; /* rosa-500 */
    box-shadow: 0 10px 25px rgba(230, 141, 165, 0.5);
}

#services-prev:active,
#services-next:active {
    transform: translateY(-50%);
    background-color: #c95275; /* rosa-600 */
}

/* Disable button state */
#services-prev:disabled,
#services-next:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#services-prev:disabled:hover,
#services-next:disabled:hover {
    transform: translateY(-50%);
    background-color: #e68da5; /* volta para rosa-400 */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
