/* =========================================================
   MEMORY 1 — DISCOVERY / MEMORY REVEAL SCREEN
   CLEAN FINAL VERSION
========================================================= */


/* =========================================================
   MAIN SCREEN
========================================================= */

#memory1{

    position:fixed !important;
    inset:0 !important;

    width:100% !important;
    height:100dvh !important;
    min-height:100dvh !important;

    margin:0;
    padding:0;

    box-sizing:border-box;

    display:flex;
    align-items:center;
    justify-content:center;

    overflow:hidden;

    text-align:center;

    color:#fff;

    background:

        radial-gradient(
            circle at 50% 42%,
            rgba(255,215,106,.12),
            transparent 48%
        ),

        linear-gradient(
            180deg,
            #030711 0%,
            #071426 50%,
            #0a1c31 100%
        );
}


/* =========================================================
   VIGNETTE
========================================================= */

#memory1::after{

    content:"";

    position:absolute;
    inset:0;

    pointer-events:none;

    background:

        radial-gradient(
            circle,
            transparent 40%,
            rgba(0,0,0,.18) 72%,
            rgba(0,0,0,.58) 100%
        );

    z-index:10;
}


/* =========================================================
   GOLDEN GLOW
========================================================= */

.memory1-glow{

    position:absolute;

    left:50%;
    top:42%;

    width:360px;
    height:360px;

    transform:translate(-50%,-50%);

    border-radius:50%;

    background:

        radial-gradient(
            circle,
            rgba(255,215,106,.13),
            transparent 68%
        );

    filter:blur(35px);

    pointer-events:none;

    z-index:1;

    animation:memoryGlow 7s ease-in-out infinite;
}


@keyframes memoryGlow{

    0%,
    100%{

        transform:
            translate(-50%,-50%)
            scale(1);

        opacity:.45;
    }

    50%{

        transform:
            translate(-50%,-50%)
            scale(1.12);

        opacity:.75;
    }
}


/* =========================================================
   STARS
========================================================= */

.memory1-stars{

    position:absolute;
    inset:0;

    overflow:hidden;

    pointer-events:none;

    z-index:3;
}


.memory1-stars span{

    position:absolute;

    display:block;

    width:2px;
    height:2px;

    border-radius:50%;

    background:#fff;

    box-shadow:
        0 0 8px rgba(255,255,255,.75);

    opacity:.3;

    animation:
        memoryTwinkle 4s ease-in-out infinite;
}


.memory1-stars span:nth-child(1){
    top:13%;
    left:17%;
}

.memory1-stars span:nth-child(2){
    top:27%;
    left:82%;
    animation-delay:.7s;
}

.memory1-stars span:nth-child(3){
    top:43%;
    left:9%;
    animation-delay:1.5s;
}

.memory1-stars span:nth-child(4){
    top:59%;
    left:91%;
    animation-delay:2.2s;
}

.memory1-stars span:nth-child(5){
    top:76%;
    left:25%;
    animation-delay:1s;
}

.memory1-stars span:nth-child(6){
    top:84%;
    left:74%;
    animation-delay:2.8s;
}


@keyframes memoryTwinkle{

    0%,
    100%{

        opacity:.18;
        transform:scale(1);
    }

    50%{

        opacity:.8;
        transform:scale(1.8);
    }
}


/* =========================================================
   MAIN CONTENT — DISCOVERY
========================================================= */

#memory1:not(.memory-revealed) .memory1-content{

    position:absolute !important;

    top:50% !important;
    left:50% !important;

    width:calc(100% - 32px) !important;
    max-width:350px !important;

    height:auto;

    margin:0 !important;
    padding:0 !important;

    transform:translate(-50%,-50%) !important;

    display:flex !important;

    flex-direction:column;

    align-items:center;
    justify-content:center;

    box-sizing:border-box;

    text-align:center;

    z-index:20;
}


/* =========================================================
   KICKER
========================================================= */

.memory1-kicker{

    display:block;

    width:100%;

    margin:0 0 14px;
    padding:0;

    font-size:10px;
    font-weight:600;

    line-height:1.5;

    letter-spacing:4px;

    color:#D9B65C;

    text-align:center;
}


/* =========================================================
   DIVIDER
========================================================= */

.memory1-line{

    position:relative;

    display:block;

    width:145px;
    height:1px;

    margin:0 auto 20px;

    background:

        linear-gradient(
            90deg,
            transparent,
            rgba(255,215,106,.75),
            transparent
        );
}


/* =========================================================
   TITLE
========================================================= */

.memory1-title{

    display:block;

    width:100%;
    max-width:340px;

    margin:0;
    padding:0;

    font-size:40px;
    font-weight:700;

    line-height:1.12;

    letter-spacing:-.8px;

    color:#fff;

    text-align:center;

    white-space:normal;

    overflow:visible;

    text-shadow:
        0 0 25px rgba(255,255,255,.08);
}


