.photo-tab-count{margin-left:3px;color:inherit;font:500 .82em var(--mono);opacity:.8}
.photo-stage,.photo-dialog-stage{position:relative;min-width:0;isolation:isolate;background:#101310}
.photo-stage{--stage-height:clamp(320px,49vh,500px);--stage-height:clamp(320px,49svh,500px)}
.photo-track{position:relative;display:flex;gap:5px;align-items:start;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:thin;scrollbar-color:#a4ac9e #252825;outline-offset:-4px!important}
.photo-item{flex:0 0 var(--photo-width);width:var(--photo-width);height:var(--stage-height);overflow:hidden;position:relative;display:block;cursor:zoom-in;outline-offset:-5px!important}
.photo-item img{display:block;position:absolute;left:0;top:var(--subject-y);transform:translateY(calc(0% - var(--subject-y)));width:var(--photo-width);height:auto;max-width:none}
.photo-arrow{position:absolute;top:50%;transform:translateY(-50%);z-index:2;display:grid;place-items:center;width:46px;height:56px;padding:0;border:1px solid #ffffff6b;background:#111510df;color:white;box-shadow:0 1px 9px #0003;cursor:pointer;touch-action:manipulation}
.photo-arrow[data-step="-1"]{left:0;border-radius:0 8px 8px 0;border-left:0}
.photo-arrow[data-step="1"]{right:0;border-radius:8px 0 0 8px;border-right:0}
.photo-arrow[aria-disabled="true"]{background:#15181585;color:#d7d9d7a8;border-color:#ffffff39;cursor:default}
.photo-arrow:focus-visible{outline-offset:-4px;outline-color:var(--yellow)}
@media(hover:hover){.photo-arrow:not([aria-disabled="true"]):hover{background:var(--yellow);color:#151815;border-color:var(--yellow)}}
#panel-photo .photo-caption{display:flex;align-items:flex-start;justify-content:space-between;gap:4px 16px;padding:11px 15px 8px;min-width:0}
.photo-description,.photo-dialog-head{display:flex;align-items:baseline;gap:11px;min-width:0}
.photo-description{flex:1 1 240px}
.photo-count{font:500 12px/1.4 var(--mono);color:var(--yellow);font-variant-numeric:tabular-nums;white-space:nowrap}
.photo-description strong{font-size:14px;line-height:1.4}
#panel-photo .figure-links{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
#panel-photo .figure-links a{min-height:44px}
.photo-dialog{position:fixed;inset:0;width:100%;height:100%;height:100dvh;max-width:none;max-height:none;border:0;margin:0;padding:0;color:#fff;background:#101310;overflow:hidden}
.photo-dialog[open]{display:grid;grid-template-rows:auto minmax(0,1fr)}
html:has(.photo-dialog[open]){overflow:hidden}
.photo-dialog::backdrop{background:#101310}
.photo-dialog-bar{padding:8px clamp(12px,2.5vw,40px);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:4px 16px;background:#191c19;border-bottom:1px solid #40453e}
.photo-dialog-head{flex:1 1 280px}
.photo-dialog h2{font-size:clamp(15px,1.25vw,20px);font-weight:600;line-height:1.3;letter-spacing:normal}
.photo-dialog-actions{display:flex;align-items:center;gap:8px}
.photo-dialog-actions button{min-height:44px;color:#fff;background:#2a2f29;border:1px solid #5f675c;border-radius:5px;padding:0 12px;font-size:13px}
#photo-fit[aria-pressed="true"]{color:var(--yellow)}
#photo-close span{font-size:18px;margin-left:3px}
.photo-dialog-stage{min-height:0}
.photo-pan{width:100%;height:100%;overflow:auto;overscroll-behavior:contain;display:flex;align-items:safe center;justify-content:safe center;outline-offset:-4px!important}
.photo-pan img{flex:none;width:auto;height:auto;max-width:none;max-height:none}
.photo-pan.is-fit img{width:100%;height:100%;object-fit:contain}
@media(max-width:680px){
 .photo-stage{--stage-height:clamp(290px,48vh,475px);--stage-height:clamp(290px,48svh,475px)}
 .photo-arrow{width:44px;height:52px}
 #panel-photo .photo-caption{padding:10px 13px 5px}
 #panel-photo .figure-links a,.photo-dialog-actions button{min-height:44px}
 .photo-description{flex-basis:100%}
}
