/* Reset e Base */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: Arial, sans-serif; }

/* HOME PAGE LAYOUT */
.home-container {
  display: flex;
  height: 100vh;
}
.artwork.large {
  display: flex;
  flex-direction: column;
}

.artwork.large .caption {
  order: -1; /* Sposta la caption sopra l'immagine */
  margin-top: 0;
  margin-bottom: 1rem;
  padding: 0.5rem;
  background: rgba(255,255,255,0.8); /* Sfondo leggero per migliorare la leggibilità */
}

@media (max-width: 768px) {
  .artwork.large .caption {
    margin-bottom: 0.5rem;
    padding: 0.3rem;
  }
}

.sidebar {
  width: 20%;
  padding-left: 2rem;
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: white;
}

.logo {
    font-size: 1.8rem;
    line-height: 0.8;
    margin-bottom: 0rem;
    font-weight: normal;
	color: inherit !important;
	text-decoration: none !important;
}

.main-image {
  width: 80%;
  background-size: cover;
  background-position: center;
}

/* ==================== */
/* HEADER REVISED STYLE */
/* ==================== */
.internal-page .compact-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(5px);
  box-shadow: 0 2px 20px rgba(0,0,0,1);
  padding: 0.8rem 2rem;
}

.internal-page .top-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1440px;
  margin: 0 auto;
}

.internal-page .logo_b {
	font-size: 11pt;
    line-height: .8;
    letter-spacing: 1.5px;
    font-weight: normal;
    text-align: left;
    white-space: nowrap;
    display: flow-root;
	color: inherit !important;
	text-decoration: none !important;
	margin-left: 30px;
}

.internal-page .logo_b a,  /* Aggiungi questa linea */
.internal-page .logo_b a:hover {  /* E questa per lo stato hover */
  color: #333 !important; /* Sostituisci #333 con il colore esatto che vuoi usare */
  text-decoration: none !important;
}

.internal-page .menu-links {
    display: inline-flex;
    gap: 1.5rem;
    background: white;
    padding-left: 15px;
    margin-left: 30%;
    border-color: black;
    border-style:  none;   /* Prima solid; */  
    padding-right: 10px;
}

.internal-page .menu-links a {
  text-decoration: none;
  color: #333;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  padding: 0.5rem 0;
  position: relative;
  font-family: Arial, sans-serif;
}

.internal-page .menu-links a:hover {
  color: #000;
}

.internal-page .menu-links a.active {
  color: #000;
  font-weight: 600;
}

/* Sottolinea dinamica */
.internal-page .menu-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1.5px;
  background: currentColor;
  transition: width 0.3s;
}

.internal-page .menu-links a:hover::after,
.internal-page .menu-links a.active::after {
  width: 100%;
}

/* Responsive */
@media (max-width: 768px) {
  .internal-page .compact-header {
    padding: 0.8rem 1.5rem;
  }
  
  .internal-page .top-nav {
    flex-direction: column;
    gap: 1rem;
  }
  
  .internal-page .menu-links {
    gap: 1.2rem;
    flex-wrap: wrap;
  }
  
  .internal-page .menu-links a {
    font-size: 0.9rem;
    padding: 0.3rem 0;
  }
}
/* Mantieni lo stile del main come prima */
.internal-page main {
  padding: 2rem;
  max-width: 100%;
  margin: 0 auto;
}
/* Menu */
.menu {
	display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 10%;
}

.menu a {
  text-decoration: none;
  color: white;
  font-size: 1.2rem;
  background-color: black;
}

/* RESPONSIVE */
/* Tablet (1024px) */
@media (max-width: 1024px) {
  /* Homepage */
  .sidebar { width: 25%; }
  .main-image { width: 75%; }
  
}


/* ------------------------------- GALLERY STYLES ------------------------------ */
.gallery-section {
  margin: 20rem 0;
  padding-bottom:200px;
}

