.gallery-main {
    position: relative;
    isolation: isolate;
}
.upload-backdrop {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
    user-select: none;
}
.upload-backdrop span {
    position: absolute;
    top: 5rem;
    left: -5%;
    color: var(--gal-blue);
    opacity: 0.09;
    font: 700 clamp(4rem, 13vw, 10rem)/1 var(--font-body);
    letter-spacing: -0.05em;
    white-space: nowrap;
    animation: upload-text-drift 24s ease-in-out infinite alternate;
}
.upload-backdrop span:nth-child(2) {
    top: 30rem;
    left: 12%;
    color: #a46828;
    animation-delay: -12s;
    animation-direction: alternate-reverse;
}
@keyframes upload-text-drift {
    from { transform: translate(-2%, 0) rotate(-8deg); }
    to { transform: translate(12%, 2rem) rotate(-4deg); }
}
.upload-content {
    max-width: 720px;
    margin: 1rem auto 2.5rem;
    line-height: 1.6;
}
.upload-content .intro {
    margin-bottom: 1.5rem;
    padding: 1.75rem;
    border: 1px solid rgba(44, 107, 138, 0.2);
    border-left: 5px solid var(--gal-blue);
    border-radius: var(--gal-radius);
    background: linear-gradient(125deg, #e2f0f5, #f3f8f6 65%, #fff1d8);
    box-shadow: 0 12px 30px rgba(44, 107, 138, 0.08);
}
.upload-content .intro h2 { color: #205570; }
.upload-content h2 {
    margin: 0 0 1rem;
    font: 600 1.5rem/1.3 var(--font-display);
}
.upload-content .card {
    margin-bottom: 1rem;
    padding: 1.75rem;
    border: 1px solid var(--gal-line);
    border-radius: var(--gal-radius);
    border-top: 5px solid var(--gal-amber);
    background: linear-gradient(145deg, #fff9eb, #ffffff 55%);
    box-shadow: 0 12px 30px rgba(164, 104, 40, 0.09);
}
.upload-content #identity h2 { color: #754c10; }
.upload-content #upload {
    border-top-color: var(--clean-sage);
    background: linear-gradient(145deg, #eaf5ef, #ffffff 55%);
    box-shadow: 0 12px 30px rgba(76, 134, 112, 0.09);
}
.upload-content #upload h2 { color: #315d4d; }
.upload-content label {
    display: block;
    margin: 1rem 0 0.4rem;
    font-weight: 600;
}
.upload-content input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: white;
    color: var(--gal-ink);
    font: inherit;
}
.upload-content .gallery-action { margin: 1rem 0.5rem 0 0; }
.upload-content button:disabled { opacity: 0.55; }
.upload-content :focus-visible { outline: 3px solid var(--gal-amber); outline-offset: 3px; }
.upload-content .muted { color: var(--gal-muted); font-size: 0.85rem; }
#message { white-space: pre-line; overflow-wrap: anywhere; }
#identity-summary, #file-list { overflow-wrap: anywhere; }
#message.error { color: #a01828; }
#message.success { color: #22623a; }
.upload-content [hidden] { display: none !important; }
@media (max-width: 600px) {
    .upload-content .card, .upload-content .intro { padding: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) {
    .upload-backdrop span { animation: none; }
}
