* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: Calibri, Arial, sans-serif;
  color: #000;
  line-height: 1.15;
  background:
    /* valori originali : linear-gradient(rgba(255,255,255,0.35), rgba(255,255,255,0.35),*/
    linear-gradient(rgba(255,255,255,0.85), rgba(255,255,255,0.85)),
    url("../sfondo.jpg") center center / cover fixed no-repeat;
}
a { color: #111; text-decoration: none; }
a:hover { text-decoration: underline; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 18px;
  background: rgba(255,255,255,0.94);
  border-bottom: 1px solid #d9d9d9;
}
.brand a { font-size: 1.5rem; font-weight: 700; }
.menu-toggle {
  width: 46px; height: 46px;
  border: 1px solid #777;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
}
.bars, .bars::before, .bars::after {
  display: block;
  width: 22px;
  height: 2px;
  background: #111;
  margin: 0 auto;
  position: relative;
  content: "";
}
.bars::before { top: -7px; }
.bars::after { top: 5px; }
.lang-switch {
  display: flex;
  gap: 8px;
  margin-left: auto;
}
.lang-switch a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  padding: 8px 10px;
  border: 1px solid #888;
  border-radius: 999px;
  background: #fff;
  font-size: 0.95rem;
  font-weight: 700;
}
.lang-switch a.active {
  background: #111;
  color: #fff;
  border-color: #111;
}

/* ================================================== */
/* DANILO: menu laterale                        */
/* ================================================== */
.side-menu {
  position: fixed;
  top: 71px;
  left: -380px;
  width: 350px;
  max-width: 90vw;
  height: calc(100vh - 71px);
  overflow-y: auto;
  background: rgba(255,255,255,0.98);
  border-right: 1px solid #ccc;
  padding: 14px;
  z-index: 999;
  transition: left 0.25s ease;
}
.side-menu.open { left: 0; }
.menu-level { list-style: none; margin: 0; padding: 0; }
.menu-item { 
      margin: 2px 0; 
}
.menu-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.menu-row > a,
.menu-row > .menu-parent {
  display: block;
  flex: 1;
  padding: 3px 8px;
  border-radius: 8px;
  line-height: 1.05;
}
.menu-row > a:hover { background: #f2f2f2; }
.menu-row[style*="background-color"] {
  border-radius: 8px;
  padding: 2px 4px;
}
.submenu-toggle {
  border: 1px solid #888;
  background: #fff;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  cursor: pointer;
}
.submenu { display: none; padding-left: 18px; }
.submenu.open { display: block; }
.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 34px 24px 60px;
}

.hero {
  background: rgba(255,255,255,0.82);
  border: 1px solid #ddd;
  border-radius: 16px;
  padding: 24px;
}

/* ================================================== */
/* DANILO: Intestazioni e Titoli                      */
/* ================================================== */
h1 { font-size: 2rem; margin: 0 0 18px; }
h2 { font-size: 1.4rem; margin: 12px 0 12px; }
h3 { font-size: 1.2rem; margin: 3px 0 0; }
p, li { font-size: 1.06rem; }

/* ================================================== */
/* DANILO: Pagina Catalogo                            */
/* ================================================== */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}
.catalog-card {
  background: rgba(255,255,255,0.92);
  border: 1px solid #ddd;
  border-radius: 14px;
  padding: 12px;
  text-align: center;
}
.catalog-card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #ccc;
}
.catalog-caption { margin: 10px 0; min-height: 42px; }
.download-btn {
  display: inline-block;
  padding: 9px 12px;
  border-radius: 999px;
  background: #111;
  color: #fff;
  font-weight: 700;
}
.form-row input.input-short {
  width: 500px;
  max-width: 100%;
}
.custom-upload {
  display: inline-block;
  background: #eef2f7;
  color: #1f2a37;
  padding: 8px 14px;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 600;
}
.custom-upload input {
  display: none;
}
.download-btn:hover {
  text-decoration: none;
  opacity: 0.9;
}
.menu-speciale {
  color: red;
  font-weight: bold;
}

