/* Galeri: doğal oranlı medya, mozaik önizlemeler ve tam ekran lightbox. */
.gallery-section { padding: 38px 0 80px; background: #f7f9fb; }
.gallery-preview { padding: 72px 0 76px; }
.gallery-crumb { display: flex; gap: 12px; margin-bottom: 42px; font-size: 13px; color: var(--muted); }
.gallery-crumb a { color: var(--muted); }
.gallery-crumb [aria-current] { color: var(--deep); }
.gallery-heading-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 36px; }
.gallery-eyebrow { margin: 0 0 14px; font-size: 11px; font-weight: 600; letter-spacing: .19em; color: var(--primary); }
.gallery-heading-row h1, .gallery-heading-row h2 { max-width: 23ch; margin: 0; font-size: clamp(30px, 3.5vw, 48px); font-weight: 500; letter-spacing: -.045em; line-height: 1.18; color: var(--deep); }
.gallery-lead { max-width: 56ch; margin: 16px 0 0; font-size: 15px; color: var(--muted); }
.gallery-total { flex-shrink: 0; padding-bottom: 4px; font-size: 12px; color: var(--muted); }
.gallery-total strong { margin-right: 5px; font-size: 25px; font-weight: 500; color: var(--deep); }
.gallery-all { display: inline-flex; align-items: center; gap: 18px; flex-shrink: 0; padding: 12px 0; border-bottom: 1px solid var(--primary); font-size: 14px; font-weight: 500; color: var(--deep); }
.gallery-all svg { width: 18px; height: 18px; color: var(--primary); transition: transform .2s; }
.gallery-all:hover svg { transform: translateX(4px); }
.gallery-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; margin-bottom: 10px; border-top: 1px solid var(--hair); }
.gallery-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.gallery-filters button { display: inline-flex; gap: 10px; align-items: center; min-height: 42px; padding: 8px 16px; border-radius: 5px; font-size: 13px; font-weight: 500; color: var(--muted); transition: color .2s, background .2s; }
.gallery-filters button span { opacity: .65; font-size: 11px; }
.gallery-filters button:hover { background: var(--mist); color: var(--deep); }
.gallery-filters button.is-active { background: var(--deep); color: #fff; }
.gallery-hint { margin: 0; font-size: 12px; color: var(--muted); }
.gallery-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-flow: dense; grid-auto-rows: clamp(150px, 14.5vw, 205px); gap: 14px; }
.gallery-card { position: relative; display: block; min-width: 0; overflow: hidden; isolation: isolate; background: var(--deep); border-radius: 6px; color: #fff; }
.gallery-card--featured { grid-column: span 2; grid-row: span 2; }
.gallery-card--portrait { grid-row: span 2; }
.gallery-card::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(5, 20, 32, .2), transparent 38%, rgba(5, 20, 32, .78)); }
.gallery-card img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transition: transform .65s cubic-bezier(.2, .7, .3, 1); }
.gallery-card:hover img { transform: scale(1.045); }
.gallery-card:hover { color: #fff; }
.gallery-card-type { position: absolute; top: 16px; left: 16px; display: inline-flex; align-items: center; gap: 7px; padding: 5px 9px; background: rgba(6, 25, 42, .5); border: 1px solid rgba(255,255,255,.18); border-radius: 4px; font-size: 10px; font-weight: 500; backdrop-filter: blur(8px); }
.gallery-card-type svg { width: 13px; height: 13px; }
.gallery-card-caption { position: absolute; right: 48px; bottom: 20px; left: 20px; }
.gallery-card-caption > span { display: block; margin-bottom: 5px; font-size: 10px; color: #c5e4f5; }
.gallery-card-caption strong { display: block; font-size: 16px; font-weight: 500; line-height: 1.3; letter-spacing: -.02em; }
.gallery-card--featured .gallery-card-caption { left: 28px; bottom: 28px; }
.gallery-card--featured .gallery-card-caption strong { font-size: clamp(23px, 2.2vw, 32px); }
.gallery-card-open { position: absolute; right: 17px; bottom: 22px; display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid rgba(255,255,255,.4); border-radius: 50%; transition: background .2s; }
.gallery-card-open svg { width: 12px; height: 12px; }
.gallery-card:hover .gallery-card-open { background: var(--primary); border-color: var(--primary); }
.gallery-play { position: absolute; top: 50%; left: 50%; display: grid; place-items: center; width: 60px; height: 60px; border: 1px solid rgba(255,255,255,.7); border-radius: 50%; background: rgba(13,44,74,.45); transform: translate(-50%, -50%); backdrop-filter: blur(6px); }
.gallery-play svg { width: 25px; height: 25px; margin-left: 3px; }
.gallery-note { margin: 20px 0 0; font-size: 11px; color: var(--muted); }
.gallery-empty { padding: 64px 20px; margin: 0; text-align: center; color: var(--muted); background: var(--mist); border-radius: 6px; }
.gallery-section [hidden], .lightbox [hidden] { display: none !important; }
.gallery-card:focus-visible, .gallery-filters button:focus-visible, .gallery-all:focus-visible { outline: 3px solid var(--secondary); outline-offset: 4px; }

body.lightbox-open { overflow: hidden; }
.lightbox { position: fixed; inset: 0; width: 100%; height: 100%; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; color: #fff; background: #07121d; }
.lightbox::backdrop { background: rgba(3, 10, 17, .96); }
.lightbox-shell { display: flex; flex-direction: column; width: 100%; height: 100%; padding: max(16px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); }
.lightbox-top { display: flex; align-items: center; justify-content: space-between; flex: 0 0 auto; gap: 16px; padding-bottom: 16px; }
.lightbox-shell:fullscreen { background: #07121d; }
.lightbox-brand { font-size: 11px; font-weight: 500; letter-spacing: .12em; }
.lightbox-brand > span { margin-left: 12px; font-size: 10px; font-weight: 300; color: #99a9b7; }
.lightbox-tools { display: flex; align-items: center; gap: 8px; }
.lightbox-counter { margin-right: 16px; font-size: 12px; font-variant-numeric: tabular-nums; color: #c5d1dd; }
.lightbox-tools button, .lightbox-arrow { display: grid; place-items: center; width: 44px; height: 44px; flex-shrink: 0; border: 1px solid #334353; border-radius: 50%; background: #122230; color: #fff; transition: background .2s, border-color .2s; }
.lightbox-tools svg, .lightbox-arrow svg { width: 19px; height: 19px; }
.lightbox-tools button:hover, .lightbox-arrow:hover { border-color: #7ac5ef; background: #23455e; }
.lightbox-tools button[aria-pressed="true"] { background: var(--primary); }
.lightbox-tools button:disabled { opacity: .3; cursor: default; }
.lightbox button:focus-visible { outline: 2px solid #7ac5ef; outline-offset: 4px; }
.lightbox-stage { position: relative; display: flex; flex: 1 1 0; min-height: 0; align-items: center; justify-content: center; }
.lightbox-media { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 0; overflow: auto; overscroll-behavior: contain; touch-action: pan-y pinch-zoom; }
.lightbox-media img, .lightbox-media video { display: block; flex: 0 0 auto; width: auto; height: auto; max-width: calc(100% - 128px); max-height: 100%; object-fit: contain; border-radius: 3px; }
.lightbox-media img { cursor: zoom-in; }
.lightbox-media.is-zoomed { display: block; }
.lightbox-media.is-zoomed img { width: 180%; height: auto; max-width: none; max-height: none; margin: 0 auto; cursor: zoom-out; }
.lightbox-arrow { position: absolute; top: 50%; z-index: 2; transform: translateY(-50%); background: rgba(18,34,48,.85); }
.lightbox-prev { left: 0; }
.lightbox-next { right: 0; }
.lightbox-prev svg { transform: rotate(180deg); }
.lightbox-message { position: absolute; left: 60px; right: 60px; top: 50%; margin: 0; padding: 16px; text-align: center; font-size: 14px; color: #d0e0ec; background: #122230; transform: translateY(-50%); pointer-events: none; }
.lightbox-bottom { flex: 0 0 auto; padding-top: 22px; }
.lightbox-caption { text-align: center; }
.lightbox-caption > span { font-size: 10px; letter-spacing: .08em; color: #7ac5ef; }
.lightbox-caption h2 { margin: 4px 0; font-size: 20px; font-weight: 500; color: #fff; }
.lightbox-caption p { margin: 0 auto 16px; max-width: 75ch; font-size: 12px; color: #adbecb; }
.lightbox-thumbs { display: flex; justify-content: flex-start; gap: 8px; width: max-content; max-width: 100%; margin: 0 auto; padding: 5px; overflow-x: auto; scrollbar-width: thin; scrollbar-color: #334353 transparent; }
.lightbox-thumb { position: relative; flex: 0 0 62px; width: 62px; height: 44px; padding: 0; overflow: hidden; border: 2px solid transparent; border-radius: 4px; background: #23455e; opacity: .45; transition: opacity .2s; }
.lightbox-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.lightbox-thumb > svg { position: absolute; left: 50%; top: 50%; width: 19px; height: 19px; filter: drop-shadow(0 1px 3px #000); transform: translate(-50%, -50%); }
.lightbox-thumb[aria-current="true"] { opacity: 1; border-color: #7ac5ef; }
.lightbox-thumb:hover { opacity: 1; }
.lightbox-key-hint { display: block; margin-top: 10px; text-align: center; font-size: 10px; color: #899eae; }
.lightbox-key-hint span { margin: 0 10px; }
@media (min-width: 1600px) { .gallery-grid { grid-auto-rows: 220px; } }
@media (max-width: 849px) {
  .gallery-heading-row { align-items: flex-start; flex-direction: column; gap: 20px; }
  .gallery-total { display: none; }
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: clamp(160px, 29vw, 240px); gap: 12px; }
  .gallery-card--featured { grid-column: span 2; grid-row: span 1; }
  .gallery-card--portrait { grid-row: span 2; }
  .gallery-hint { display: none; }
  .gallery-preview { padding: 52px 0; }
  .lightbox-brand > span { display: none; }
  .lightbox-shell { padding-right: 12px; padding-left: 12px; }
  .lightbox-media img, .lightbox-media video { max-width: 100%; }
  .lightbox-arrow { width: 40px; height: 40px; }
  .lightbox-caption h2 { font-size: 18px; }
}
@media (max-width: 549px) {
  .gallery-crumb { margin-bottom: 30px; }
  .gallery-heading-row { margin-bottom: 24px; }
  .gallery-section { padding-top: 28px; padding-bottom: 48px; }
  .gallery-preview { padding-top: 48px; }
  .gallery-grid { grid-auto-rows: 180px; gap: 10px; }
  .gallery-card-caption { left: 12px; bottom: 14px; right: 30px; }
  .gallery-card-caption strong { font-size: 13px; }
  .gallery-card-caption > span { font-size: 9px; }
  .gallery-card--featured .gallery-card-caption { left: 18px; bottom: 18px; }
  .gallery-card-type { top: 10px; left: 10px; font-size: 9px; }
  .gallery-card-open { right: 9px; bottom: 13px; width: 22px; height: 22px; }
  .gallery-filters { gap: 2px; }
  .gallery-filters button { padding: 8px 12px; gap: 7px; }
  .lightbox-brand { font-size: 9px; letter-spacing: .06em; }
  .lightbox-tools { gap: 5px; }
  .lightbox-tools button { width: 38px; height: 38px; }
  .lightbox-counter { margin-right: 4px; font-size: 10px; }
  .lightbox-tools svg { width: 16px; height: 16px; }
  .lightbox-bottom { padding-top: 14px; }
  .lightbox-caption p { max-height: 4.8em; overflow: auto; font-size: 11px; }
  .lightbox-key-hint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-card img, .gallery-all svg, .lightbox button { transition: none; }
}
