.custom-catalog-entry{width:100%;margin-top:18px;border-top:1px solid #d6ded7;border-radius:4px;min-height:52px}
.custom-catalog-active .catalog-head{display:flex;flex-direction:column;align-items:stretch;gap:18px}
.custom-catalog-active .catalog-head>div:first-child{width:100%;max-width:none}
.custom-catalog-active .catalog-head .action-row{justify-content:flex-start;flex-wrap:wrap}
.custom-catalog-active .catalog-head .catalog-search{flex:1 1 200px;width:auto;max-width:560px}
.custom-catalog-active .subcat-strip{flex-wrap:wrap;overflow:visible;gap:8px}
.custom-catalog-active .subcat-pill{min-width:0;gap:12px}
.custom-catalog-entry:focus-visible,.custom-product-dialog button:focus-visible,.custom-case-card:focus-visible{outline:3px solid #426a24;outline-offset:3px}
.custom-catalog-note{grid-column:1/-1;font-size:14px;line-height:1.8;padding:12px 0;color:#56615b;border-bottom:1px solid #d9e0da}
.custom-card-meta{display:flex;justify-content:space-between;gap:12px;font-size:12px;line-height:1.7;color:#52615a;margin-bottom:12px}
.custom-card-meta>span:last-child{flex-shrink:0}
.custom-case-cover{position:relative;overflow:hidden;aspect-ratio:4/3;background:#f5f5ef}
.custom-case-cover>.profile-photo{width:100%}
.custom-catalog-grid .profile-photo,.custom-product-dialog .profile-photo{display:block;position:relative;overflow:hidden;aspect-ratio:var(--photo-ratio,1.3333)}
.custom-catalog-grid .profile-photo>img,.custom-product-dialog .profile-photo>img{position:absolute!important;max-width:none!important;width:var(--photo-width)!important;height:var(--photo-height)!important;left:var(--photo-left)!important;top:var(--photo-top)!important;object-fit:fill!important}
.custom-more{position:absolute;right:14px;bottom:12px;display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:600;color:#17221c;text-shadow:0 1px 4px #fff,0 0 8px #fff}
.custom-more svg{width:19px;height:19px}
.custom-case-card{transition:transform .16s ease,box-shadow .16s ease}
.custom-case-card:hover{transform:translateY(-2px);box-shadow:0 8px 22px #17221c0d}
.custom-case-card .product-body h3{font-size:19px;line-height:1.6;letter-spacing:.02em}
.custom-case-card .product-body p{line-height:1.85}
.custom-photo-error{display:grid;place-items:center;min-height:180px;color:#677068}
.custom-product-dialog{width:min(1240px,94vw);max-height:90vh;margin:auto;border:1px solid #d8dfd8;border-radius:8px;padding:28px;color:#18231c;background:#fff;overflow:auto}
.custom-product-dialog::backdrop{background:#17221c88}
.custom-product-dialog>header{display:flex;align-items:flex-start;justify-content:space-between;gap:24px;margin-bottom:24px}
.custom-product-dialog h2{font-size:28px;line-height:1.5;margin:8px 0;letter-spacing:.02em}
.custom-product-dialog header p{font-size:13px;color:#657068;margin:0}
.custom-detail-layout{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(260px,1fr);gap:32px}
.custom-detail-photo{min-height:240px;height:49vh;display:flex;justify-content:center;align-items:center;background:#f6f6f1}
.custom-detail-photo>.profile-photo{width:min(100%,calc(49vh * var(--photo-ratio)));max-height:49vh}
.custom-gallery-controls{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:14px 0;font-size:13px;color:#4e5e54}
.custom-gallery-controls button{min-width:44px;min-height:44px}
.custom-detail-thumbs{display:flex;gap:8px;overflow-x:auto;padding:4px}
.custom-detail-thumbs>button{padding:3px;border:1px solid #c4cec6;border-radius:4px;background:#fff;flex:0 0 76px}
.custom-detail-thumbs>button[aria-pressed=true]{outline:2px solid #4d6b21;background:#dcff33}
.custom-detail-thumbs .profile-photo{width:100%}
.custom-detail-copy{font-size:16px;line-height:1.9;letter-spacing:.025em}
.custom-detail-copy>p:first-child{margin-top:0;white-space:pre-line}
.custom-detail-note{padding:16px 0;border-block:1px solid #d8dfd8;color:#52615a;font-size:14px}
.custom-detail-copy>.btn{display:block;margin:26px 0 16px;min-height:48px;background:#dcff33;color:#18231c;border:1px solid #dcff33;font-weight:600}
.custom-detail-copy>a{color:#334c3c;font-size:14px;text-underline-offset:5px}
@media(max-width:800px){.custom-detail-layout{grid-template-columns:1fr}.custom-product-dialog{padding:18px}.custom-product-dialog h2{font-size:22px}.custom-card-meta{flex-wrap:wrap}.custom-detail-photo{height:40vh}.custom-detail-photo>.profile-photo{width:min(100%,calc(40vh * var(--photo-ratio)));max-height:40vh}}
@media(prefers-reduced-motion:reduce){.custom-case-card{transition:none}.custom-case-card:hover{transform:none}}

/* Full descriptions remain readable even when long or split into paragraphs. */
.custom-detail-copy{min-width:0;overflow-wrap:anywhere}
.custom-detail-layout>div{min-width:0}
#customDetailDesc{white-space:pre-wrap}
#customDetailTitle,#customFrameName{overflow-wrap:anywhere}
