/* Pars Futbol Kulübü — global stiller */
:root {
  --red: #153a5c;
  --red-dark: #0d2840;
  --red-light: #c9a227;
  --white: #ffffff;
  --black: #0d0d0d;
  --gray-100: #f5f5f5;
  --gray-200: #e8e8e8;
  --gray-400: #9a9a9a;
  --gray-600: #4a4a4a;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
  --maxw: 1200px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--black);
  background: var(--gray-100);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--red-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* --- Header --- */
.site-header {
  background: linear-gradient(180deg, var(--red-dark) 0%, var(--red) 100%);
  color: var(--white);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  min-width: 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  min-width: 0;
  flex: 1 1 auto;
}

.logo span {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.logo:hover {
  text-decoration: none;
  opacity: 0.95;
}

.logo img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  object-position: center;
  display: block;
  background: var(--white);
  padding: 3px;
  border-radius: 6px;
}

.nav-toggle {
  display: none;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: var(--white);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.25);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--white);
  text-decoration: none;
  padding: 0.5rem 0.85rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.95rem;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  background: rgba(0, 0, 0, 0.2);
  text-decoration: none;
}

.nav-item {
  position: relative;
}

.nav-item > button {
  background: transparent;
  border: none;
  color: var(--white);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  padding: 0.5rem 0.85rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-item > button:hover {
  background: rgba(0, 0, 0, 0.2);
}

.nav-item > button::after {
  content: "";
  border: solid currentColor;
  border-width: 0 2px 2px 0;
  display: inline-block;
  padding: 3px;
  transform: rotate(45deg);
  margin-top: -2px;
}

.submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--white);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 0.5rem 0;
}

.submenu a {
  color: var(--black);
  display: block;
  padding: 0.5rem 1rem;
  font-weight: 500;
}

.submenu a:hover {
  background: var(--gray-100);
}

.nav-item:hover .submenu,
.nav-item:focus-within .submenu {
  display: block;
}

@media (max-width: 900px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    padding-top: 0.5rem;
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a,
  .nav-item > button {
    width: 100%;
    text-align: left;
  }

  .submenu {
    position: static;
    display: none;
    box-shadow: none;
    border: 1px solid var(--gray-200);
    margin: 0.25rem 0 0.5rem;
  }

  .nav-item.is-open .submenu {
    display: block;
  }

  .nav-item:hover .submenu {
    display: none;
  }

  .nav-item.is-open:hover .submenu,
  .nav-item.is-open .submenu {
    display: block;
  }
}

/* --- Layout --- */
.page-wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
  flex: 1;
  min-width: 0;
  width: 100%;
}

.page-title {
  margin: 0 0 1.25rem;
  font-size: 1.75rem;
  color: var(--red-dark);
  border-bottom: 3px solid var(--red);
  padding-bottom: 0.5rem;
  display: inline-block;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 1.5rem;
  align-items: start;
}

@media (max-width: 960px) {
  .two-col {
    grid-template-columns: 1fr;
  }
}

.contact-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

@media (max-width: 960px) {
  .contact-two-col {
    grid-template-columns: 1fr;
  }
}

.contact-map-section {
  max-width: 100%;
}

.contact-map {
  margin-top: 0.75rem;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--gray-200);
  line-height: 0;
}

.contact-map iframe {
  width: 100%;
  max-width: 100%;
  height: 450px;
  display: block;
  border: 0;
}

@media (max-width: 560px) {
  .contact-map iframe {
    height: 280px;
  }
}

main.primary {
  min-width: 0;
}

aside.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* --- Cards & panels --- */
.panel {
  background: var(--white);
  border-radius: 10px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel__head {
  background: var(--black);
  color: var(--white);
  padding: 0.65rem 1rem;
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.panel__body {
  padding: 1rem;
}

.match-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.5rem;
  align-items: center;
  text-align: center;
  font-weight: 600;
  font-size: 0.9rem;
}

.match-row .vs {
  color: var(--red);
  font-size: 0.85rem;
}

.panel .match-row--result span:not(.score-big) {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.25;
  color: var(--black);
}

.panel .match-row--result .score-big {
  color: #800020;
}

.match-meta {
  font-size: 0.8rem;
  color: var(--gray-600);
  text-align: center;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--gray-200);
}

.score-big {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--red-dark);
}

.result-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.88rem;
}

