:root {
  --bg: #111612;
  --surface: #1c241f;
  --text: #f4f5f3;
  --accent: #a8c1af;
  --line: rgba(255, 255, 255, 0.10);
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.30);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "DM Sans", system-ui, sans-serif;
  transition: background .25s ease, color .25s ease;
}

button {
  font: inherit;
  cursor: pointer;
}

.app-shell {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: max(24px, env(safe-area-inset-top)) 18px
    calc(40px + env(safe-area-inset-bottom));
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 42px;
}

h1,
h2 {
  margin: 0;
  font-family: "Playfair Display", serif;
}

h1 {
  font-size: clamp(1.8rem, 7vw, 2.7rem);
  line-height: 1.05;
}

h2 {
  margin-bottom: 20px;
  font-size: clamp(1.7rem, 7vw, 2.5rem);
  letter-spacing: .03em;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.photo-card {
  display: block;
  width: 100%;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.photo-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  transition: transform .25s ease;
}

.photo-card:hover img,
.photo-card:focus-visible img {
  transform: scale(1.025);
}

.viewer {
  width: min(calc(100% - 20px), 820px);
  border: 0;
  padding: 0;
  background: transparent;
}

.viewer::backdrop {
  background: rgba(8, 11, 9, .88);
  backdrop-filter: blur(5px);
}

.viewer img {
  display: block;
  width: 100%;
  max-height: 88vh;
  border-radius: 22px;
  background: #0b0d0c;
  object-fit: contain;
}

.viewer-close {
  position: fixed;
  top: max(18px, env(safe-area-inset-top));
  right: 18px;
  z-index: 3;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .62);
  color: #fff;
  font-size: 1.45rem;
}

@media (min-width: 600px) {
  .app-shell {
    padding-left: 28px;
    padding-right: 28px;
  }

  .photo-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
}


.title-block {
  min-width: 0;
}

.event-date {
  margin: 8px 0 0;
  color: var(--accent);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .03em;
}


.photo-card {
  position: relative;
}

.photo-card::after {
  content: "Tocca per leggere";
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .66);
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  opacity: 0;
  transition: opacity .2s ease;
}

.photo-card:hover::after,
.photo-card:focus-visible::after {
  opacity: 1;
}

@media (hover: none) {
  .photo-card::after {
    opacity: 1;
  }
}

.intro-section{max-width:700px;margin:20px auto;text-align:center;color:#ddd;font-size:1.05rem;line-height:1.5}


.photo-card {
  text-align: left;
}

.photo-meta {
  padding: 14px 14px 16px;
}

.photo-title {
  margin: 0 0 10px;
  font-size: 1.12rem;
  line-height: 1.2;
  font-family: "Playfair Display", serif;
  color: var(--text);
}

.photo-meta-line,
.photo-subitem {
  margin: 0 0 6px;
  font-size: .93rem;
  line-height: 1.4;
  color: #d8ddd9;
}

.photo-meta-line strong {
  color: #fff;
}

.photo-sublist {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.photo-subitem {
  padding-left: 10px;
  position: relative;
}

.photo-subitem::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
}


.photo-card {
  position: relative;
  text-align: left;
}

.photo-subtitle {
  margin: -2px 0 10px;
  color: var(--accent);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .02em;
}