/* =========================================================
   DESCRIPTION
========================================================= */

.memory1-text{

    display:block;

    width:100%;
    max-width:310px;

    margin:22px auto 0;
    padding:0;

    font-size:15px;
    font-weight:400;

    line-height:1.65;

    color:rgba(255,255,255,.68);

    text-align:center;
}


/* =========================================================
   REVEAL BUTTON
========================================================= */

.memory1-reveal{

    position:relative;

    display:flex;

    align-items:center;
    justify-content:center;

    gap:12px;

    width:220px;
    height:56px;

    margin:25px auto 0;
    padding:0;

    flex-shrink:0;

    border:
        1px solid rgba(255,215,106,.38);

    border-radius:999px;

    background:
        rgba(255,255,255,.045);

    backdrop-filter:blur(14px);
    -webkit-backdrop-filter:blur(14px);

    color:#FFE7A0;

    font-family:inherit;

    font-size:15px;
    font-weight:600;

    letter-spacing:.3px;

    cursor:pointer;

    box-sizing:border-box;

    box-shadow:
        0 0 24px rgba(255,215,106,.06);

    transition:
        transform .25s ease,
        background .3s ease,
        border-color .3s ease,
        box-shadow .3s ease;
}


.memory1-reveal:hover{

    transform:translateY(-2px);

    background:
        rgba(255,215,106,.08);

    border-color:
        rgba(255,215,106,.65);

    box-shadow:
        0 8px 30px rgba(255,215,106,.13);
}


.memory1-reveal:active{

    transform:scale(.97);
}


/* =========================================================
   REVEAL ICON
========================================================= */

.memory1-reveal-icon{

    display:flex;

    align-items:center;
    justify-content:center;

    width:24px;
    height:24px;

    font-size:15px;

    color:#FFD76A;

    text-shadow:
        0 0 10px rgba(255,215,106,.8);

    transition:
        transform .3s ease;
}


.memory1-reveal:hover .memory1-reveal-icon{

    transform:rotate(90deg);
}


/* =========================================================
   REVEAL TEXT
========================================================= */

.memory1-reveal-text{

    white-space:nowrap;
}


/* =========================================================
   ARROW
========================================================= */

.memory1-reveal-arrow{

    font-size:18px;

    font-weight:400;

    transition:
        transform .25s ease;
}


.memory1-reveal:hover .memory1-reveal-arrow{

    transform:translateX(4px);
}


/* =========================================================
   HINT
========================================================= */

.memory1-hint{

    display:block;

    width:100%;

    margin:11px auto 0;
    padding:0;

    font-size:10px;

    line-height:1.5;

    letter-spacing:.8px;

    color:rgba(255,255,255,.28);

    text-align:center;
}


/* =========================================================
   BOTTOM NOTE
========================================================= */

.memory1-note{

    position:absolute;

    left:50%;
    bottom:18px;

    z-index:20;

    width:100%;

    margin:0;

    transform:translateX(-50%);

    font-size:9px;

    line-height:1.5;

    letter-spacing:1.5px;

    color:rgba(255,255,255,.22);

    text-align:center;
}


/* =========================================================
   DISCOVERY → REVEAL TRANSITION
========================================================= */

#memory1.memory-revealed .memory1-kicker,
#memory1.memory-revealed .memory1-line,
#memory1.memory-revealed .memory1-title,
#memory1.memory-revealed .memory1-text,
#memory1.memory-revealed .memory1-reveal,
#memory1.memory-revealed .memory1-hint{

    display:none !important;
}


#memory1.memory-revealed .memory1-note{

    display:none !important;
}


/* =========================================================
   MEMORY CARD — HIDDEN
   Does NOT occupy layout space
========================================================= */

#memory1:not(.memory-revealed) .memory1-card{

    position:absolute !important;

    top:100% !important;
    left:50% !important;

    width:100%;

    margin:0;

    opacity:0;
    visibility:hidden;

    pointer-events:none;

    transform:
        translate(-50%,20px)
        scale(.96);
}


/* =========================================================
   MEMORY CARD — REVEALED
========================================================= */

#memory1.memory-revealed .memory1-content{

    position:absolute !important;

    top:50% !important;
    left:50% !important;

    width:calc(100% - 32px) !important;
    max-width:320px !important;

    margin:0 !important;
    padding:0 !important;

    transform:translate(-50%,-50%) !important;

    display:flex !important;

    align-items:center;
    justify-content:center;

    z-index:20;
}


#memory1.memory-revealed .memory1-card{

    position:relative !important;

    top:auto !important;
    left:auto !important;

    width:100%;

    max-width:300px;

    margin:0;

    display:flex;

    flex-direction:column;

    align-items:center;

    opacity:1;
    visibility:visible;

    transform:none;

    pointer-events:auto;
}


/* =========================================================
   MEMORY PHOTO
========================================================= */

