
*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg: #050608;
  --bg-alt: #111216;
  --paper: #1b1c21;
  --accent: #e1c48f;
  --accent-soft: rgba(225, 196, 143, 0.14);
  --text: #f5f2e9;
  --muted: #b3aa96;
  --danger: #ff5c5c;
  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.6);
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition-fast: 180ms ease-out;
  --transition-normal: 260ms ease-out;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* HERO */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 1.5rem 3rem;
  background: radial-gradient(circle at top, #262733 0, #050608 55%);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
      120deg,
      rgba(255, 255, 255, 0.04) 0,
      transparent 40%,
      transparent 60%,
      rgba(255, 255, 255, 0.03) 100%
    ),
    url("../img/paper_texture.png");
  mix-blend-mode: screen;
  opacity: 0.45;
  pointer-events: none;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(
    circle at top left,
    rgba(225, 196, 143, 0.16),
    transparent 60%
  );
  pointer-events: none;
}

.hero-content {
  position: relative;
  max-width: 920px;
  text-align: center;
  padding: 2.5rem 2.5rem 3rem;
  background: radial-gradient(circle at top, #181921 0, #101117 60%, #050608 100%);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(225, 196, 143, 0.35);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  color: var(--accent);
  margin-bottom: 0.4rem;
}

.hero h1 {
  font-family: "Cormorant Garamond", "Times New Roman", serif;
  font-size: clamp(2.8rem, 5vw, 3.9rem);
  letter-spacing: 0.06em;
  margin: 0 0 1rem;
}

.subtitle {
  margin: 0 auto 1.8rem;
  max-width: 38rem;
  color: var(--muted);
  font-size: 0.98rem;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.9rem;
}

.nav-link {
  border-radius: 999px;
  padding: 0.6rem 1.3rem;
  border: 1px solid rgba(225, 196, 143, 0.6);
  background: radial-gradient(circle at top, rgba(225, 196, 143, 0.18), transparent 70%);
  color: var(--text);
  text-decoration: none;
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: background var(--transition-normal), transform var(--transition-fast),
    box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.nav-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.26), transparent 62%);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.nav-link:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.5);
  border-color: var(--accent);
}

.nav-link:hover::after {
  opacity: 1;
}

.scroll-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px dashed rgba(225, 196, 143, 0.55);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
  text-decoration: none;
}

.scroll-indicator::after {
  content: "▾";
  font-size: 0.9rem;
}

/* OVERVIEW SECTION */

main {
  padding-bottom: 4rem;
  /*background-image: url("../img/sfondo.png");*/
 /* background-color: hsla(0, 0%, 0%, 0.1);*/
  /*opacity: 0.1;*/
}

.overview {
  padding: 4rem 1.5rem 3rem;
  max-width: 1100px;
  margin: 0 auto;
}

.overview h2 {
  font-family: "Cormorant Garamond", "Times New Roman", serif;
  font-size: 2rem;
  margin-bottom: 0.4rem;
}

.overview-text {
  max-width: 40rem;
  color: var(--muted);
  font-size: 0.98rem;
  margin-bottom: 2.4rem;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.6rem;
}

