/* =====================================================
   COMPONENTS — home, shows, gallery, download, contact
   ===================================================== */

/* ---- HOME: Top image showcase ---- */
.home-showcase {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: auto;
  gap: 4px;
  margin-bottom: var(--space-lg);
}

.home-showcase img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  display: block;
}

.home-showcase .showcase-main {
  grid-row: 1 / 3;
}

.home-showcase .showcase-main img {
  height: 100%;
}

.home-showcase .showcase-portrait {
  grid-row: 1 / 3;
}

.home-showcase .showcase-portrait img {
  height: 100%;
}

@media (max-width: 600px) {
  .home-showcase > div:not(.showcase-main) {
    display: none;
  }
  .home-showcase {
    grid-template-columns: 1fr;
  }
  .home-showcase .showcase-main {
    grid-row: auto;
  }
  .home-showcase .showcase-main img {
    height: 220px;
  }
}

/* ---- HOME: Content + portrait two-column ---- */
.home-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: start;
}

@media (min-width: 640px) {
  .home-grid {
    grid-template-columns: 3fr 1fr;
  }
}

.home-portrait {
  width: 100%;
  border: 1px solid var(--color-border);
  display: block;
}

.home-portrait--gap {
  margin-top: var(--space-md);
}

/* ---- HOME: Content sections ---- */
.content-section {
  margin-bottom: var(--space-xl);
}

.content-section h2 {
  margin-bottom: var(--space-sm);
}

.content-section p {
  margin-bottom: var(--space-sm);
}

.content-section p:last-child {
  margin-bottom: 0;
}

/* ---- SHOWS: Simple text sections with optional images ---- */
.shows-intro {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.shows-intro img {
  margin: var(--space-md) auto 0;
  max-width: 220px;
}

.shows-image-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  margin: var(--space-lg) 0;
  justify-content: center;
}

.shows-image-row img {
  border: 1px solid var(--color-border);
  max-height: 200px;
  width: auto;
  flex-shrink: 0;
}

.shows-section {
  margin-bottom: var(--space-xl);
}

.shows-section h2 {
  margin-bottom: var(--space-sm);
  padding-bottom: var(--space-xs);
  border-bottom: 1px solid var(--color-border);
}

.shows-section p {
  margin-bottom: var(--space-sm);
}

.shows-section p:last-child {
  margin-bottom: 0;
}

.shows-section-with-image {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
  align-items: start;
  margin-bottom: var(--space-xl);
}

@media (min-width: 580px) {
  .shows-section-with-image {
    grid-template-columns: 1fr auto;
  }
  .shows-section-with-image img {
    max-width: 220px;
    border: 1px solid var(--color-border);
  }
}

/* ---- PHOTO GALLERY ---- */
.gallery-intro {
  margin-bottom: var(--space-xl);
}

.gallery-intro p {
  margin-bottom: var(--space-sm);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
}

@media (min-width: 440px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 640px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.gallery-item {
  display: block;
  overflow: hidden;
  aspect-ratio: 1;
  background: #ccc;
}

.gallery-item:hover img,
.gallery-item:focus-visible img {
  transform: scale(1.06);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s;
}

/* ---- LIGHTBOX ---- */
dialog.lightbox {
  border: none;
  background: transparent;
  padding: 0;
  max-width: 92vw;
  max-height: 92vh;
  overflow: visible;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
}

dialog.lightbox::backdrop {
  background: rgba(0,0,0,0.88);
}

.lightbox-inner {
  background: #111;
  border: 2px solid #444;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 880px;
  width: 88vw;
}

.lightbox-img {
  display: block;
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
  width: auto;
  height: auto;
}

.lightbox-controls {
  display: flex;
  gap: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  background: rgba(0,0,0,0.7);
  width: 100%;
  justify-content: center;
  flex-wrap: wrap;
}

.lightbox-btn {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: var(--radius);
  padding: var(--space-xs) var(--space-md);
  cursor: pointer;
  font-size: var(--text-base);
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  transition: background 0.15s;
}

.lightbox-btn:hover,
.lightbox-btn:focus-visible {
  background: rgba(255,255,255,0.28);
}

.lightbox-caption {
  color: #bbb;
  font-size: var(--text-sm);
  padding: var(--space-xs) var(--space-md);
  text-align: center;
}

.lightbox-counter {
  color: #888;
  font-size: var(--text-sm);
  align-self: center;
}

/* ---- DOWNLOAD ---- */
.download-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  margin-top: var(--space-xl);
}