.result-list li {
  display: flex;
  justify-content: space-between;
  padding: 0.4rem 0;
  border-bottom: 1px dashed var(--gray-200);
}

.result-list li:last-child {
  border-bottom: none;
}

.link-all {
  display: inline-block;
  margin-top: 0.75rem;
  font-weight: 600;
  font-size: 0.9rem;
}

/* --- Section titles --- */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.section-head h2 {
  margin: 0;
  font-size: 1.25rem;
  color: var(--black);
  border-left: 4px solid var(--red-light);
  padding-left: 0.65rem;
}

/* --- News grid --- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}

.news-card {
  background: var(--white);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.2s;
}

.news-card:hover {
  transform: translateY(-2px);
}

.news-card__img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
  width: 100%;
  background: var(--gray-200);
}

.news-card__body {
  padding: 1rem;
}

.news-card__body h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  line-height: 1.35;
}

.news-card__body p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--gray-600);
}

.read-more {
  display: inline-block;
  margin-top: 0.65rem;
  font-weight: 600;
  font-size: 0.88rem;
}

/* --- Slider --- */
.hero-slider {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
  background: var(--black);
}

.hero-slider__track {
  display: flex;
  transition: transform 0.5s ease;
}

.hero-slide {
  min-width: 100%;
  position: relative;
}

.hero-slide img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: contain;
  display: block;
}

@media (max-width: 640px) {
  .hero-slide img {
    aspect-ratio: 16 / 10;
    object-fit: contain;
  }
}

.hero-slide__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1rem 1.25rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
  color: var(--white);
}

.hero-slide__caption h2 {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
  line-height: 1.3;
}

.hero-slide__caption a {
  color: var(--white);
  font-weight: 600;
  font-size: 0.9rem;
}

.hero-slider__dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  background: var(--black);
}

.hero-slider__dots button {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: var(--gray-400);
  cursor: pointer;
  padding: 0;
}

.hero-slider__dots button[aria-selected="true"] {
  background: var(--red);
}

.hero-slider__prev,
.hero-slider__next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  z-index: 2;
}

.hero-slider__prev:hover,
.hero-slider__next:hover {
  background: rgba(255, 255, 255, 0.35);
}

.hero-slider__prev {
  left: 0.75rem;
}

.hero-slider__next {
  right: 0.75rem;
}

/* --- Team roster pagination --- */
.kadro-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-top: 1rem;
}

.kadro-pager a {
  font-weight: 600;
}

/* --- Tables --- */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  max-width: 100%;
  min-width: 0;
  border-radius: 8px;
  border: 1px solid var(--gray-200);
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  background: var(--white);
}

table.data-table th,
table.data-table td {
  padding: 0.55rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid var(--gray-200);
}

table.data-table th {
  background: var(--black);
  color: var(--white);
  font-weight: 600;
}

table.data-table tbody tr:nth-child(even) {
  background: var(--gray-100);
}

table.data-table .highlight-row {
  background: rgba(196, 30, 58, 0.12) !important;
  font-weight: 600;
}

.fixture-league-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--black);
  margin: 0 0 0.5rem;
}

.fixture-week {
  margin-bottom: 1.75rem;
}

.fixture-week h2 {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--red-dark);
  border-left: 4px solid var(--red-light);
  padding-left: 0.5rem;
}

.fixture-note {
  font-size: 0.9rem;
  color: var(--gray-600);
  margin-bottom: 1.25rem;
  max-width: 720px;
}

.fixture-note img {
  max-width: 100%;
  height: auto;
}

/* Fikstür: mobilde tablo sıkışmasın — genişlik içeriğe göre, sağa kaydırarak okunur */
@media (max-width: 720px) {
  .page-fikstur .table-wrap .data-table {
    width: max-content;
    min-width: 100%;
    max-width: none;
    table-layout: auto;
  }

  .page-fikstur .table-wrap .data-table th,
  .page-fikstur .table-wrap .data-table td {
    white-space: nowrap;
    vertical-align: middle;
  }
}