/* ================================================== */
/* DANILO: immagine in tabella                        */
/* ================================================== */
.img-tabe {
    width: 300px;
    height: 300px;
    padding: 6px;
    border: 1px solid black;
    box-sizing: border-box;
    overflow: hidden;
    float: right;
    margin-left: 20px;
    background: transparent;
}
.img-tabe > img.img-tabe-fix {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    display: block;
    background: transparent;
}
.img-tabe-fix {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ================================================== */
/* DANILO: Tabella con griglia visibile               */
/* ================================================== */
.data-table-grid {
    border-collapse: collapse;
    width: 100%;
}

/* Celle */
/*--------------------------------------------------- */
.data-table-grid td,
.data-table-grid th {
    border: 1px solid #999;   /* griglia 1px */
    padding: 6px;
}

/* Prima riga (intestazione) */
/*--------------------------------------------------- */
.data-table-grid tr:first-child {
    background-color: #e0e0e0; /* grigio */
    font-weight: bold;
}

/* ================================================== */
/* DANILO: background bianco → trasparente            */
/* ================================================== */
.img-fixed {
  width: 400px;
  height: 260px;
  object-fit: contain;
  background: transparent;
  border: none;
  border-radius: 10px;
  display: block;
}

/* ================================================== */
/* DANILO: contenitore immagine con didascalia        */
/* ================================================== */
.img-box {
    width: 500px;
    height: 500px;
    padding: 12px;
    border: 2px solid black;
    box-sizing: border-box;
}

/* ================================================== */
/* DANILO: didascalia immagine                        */
/* ================================================== */
.img-caption {
  font-size: 0.85rem;
  color: #444;
  text-align: center;
  margin-top: 6px;
  line-height: 1.3;
}

.img-left {
  float: left;
  margin: 0 20px 12px 0;
}

.img-right {
  float: right;
  margin: 0 0 12px 20px;
}

.img-center {
  display: block;
  margin: 20px auto;
}

.clear {
  clear: both;
}

/* ================================================== */
/* DANILO: PHOTO GRID SYSTEM                          */
/* ================================================== */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 20px;
    margin: 30px 0;
}

/* contenitore immagine */
/* ------------------------------------------------- */
.photo-item {
    position: relative;
    box-sizing: border-box;
    padding: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    background: transparent;
    overflow: hidden;
}

/* immagine */
/* ------------------------------------------------- */
.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ===== DIMENSIONI ===== */

/* piccola */
/* ------------------------------------------------- */
.photo-small {
    grid-column: span 4;
    height: 220px;
}

/* media */
/* ------------------------------------------------- */
.photo-medium {
    grid-column: span 6;
    height: 300px;
}

/* grande */
/* ------------------------------------------------- */
.photo-large {
    grid-column: span 8;
    height: 380px;
}

/* tutta larghezza */
/* ------------------------------------------------- */
.photo-full {
    grid-column: span 12;
    height: 480px;
}

/* ===== VARIANTI ===== */

/* non taglia mai */
/* ------------------------------------------------- */
.photo-contain img {
    object-fit: contain;
}

/* effetto elegante */
/* ------------------------------------------------- */
.photo-frame {
    border: 1px solid rgba(255,255,255,0.25);
}

/* ================================================== */
/* DIDASCALIE                                         */
/* ================================================== */
.photo-caption {
    font-size: 0.9em;
    font-style: italic;
    text-align: center;
    margin-top: 6px;
    opacity: 0.8;
}

/* ================================================== */
/* CORNICE                                         */
/* ================================================== */
.box-evidenza {
    border: 1px solid rgba(0,0,0,0.15);
    /* background-color: rgba(173, 216, 230, 0.25); azzurro trasparente */
    background-color: rgba(120, 120, 120, 0.20); /* grigio medio */
    padding: 20px;
    margin: 24px 0;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
/* ================================================== */
/*  MOBILE                                            */
/* ================================================== */
@media (max-width: 900px) {

    .photo-small,
    .photo-medium,
    .photo-large,
    .photo-full {
        grid-column: span 12;
        height: auto;
    }

    .photo-item img {
        height: auto;
    }
}
@media (max-width: 720px) {
  .img-fixed {
    width: 100%;
    max-width: 400px;
    height: auto;
  }

  .img-box {
    width: 100%;
    max-width: 400px;
  }

  .img-left,
  .img-right {
    float: none;
    display: block;
    margin: 20px auto;
  }
}

@media (max-width: 1000px) {
  .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .topbar { flex-wrap: wrap; }
  .brand { order: 2; width: 100%; }
  .lang-switch { order: 3; width: 100%; justify-content: flex-end; }
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
  .catalog-grid { grid-template-columns: 1fr; }
}
