/* SKTC Ordensgalerie V5 – nur innerhalb der Galerie und ihrer Modals */
.sktc-ordengalerie {font-family:Calibri,Arial,sans-serif;color:#383838;line-height:1.55;}
.sktc-ordengalerie *, .sktc-og-modal * {box-sizing:border-box;}
.sktc-ordengalerie a,.sktc-og-modal a {text-decoration:none;}
.sktc-ordengalerie .og-title {text-align:center;color:#254477;line-height:1.25;margin:0 0 1rem;}
.sktc-ordengalerie .og-club {text-align:center;margin:0 auto 1.1rem;}
.sktc-ordengalerie .og-club img {display:block;width:min(100%,340px)!important;height:auto!important;margin:0 auto .5rem;}
.sktc-ordengalerie .og-club .og-caption {font-size:1.05rem;}
.sktc-ordengalerie .og-club small {display:block;font-size:.88rem;}
.sktc-ordengalerie .og-intro {text-align:center;max-width:680px;margin:0 auto 1.3rem;}
.sktc-ordengalerie .og-colors {height:4px;border-radius:4px;background:linear-gradient(90deg,#c92130 25%,#fff 25% 50%,#254477 50% 75%,#eac022 75%);margin:1rem 0;}
.sktc-ordengalerie .og-grid {display:grid!important;grid-template-columns:repeat(auto-fill,minmax(min(100%,116px),1fr));gap:7px 8px;padding:8px 2px 20px;align-items:start;max-width:800px;margin:0 auto;}
.sktc-ordengalerie .og-grid .og-item {display:flex!important;flex-direction:column;align-items:center;justify-content:center;min-width:0;width:100%;margin:0;padding:3px 1px 5px;background:none;border:0;text-align:center;color:#383838;cursor:pointer;--og-shift:0px;--og-rotate:-6deg;}
.sktc-ordengalerie .og-grid .og-item:nth-child(4n+2) {--og-shift:16px;--og-rotate:6deg;}
.sktc-ordengalerie .og-grid .og-item:nth-child(4n+3) {--og-shift:4px;--og-rotate:-3deg;}
.sktc-ordengalerie .og-grid .og-item:nth-child(4n+4) {--og-shift:12px;--og-rotate:8deg;}
.sktc-ordengalerie .og-grid .og-item {margin-top:var(--og-shift);}
.sktc-ordengalerie .og-grid .og-item img {display:block!important;width:108px!important;height:108px!important;max-width:100%!important;max-height:108px!important;object-fit:contain!important;margin:0 auto!important;padding:0!important;border:0!important;border-radius:0!important;transform:rotate(var(--og-rotate));filter:drop-shadow(2px 4px 3px #0003);transition:transform .18s ease;}
.sktc-ordengalerie .og-grid .og-item:hover img,.sktc-ordengalerie .og-grid .og-item:focus-visible img {transform:rotate(0) scale(1.12);}
.sktc-ordengalerie .og-year {display:block;font-size:14px;font-weight:700;line-height:1.2;margin-top:5px;}
.sktc-ordengalerie .og-item:focus-visible,.sktc-og-modal .og-btn:focus-visible,.sktc-ordengalerie .og-btn:focus-visible {outline:2px solid #254477;outline-offset:3px;}
/* Normale HTML-Detailbereiche bleiben verborgen. Ohne JS gibt es einen CSS-Target-Fallback. */
.sktc-ordengalerie .og-dialog {display:none!important;}
.sktc-ordengalerie:not(.og-enhanced) .og-dialog:target {display:block!important;position:fixed;inset:0;margin:auto;width:min(92vw,860px);height:max-content;max-height:86vh;max-height:86dvh;overflow:auto;z-index:2147483640;box-shadow:0 0 0 100vmax #0009;}
.sktc-og-modal,.sktc-ordengalerie .og-dialog:target {font-family:Calibri,Arial,sans-serif;color:#383838;background:#fffdf9;border:1px solid #ddd;border-radius:14px;padding:0;line-height:1.5;}
.sktc-og-modal {position:fixed;inset:0;margin:auto;width:min(92vw,860px);max-width:92vw;height:max-content;max-height:86vh;max-height:86dvh;overflow:auto;box-shadow:0 14px 65px #0005;}
.sktc-og-modal:not([open]) {display:none!important;}
.sktc-og-modal::backdrop {background:#0009;}
.sktc-og-modal .og-head,.sktc-ordengalerie .og-dialog .og-head {display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 16px;border-bottom:1px solid #ddd;position:sticky;top:0;background:#fffdf9;z-index:2;}
.sktc-og-modal .og-head h3,.sktc-ordengalerie .og-dialog .og-head h3 {margin:0;color:#254477;font-size:1.25rem;line-height:1.3;}
.sktc-og-modal .og-content,.sktc-ordengalerie .og-dialog .og-content {display:grid;grid-template-columns:minmax(0,340px) minmax(0,1fr);align-items:center;gap:18px;padding:16px;}
.sktc-og-modal .og-figure,.sktc-ordengalerie .og-dialog .og-figure {margin:0;text-align:center;}
.sktc-og-modal .og-content img,.sktc-ordengalerie .og-dialog .og-content img {display:block;width:100%!important;max-width:340px!important;height:auto!important;max-height:380px!important;object-fit:contain;margin:0 auto 8px!important;border-radius:0!important;}
.sktc-og-modal .og-motto,.sktc-ordengalerie .og-dialog .og-motto {font-size:1.12rem;font-weight:bold;color:#254477;line-height:1.4;margin:0 0 .45rem;}
.sktc-og-modal .og-author,.sktc-ordengalerie .og-dialog .og-author {font-size:.88rem;font-style:italic;margin:0 0 .8rem;}
.sktc-og-modal .og-foot,.sktc-ordengalerie .og-dialog .og-foot {display:flex;align-items:center;justify-content:space-between;gap:6px;padding:10px 12px;border-top:1px solid #ddd;flex-wrap:wrap;position:sticky;bottom:0;background:#fffdf9;}
.sktc-og-modal .og-btn,.sktc-ordengalerie .og-dialog .og-btn {display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:6px 9px;border:1px solid #254477;border-radius:6px;color:#254477;background:#fff;font-size:.9rem;font-weight:600;cursor:pointer;text-decoration:none;}
.sktc-og-modal .og-close,.sktc-ordengalerie .og-dialog .og-close {background:#254477;color:#fff;}
.sktc-og-modal .og-x,.sktc-ordengalerie .og-dialog .og-x {font-size:1.5rem;min-width:44px;}
.sktc-og-modal .og-spacer,.sktc-ordengalerie .og-dialog .og-spacer {min-width:44px;}
@media(max-width:600px){
 .sktc-ordengalerie .og-grid {grid-template-columns:repeat(auto-fill,minmax(min(100%,88px),1fr));gap:5px 4px;}
 .sktc-ordengalerie .og-grid .og-item img {width:84px!important;height:84px!important;max-height:84px!important;}
 .sktc-ordengalerie .og-grid .og-item {margin-top:calc(var(--og-shift) * .65);}
 .sktc-og-modal .og-content,.sktc-ordengalerie .og-dialog .og-content {grid-template-columns:1fr;gap:10px;padding:12px;}
 .sktc-og-modal .og-content img,.sktc-ordengalerie .og-dialog .og-content img {max-width:280px!important;max-height:280px!important;}
}
@media(prefers-reduced-motion:reduce){.sktc-ordengalerie .og-grid .og-item img {transition:none;}}

/* Scrollleistenplatz beim Oeffnen der Ordensdetails beibehalten. */
html:has(#sktc-ordengalerie.og-enhanced) {scrollbar-gutter:stable;}

/* V5: Originaltexte und Bilddetailansicht; nur Galerie-Elemente. */
.sktc-og-modal .og-story {min-width:0;overflow-wrap:break-word;}
.sktc-og-modal .og-story p {margin:0 0 .85rem;}
.sktc-og-modal .og-story .og-author {margin-bottom:1rem;}
.sktc-og-modal .og-content {align-items:start;}
.sktc-og-modal .og-foot {z-index:2;}
.sktc-ordengalerie .og-original-footer {margin:1rem auto 0;max-width:680px;}
.sktc-og-modal .og-zoom-trigger {display:block;width:100%;border:0;background:transparent;padding:0;cursor:zoom-in;position:relative;}
.sktc-og-modal .og-zoom-trigger img {transition:transform .2s ease;}
.sktc-og-modal .og-zoom-hint {display:block;font:600 .85rem Calibri,Arial,sans-serif;color:#254477;margin:.5rem 0;}
@media (hover:hover) and (pointer:fine) {
 .sktc-og-modal .og-zoom-trigger:hover img {transform:scale(1.09);}
}
.sktc-og-modal .og-zoom-trigger:focus-visible {outline:2px solid #254477;outline-offset:3px;}
.sktc-og-image-modal {width:min(94vw,1100px);max-width:94vw;max-height:92vh;max-height:92dvh;}
.sktc-og-image-modal .og-image-body {padding:10px;text-align:center;}
.sktc-og-image-modal .og-image-body img {display:block;margin:auto;width:100%!important;height:72vh!important;height:72dvh!important;max-width:100%!important;max-height:72vh!important;max-height:72dvh!important;object-fit:contain;}
.sktc-og-image-modal .og-foot {justify-content:center;}
@media(prefers-reduced-motion:reduce){.sktc-og-modal .og-zoom-trigger img {transition:none;}}
