/* --- VARIABILI & SETUP WARM MINIMALIST --- */
:root {
    --bg-base: #F9F8F6; /* Bianco caldo/Panna delle pareti */
    --bg-surface: #FFFFFF; /* Bianco puro per staccare i box */
    --accent-main: #C4A47C; /* Legno chiaro/Sabbia */
    --accent-hover: #A88A62; /* Legno leggermente più scuro */
    --text-main: #4A4238; /* Grigio scuro/Marrone caldo per i testi */
    --text-muted: #8A8175; /* Testo secondario */
    --border-color: #E8E3DD; /* Bordi delicati */
    --font-titles: 'Oswald', sans-serif;
    --font-text: 'Montserrat', sans-serif;
    --trans-fast: 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-text);
    overflow-x: hidden;
    line-height: 1.6;
}

h1, h2, h3, h4 {
    font-family: var(--font-titles);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-main);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--trans-fast);
}

img {
    width: 100%;
    display: block;
    object-fit: cover;
}

/* --- CLASSI DI ANIMAZIONE SCROLL --- */
.reveal-up {
    opacity: 0;
    transform: translateY(30px); /* Ridotto per maggiore eleganza */
    transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.reveal-right {
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.reveal-up.active, .reveal-left.active, .reveal-right.active {
    opacity: 1;
    transform: translate(0);
}

/* --- BOTTONI ELEGANTI (Mantenute le classi originali) --- */
.btn-aggr {
    display: inline-block;
    padding: 15px 40px;
    background: var(--accent-main);
    color: #ffffff;
    font-family: var(--font-titles);
    font-size: 1.1rem;
    border: none;
    border-radius: 30px; /* Bordo arrotondato moderno */
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: var(--trans-fast);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(196, 164, 124, 0.3);
}

.btn-aggr:hover {
    background: var(--accent-hover);
    color: #ffffff;
    box-shadow: 0 6px 20px rgba(168, 138, 98, 0.4);
    transform: translateY(-2px);
}

.btn-aggr-small {
    padding: 10px 25px;
    background: #ffffff;
    color: var(--text-main);
    font-family: var(--font-titles);
    text-transform: uppercase;
    font-weight: 600;
    border-radius: 20px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.btn-aggr-small:hover {
    background: var(--accent-main);
    color: #ffffff;
}

/* --- HEADER --- */
header {
    position: fixed;
    width: 100%;
    padding: 25px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: var(--trans-fast);
    border-bottom: 1px solid transparent;
}

header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    padding: 15px 5%;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 20px rgba(0,0,0,0.03);
}

/* Colore logo base (su immagini scure) e scrolled (su bianco) */
.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
header.scrolled .logo {
    color: var(--text-main);
    text-shadow: none;
}

.logo span {
    color: var(--accent-main);
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
    font-family: var(--font-titles);
    letter-spacing: 1px;
    color: #ffffff;
}

header.scrolled .nav-links {
    color: var(--text-main);
}

.nav-links a:hover {
    color: var(--accent-main);
}

.lang-switch {
    display: flex;
    gap: 15px;
    border-left: 1px solid rgba(255,255,255,0.3);
    padding-left: 20px;
}
header.scrolled .lang-switch {
    border-left: 1px solid var(--border-color);
}

.lang-switch a {
    color: inherit;
    font-weight: 600;
    opacity: 0.7;
}

.lang-switch a.active, .lang-switch a:hover {
    color: var(--accent-main);
    opacity: 1;
}

.hamburger {
    display: none;
    font-size: 2rem;
    color: #ffffff;
    cursor: pointer;
}
header.scrolled .hamburger {
    color: var(--text-main);
}

/* Menu Mobile */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bg-surface);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 40px;
    z-index: 999;
    transform: translateY(-100%);
    transition: 0.5s cubic-bezier(0.77, 0, 0.175, 1);
}

.mobile-menu.active {
    transform: translateY(0);
}

