/* Contenuto di: color_scheme.css */
:root {
  /* Palette Principale (Light Mode di default) */
  --bg-primary: #f8f9fa;
  --primary-dark: #0c1a2c;
  --text-dark: #343a40;
  --text-light: #ffffff;
  --dark-gray: #6c757d;
  --sand: #e9ecef;
  --border-light: #dee2e6;
  --ocean-blue: #104B8F;
  --turquoise: #00897B;
  --coral: #e74c3c;
  --card-bg: #ffffff;
  --primary-dark-light: #1a2b42;
}
html[data-theme="dark"] {
  --bg-primary: #0c1a2c;
  --primary-dark: #07111d;
  --text-dark: #e0e1e2;
  --text-light: #ffffff;
  --dark-gray: #a0a7b3;
  --sand: #3a4a60;
  --border-light: #2c3a4f;
  --ocean-blue: #2471A3;
  --turquoise: #1abc9c;
  --coral: #e67e22;
  --card-bg: var(--primary-dark-light);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Poppins', sans-serif;
  color: var(--text-dark);
  background-color: var(--bg-primary);
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
}
h1, h2, h3, h4, h5, h6 { font-family: 'Playfair Display', serif; margin-bottom: 1rem; }
article h1, section h1, aside h1, nav h1 { font-size: 2.2rem; }
a { text-decoration: none; color: var(--ocean-blue); transition: color 0.3s ease; }
a:hover { color: var(--turquoise); }
img { max-width: 100%; height: auto; }
.container { display: flex; min-height: 100vh; }
.sidebar {
  width: 290px;
  background-color: var(--primary-dark);
  color: var(--text-light);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  position: fixed;
  height: 100vh;
  overflow-y: auto;
}
.sidebar-logo { text-align: center; }
.sidebar-logo img { max-width: 180px; }
.sidebar-nav { margin: 1.5rem 0; }
.sidebar-nav ul { list-style: none; }
.sidebar-nav li { margin-bottom: 0.5rem; }
.sidebar-nav a {
  color: var(--text-light);
  display: block;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}