@media (max-width: 640px) {
  .fixture-league-title {
    font-size: 1.05rem;
    line-height: 1.35;
  }

  .fixture-week h2 {
    font-size: 0.98rem;
  }

  .fixture-note {
    font-size: 0.88rem;
    overflow-wrap: anywhere;
    max-width: 100%;
  }

  table.data-table {
    font-size: 0.78rem;
  }

  table.data-table th,
  table.data-table td {
    padding: 0.45rem 0.35rem;
    word-break: break-word;
  }

  .page-fikstur .table-wrap .data-table th,
  .page-fikstur .table-wrap .data-table td {
    word-break: normal;
    overflow-wrap: normal;
    white-space: nowrap;
    padding: 0.5rem 0.6rem;
  }

  .page-fikstur .table-wrap .data-table {
    font-size: 0.85rem;
  }
}

/* --- Sponsors --- */
.sponsors {
  margin-top: 2rem;
  padding: 1.5rem 1rem;
  background: var(--white);
  border-radius: 10px;
  box-shadow: var(--shadow);
}

.sponsors h2 {
  margin: 0 0 1rem;
  font-size: 1.1rem;
  text-align: center;
  color: var(--gray-600);
}

.sponsor-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.5rem 2rem;
}

.sponsor-strip__link img {
  max-height: 48px;
  width: auto;
  margin: 0 auto;
}

.sponsor-placeholder {
  min-width: 120px;
  height: 48px;
  background: var(--gray-100);
  border: 1px dashed var(--gray-400);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  color: var(--gray-600);
  padding: 0 0.5rem;
  text-align: center;
}

/* --- Footer --- */
.site-footer {
  background: var(--black);
  color: var(--gray-200);
  padding: 2rem 1rem;
  margin-top: auto;
}

.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  font-size: 0.9rem;
}

.site-footer h3 {
  color: var(--white);
  font-size: 0.95rem;
  margin: 0 0 0.75rem;
  border-bottom: 2px solid var(--red);
  padding-bottom: 0.35rem;
  display: inline-block;
}

.site-footer a {
  color: var(--red-light);
}

.footer-bottom {
  max-width: var(--maxw);
  margin: 1.5rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid var(--gray-600);
  text-align: center;
  font-size: 0.8rem;
  color: var(--gray-400);
}

.back-to-top {
  display: inline-block;
  margin-top: 0.5rem;
  color: var(--white);
  font-size: 0.85rem;
}

/* --- Page content prose --- */
.prose {
  background: var(--white);
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: var(--shadow);
}

.prose p {
  margin-top: 0;
}

.prose img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  margin-bottom: 1rem;
}

/* --- Contact form --- */
.form-grid {
  display: grid;
  gap: 1rem;
  max-width: 520px;
}

.form-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.form-grid input,
.form-grid textarea {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gray-200);
  border-radius: 6px;
  font: inherit;
}

.form-grid textarea {
  min-height: 120px;
  resize: vertical;
}

.btn {
  display: inline-block;
  padding: 0.65rem 1.25rem;
  background: var(--red);
  color: var(--white);
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  font-size: 1rem;
}

.btn:hover {
  background: var(--red-dark);
}

/* --- Staff card --- */
.staff-highlight {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1.5rem;
  align-items: start;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: var(--white);
  border-radius: 10px;
  box-shadow: var(--shadow);
  border-left: 4px solid var(--red);
}

.staff-highlight img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  object-position: center 25%;
  border-radius: 8px;
}

