#kas-rehberi .kg-photo-open { position: relative; display: block; width: 100%; color: #fffef2; }
#kas-rehberi .kg-card-visual .kg-photo-open, #kas-rehberi .kg-cover .kg-cover-photo .kg-photo-open { position: absolute; inset: 0; height: 100%; }
#kas-rehberi .kg-photo-open:focus-visible { outline: 3px solid #f7efc5; outline-offset: -5px; }
#kas-rehberi .kg-photo-expand { position: absolute; right: 14px; top: 14px; display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid #fff9; border-radius: 50%; background: #0a272d99; color: #fffef5; pointer-events: none; }
#kas-rehberi .kg-photo-expand svg { width: 22px; height: 22px; }
#kas-rehberi .kg-cover .kg-photo-expand { top: 22px; right: 24px; }
#kas-rehberi .kg-card-category, #kas-rehberi .kg-card-photo-credit, #kas-rehberi .kg-card-shade, #kas-rehberi .kg-cover-shade { pointer-events: none; }
#kas-rehberi .kg-card-category { max-width: calc(100% - 88px); }
html:has(#kg-photo-dialog[open]) { overflow: hidden; }
#kas-rehberi #kg-photo-dialog {
  position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; border-radius: 0;
  color: #f2f5eb; background: #071116; overflow: hidden; overscroll-behavior: none; color-scheme: dark;
}
#kas-rehberi #kg-photo-dialog::backdrop { background: #071116; }
#kas-rehberi #kg-photo-dialog [hidden] { display: none !important; }
#kas-rehberi #kg-photo-dialog .kg-photo-shell { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; width: 100%; height: 100%; min-height: 0; }
#kas-rehberi #kg-photo-dialog .kg-photo-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 68px; padding: 10px 24px; background: #0e1d23; border-bottom: 1px solid #d7e4df24; }
#kas-rehberi #kg-photo-dialog-title { margin: 0; color: #f2f5eb; font: 600 18px/1.4 var(--body, Arial, sans-serif); letter-spacing: 0; text-wrap: balance; }
#kas-rehberi #kg-photo-dialog button { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; gap: 9px; min-width: 48px; min-height: 48px; padding: 10px 14px; border: 1px solid #d9e8d87a; border-radius: 999px; color: #f5f9ed; background: #e6eee514; cursor: pointer; font: 650 14px/1.4 var(--body, Arial, sans-serif); }
#kas-rehberi #kg-photo-dialog button:hover { background: #e6eee52b; }
#kas-rehberi #kg-photo-dialog button:focus-visible, #kas-rehberi #kg-photo-dialog a:focus-visible { outline: 2px solid #f4edba; outline-offset: 4px; }
#kas-rehberi #kg-photo-dialog button svg { width: 22px; height: 22px; }
#kas-rehberi #kg-photo-dialog .kg-photo-row { display: grid; grid-template-columns: 76px minmax(0, 1fr) 76px; align-items: center; gap: 6px; min-height: 0; padding: 12px 10px; }
#kas-rehberi #kg-photo-dialog .kg-photo-arrow { width: 52px; height: 52px; padding: 10px; justify-self: center; background: #dfeddf21; border-color: #e2edde8c; }
#kas-rehberi #kg-photo-dialog .kg-photo-arrow svg { width: 27px; height: 27px; }
#kas-rehberi #kg-photo-dialog .kg-photo-canvas { position: relative; display: grid; place-items: center; width: 100%; height: 100%; min-width: 0; min-height: 0; overflow: hidden; touch-action: pan-y pinch-zoom; user-select: none; }
#kas-rehberi #kg-photo-image { display: block; width: 100%; height: 100%; min-width: 0; min-height: 0; max-width: 100%; max-height: 100%; object-fit: contain; object-position: center; border-radius: 0; pointer-events: none; user-select: none; }
#kas-rehberi #kg-photo-dialog[data-state="ready"] #kg-photo-image { animation: kg-photo-reveal 140ms ease-out; }
#kas-rehberi #kg-photo-dialog .kg-photo-status { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 16px; padding: 20px; text-align: center; pointer-events: none; }
#kas-rehberi #kg-photo-status { color: #d5dfd8; font-size: 16px; line-height: 1.6; }
#kas-rehberi #kg-photo-original { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 15px; border: 1px solid #a8c9b9; border-radius: 999px; color: #e4f1d9; font-size: 14px; text-decoration: none; pointer-events: auto; }
#kas-rehberi #kg-photo-dialog .kg-photo-bottom { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 16px 24px; padding: 15px 26px 18px; max-height: 25vh; overflow: auto; background: #0e1d23; border-top: 1px solid #d7e4df24; }
#kas-rehberi #kg-photo-caption { color: #f2f5eb; font: 600 17px/1.4 var(--body, Arial, sans-serif); margin: 0 0 6px; }
#kas-rehberi #kg-photo-credit { color: #c5d4cb; font-size: 14px; line-height: 1.65; margin: 0; overflow-wrap: anywhere; }
#kas-rehberi #kg-photo-credit a { color: #d8edd0; text-decoration: underline; text-underline-offset: 3px; }
#kas-rehberi #kg-photo-count { color: #edf5e5; font: 650 16px/1.4 var(--body, Arial, sans-serif); white-space: nowrap; margin: 0; padding: 6px 0; }
@keyframes kg-photo-reveal { from { opacity: .2; } to { opacity: 1; } }
@media (max-width: 760px) {
  #kas-rehberi #kg-photo-dialog .kg-photo-top { min-height: 64px; padding: 8px 14px; gap: 12px; }
  #kas-rehberi #kg-photo-dialog-title { font-size: 16px; }
  #kas-rehberi #kg-photo-dialog button { min-width: 44px; min-height: 44px; padding: 9px 12px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-row { grid-template-columns: 46px minmax(0, 1fr) 46px; gap: 2px; padding: 8px 3px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-arrow { width: 44px; height: 48px; padding: 7px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-arrow svg { width: 25px; height: 25px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-bottom { align-items: start; gap: 12px; padding: 12px 15px 15px; max-height: 28vh; }
  #kas-rehberi #kg-photo-caption { font-size: 15px; }
  #kas-rehberi #kg-photo-credit { font-size: 12px; line-height: 1.6; }
  #kas-rehberi #kg-photo-count { font-size: 14px; padding-top: 0; }
}
@media (max-height: 500px) {
  #kas-rehberi #kg-photo-dialog .kg-photo-top { min-height: 54px; padding: 5px 14px; }
  #kas-rehberi #kg-photo-dialog button { min-width: 44px; min-height: 44px; padding: 8px 12px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-row { padding-top: 5px; padding-bottom: 5px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-arrow { width: 48px; height: 48px; }
  #kas-rehberi #kg-photo-dialog .kg-photo-bottom { padding: 7px 18px 9px; max-height: 26vh; }
  #kas-rehberi #kg-photo-caption { margin-bottom: 3px; font-size: 14px; }
  #kas-rehberi #kg-photo-credit { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  #kas-rehberi #kg-photo-dialog[data-state="ready"] #kg-photo-image { animation: none; }
}
