
.mfg-gate{position:relative;max-width:none;margin:0 auto 2rem;padding:clamp(22px,3vw,40px);border:1px solid #d7e5f4;border-radius:34px;background:linear-gradient(180deg,#dff3ff 0%,#f7fbff 100%);box-shadow:0 20px 48px rgba(17,52,99,.10);color:#16386d;overflow:hidden}
.mfg-gate :focus-visible,.mfg-private-grid a:focus-visible{outline:3px solid #e09d23;outline-offset:4px}
.mfg-gate__inner{max-width:1060px;margin:0 auto}
.mfg-gate__eyebrow{margin:0 0 18px;font-size:clamp(1.3rem,2vw,1.9rem);font-weight:800;color:#173a73}
.mfg-gate__hero{display:grid;grid-template-columns:minmax(130px,170px) minmax(0,1fr) minmax(130px,170px);align-items:start;gap:16px;margin-bottom:18px}
.mfg-gate__art{display:flex;justify-content:center;align-items:flex-start;padding-top:8px}
.mfg-gate__art svg{width:min(100%,136px);height:auto;display:block;filter:drop-shadow(0 10px 16px rgba(31,103,188,.14))}
.mfg-gate__art--lock svg{width:min(100%,112px)}
.mfg-gate__content{text-align:center}
.mfg-gate__title{margin:0 0 10px!important;font-size:clamp(2rem,4vw,3rem)!important;line-height:1.1;color:#143c83;font-weight:800}
.mfg-gate__subtitle{margin:0 auto 20px!important;max-width:650px;font-size:clamp(1rem,1.4vw,1.22rem);line-height:1.5;color:#35527b}
.mfg-gate__alert{max-width:650px;margin:0 auto 16px;padding:12px 14px;border-radius:14px;background:#fff3f3;border:1px solid #f0b0b0;color:#8b2331}
.mfg-gate__form{max-width:650px;margin:0 auto}
.mfg-gate__form label{display:block;text-align:left;font-weight:800;margin:0 0 8px;color:#163c73}
.mfg-gate .mfg-password-field{display:block;position:relative}
.mfg-gate .mfg-password-field input:is([type=password],[type=text]){width:100%;max-width:100%;min-height:58px;padding:14px 60px 14px 18px;border:2px solid #7698c8;border-radius:18px;background:#fff;color:#10233e;font-size:1.08rem;box-shadow:inset 0 1px 2px rgba(0,0,0,.03)}
.mfg-gate button[type=submit]{display:inline-flex;align-items:center;justify-content:center;gap:10px;min-height:58px;margin-top:18px;padding:14px 30px;border:0;border-radius:18px;background:linear-gradient(180deg,#ff3b8f 0%,#ea126f 100%);color:#fff;font-weight:800;font-size:1.08rem;cursor:pointer;box-shadow:0 14px 24px rgba(234,18,111,.22)}
.mfg-gate button[type=submit]:hover{transform:translateY(-1px)}
.mfg-gate__help{margin:14px 0 0;color:#35527b;font-style:italic}
.mfg-gate__footer{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;margin-top:18px}
.mfg-gate__back{color:#1658a3!important;text-decoration:none!important;font-weight:700}
.mfg-gate__back:hover{text-decoration:underline!important}
.mfg-gate__decor{position:absolute;pointer-events:none;inset:auto 0 0 0;height:32px;background:linear-gradient(90deg,rgba(255,255,255,0) 0%,rgba(255,255,255,.28) 50%,rgba(255,255,255,0) 100%)}
.mfg-private-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,220px),1fr));gap:18px;margin:20px 0}
.mfg-private-grid figure{margin:0;border:1px solid #a9b5be;border-radius:10px;overflow:hidden;background:#fff}
.mfg-private-grid img{width:100%;height:220px;object-fit:cover;display:block}
.mfg-private-grid figcaption{padding:10px}
.mfg-protected-label{display:block;font-size:.85rem;font-weight:650;margin-top:4px}
@media(max-width:860px){.mfg-gate__hero{grid-template-columns:1fr;gap:10px}.mfg-gate__art{order:2}.mfg-gate__content{order:1}.mfg-gate__art--rain{order:3}.mfg-gate__footer{justify-content:center}.mfg-gate__back{width:100%;text-align:center}}
@media(prefers-reduced-motion:reduce){.mfg-gate *,.mfg-private-grid *{scroll-behavior:auto!important;animation:none!important;transition:none!important}}
@media(forced-colors:active){.mfg-gate,.mfg-private-grid figure{border:2px solid CanvasText}.mfg-gate button{forced-color-adjust:auto}}
.mfg-gallery-list-wrap .mfg-gallery-detail{background:#fff!important;background-color:#fff!important;color:#1e293b!important}

/* 2.5.44: no redundant exterior spacing on the locked view. */
.mfg-gallery-detail > .mfg-gate{margin-bottom:0}

/* High contrast for locked and unlocked private galleries. */
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gallery-list-wrap .mfg-gallery-detail{background:transparent!important;color:#fff!important;box-shadow:none!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate{background:#000!important;color:#fff!important;border-color:#fff!important;box-shadow:none!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate :is(.mfg-gate__eyebrow,.mfg-gate__title,.mfg-gate__subtitle,.mfg-gate__help,label){color:#fff!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-password-field input{background:#000!important;color:#fff!important;border:2px solid #fff!important;box-shadow:none!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-eye-toggle{background:#000!important;color:#fff!important;border:1px solid #fff!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate button[type=submit]{background:#000!important;color:#ffff00!important;border:2px solid #ffff00!important;box-shadow:none!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-gate__back{color:#ffff00!important;text-decoration:underline!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-gate__alert{background:#000!important;color:#fff!important;border:2px solid #ffff00!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate__decor{display:none}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-private-grid :is(figure,figcaption){background:#000!important;color:#fff!important;border-color:#fff!important}
:is(body.high-contrast,html.zsams-high-contrast-early body) :is(.mfg-gate,.mfg-private-grid) :focus-visible{outline:3px solid #ffff00!important;outline-offset:3px}

/* 2.5.49: visible keyboard focus on each individual photograph. */
.mfg-private-grid > figure > a {display:block;position:relative;border-radius:12px;}
.mfg-private-grid > figure > a:focus-visible {outline:3px solid var(--focus-ring,#ffbf47)!important;outline-offset:3px!important;box-shadow:0 0 0 3px var(--focus-ring-shadow,rgba(31,41,55,.95))!important;z-index:2;}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-private-grid > figure > a:focus-visible {outline:3px solid #ffff00!important;outline-offset:3px!important;box-shadow:0 0 0 3px #000!important;}
@media(forced-colors:active) {.mfg-private-grid > figure > a:focus-visible {outline:3px solid Highlight!important;box-shadow:none!important;}}

.mfg-private-grid > figure {overflow:visible;}
.mfg-private-grid > figure > a {overflow:hidden;border-radius:9px;}
.mfg-private-grid > figure > a > img {border-radius:inherit;}

/* 2.5.51: one consistent password visibility control. */
.mfg-gate input::-ms-reveal,.mfg-gate input::-ms-clear{display:none!important;}
.mfg-gate .mfg-password-field button.mfg-eye-toggle{width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;max-width:44px!important;margin:0!important;padding:9px!important;right:7px;top:50%;transform:translateY(-50%);background:transparent!important;color:#17376d!important;border:0!important;box-shadow:none!important;}
.mfg-gate .mfg-password-field button.mfg-eye-toggle svg{display:block!important;width:24px!important;height:24px!important;flex:none;fill:none!important;stroke:currentColor!important;visibility:visible!important;opacity:1!important;pointer-events:none;}
.mfg-gate .mfg-password-field button.mfg-eye-toggle:hover{background:transparent!important;color:#0b4e99!important;}
.mfg-gate .mfg-password-field button.mfg-eye-toggle:focus-visible{outline:3px solid var(--focus-ring,#ffbf47)!important;outline-offset:1px!important;box-shadow:0 0 0 2px var(--focus-ring-shadow,#1f2937)!important;}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-password-field button.mfg-eye-toggle{color:#fff!important;background:transparent!important;}
:is(body.high-contrast,html.zsams-high-contrast-early body) .mfg-gate .mfg-password-field button.mfg-eye-toggle:focus-visible{outline-color:#ffff00!important;box-shadow:none!important;}
@media(forced-colors:active){.mfg-gate .mfg-password-field button.mfg-eye-toggle{color:ButtonText!important;}.mfg-gate .mfg-password-field button.mfg-eye-toggle:focus-visible{outline-color:Highlight!important;box-shadow:none!important;}}

.mfg-parent-logout{display:flex;justify-content:flex-end;margin:0 0 16px}.mfg-parent-logout button{background:#fff;color:#173b75;border:1px solid #7698c8;border-radius:10px;padding:10px 16px;min-height:44px;font-weight:700;cursor:pointer}.mfg-parent-logout button:focus-visible{outline:3px solid #ffbf47;outline-offset:3px;box-shadow:0 0 0 2px #1f2937}body.high-contrast .mfg-parent-logout button{background:#000!important;color:#fff!important;border-color:#fff!important}body.high-contrast .mfg-parent-logout button:focus-visible{outline-color:#ff0!important}

/* 2.5.57: single full-width locked gallery panel. */
.mfg-gallery-list-wrap #mfg-gallery-detail.mfg-gallery-detail--locked{padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;border-radius:0!important;overflow:visible!important}
.mfg-gallery-detail--locked .mfg-gate{width:100%;max-width:none;margin:0;box-sizing:border-box}
.mfg-gate__hero{grid-template-columns:minmax(85px,150px) minmax(0,1fr) minmax(85px,150px);grid-template-areas:"sun lock rain" "sun content rain";gap:0 16px;align-items:start}
.mfg-gate__art--sun{grid-area:sun;align-self:start}
.mfg-gate__art--lock{grid-area:lock;padding:0;justify-self:center}
.mfg-gate__art--lock svg{width:85px;height:99px}
.mfg-gate__art--rain{grid-area:rain;align-self:start}
.mfg-gate__content{grid-area:content;min-width:0}
.mfg-gate__form{width:100%}
.mfg-gate__footer{margin-top:24px}
@media(max-width:860px){.mfg-gate__hero{grid-template-columns:minmax(0,1fr) minmax(0,1fr) minmax(0,1fr);grid-template-areas:"sun lock rain" "content content content";gap:12px}.mfg-gate__art svg{max-width:100%;width:95px}.mfg-gate__art--lock svg{width:66px;height:77px}.mfg-gate__art{padding:0}.mfg-gate__title{overflow-wrap:anywhere}}

/* 2.5.58: remove the school theme's outer white card only for the password gate. */
html body .page-card:is(.page-card--gallery-detail-open,.page-card-gallery-detail-open):has(.mfg-gallery-detail--locked .mfg-gate){background:transparent!important;background-image:none!important;border:0!important;box-shadow:none!important;padding:0!important;overflow:visible!important}
html body .page-card:is(.page-card--gallery-detail-open,.page-card-gallery-detail-open):has(.mfg-gallery-detail--locked .mfg-gate) > .entry-content{padding:0!important;margin:0!important;background:transparent!important;border:0!important;box-shadow:none!important;max-width:none!important}
.mfg-gallery-list-wrap:has(.mfg-gallery-detail--locked){margin:0!important;padding:0!important;background:transparent!important;border:0!important;box-shadow:none!important}
.mfg-gate .mfg-gate__form{width:100%;max-width:520px;margin-inline:auto!important;text-align:center}
.mfg-gate .mfg-gate__form > p{width:100%;max-width:none;margin-inline:auto!important;box-sizing:border-box}
.mfg-gate .mfg-gate__form .mfg-password-field{width:100%;max-width:100%;margin-inline:auto!important}
.mfg-gate .mfg-gate__form button[type=submit]{margin-inline:auto!important;max-width:100%;white-space:normal}