@media (max-width: 560px) {
  .staff-highlight {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .staff-highlight img {
    margin: 0 auto;
  }
}

/* --- Yönetim kurul --- */
.breadcrumb {
  font-size: 0.9rem;
  color: var(--gray-600);
  margin: 0 0 0.75rem;
}

.breadcrumb a {
  color: var(--red-dark);
}

.breadcrumb span[aria-hidden="true"] {
  margin: 0 0.35rem;
  color: var(--gray-400);
}

/* Yönetim kurulu */
.board-prose {
  max-width: 960px;
  margin: 0 auto;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.board-page-title {
  margin: 0 0 1.75rem;
}

.board-page-title__text {
  display: block;
  font-size: 1.75rem;
  color: var(--black);
  font-weight: 700;
  line-height: 1.2;
}

.board-page-title__line {
  display: block;
  height: 4px;
  max-width: 280px;
  margin-top: 0.5rem;
  background: linear-gradient(to right, var(--red) 72px, var(--gray-200) 72px);
  border-radius: 2px;
}

.board-section-label {
  font-size: 1rem;
  font-weight: 700;
  color: var(--black);
  margin: 2rem 0 1rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--gray-200);
}

.board-grid {
  display: grid;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.board-grid--single {
  justify-items: center;
  margin-bottom: 1rem;
}

.board-grid--single .board-card {
  width: 100%;
  max-width: 320px;
}

.board-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 720px) {
  .board-grid--3 {
    grid-template-columns: 1fr;
  }
}

.board-card {
  background: var(--red);
  min-height: 120px;
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.board-card__name {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.3;
}

.board-card__role {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--white);
  line-height: 1.3;
}

@media (max-width: 480px) {
  .board-card {
    min-height: 100px;
    padding: 1rem 0.75rem;
  }

  .board-card__name {
    font-size: 0.98rem;
  }

  .board-card__role {
    font-size: 0.88rem;
  }
}

/* --- Foto galeri --- */
.gallery-page {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

.gallery-hero {
  position: relative;
  padding: 2.75rem 1.25rem 3rem;
  margin: 0 0 0;
  color: #fff;
  text-align: center;
  overflow: hidden;
  background: linear-gradient(145deg, #1a0a12 0%, var(--red-dark) 42%, #5c1028 100%);
}

.gallery-hero__bg {
  position: absolute;
  inset: 0;
  opacity: 0.45;
  background:
    radial-gradient(ellipse 80% 60% at 15% 20%, rgba(255, 255, 255, 0.12) 0%, transparent 55%),
    radial-gradient(ellipse 70% 50% at 85% 80%, rgba(232, 93, 117, 0.2) 0%, transparent 50%),
    repeating-linear-gradient(
      -12deg,
      transparent,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 2px,
      rgba(255, 255, 255, 0.03) 4px
    );
  pointer-events: none;
}

.gallery-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 42rem;
  margin: 0 auto;
}

.gallery-hero__eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

.gallery-hero__title {
  margin: 0 0 0.85rem;
  font-size: clamp(1.85rem, 4.5vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.25);
}

.gallery-hero__lead {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.88);
}

.gallery-hero__meta {
  margin: 1.35rem 0 0;
}

.gallery-hero__badge {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--red-dark);
  background: rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.gallery-page__main {
  padding-top: 2rem;
  padding-bottom: 3.5rem;
  min-width: 0;
  box-sizing: border-box;
}

.gallery-empty {
  text-align: center;
  padding: 3rem 1.5rem;
  max-width: 26rem;
  margin: 0 auto;
  background: var(--white);
  border-radius: 16px;
  border: 1px dashed var(--gray-200);
  box-shadow: var(--shadow);
}

.gallery-empty__icon {
  color: var(--red);
  margin-bottom: 1rem;
}

.gallery-empty__icon svg {
  display: inline-block;
  vertical-align: middle;
}

.gallery-empty__title {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  color: var(--red-dark);
}

.gallery-empty__text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--gray-600);
  line-height: 1.55;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 1.35rem;
  min-width: 0;
}

@media (min-width: 900px) {
  .gallery-grid {
    gap: 1.5rem;
  }
}

.gallery-card {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: var(--white);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.06),
    0 12px 32px rgba(139, 21, 56, 0.08);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

@media (prefers-reduced-motion: no-preference) {
  .gallery-card:hover {
    transform: translateY(-3px);
    box-shadow:
      0 8px 24px rgba(0, 0, 0, 0.1),
      0 20px 48px rgba(139, 21, 56, 0.12);
  }
}

.gallery-card__link {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: linear-gradient(160deg, var(--gray-200) 0%, #ddd 100%);
  outline: none;
}

.gallery-card__link:hover {
  text-decoration: none;
}

.gallery-card__link:focus-visible {
  box-shadow: 0 0 0 3px var(--white), 0 0 0 5px var(--red);
}

.gallery-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.gallery-card__shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    125deg,
    rgba(255, 255, 255, 0) 40%,
    rgba(255, 255, 255, 0.12) 50%,
    rgba(255, 255, 255, 0) 60%
  );
  transform: translateX(-100%);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.gallery-card__lens {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 52px;
  height: 52px;
  margin: -26px 0 0 -26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: var(--red-dark);
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.25s ease, transform 0.25s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  pointer-events: none;
}

.gallery-card__overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 2.5rem 1rem 0.85rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.75));
  pointer-events: none;
}

.gallery-card__overlay-text {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.35;
  color: #fff;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
}

