/* ==========================================================
   PALACE OF CITIZENSHIP
   GRAND CITADEL COMMONWEALTH
========================================================== */

:root{

    --black:#050505;

    --panel:#111111;

    --gold:#d4af37;

    --gold-soft:#efd37c;

    --text:#e8e2cf;

    --muted:#b9af95;

    --transition:.45s ease;

}

*,
*::before,
*::after{

    box-sizing:border-box;

}

html{

    scroll-behavior:smooth;

}

body{

    margin:0;

    min-height:100vh;

    background:
        radial-gradient(circle at top,
        rgba(212,175,55,.10),
        transparent 45%),
        var(--black);

    color:var(--text);

    font-family:"Segoe UI",sans-serif;

    overflow-x:hidden;

}

img{

    display:block;

    max-width:100%;

}

a{

    text-decoration:none;

}
/* ==========================================================
   PAGE LAYOUT
========================================================== */

.palace-arrival {
    position: relative;
    min-height: 100vh;
    overflow: hidden;

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

    padding: 6rem 1.5rem;
    overflow: hidden;
}

.palace-atmosphere {
    position: absolute;
    inset: 0;

    pointer-events: none;

    background:
        radial-gradient(
            circle,
            rgba(212, 175, 55, 0.08),
            transparent 70%
        );

    animation: atmosphere 10s ease-in-out infinite;
}

.palace-entrance {
    position: relative;
    z-index: 2;

    width: min(860px, 100%);
    text-align: center;
}
/* ==========================================================
   PALACE SEAL
========================================================== */

.palace-seal {
    position: relative;
    width: min(560px, 88vw);
    margin: 0 auto 2.5rem;

    opacity: 0;
    transform: translateY(18px) rotate(-3deg) scale(0.96);

    animation:
        seal-arrival 1.8s cubic-bezier(.2, .8, .2, 1) 0.4s forwards,
        seal-float 8s ease-in-out 2.4s infinite;
}

.palace-seal__glow {
    position: absolute;
    inset: 8%;

    border-radius: 50%;

    background:
        radial-gradient(
            circle,
            rgba(212, 175, 55, 0.26),
            rgba(212, 175, 55, 0.08) 45%,
            transparent 72%
        );

    filter: blur(34px);
    opacity: 0;

    animation: glow-awaken 2.2s ease 1.1s forwards;
}

.palace-seal__frame {
    position: relative;
    overflow: hidden;

    border-radius: 2px;

    filter:
        drop-shadow(0 0 24px rgba(212, 175, 55, 0.26))
        drop-shadow(0 0 70px rgba(212, 175, 55, 0.10));
}

.palace-seal__image {
    position: relative;
    z-index: 1;

    width: 100%;
    height: auto;
}

.palace-seal__shimmer {
    position: absolute;
    z-index: 2;
    top: -20%;
    bottom: -20%;
    left: -45%;

    width: 24%;

    pointer-events: none;

    background:
        linear-gradient(
            105deg,
            transparent 0%,
            rgba(255, 244, 190, 0.04) 32%,
            rgba(255, 244, 190, 0.34) 50%,
            rgba(255, 244, 190, 0.04) 68%,
            transparent 100%
        );

    transform: skewX(-15deg);

    animation: metallic-shimmer 14s ease-in-out 4s infinite;
}
/* ==========================================================
   PALACE ANIMATIONS
========================================================== */

@keyframes seal-arrival {

    0%{
        opacity:0;
        transform:
            translateY(24px)
            rotate(-3deg)
            scale(.94);
    }

    60%{
        opacity:1;
    }

    100%{
        opacity:1;
        transform:
            translateY(0)
            rotate(0deg)
            scale(1);
    }
}

@keyframes seal-float{

    0%,100%{
        transform:translateY(0px);
    }

    50%{
        transform:translateY(-8px);
    }
}

@keyframes glow-awaken{

    from{
        opacity:0;
        transform:scale(.85);
    }

    to{
        opacity:1;
        transform:scale(1.1);
    }
}

@keyframes metallic-shimmer{

    0%{
        left:-45%;
        opacity:0;
    }

    10%{
        opacity:1;
    }

    35%{
        left:125%;
        opacity:1;
    }

    45%{
        opacity:0;
    }

    100%{
        left:125%;
        opacity:0;
    }
}
/* ==========================================================
   PALACE TEXT AND ENTRY
========================================================== */

.government-heading,
.equality-declaration,
#palace-title,
.constitutional-creed,
.gold-divider,
.enter-palace-button {
    opacity: 0;
    transform: translateY(16px);
}

.government-heading {
    margin: 0 0 0.7rem;

    color: var(--gold);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.28em;
    text-transform: uppercase;

    animation: content-arrival 1s ease 2.1s forwards;
}

.equality-declaration {
    margin: 0 0 1.5rem;

    color: var(--muted);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.9rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;

    animation: content-arrival 1s ease 2.4s forwards;
}

#palace-title {
    margin: 0;

    color: var(--gold-soft);
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(3rem, 9vw, 7rem);
    font-weight: 400;
    line-height: 0.9;
    text-transform: uppercase;

    animation: content-arrival 1.2s ease 2.7s forwards;
}

#palace-title span {
    display: block;
}