.sidebar-nav a:hover { color: var(--turquoise); padding-left: 0.5rem; }
.sidebar-nav a.active {
  color: var(--coral);
  font-weight: 600;
  padding-left: 0.5rem;
  background-color: rgba(0, 0, 0, 0.15);
  border-left: 3px solid var(--coral);
}
.sidebar-nav a.active:hover { color: var(--coral); background-color: rgba(0, 0, 0, 0.25); }
.sidebar-contact { margin-top: 1.5rem; }
.sidebar-contact h3 { font-size: 1.2rem; margin-bottom: 1rem; color: var(--turquoise); }
.sidebar-contact p { font-size: 0.8rem; margin-bottom: 0.5rem; }
.book-now-btn {
  background-color: var(--coral);
  color: var(--primary-dark);
  border: none;
  padding: 0.8rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease;
  text-align: center;
  display: block;
  margin-top: 1.5rem;
}
.book-now-btn:hover { background-color: #ff6a3c; color: var(--primary-dark); }
.language-toggle img { width: 24px; height: auto; margin-right: 0.5rem; }
.language-toggle span { font-size: 0.9rem; }
.main-content { flex: 1; margin-left: 290px; padding: 2rem; }
.footer { background-color: var(--primary-dark); color: var(--text-light); padding: 2rem; margin-left: 290px; }
.sidebar-controls { display: flex; justify-content: center; align-items: center; gap: 1.5rem; padding-top: 1rem; margin-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.theme-switch-wrapper { display: flex; align-items: center; }
.theme-switch { display: inline-block; height: 24px; position: relative; width: 48px; }
.theme-switch input { display: none; }
.slider { background-color: #5b6e84; bottom: 0; cursor: pointer; left: 0; position: absolute; right: 0; top: 0; transition: .4s; }
.slider:before { background-color: #fff; bottom: 4px; content: ""; height: 16px; left: 4px; position: absolute; transition: .4s; width: 16px; }
input:checked + .slider { background-color: var(--turquoise); }
input:checked + .slider:before { transform: translateX(24px); }
.slider.round { border-radius: 24px; }
.slider.round:before { border-radius: 50%; }
.form-group { margin-bottom: 1.5rem; }
.form-label { display: block; margin-bottom: 0.5rem; font-weight: 500; }
.form-control { width: 100%; padding: 0.75rem; border: 1px solid var(--border-light); border-radius: 4px; font-family: inherit; font-size: 1rem; }
.form-control:focus { outline: none; border-color: var(--ocean-blue); box-shadow: 0 0 0 3px rgba(34, 137, 221, 0.2); }
.form-row { display: flex; gap: 1.5rem; }
.form-row .form-group { flex: 1; }
.hero { position: relative; margin-bottom: 2rem; }
.hero-image { width: 100%; object-fit: cover; border-radius: 8px; }
.hero-overlay { position: absolute; bottom: 0; left: 0; right: 0; padding: 2rem; background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0)); color: var(--text-light); border-radius: 0 0 8px 8px; }
.hero-overlay h2 { font-size: 2.2rem; margin-bottom: 0.5rem; }
.features { margin: 3rem 0; }
.row { display: flex; flex-wrap: wrap; gap: 2rem; }
.feature-card { flex: 1; min-width: 250px; background-color: var(--bg-primary); padding: 2rem; border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); text-align: center; }
.feature-card i { font-size: 2.5rem; color: var(--ocean-blue); margin-bottom: 1rem; }
.about .row { align-items: center; }
.about-image { border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); }
.col { flex: 1; min-width: 300px; }
.event-card { display: flex; background-color: var(--bg-primary); border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); overflow: hidden; margin-bottom: 1.5rem; }
.event-date { background-color: var(--ocean-blue); color: var(--text-light); padding: 1.5rem; display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 100px; }
.event-date .day { font-size: 1.5rem; font-weight: 700; }
.event-details { padding: 1.5rem; flex: 1; }
.testimonial { background-color: var(--bg-secondary); padding: 2rem; border-radius: 8px; position: relative; }
.testimonial p { font-style: italic; margin-bottom: 1rem; }
.testimonial-author { font-weight: 600; text-align: right; }
.story-image img { width: 100%; border-radius: 8px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); }
.timeline { position: relative; padding-left: 2rem; }
.timeline::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background-color: var(--ocean-blue); }
.timeline-item { position: relative; margin-bottom: 2rem; padding-left: 1.5rem; }
.timeline-item::before { content: ''; position: absolute; left: -0.5rem; top: 0.5rem; width: 1rem; height: 1rem; background-color: var(--ocean-blue); border-radius: 50%; }
.timeline-year { font-weight: 700; color: var(--ocean-blue); margin-bottom: 0.5rem; }
/* ... (tutto il resto del tuo CSS originale) ... */
@media (max-width: 768px) {
    .container { flex-direction: column; }
    .sidebar { width: 100%; height: auto; position: relative; padding: 1rem; }
    .main-content, .footer { margin-left: 0; }
    .form-row { flex-direction: column; gap: 0; }
    .hero-overlay h2 { font-size: 1.8rem; }
    .event-card, .episode-card, .accommodation-card { flex-direction: column; }
    .event-date, .episode-number { padding: 1rem; min-width: auto; }
}

/* ========================================================= */
/* Stile DEFINITIVO e SICURO per layout Storia (con Flexbox) */
/* ========================================================= */

.intro-layout {
  display: flex;
  flex-wrap: wrap; /* Permette di andare a capo su schermi piccoli */
  gap: 2.5rem;
  align-items: center;
  margin-bottom: 2.5rem;
}

.intro-layout-text,
.intro-layout-image {
  flex: 1; /* Fa sì che entrambi gli elementi occupino metà spazio */
  min-width: 300px; /* Larghezza minima prima di andare a capo */
}

.intro-layout-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Solo su schermi grandi, invertiamo l'ordine visivo del secondo blocco */
@media (min-width: 769px) {
  .intro-layout--reverse .intro-layout-image {
    order: -1; /* Sposta l'immagine prima del testo */
  }
}