.memory1-card-image{

    position:relative;

    width:100%;

    aspect-ratio:3 / 4;

    overflow:hidden;

    border-radius:20px;

    background:#081322;

    border:
        1px solid rgba(255,215,106,.20);

    box-shadow:

        0 18px 45px rgba(0,0,0,.35),

        0 0 30px rgba(255,215,106,.08);

    backdrop-filter:blur(12px);
    -webkit-backdrop-filter:blur(12px);
}


/* =========================================================
   PHOTO PLACEHOLDER
========================================================= */

.memory1-image-placeholder{

    position:absolute;
    inset:0;

    display:flex;

    align-items:center;
    justify-content:center;

    font-size:30px;

    color:#FFD76A;

    background:

        radial-gradient(
            circle,
            rgba(255,215,106,.13),
            transparent 65%
        );

    text-shadow:
        0 0 20px rgba(255,215,106,.7);
}


/* =========================================================
   MEMORY PHOTO IMAGE
========================================================= */

.memory1-card-image img{

    display:block;

    width:100%;
    height:100%;

    object-fit:cover;
    object-position:center center;

    opacity:0;

    filter:
        blur(14px)
        brightness(.82);

    transform:scale(1.06);

    transition:

        opacity 1.2s ease,

        filter 1.4s ease,

        transform 1.4s cubic-bezier(.22,1,.36,1);
}


/* =========================================================
   PHOTO LOADED
========================================================= */

.memory1-card-image img.loaded,
.memory1-card.revealed .memory1-card-image img{

    opacity:1;

    filter:
        blur(0)
        brightness(1);

    transform:scale(1);
}


/* =========================================================
   REVEALED PHOTO GLOW
========================================================= */

#memory1.memory-revealed .memory1-card-image{

    box-shadow:

        0 20px 55px rgba(0,0,0,.45),

        0 0 35px rgba(255,215,106,.10);
}


/* =========================================================
   CARD CAPTION
========================================================= */

.memory1-card-caption{

    width:100%;
    max-width:285px;

    margin:16px auto 0;

    font-size:14px;

    line-height:1.6;

    color:rgba(255,255,255,.78);

    text-align:center;
}


/* =========================================================
   NEXT BUTTON
========================================================= */

.memory1-next{

    display:flex;

    align-items:center;
    justify-content:center;

    gap:12px;

    min-width:160px;
    height:46px;

    margin:18px auto 0;
    padding:0 20px;

    border:
        1px solid rgba(255,215,106,.28);

    border-radius:999px;

    background:
        rgba(255,255,255,.045);

    color:#FFE7A0;

    font-family:inherit;

    font-size:14px;
    font-weight:600;

    cursor:pointer;

    backdrop-filter:blur(12px);
    -webkit-backdrop-filter:blur(12px);

    transition:

        transform .25s ease,

        background .3s ease,

        border-color .3s ease,

        box-shadow .3s ease;
}


.memory1-next b{

    font-size:17px;

    font-weight:400;

    transition:
        transform .25s ease;
}


.memory1-next:hover{

    transform:translateY(-2px);

    background:
        rgba(255,215,106,.07);

    border-color:
        rgba(255,215,106,.55);

    box-shadow:
        0 8px 25px rgba(255,215,106,.10);
}


.memory1-next:hover b{

    transform:translateX(4px);
}


.memory1-next:active{

    transform:scale(.97);
}


/* =========================================================
   MOBILE — WIDTH
========================================================= */

@media (max-width:420px){

    #memory1:not(.memory-revealed) .memory1-content{

        width:calc(100% - 32px);

        max-width:350px;
    }


    #memory1:not(.memory-revealed) .memory1-title{

        font-size:38px;
    }


    #memory1:not(.memory-revealed) .memory1-text{

        max-width:300px;

        font-size:14.5px;
    }


    #memory1.memory-revealed .memory1-content{

        width:calc(100% - 32px);

        max-width:320px;
    }


    #memory1.memory-revealed .memory1-card{

        max-width:300px;
    }


    #memory1.memory-revealed .memory1-card-image{

        border-radius:20px;
    }


    #memory1.memory-revealed .memory1-card-caption{

        max-width:285px;

        margin-top:16px;

        font-size:14px;

        line-height:1.6;
    }
}


/* =========================================================
   SHORT DEVICES
========================================================= */

@media (max-height:750px){

    #memory1:not(.memory-revealed) .memory1-content{

        transform:
            translate(-50%,-50%)
            scale(.90) !important;
    }


    #memory1:not(.memory-revealed) .memory1-note{

        display:none;
    }
}


/* =========================================================
   VERY SHORT DEVICES
========================================================= */

@media (max-height:650px){

    #memory1:not(.memory-revealed) .memory1-content{

        transform:
            translate(-50%,-50%)
            scale(.80) !important;
    }


    #memory1:not(.memory-revealed) .memory1-hint{

        display:none;
    }


    #memory1:not(.memory-revealed) .memory1-note{

        display:none !important;
    }
}