/* 女兒的藝廊 — 前台藝廊與燈箱 */

.dg-gallery {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem 4rem;
}

.dg-hero {
    text-align: center;
    margin-bottom: 2rem;
}

.dg-hero h1 {
    font-size: 2rem;
    color: #db2777;
    margin: 0 0 .4rem;
}

.dg-hero p {
    color: #94a3b8;
    margin: 0;
}

.dg-studio-entry {
    text-align: center;
    margin: 0 0 1.5rem;
}

.dg-studio-link {
    display: inline-block;
    background: linear-gradient(135deg, #f472b6, #fb7185);
    color: #fff;
    text-decoration: none;
    padding: .7rem 1.6rem;
    border-radius: 999px;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(244, 114, 182, .35);
    transition: transform .2s, box-shadow .2s;
}

.dg-studio-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(244, 114, 182, .45);
}

.dg-empty {
    text-align: center;
    color: #94a3b8;
    padding: 3rem 1rem;
    font-size: 1.05rem;
}

.dg-masonry {
    column-count: 4;
    column-gap: 1rem;
}

@media (max-width: 1100px) {
    .dg-masonry { column-count: 3; }
}

@media (max-width: 800px) {
    .dg-masonry { column-count: 2; }
}

@media (max-width: 500px) {
    .dg-masonry { column-count: 1; }
}

.dg-card {
    break-inside: avoid;
    margin: 0 0 1rem;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(15, 23, 42, .10);
    cursor: pointer;
    transition: transform .2s, box-shadow .2s;
}

.dg-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(15, 23, 42, .16);
}

.dg-card img {
    width: 100%;
    height: auto;
    display: block;
}

.dg-card figcaption {
    padding: .6rem .9rem .75rem;
}

.dg-card-title {
    font-weight: 600;
    color: #334155;
}

.dg-card-meta {
    color: #94a3b8;
    font-size: .8rem;
    margin-top: .15rem;
}

.dg-dot {
    margin: 0 .35rem;
}

/* ---- 燈箱 ---- */

.dg-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
}

.dg-lb-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 10, 40, .86);
    animation: dgFade .2s ease;
}

@keyframes dgFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.dg-lb-btn {
    position: absolute;
    z-index: 2;
    width: 46px;
    height: 46px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: #334155;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .25);
}

.dg-lb-btn:hover {
    background: #fff;
}

.dg-lb-close {
    top: 1rem;
    right: 1rem;
}

.dg-lb-prev {
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
}

.dg-lb-next {
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
}

.dg-lb-stage {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.75rem;
    padding: 3.5rem 5rem;
}

.dg-lb-img {
    max-width: min(68vw, 1000px);
    max-height: 82vh;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .45);
    background: #fff;
}

.dg-lb-info {
    max-width: 320px;
    color: #f8fafc;
    align-self: center;
}

.dg-lb-title {
    margin: 0 0 .35rem;
    font-size: 1.5rem;
    color: #fff;
}

.dg-lb-meta {
    color: #cbd5e1;
    font-size: .9rem;
    margin-bottom: .7rem;
}

.dg-lb-desc {
    color: #e2e8f0;
    line-height: 1.7;
    margin: 0 0 .9rem;
}

.dg-lb-note {
    background: rgba(255, 255, 255, .12);
    border-radius: 12px;
    padding: .7rem .9rem;
    font-style: italic;
    color: #fdf2f8;
    margin: 0 0 1rem;
}

.dg-love-btn {
    border: none;
    background: linear-gradient(135deg, #ff5d8f, #fb7185);
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    padding: .65rem 1.2rem;
    border-radius: 999px;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(255, 93, 143, .4);
    transition: transform .15s;
}

.dg-love-btn:hover {
    transform: scale(1.05);
}

.dg-love-btn.dg-loved {
    background: #94a3b8;
    box-shadow: none;
    cursor: default;
}

@media (max-width: 860px) {
    .dg-lb-stage {
        flex-direction: column;
        justify-content: flex-start;
        gap: .9rem;
        padding: 4.2rem 1rem 2rem;
        overflow-y: auto;
    }

    .dg-lb-img {
        max-width: 92vw;
        max-height: 52vh;
    }

    .dg-lb-info {
        max-width: 92vw;
        text-align: center;
    }

    .dg-lb-prev { left: .6rem; }
    .dg-lb-next { right: .6rem; }
    .dg-lb-close { top: .6rem; right: .6rem; }
}

.dg-no-scroll {
    overflow: hidden;
}
