.private-gallery-access {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 24px;
    background: rgba(35, 25, 29, 0.0);
}

.private-gallery-access[hidden] {
    display: none;
}

.private-gallery-popup {
    width: min(100%, 440px);
    padding: 42px 40px 40px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 24px;
    background: rgba(255, 250, 250, 1.0);
    box-shadow: 0 24px 80px rgba(37, 16, 25, 0.28);
    box-sizing: border-box;
}

.private-gallery-eyebrow {
    display: block;
    margin-bottom: 14px;
    color: #b55d73;
    font-family: var(--font-bold);
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.private-gallery-access h1 {
    color: #24191d;
    font-size: clamp(30px, 5vw, 42px);
    letter-spacing: -0.04em;
    line-height: 1;
    margin-bottom: 14px;
}

.private-gallery-intro {
    max-width: 32ch;
    color: #6b575d;
    line-height: 1.55;
    margin-top: 0;
    margin-bottom: 28px;
}

.private-gallery-access form {
    gap: 8px;
}

.private-gallery-access label {
    color: #49383e;
    font-family: var(--font-bold);
    font-size: 12px;
    letter-spacing: 0.04em;
}

.private-gallery-access form input {
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid #ead7dc;
    border-radius: 10px;
    background: #fff;
    color: #24191d;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.private-gallery-access form input:focus {
    border-color: #d68197;
    box-shadow: 0 0 0 3px rgba(214, 129, 151, 0.18);
}

.private-gallery-access form .button {
    width: auto;
    min-height: 46px;
    margin: 10px 0 0;
    padding: 12px 19px;
    border: 0;
    border-radius: 10px;
    color: #fff;
    background: #d97891;
    letter-spacing: 0.07em;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.private-gallery-access form .button:hover {
    border: 0;
    background: #c9657d;
    transform: translateY(-1px);
}

.private-gallery-error {
    margin-bottom: 0;
    color: #a32929;
    font-size: 13px;
}

.private-gallery-images img {
    display: block;
    width: 100%;
    height: 300px;
    object-fit: cover;
    filter: none;
    transform: none;
    transition: opacity 0.3s ease;
}

.private-gallery-content {
    position: relative;
}

.private-gallery-content.is-unlocked .private-gallery-images img {
    filter: none;
    transform: none;
}

.private-gallery-content:not(.is-unlocked) .private-gallery-images a {
    cursor: not-allowed;
    pointer-events: none;
}

.private-gallery-userbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    max-width: 1200px;
    margin: 20px auto 0;
    padding: 0 20px;
    box-sizing: border-box;
}

.private-gallery-signed-in {
    font-size: 0.85rem;
    opacity: 0.6;
}

.private-gallery-username-link {
    color: var(--color-action);
    text-decoration: none;
    transition: color 0.25s var(--easing);
}

.private-gallery-username-link:hover {
    text-decoration: underline;
}

.private-gallery-username-link strong {
    font-weight: inherit;
}

.private-gallery-userbar form {
    width: auto;
}

.private-gallery-logout {
    padding: 0 0 2px;
    border: none;
    border-bottom: 1px solid rgba(0, 0, 0, 0.25);
    border-radius: 0;
    background: none;
    color: var(--color-text);
    font-family: var(--font-bold);
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    cursor: pointer;
    transition: color 0.25s var(--easing), border-color 0.25s var(--easing);
}

.private-gallery-logout:hover {
    color: var(--color-cta);
    border-color: var(--color-cta);
}

.private-gallery-tabs {
    display: flex;
    gap: 4px;
    max-width: 1200px;
    margin: 24px auto 0;
    padding: 0 20px;
    box-sizing: border-box;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.private-gallery-tab {
    padding: 12px 18px;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: none;
    color: var(--color-text);
    opacity: 0.5;
    font-family: var(--font-bold);
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    cursor: pointer;
    transition: color 0.25s var(--easing), opacity 0.25s var(--easing), border-color 0.25s var(--easing);
}

.private-gallery-tab:hover {
    color: var(--color-cta);
    opacity: 1;
}

.private-gallery-tab.is-active {
    color: var(--color-cta);
    opacity: 1;
    border-bottom-color: var(--color-cta);
}

.private-gallery-panel:not([hidden]) {
    animation: private-gallery-panel-in 0.35s var(--easing) both;
}

@keyframes private-gallery-panel-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

.private-gallery-panel .image-gallery {
    margin-top: 28px;
}

.private-gallery-collection-header {
    max-width: 1200px;
    margin: 40px auto 0;
    padding: 0 20px;
    box-sizing: border-box;
    color: var(--color-text);
    font-family: var(--font-bold);
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.private-gallery-collection-header + .image-gallery {
    margin-top: 12px;
}

@media (prefers-reduced-motion: reduce) {
    .private-gallery-panel:not([hidden]) {
        animation: none;
    }
}

.private-gallery-empty {
    max-width: 1200px;
    margin: 48px auto;
    padding: 0 20px;
    text-align: center;
    opacity: 0.6;
}

.favourite-toggle {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    color: #b9aeb2;
    cursor: pointer;
    transition: transform 0.2s var(--easing), color 0.2s var(--easing), background 0.2s var(--easing);
}

.favourite-toggle:hover {
    transform: scale(1.1);
    color: var(--color-cta);
}

.favourite-toggle.is-favourited {
    color: var(--color-cta);
}

.favourite-toggle svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.favourite-toggle:not(.is-favourited):hover svg {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}

@media (max-width: 600px) {
    .private-gallery-popup {
        padding: 32px 24px 28px;
        border-radius: 18px;
    }
}
