/* Main Styles for De.or Website */

:root {
    --primary: #1a1a1a;
    --secondary: #e2c8a0;
    --accent: #8b5a2b;
    --light: #f9f9f9;
    --dark: #121212;
    --gray: #6e6e6e;
}

/* Base Styles */
body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--light);
    color: var(--primary);
    overflow-x: hidden;
    scroll-behavior: smooth;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', serif;
}

.text-secondary-500 {
    color: var(--secondary);
}

.bg-secondary-500 {
    background-color: var(--secondary);
}

.bg-secondary-600 {
    background-color: #c9b08e;
}

.border-secondary-500 {
    border-color: var(--secondary);
}

.hover\:bg-secondary-500:hover {
    background-color: var(--secondary);
}

.hover\:bg-secondary-600:hover {
    background-color: #c9b08e;
}

.hover\:text-secondary-500:hover {
    color: var(--secondary);
}

/* Navigation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--secondary);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Hero Section con Slider */
.hero {
    height: 100vh;
    min-height: 600px;
    position: relative;
    overflow: hidden;
}

/* Hero slider container */
.hero-slider {
    z-index: 1;
}

/* Singola slide */
.hero-slide {
    background-size: cover;
    background-position: center;
    transition: opacity 1s ease-in-out;
}

/* Effetto parallax solo su desktop */
@media (min-width: 768px) {
    .hero-slide {
        background-attachment: fixed;
    }
}

/* Contenuto hero */
.hero-content {
    z-index: 10;
    position: relative;
}

/* Controlli dello slider */
.slider-controls {
    z-index: 20;
}

.slider-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background-color: #fff;
    transform: scale(1.2);
}

.slider-dot:hover {
    transform: scale(1.3);
    background-color: rgba(255, 255, 255, 0.8);
}

/* Effetto glow per il titolo */
.glow {
    text-shadow: 0 0 10px rgba(226, 200, 160, 0.7);
}

/* Projects */
.project-card {
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    perspective: 1000px;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 14px 28px rgba(0,0,0,0.25), 0 10px 10px rgba(0,0,0,0.22);
}

.project-card-inner {
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.project-card:hover .project-card-inner {
    transform: rotateY(10deg);
}

/* Forms */
input:focus, textarea:focus, select:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--secondary);
}

/* Language Selector */
.language-selector button:focus + .language-dropdown,
.language-dropdown:hover {
    display: block;
}

.language-selector-mobile button:focus + .language-dropdown-mobile,
.language-dropdown-mobile:hover {
    display: block;
}

/* Custom Shape Divider - RIPRISTINATO ALLA VERSIONE ORIGINALE */
.custom-shape-divider-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg);
}

.custom-shape-divider-bottom svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 150px;
}

.custom-shape-divider-bottom .shape-fill {
    fill: #FFFFFF;
}

/* Mobile Menu Toggle */
.menu-toggle {
    transition: all 0.3s ease;
}

.menu-toggle.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.bar {
    transition: all 0.3s ease;
}

/* Parallax */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Back to top button */
#back-to-top {
    transition: all 0.3s ease;
}

#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Form success/error messages */
.form-message {
    transition: all 0.3s ease;
    max-height: 0;
    overflow: hidden;
}

.form-message.visible {
    max-height: 60px;
    margin-bottom: 16px;
}

/* Animazione freccia che rimbalza */
.bounce {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    40% {
        transform: translateY(-10px) translateX(-50%);
    }
    60% {
        transform: translateY(-5px) translateX(-50%);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .parallax {
        background-attachment: scroll;
    }
    
    .hero-slide {
        background-attachment: scroll;
    }
}

/* Animations for De.or Website */
/* Slide-in animation */
.slide-in {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease-out;
}
.slide-in.active {
    opacity: 1;
    transform: translateY(0);
}
/* Fade-in animation */
.fade-in {
    opacity: 0;
    transition: opacity 0.8s ease;
}
.fade-in.active {
    opacity: 1;
}
/* Scale animation */
.scale-in {
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.8s ease;
}
.scale-in.active {
    opacity: 1;
    transform: scale(1);
}
/* Left slide-in animation */
.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s ease-out;
}
.slide-in-left.active {
    opacity: 1;
    transform: translateX(0);
}
/* Right slide-in animation */
.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s ease-out;
}
.slide-in-right.active {
    opacity: 1;
    transform: translateX(0);
}
/* Floating animation */
.floating {
    animation: floating 6s ease-in-out infinite;
}
@keyframes floating {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}
/* Gentle pulse animation */
.pulse {
    animation: pulse 3s ease-in-out infinite;
}
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}
/* Rotating animation */
.rotate {
    animation: rotate 10s linear infinite;
}
@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
/* Shimmer effect for elements */
.shimmer {
    position: relative;
    overflow: hidden;
}
.shimmer::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(30deg);
    animation: shimmer 3s infinite;
    pointer-events: none;
}
@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(30deg); }
    100% { transform: translateX(100%) rotate(30deg); }
}
/* Staggered animations for children elements */
.stagger-children > * {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}
.stagger-children.active > *:nth-child(1) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.1s;
}
.stagger-children.active > *:nth-child(2) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.2s;
}
.stagger-children.active > *:nth-child(3) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s;
}
.stagger-children.active > *:nth-child(4) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.4s;
}
.stagger-children.active > *:nth-child(5) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.5s;
}
.stagger-children.active > *:nth-child(6) {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.6s;
}
/* Page transitions */
.page-transition {
    opacity: 0;
    transition: opacity 0.5s ease;
}
.page-transition.loaded {
    opacity: 1;
}

.logo-hover {
    transition: transform 0.3s ease, filter 0.3s ease;
}

.logo-hover:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Stile per la maniglia del visualizzatore Prima/Dopo */
image-compare-viewer {
    --divider-width: 3px;
    --divider-color: #e2c8a0; /* Colore oro del brand */
    --handle-background-color: #e2c8a0;
    --handle-color: #1a1a1a;
}