.constitutional-creed {
    width: min(700px, 100%);
    margin: 2rem auto 0;

    color: var(--muted);
    font-size: clamp(1rem, 1.8vw, 1.15rem);

    animation: content-arrival 1.1s ease 3.2s forwards;
}

.constitutional-creed p {
    margin: 0.5rem 0;
}

.gold-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;

    width: min(320px, 70%);
    margin: 2rem auto 0;

    color: var(--gold);

    animation: content-arrival 1s ease 3.6s forwards;
}

.gold-divider::before,
.gold-divider::after {
    content: "";
    flex: 1;
    height: 1px;

    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(212, 175, 55, 0.9)
        );
}

.gold-divider::after {
    transform: scaleX(-1);
}

.enter-palace-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 56px;
    margin-top: 2rem;
    padding: 0.95rem 1.8rem;

    border: 1px solid var(--gold);
    border-radius: 999px;

    color: var(--gold-soft);
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;

    transition:
        background var(--transition),
        color var(--transition),
        transform var(--transition),
        box-shadow var(--transition);

    animation: content-arrival 1s ease 4s forwards;
}

.enter-palace-button:hover {
    background: var(--gold);
    color: var(--black);

    transform: translateY(-2px);

    box-shadow:
        0 0 24px rgba(212, 175, 55, 0.34),
        0 0 60px rgba(212, 175, 55, 0.12);
}

@keyframes content-arrival {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes atmosphere {
    0%,
    100% {
        opacity: 0.55;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.08);
    }
}
/* ==========================================================
   RESPONSIVE AND ACCESSIBILITY
========================================================== */

@media (max-width: 720px) {
    .palace-arrival {
        padding: 3rem 1rem;
    }

    .palace-seal {
        width: min(460px, 94vw);
        margin-bottom: 2rem;
    }

    #palace-title {
        font-size: clamp(2.7rem, 14vw, 4.8rem);
    }

    .government-heading {
        font-size: 0.68rem;
        letter-spacing: 0.2em;
    }

    .equality-declaration {
        font-size: 0.78rem;
        letter-spacing: 0.08em;
    }

    .constitutional-creed {
        margin-top: 1.5rem;
    }

    .enter-palace-button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-delay: 0ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .government-heading,
    .equality-declaration,
    #palace-title,
    .constitutional-creed,
    .gold-divider,
    .enter-palace-button,
    .palace-seal,
    .palace-seal__glow {
        opacity: 1;
        transform: none;
    }
}
.palace-entrance {
    transition:
        opacity 0.65s ease,
        transform 0.65s ease,
        filter 0.65s ease;
}

.palace-entrance.is-departing {
    opacity: 0;
    transform: scale(1.025);
    filter: blur(8px);
}
/* ==========================================
   LIVING PALACE LIGHT
========================================== */

.palace-arrival::before{
    content:"";
    position:absolute;
    inset:-20%;
    pointer-events:none;

    background:
    radial-gradient(circle at 30% 25%,
        rgba(212,175,55,.08),
        transparent 22%),

    radial-gradient(circle at 72% 38%,
        rgba(212,175,55,.06),
        transparent 28%),

    radial-gradient(circle at 48% 80%,
        rgba(255,230,150,.05),
        transparent 26%);

    animation: palace-light 18s ease-in-out infinite;
}

@keyframes palace-light{

0%,100%{

opacity:.55;

transform:scale(1);

}

35%{

opacity:.9;

transform:scale(1.04);

}

70%{

opacity:.65;

transform:scale(1.02);

}

}
/* ==========================================
   FLOATING GOLD PARTICLES
========================================== */

/* =========================================
   FLOATING GOLD PARTICLES
========================================= */

.gold-particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.gold-particles span {
    position: absolute;

    width: 4px;
    height: 4px;

    border-radius: 50%;

    background: rgba(255, 225, 140, 0.85);

    box-shadow:
        0 0 12px rgba(255, 220, 120, 0.75);

    opacity: 0;

    animation: particle-rise linear infinite;
}

.gold-particles span:nth-child(1) {
    left: 8%;
    animation-duration: 13s;
    animation-delay: 0s;
}

.gold-particles span:nth-child(2) {
    left: 18%;
    animation-duration: 18s;
    animation-delay: 2s;
}

.gold-particles span:nth-child(3) {
    left: 31%;
    animation-duration: 15s;
    animation-delay: 5s;
}

.gold-particles span:nth-child(4) {
    left: 46%;
    animation-duration: 20s;
    animation-delay: 1s;
}

.gold-particles span:nth-child(5) {
    left: 61%;
    animation-duration: 17s;
    animation-delay: 4s;
}

.gold-particles span:nth-child(6) {
    left: 74%;
    animation-duration: 14s;
    animation-delay: 6s;
}

.gold-particles span:nth-child(7) {
    left: 86%;
    animation-duration: 19s;
    animation-delay: 3s;
}

.gold-particles span:nth-child(8) {
    left: 94%;
    animation-duration: 16s;
    animation-delay: 7s;
}

@keyframes particle-rise {
    0% {
        transform:
            translateY(120vh)
            scale(0.4);

        opacity: 0;
    }

    15% {
        opacity: 0.9;
    }

    85% {
        opacity: 0.9;
    }

    100% {
        transform:
            translateY(-20vh)
            scale(1.25);

        opacity: 0;
    }
}