.mobile-menu a {
    font-family: var(--font-titles);
    font-size: 2.2rem;
    color: var(--text-main);
}
.mobile-menu a:hover {
    color: var(--accent-main);
}

/* --- HERO HOME --- */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    padding: 0 5%;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://images.winalist.com/blog/wp-content/uploads/2024/09/25074400/shutterstock_2498491287-1500x1000.jpg') center/cover;
    filter: brightness(0.7); /* Schiarito rispetto al 0.3 originale */
    z-index: -1;
    animation: zoomBg 20s infinite alternate;
}

@keyframes zoomBg {
    from { transform: scale(1); }
    to { transform: scale(1.05); }
}

.hero-content {
    max-width: 800px;
    color: #ffffff;
}

.hero-content .subtitle {
    color: var(--accent-main);
    font-family: var(--font-titles);
    letter-spacing: 3px;
    margin-bottom: 15px;
    font-size: 1.1rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.hero-content h1 {
    font-size: clamp(2.5rem, 7vw, 5rem);
    margin-bottom: 35px;
    text-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    color: #ffffff;
}

/* --- PAGE HEADERS --- */
.page-header {
    height: 50vh; /* Leggermente ridotto per eleganza */
    display: flex;
    align-items: center;
    justify-content: center;
    background-position: center;
    background-size: cover;
    position: relative;
}

.header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.6), rgba(0,0,0,0.2));
}

.page-header h1 {
    position: relative;
    z-index: 1;
    font-size: 3.5rem;
    color: #ffffff;
    text-shadow: 0 3px 10px rgba(0,0,0,0.3);
    letter-spacing: 2px;
}

/* --- LAYOUTS CONDIVISI --- */
.section-pad {
    padding: 90px 5%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.sec-title {
    font-size: 2.5rem;
    color: var(--text-main);
    margin-bottom: 40px;
    text-align: center;
}

/* Override classi inline dei file PHP */
.sec-title[style*="border-left"] {
    border-left: 3px solid var(--accent-main) !important;
}
p[style*="color: var(--text-muted)"] {
    color: var(--text-muted) !important;
}

/* Grid Appartamenti Home */
.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.app-card {
    background: var(--bg-surface);
    border-radius: 8px; /* Bordi morbidi */
    overflow: hidden;
    transition: var(--trans-fast);
    box-shadow: 0 10px 30px rgba(0,0,0,0.04); /* Ombra pulita */
    border: 1px solid var(--border-color);
}

.app-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.app-img-wrap {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.app-img-wrap img {
    height: 100%;
    transition: 0.6s ease;
}

.app-card:hover .app-img-wrap img {
    transform: scale(1.05);
}

.app-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--trans-fast);
}

.app-card:hover .app-overlay {
    opacity: 1;
}

.app-info {
    padding: 25px;
    text-align: center;
}

.app-info h3 {
    color: var(--text-main);
    font-size: 1.5rem;
    margin-bottom: 10px;
}
.app-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Split Grid */
.split-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.amenities-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 30px;
}

.am-item {
    background: var(--bg-surface);
    padding: 15px 20px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    font-weight: 500;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 10px;
}

.am-item i {
    color: var(--accent-main);
    font-size: 1.2rem;
}

/* Box Dintorni / Info Appartamento */
.nearby-box {
    background: var(--bg-surface) !important;
    color: var(--text-main) !important;
    padding: 40px;
    border-radius: 8px;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

.nearby-box h3 {
    margin-bottom: 25px;
    font-size: 1.5rem;
    color: var(--accent-main) !important;
}

.nearby-box ul li {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    font-weight: 500;
    font-size: 1.05rem;
    border-bottom: 1px solid var(--border-color) !important;
    padding-bottom: 15px;
    color: var(--text-main);
}

.nearby-box ul li span {
    background: var(--bg-base);
    color: var(--accent-main);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.1rem;
}

/* Galleria Masonry */
.gallery-masonry {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
}

.gal-item {
    overflow: hidden;
    border-radius: 6px;
    height: 250px;
}

.gal-item img {
    height: 100%;
    transition: 0.5s;
    cursor: zoom-in;
}

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

/* Contatti */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info-list a, .contact-info-list p {
    display: flex;
    align-items: center;
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 20px;
    font-family: var(--font-text);
    transition: var(--trans-fast);
}

.contact-info-list a:hover {
    color: var(--accent-main);
}

.contact-info-list i {
    color: var(--accent-main);
    font-size: 1.3rem;
    width: 35px;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    padding: 15px 20px;
    margin-bottom: 20px;
    font-family: var(--font-text);
    font-size: 1rem;
    border-radius: 4px;
    transition: var(--trans-fast);
}

.contact-form input:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-main);
    box-shadow: 0 0 0 3px rgba(196, 164, 124, 0.1);
}