@media (prefers-reduced-motion: no-preference) {
  .gallery-card__link:hover .gallery-card__img {
    transform: scale(1.06);
  }

  .gallery-card__link:hover .gallery-card__shine {
    transform: translateX(100%);
  }

  .gallery-card__link:hover .gallery-card__lens {
    opacity: 1;
    transform: scale(1);
  }
}

.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(8, 6, 8, 0.92);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 0.75rem 2rem;
  box-sizing: border-box;
}

.gallery-lightbox[hidden] {
  display: none !important;
}

.gallery-lightbox__close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1.85rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease;
  z-index: 2;
}

.gallery-lightbox__close:hover {
  background: rgba(255, 255, 255, 0.22);
}

.gallery-lightbox__nav {
  position: absolute;
  top: 50%;
  margin-top: -1.75rem;
  width: 3rem;
  height: 3.5rem;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s ease;
}

.gallery-lightbox__nav:hover {
  background: rgba(255, 255, 255, 0.2);
}

.gallery-lightbox__nav--prev {
  left: 0.5rem;
}

.gallery-lightbox__nav--next {
  right: 0.5rem;
}

@media (max-width: 560px) {
  .gallery-lightbox__nav {
    width: 2.5rem;
    height: 3rem;
    font-size: 1.6rem;
  }

  .gallery-lightbox__nav--prev {
    left: 0.25rem;
  }

  .gallery-lightbox__nav--next {
    right: 0.25rem;
  }
}

.gallery-lightbox__inner {
  max-width: min(96vw, 1120px);
  max-height: 88vh;
  text-align: center;
}

.gallery-lightbox__img {
  max-width: 100%;
  max-height: calc(88vh - 5rem);
  width: auto;
  height: auto;
  object-fit: contain;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 16px 64px rgba(0, 0, 0, 0.45);
}

.gallery-lightbox__cap {
  margin: 1rem 0 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 1rem;
  font-weight: 500;
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.45;
}

.gallery-lightbox__cap:empty {
  display: none;
}

.gallery-lightbox__counter {
  position: absolute;
  bottom: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.55);
  text-transform: uppercase;
}

.gallery-lightbox__counter:empty {
  display: none;
}

@media (max-width: 600px) {
  .gallery-hero {
    padding: 2rem max(1rem, env(safe-area-inset-left)) 2.5rem max(1rem, env(safe-area-inset-right));
  }

  .gallery-hero__lead {
    font-size: 0.95rem;
    line-height: 1.55;
    overflow-wrap: anywhere;
  }

  .gallery-page__main {
    padding-left: max(0.75rem, env(safe-area-inset-left));
    padding-right: max(0.75rem, env(safe-area-inset-right));
  }

  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .gallery-card {
    max-width: 100%;
  }

  .gallery-lightbox {
    align-items: flex-start;
    justify-content: flex-start;
    padding: max(3.25rem, env(safe-area-inset-top)) max(0.5rem, env(safe-area-inset-right))
      max(1rem, env(safe-area-inset-bottom)) max(0.5rem, env(safe-area-inset-left));
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    backdrop-filter: none;
    background: rgba(8, 6, 8, 0.97);
  }

  .gallery-lightbox__close {
    top: max(0.5rem, env(safe-area-inset-top));
    right: max(0.5rem, env(safe-area-inset-right));
    width: 3rem;
    height: 3rem;
    touch-action: manipulation;
  }

  .gallery-lightbox__nav {
    top: 50%;
    margin-top: -1.5rem;
    touch-action: manipulation;
  }

  .gallery-lightbox__inner {
    max-width: 100%;
    width: 100%;
    max-height: none;
    margin: 0 auto;
    padding: 0 clamp(1.75rem, 5vw, 2.75rem);
    box-sizing: border-box;
  }

  .gallery-lightbox__img {
    max-height: min(72dvh, 560px);
    width: 100%;
    max-width: 100%;
  }

  .gallery-lightbox__cap {
    font-size: 0.92rem;
    padding: 0 0.25rem;
    margin-top: 0.75rem;
  }

  .gallery-lightbox__counter {
    position: relative;
    bottom: auto;
    left: auto;
    transform: none;
    margin: 0.75rem auto 0;
    text-align: center;
  }
}

/* --- Utils --- */
.mt-0 {
  margin-top: 0;
}

.text-muted {
  color: var(--gray-600);
  font-size: 0.9rem;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