.card {
  background: linear-gradient(145deg, #15161c, #090a0f);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(225, 196, 143, 0.24);
  padding: 0.1rem;
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: conic-gradient(
    from 200deg,
    rgba(225, 196, 143, 0.45),
    transparent,
    transparent,
    rgba(225, 196, 143, 0.1),
    transparent
  );
  opacity: 0;
  transition: opacity var(--transition-normal);
  pointer-events: none;
}

.card-link {
  appearance: none;
  border: none;
  width: 100%;
  text-align: left;
  background: radial-gradient(circle at top, #22232c, #101116);
  color: inherit;
  padding: 1.4rem 1.4rem 1.6rem;
  border-radius: calc(var(--radius-lg) - 2px);
  cursor: pointer;
  position: relative;
  z-index: 1;
}

.card-tag {
  display: inline-flex;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(225, 196, 143, 0.55);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.9rem;
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
}

.card-meta {
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.card p {
  font-size: 0.9rem;
  color: #e3dfd3;
}

.card-cta {
  display: inline-flex;
  align-items: center;
  margin-top: 1.2rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.card:hover::before {
  opacity: 0.7;
}

.card:hover .card-link {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.75);
}

/* DETAIL SECTIONS */

.detail-section {
  padding: 4.5rem 1.5rem 4rem;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}

.detail-section + .detail-section {
  margin-top: 1rem;
}

.dark-section {
  background: radial-gradient(circle at top, #14151c, #050608);
  border-top: 1px solid rgba(225, 196, 143, 0.18);
  border-bottom: 1px solid rgba(225, 196, 143, 0.18);
}

.section-header {
  max-width: 46rem;
  margin-bottom: 2.6rem;
}

.section-tag {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.75rem;
  color: var(--accent);
  margin-bottom: 0.35rem;
}

.section-header h2 {
  font-family: "Cormorant Garamond", "Times New Roman", serif;
  font-size: 2.1rem;
  margin: 0 0 0.6rem;
}

.section-lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.2rem;
  align-items: flex-start;
}

.detail-column h3 {
  margin-top: 0;
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.data-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.6rem;
  font-size: 0.92rem;
}

.data-list li {
  padding: 0.2rem 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.06);
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
}

.data-list li span {
  color: var(--muted);
  font-size: 0.85rem;
}

.timeline {
  padding-left: 1.2rem;
  margin: 0;
  font-size: 0.92rem;
}

.timeline li {
  margin-bottom: 0.7rem;
}

.photo-block {
  background: radial-gradient(circle at top left, #262631, #111116);
  border-radius: var(--radius-lg);
  padding: 0.7rem;
  border: 1px solid rgba(225, 196, 143, 0.32);
  box-shadow: var(--shadow-soft);
}

.photo-block img {
  display: block;
  width: 100%;
  border-radius: calc(var(--radius-lg) - 6px);
}

.photo-caption {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0.6rem 0 0.1rem;
}

.portrait img {
  max-width: 280px;
  margin-inline: auto;
}

.classified-box {
  margin-top: 1.4rem;
  padding: 1rem 1.1rem;
  border-radius: 16px;
  border: 1px dashed rgba(255, 92, 92, 0.6);
  background: radial-gradient(circle at top left, rgba(255, 92, 92, 0.25), transparent 70%);
  font-size: 0.9rem;
}

.classified-box h3 {
  margin-top: 0;
  font-size: 0.9rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--danger);
  margin-bottom: 0.4rem;
}

/* GALLERY */

.gallery-wrapper {
  margin-top: 2.6rem;
}

.gallery-wrapper h3 {
  margin-bottom: 0.4rem;
  font-size: 1.05rem;
}

.gallery-intro {
  margin: 0 0 1rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
}

.gallery img {
  width: 100%;
  display: block;
  border-radius: 15px;
  cursor: pointer;
  border: 1px solid rgba(225, 196, 143, 0.5);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast),
    border-color var(--transition-fast), filter var(--transition-fast);
  filter: grayscale(0.06);
}

.gallery img:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.8);
  border-color: var(--accent);
  filter: grayscale(0);
}

/* SCROLL REVEAL */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 500ms ease-out, transform 500ms ease-out;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* LIGHTBOX */

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(3, 3, 6, 0.88);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
  padding: 1.5rem;
}

.lightbox.open {
  display: flex;
}

.lightbox-image {
  max-width: min(900px, 100%);
  max-height: 80vh;
  border-radius: 16px;
  border: 1px solid rgba(225, 196, 143, 0.7);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.85);
}

.lightbox-close {
  position: absolute;
  top: 1.2rem;
  right: 1.4rem;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 2rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
}

.lightbox-caption {
  margin-top: 0.8rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
}

/* FOOTER */

.site-footer {
  padding: 2.4rem 1.5rem 2.2rem;
  border-top: 1px solid rgba(225, 196, 143, 0.2);
  margin-top: 1rem;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.back-to-top {
  text-decoration: none;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.76rem;
}

/* RESPONSIVE */

@media (max-width: 960px) {
  .cards {
    grid-template-columns: 1fr;
  }

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

  .gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .hero-content {
    padding: 1.8rem 1.4rem 2.2rem;
  }

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