/* Layout 1 - 3 immagini allineate in basso (centrale più grande) */
.layout-1 .grid-container {
  display: grid;
  /* Nuova struttura: 1fr (piccola) | 1fr (spazio vuoto) | 2fr (centrale) | 1fr (spazio vuoto) | 1fr (piccola) */
  grid-template-columns: 1fr 0.5fr 2fr 0.1fr 1fr;  
  grid-template-rows: auto 2fr;
  gap: 1rem; /* Puoi regolare il gap se necessario */
  max-width: 1440px; /* Aumenta se serve più spazio */
  margin: 0 auto;
}

/* Aggiorna il posizionamento delle aree */
.layout-1 .area-1a {
    grid-column: 1;
    grid-row: 1;
    position: absolute;
    margin-left: 30px;
    margin-top: 15px;
}

@media (max-width: 768px) {
  .layout-1 .area-1a {
    margin-left: -20px;  /* Modifica da +30px a -20px */
    margin-top: 15px;    /* Mantieni invariato */
    /* Nota: position:absolute rimane attiva */
  }
}

.layout-1 .area-1b {
  grid-column: 3; /* Centrale (2fr) */
  grid-row: 2;
  display: flex;
  align-items: flex-end;
}

.layout-1 .area-1c {
  grid-column: 1; /* Prima piccola (1fr) */
  grid-row: 2;
  display: flex;
  align-items: flex-end;  /* Allinea in basso */
  justify-content: center;
}

.layout-1 .area-1d {
  grid-column: 5; /* Seconda piccola (1fr) */
  grid-row: 2;
  display: flex;
  align-items: flex-end;  /* Allinea in basso */
  justify-content: center;
}

/* Artwork styles */
.artwork {
  position: relative;
}

.artwork.large img {
  max-width: 480px;
  max-height: 480px;
  width: 100%;
  height: auto;
}

.artwork.small img {
  max-width: 240px;
  max-height: 240px;
  width: 100%;
  height: auto;
}

/* Square images (default) */
.square-img {
  border-radius: 0;
}

/* Round image for section 9 */
.round-img {
  border-radius: 50%;
}

/* Caption styles */
.caption {
  font-size: 0.9rem;
  line-height: 1;
}

.caption .title {
  font-weight: bold;
}

.caption .number {
  color: #666;
}

.caption .category {
  font-style: italic;
}

/* Layout 2 - Fullscreen con immagine centrale */
.layout-2 {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.layout-2 .fullscreen-artwork {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
}

.layout-2 .caption-right {
  padding-top: 1rem;
  font-size: 0.9rem;
  line-height: 1.4;
}
/* SINGLE ART PAGE STYLES */
.single-art-page main {
  padding: 2rem 0;
  max-width: 1440px;
  margin: 0 auto;
}

.single-art-section {
  margin: 8rem 0;
}

.single-art-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.artwork-info {
  text-align: center;
  max-width: 600px;
  margin-bottom: 2rem;
}

.artwork-info h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}
grid
.art-description {
  font-size: 1.1rem;
  line-height: 1.6;
  color: #555;
}

.artwork-full {
  width: 100%;
  display: flex;
  justify-content: center;
}

.artwork-single {
  max-width: 900px;
  width: 100%;
  position: relative;
}

.artwork-nft-container {  /* Nuovo contenitore principale */
  position: relative;
  display: inline-block; /* Per contenere gli elementi assoluti */
}

.artwork-nft {
  position: relative;
  width: 500px; /* O la dimensione del tuo quadrato */
  height: 500px;
}

.caption-container-nft {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  padding: 15px; /* Spaziatura interna */
}

.caption-nft {
  position: absolute;
  top: -65px; /* Sposta SOPRA l'immagine */
  left: 0;     /* Allineata a sinistra */
  background: rgba(255,255,255,0.9);
  z-index: 10;
  white-space: nowrap; /* Evita a capo automatico */
}

.full-width-img-nft {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Mantiene l'immagine quadrata */
  display: block;
}

/* Stili per gli elementi della caption */
.caption-nft .title {
  font-weight: bold;
  font-size: 1rem;
  margin-bottom: 3px;
}

.caption-nft .number {
  color: #555;
  font-size: 0.9rem;
  margin-bottom: 3px;
}