@media (min-width: 640px) {
  .download-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.download-card {
  border: 1px solid var(--color-border);
  background: var(--color-bg-tint);
}

.download-card img {
  width: 100%;
  height: 200px;
  object-fit: contain;
  background: #fff;
  padding: var(--space-md);
  display: block;
  border-bottom: 1px solid var(--color-border);
}

.download-card-body {
  padding: var(--space-md) var(--space-lg);
}

.download-card h2 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-sm);
}

.download-card p {
  margin-bottom: var(--space-md);
  color: var(--color-text-secondary);
  font-size: var(--text-sm);
}

.download-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-xs) var(--space-md);
  background: var(--color-accent);
  color: #fff;
  text-decoration: none;
  border-radius: var(--radius);
  font-size: var(--text-sm);
  font-weight: bold;
  min-height: 44px;
  transition: background 0.15s;
}

.download-link:hover {
  background: var(--color-accent-hover);
  color: #fff;
}

/* ---- CONTACT ---- */
.contact-layout {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xl);
  align-items: flex-start;
  justify-content: center;
  margin-top: var(--space-md);
}

.contact-photo {
  border: 1px solid var(--color-border);
  max-width: 290px;
  width: 100%;
  height: auto;
  flex-shrink: 0;
}

.contact-block {
  flex: 1;
  min-width: 260px;
}

.contact-block address {
  font-style: normal;
}

.contact-item {
  display: flex;
  gap: var(--space-lg);
  align-items: flex-start;
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--color-border);
}

.contact-item:last-child {
  border-bottom: none;
}

.contact-label {
  font-weight: bold;
  color: var(--color-accent);
  min-width: 80px;
  flex-shrink: 0;
}

.contact-item a {
  color: var(--color-text-primary);
  text-decoration: none;
  font-size: var(--text-lg);
}

.contact-item a:hover {
  color: var(--color-accent);
  text-decoration: underline;
}

/* ---- IN NEWS ---- */
.news-intro {
  margin-bottom: var(--space-xl);
}

.news-items {
  margin-top: var(--space-xl);
}

.news-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
  padding-bottom: var(--space-xl);
  margin-bottom: var(--space-xl);
  border-bottom: 1px solid var(--color-border);
}

.news-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

@media (min-width: 600px) {
  .news-item {
    grid-template-columns: 1fr 180px;
    gap: var(--space-xl);
    align-items: start;
  }
}

.news-item-img {
  display: block;
  width: 100%;
  max-width: 240px;
  border: 1px solid var(--color-border);
  order: -1;
}

@media (min-width: 600px) {
  .news-item-img {
    width: 180px;
    max-width: none;
    order: 0;
  }
}

.news-item-publication {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-xs);
}

.news-item-title {
  font-style: italic;
  color: var(--color-text-secondary);
  font-size: var(--text-lg);
  font-weight: normal;
  margin-bottom: var(--space-xs);
}

.news-item-date {
  color: var(--color-text-secondary);
  font-size: var(--text-sm);
  font-family: var(--font-nav);
  margin-bottom: var(--space-md);
}

.news-item-body p {
  margin-bottom: var(--space-sm);
}

.news-item-body p:last-child {
  margin-bottom: 0;
}

.news-read-more {
  display: inline-block;
  margin-top: var(--space-sm);
  font-size: var(--text-sm);
  font-family: var(--font-nav);
}