/* --- GRIGLIA PERCHE' SCEGLIERCI --- */
.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.why-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 40px 30px;
    text-align: center;
    transition: var(--trans-fast);
    box-shadow: 0 5px 15px rgba(0,0,0,0.02);
}

.why-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-main);
    box-shadow: 0 10px 25px rgba(196, 164, 124, 0.1);
}

.why-card i {
    font-size: 2.5rem;
    color: var(--accent-main);
    margin-bottom: 20px;
}

.why-card h4 {
    color: var(--text-main);
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.why-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* --- GRIGLIA PUNTI DI INTERESSE --- */
.poi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.poi-card {
    position: relative;
    height: 300px;
    border-radius: 8px;
    overflow: hidden;
}

.poi-card img {
    height: 100%;
    transition: 0.6s ease;
}

.poi-card:hover img {
    transform: scale(1.05);
}

.poi-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px 20px 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.poi-info h4 {
    color: #ffffff;
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.poi-info span {
    color: var(--bg-base);
    font-size: 0.9rem;
    font-weight: 500;
}

/* Footer */
footer {
    background: #FAF8F5; /* Tono su tono col body */
    padding: 60px 5%;
    text-align: center;
    border-top: 1px solid var(--border-color);
    color: var(--text-main);
}

footer h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: var(--text-main);
}

footer h2 span {
    color: var(--accent-main);
}

.socials a {
    display: inline-block;
    margin: 0 15px;
    font-size: 1.5rem;
    color: var(--text-muted);
    transition: var(--trans-fast);
}

.socials a:hover {
    color: var(--accent-main);
    transform: translateY(-3px);
}

/* --- FIX OVERRIDE HARDCODED COLORS NEI FILE PHP --- */
/* (Forziamo i colori chiari dove avevi messo style="color: #fff") */
section.section-pad h2[style*="color: #fff"],
section.section-pad p[style*="color: #fff"],
.contact-info-list a[style*="color: #fff"],
.contact-info-list p[style*="color: #fff"],
.why-card h4[style*="color: #fff"] {
    color: var(--text-main) !important;
}

/* --- RESPONSIVE & MOBILE FIXES --- */
html, body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

@media (max-width: 900px) {
    .nav-links { display: none; }
    .hamburger { display: block; z-index: 1001; }

    .split-grid, .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .section-pad { padding: 60px 5%; }

    .hero-content h1 {
        font-size: clamp(2.2rem, 8vw, 3rem);
    }

    .sec-title { font-size: 2rem; }

    .page-header h1 {
        font-size: 2.5rem;
        text-align: center;
        padding: 0 15px;
    }

    .nearby-box { padding: 25px; }

    .img-block > div { display: none !important; }

    .mobile-menu a { font-size: 2rem; }

    .amenities-grid { grid-template-columns: 1fr; }
}

/* --- FIX BUG iOS PARALLAX E SFONDI --- */
.section-pad {
    background-color: var(--bg-base); /* Forza il colore solido di base */
    position: relative;
    z-index: 2;
}

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

@media (max-width: 900px) {
    .page-header, .book-section, #why-us {
        background-attachment: scroll !important; /* Rimuove il "fixed" che rompe Safari */
        background-position: center center;
    }
}
.book-title{
    color:white !important;
}.book-desc{
    color:white !important;
}