.caption-nft .category {
  font-style: italic;
  font-size: 0.9rem;
  color: #777;
}

/* Versione mobile */
@media (max-width: 768px) {
  .artwork-nft {
    width: 100%;
    height: auto;
    aspect-ratio: 1/1; /* Mantiene il quadrato */
  }
  .caption-nft {
    top: -66px;
	  padding-left:10px;
    font-size: 14px;
  }
}

.full-width-img {
  width: 100%;
  height: auto;
  max-height: 55vh;
  object-fit: contain;
}

.caption-top {
  text-align: center;
  margin-bottom: 1.5rem;
  padding: 0 1rem;
}

.caption-top .title {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 0.3rem;
}

.caption-top .number {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0.2rem;
}

.caption-top .category {
  font-size: 0.9rem;
  font-style: italic;
  color: #888;
}

/* Responsive */
@media (max-width: 768px) {
  .single-art-section {
    margin: 5rem 0;
  }
  
  .artwork-info {
    padding: 0 1.5rem;
  }
  
  .artwork-info h2 {
    font-size: 1.6rem;
  }
  
  .art-description {
    font-size: 1rem;
  }
  
  .caption-top {
    margin-bottom: 1rem;
  }
  
  .caption-top .title {
    font-size: 1.3rem;
  }
}
/* Responsive adjustments */
@media (max-width: 768px) {
  .layout-1 .grid-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto auto;
  }
  
  .layout-1 .area-1a,
  .layout-1 .area-1b,
  .layout-1 .area-1c,
  .layout-1 .area-1d {
    grid-column: 1;
  }
  
  .layout-1 .area-1a { grid-row: 1; }
  .layout-1 .area-1c { grid-row: 2; }
  .layout-1 .area-1b { grid-row: 3; }
  .layout-1 .area-1d { grid-row: 4; }
  
  .layout-2 .fullscreen-artwork {
    flex-direction: column;
    align-items: center;
  }
  
  .layout-2 .caption-right {
    padding-top: 0;
    padding-left: 1rem;
  }
}

.internal-page .compact-header .logo_b a,
.internal-page .compact-header .logo_b a:hover {
  color: inherit;
  text-decoration: none;
  font: inherit; /* Eredita tutte le proprietà del font dal padre */
}

/* HEADER MOBILE REVISED */
@media (max-width: 768px) {
  .internal-page .compact-header {
    padding: 0.5rem 1rem;
    position: relative; /* Cambiato da fixed a relative se necessario */
  }

  .internal-page .top-nav {
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
    position: relative;
  }

.internal-page  .logo_b {
    font-size: 10pt;
    line-height: 0.8;
    z-index: 1001;
	color: inherit !important;
  text-decoration: none !important;
}

.internal-page .logo_b a,  /* Aggiungi questa linea */
.internal-page .logo_b a:hover {  /* E questa per lo stato hover */
  color: #333 !important; /* Sostituisci #333 con il colore esatto che vuoi usare */
  text-decoration: none !important;
}
	
  /* Menu hamburger */
  .menu-toggle {
    display: block;
    width: 30px;
    height: 30px;
    position: relative;
    z-index: 1001;
    cursor: pointer;
  }

  .menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #333;
    position: absolute;
    left: 0;
    transition: all 0.3s ease;
  }

  .menu-toggle span:nth-child(1) {
    top: 8px;
  }

  .menu-toggle span:nth-child(2) {
    top: 14px;
  }

  .menu-toggle span:nth-child(3) {
    top: 20px;
  }

  /* Nascondi i link normali */
  .internal-page .menu-links {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(5px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-left: 0;
    padding: 2rem;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    z-index: 1000;
    display: flex;
  }

  .internal-page .menu-links.active {
    transform: translateY(0);
  }

  .internal-page .menu-links a {
    font-size: 1.2rem;
    padding: 1rem 0;
    width: 100%;
    text-align: center;
  }

  /* Animazione hamburger */
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg);
    top: 14px;
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg);
    top: 14px;
  }
}