* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --radius-lg: 28px;
    --radius-md: 20px;
    --radius-sm: 14px;
    --shadow-soft: 0 18px 48px rgba(15, 23, 42, 0.12);
    --shadow-strong: 0 24px 70px rgba(15, 23, 42, 0.22);
    --focus-ring: 0 0 0 4px rgba(14, 165, 233, 0.18);
}

body {
    min-height: 100vh;
    position: relative;
    isolation: isolate;
    overflow-x: hidden;
    background: #0f172a;
    color: #e2e8f0;
    font-family: "Manrope", "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

body::after {
    z-index: 0;
}

.container {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
    padding: 52px 0 72px;
    position: relative;
    z-index: 2;
}

.loading,
.error {
    border-radius: var(--radius-md);
    padding: 20px 24px;
    text-align: center;
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-soft);
}

.loading {
    border: 1px solid rgba(148, 163, 184, 0.18);
    width: min(420px, 100%);
    margin: 0 auto 24px;
}

.error {
    margin-bottom: 24px;
    border: 1px solid rgba(248, 113, 113, 0.28);
}

.header {
    position: relative;
    padding: 88px 56px 64px;
    margin-bottom: 42px;
    text-align: center;
    border-radius: 36px;
    overflow: hidden;
}

.avatar {
    width: 118px;
    height: 118px;
    margin: 0 auto 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.name {
    font-size: clamp(3rem, 6vw, 5.3rem);
    line-height: 0.95;
    margin-bottom: 18px;
}

.bio {
    width: min(720px, 100%);
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.9;
    text-wrap: pretty;
}

.section-intro {
    grid-column: 1 / -1;
    margin-bottom: 2px;
}

.public-section-title {
    font-size: clamp(1.25rem, 1.6vw, 1.55rem);
    line-height: 1.1;
    letter-spacing: 0.04em;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    max-width: 1080px;
    margin-inline: auto;
    margin-bottom: 34px;
    align-items: stretch;
}

.link-card {
    display: grid;
    gap: 18px;
    align-content: start;
    min-height: 228px;
    padding: 26px 28px;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    transition:
        transform 0.28s ease,
        box-shadow 0.28s ease,
        border-color 0.28s ease,
        background 0.28s ease;
}

.link-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.12),
        transparent 32%,
        transparent 68%,
        rgba(255, 255, 255, 0.04)
    );
    opacity: 0;
    transition: opacity 0.28s ease;
    pointer-events: none;
    z-index: -1;
}

.link-card:hover::before,
.link-card:focus-visible::before {
    opacity: 1;
}

.card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.card-icon {
    width: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.9rem;
    font-weight: 700;
}

.card-content {
    display: grid;
    align-content: start;
    gap: 10px;
}

.card-order {
    font-size: 0.77rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    opacity: 0.78;
}

.card-content h3 {
    font-size: 1.45rem;
    line-height: 1.15;
}

.card-content p {
    line-height: 1.72;
    text-wrap: pretty;
}

.card-tag {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-top: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    letter-spacing: 0.06em;
}

.card-meta {
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    font-size: 0.88rem;
}

.card-host,
.card-action {
    opacity: 0.76;
}

.card-action {
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.card-arrow {
    font-size: 1.6rem;
    font-weight: 700;
    opacity: 0.58;
    line-height: 1;
    transition:
        transform 0.22s ease,
        opacity 0.22s ease;
}

.link-card:hover .card-arrow,
.link-card:focus-visible .card-arrow {
    transform: translate(4px, -4px);
    opacity: 1;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    width: min(940px, 100%);
    margin-inline: auto;
    margin-bottom: 34px;
}

.social-heading {
    width: 100%;
    margin-top: 4px;
    margin-bottom: 8px;
    text-align: center;
}

.social-link {
    min-height: 58px;
    padding: 0 16px 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-decoration: none;
    font-weight: 700;
    transition:
        transform 0.24s ease,
        box-shadow 0.24s ease,
        border-color 0.24s ease;
}

.social-mark {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.92rem;
    font-weight: 800;
}

.social-label {
    font-size: 0.92rem;
    letter-spacing: 0.02em;
}

.footer {
    width: min(760px, 100%);
    margin: 0 auto;
    padding: 24px 0 8px;
    text-align: center;
    line-height: 1.9;
}

.footer a,
.preview-footer a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 0.18em;
}

.footer code,
.preview-footer code {
    padding: 0.12em 0.46em;
    border-radius: 0.5em;
    font-size: 0.92em;
}

.refresh-btn,
.admin-btn {
    position: fixed;
    bottom: 24px;
    height: 54px;
    z-index: 30;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition:
        transform 0.24s ease,
        box-shadow 0.24s ease,
        background 0.24s ease;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

.refresh-btn {
    right: 24px;
    width: 54px;
    border-radius: 50%;
    font-size: 1.15rem;
}

.admin-btn {
    right: 92px;
    min-width: 76px;
    padding: 0 18px;
    border-radius: 999px;
    font-weight: 700;
}

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

.particle {
    position: absolute;
    border-radius: 50%;
    filter: blur(var(--blur, 0px));
    animation:
        particle-float var(--drift-duration, 20s) linear infinite,
        star-twinkle var(--twinkle-duration, 4.8s) ease-in-out infinite;
    animation-delay: var(--drift-delay, 0s), var(--twinkle-delay, 0s);
    opacity: 0;
    will-change: transform, opacity, filter;
}

@keyframes particle-float {
    0% {
        transform: translate3d(var(--from-x, 0px), var(--from-y, 18px), 0)
            scale(var(--scale-start, 0.82));
        opacity: 0;
    }
    16% {
        opacity: 0.58;
    }
    52% {
        transform: translate3d(var(--mid-x, 12px), var(--mid-y, -16px), 0)
            scale(var(--scale-mid, 1));
        opacity: 0.92;
    }
    100% {
        transform: translate3d(var(--to-x, -10px), var(--to-y, -38px), 0)
            scale(var(--scale-end, 0.92));
        opacity: 0;
    }
}

@keyframes star-twinkle {
    0% {
        opacity: 0.16;
        filter: brightness(0.88);
    }
    28% {
        opacity: 0.88;
        filter: brightness(1.24);
    }
    54% {
        opacity: 0.34;
        filter: brightness(0.96);
    }
    76% {
        opacity: 0.72;
        filter: brightness(1.14);
    }
    100% {
        opacity: 0.2;
        filter: brightness(0.9);
    }
}

@keyframes cosmic-drift {
    0% {
        transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
    }
    35% {
        transform: translate3d(-1.8%, 1.6%, 0) scale(1.06) rotate(-0.8deg);
    }
    68% {
        transform: translate3d(1.6%, -1.4%, 0) scale(1.035) rotate(0.75deg);
    }
    100% {
        transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
    }
}

@keyframes starfield-shift {
    0% {
        transform: translate3d(0, 0, 0) scale(1);
        opacity: 0.66;
    }
    25% {
        transform: translate3d(1.2%, -1.5%, 0) scale(1.032);
        opacity: 0.9;
    }
    55% {
        transform: translate3d(-1.6%, 1.2%, 0) scale(1.044);
        opacity: 0.74;
    }
    78% {
        transform: translate3d(1.1%, 0.6%, 0) scale(1.028);
        opacity: 0.94;
    }
    100% {
        transform: translate3d(0, 0, 0) scale(1);
        opacity: 0.7;
    }
}

@keyframes starfield-pulse {
    0% {
        opacity: 0.72;
        filter: brightness(0.94);
    }
    32% {
        opacity: 0.96;
        filter: brightness(1.08);
    }
    64% {
        opacity: 0.74;
        filter: brightness(0.98);
    }
    100% {
        opacity: 0.78;
        filter: brightness(0.95);
    }
}

.theme-luxe {
    background:
        radial-gradient(
            circle at 14% 18%,
            rgba(244, 212, 161, 0.12),
            transparent 20%
        ),
        radial-gradient(
            circle at 82% 14%,
            rgba(217, 119, 6, 0.12),
            transparent 22%
        ),
        radial-gradient(
            circle at 66% 72%,
            rgba(245, 158, 11, 0.08),
            transparent 24%
        ),
        radial-gradient(
            circle at 38% 42%,
            rgba(255, 248, 235, 0.05),
            transparent 18%
        ),
        radial-gradient(
            circle at 52% 18%,
            rgba(251, 191, 36, 0.05),
            transparent 16%
        ),
        linear-gradient(180deg, #01030a 0%, #030712 42%, #07111f 100%);
    color: #edf2ff;
}

.theme-luxe::before {
    background:
        radial-gradient(
            circle at 50% -8%,
            rgba(255, 255, 255, 0.08),
            transparent 26%
        ),
        radial-gradient(
            circle at 74% 24%,
            rgba(245, 158, 11, 0.12),
            transparent 20%
        ),
        radial-gradient(
            circle at 20% 64%,
            rgba(251, 191, 36, 0.08),
            transparent 18%
        ),
        radial-gradient(
            circle at 48% 38%,
            rgba(234, 179, 8, 0.05),
            transparent 14%
        ),
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 38%);
    transform-origin: center;
    filter: blur(6px);
    animation: cosmic-drift 24s ease-in-out infinite;
}

.theme-luxe::after {
    background:
        radial-gradient(
            circle at 4% 12%,
            rgba(255, 255, 255, 0.92) 0 0.9px,
            transparent 1.6px
        ),
        radial-gradient(
            circle at 9% 68%,
            rgba(255, 255, 255, 0.78) 0 1px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 14% 26%,
            rgba(254, 240, 138, 0.78) 0 1px,
            transparent 1.8px
        ),
        radial-gradient(
            circle at 18% 84%,
            rgba(255, 255, 255, 0.82) 0 0.9px,
            transparent 1.6px
        ),
        radial-gradient(
            circle at 24% 44%,
            rgba(253, 224, 71, 0.76) 0 1.1px,
            transparent 1.9px
        ),
        radial-gradient(
            circle at 29% 16%,
            rgba(255, 255, 255, 0.8) 0 0.9px,
            transparent 1.6px
        ),
        radial-gradient(
            circle at 33% 72%,
            rgba(255, 237, 213, 0.72) 0 1px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 38% 30%,
            rgba(255, 255, 255, 0.88) 0 1.1px,
            transparent 1.9px
        ),
        radial-gradient(
            circle at 43% 58%,
            rgba(253, 230, 138, 0.72) 0 0.9px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 49% 10%,
            rgba(255, 255, 255, 0.84) 0 1px,
            transparent 1.8px
        ),
        radial-gradient(
            circle at 54% 82%,
            rgba(255, 255, 255, 0.8) 0 0.9px,
            transparent 1.6px
        ),
        radial-gradient(
            circle at 58% 36%,
            rgba(251, 191, 36, 0.8) 0 1.1px,
            transparent 1.9px
        ),
        radial-gradient(
            circle at 63% 22%,
            rgba(255, 255, 255, 0.86) 0 0.9px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 68% 66%,
            rgba(255, 237, 213, 0.74) 0 1px,
            transparent 1.8px
        ),
        radial-gradient(
            circle at 74% 12%,
            rgba(255, 255, 255, 0.88) 0 1.1px,
            transparent 1.9px
        ),
        radial-gradient(
            circle at 78% 48%,
            rgba(254, 240, 138, 0.72) 0 0.9px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 83% 74%,
            rgba(255, 255, 255, 0.9) 0 1px,
            transparent 1.8px
        ),
        radial-gradient(
            circle at 89% 28%,
            rgba(255, 237, 213, 0.72) 0 0.9px,
            transparent 1.7px
        ),
        radial-gradient(
            circle at 94% 58%,
            rgba(255, 255, 255, 0.8) 0 1px,
            transparent 1.8px
        );
    opacity: 0.84;
    transform-origin: center;
    filter: brightness(1);
    animation:
        starfield-shift 18s ease-in-out infinite,
        starfield-pulse 7.2s ease-in-out infinite;
}

.theme-luxe .header {
    background:
        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.07),
            rgba(255, 255, 255, 0.02)
        ),
        linear-gradient(160deg, rgba(24, 32, 54, 0.98), rgba(10, 14, 23, 0.96));
    border: 1px solid rgba(215, 186, 131, 0.18);
    box-shadow: 0 36px 90px rgba(0, 0, 0, 0.32);
}

.theme-luxe .header::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(
            circle at top right,
            rgba(245, 208, 137, 0.2),
            transparent 30%
        ),
        linear-gradient(
            120deg,
            transparent 0%,
            rgba(255, 255, 255, 0.06) 45%,
            transparent 70%
        );
    pointer-events: none;
}

.theme-luxe .public-section-title {
    color: #fff8ef;
}

.theme-luxe .avatar {
    border-radius: 32px;
    color: #fff7eb;
    background: linear-gradient(145deg, #f4d4a1, #9b6b36);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.34),
        0 26px 56px rgba(155, 107, 54, 0.3);
}

.theme-luxe .name {
    font-family: "Cormorant Garamond", "Noto Serif SC", serif;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #fff7eb;
}

.theme-luxe .bio {
    color: rgba(237, 242, 255, 0.74);
}

.theme-luxe .link-card {
    border-radius: 30px;
    border: 1px solid rgba(215, 186, 131, 0.14);
    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.06),
            rgba(255, 255, 255, 0.02)
        ),
        rgba(6, 10, 20, 0.92);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
    color: #edf2ff;
}

.theme-luxe .link-card:hover {
    transform: translateY(-10px);
    border-color: rgba(233, 204, 150, 0.32);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.28);
}

.theme-luxe .card-icon {
    border-radius: 22px;
    background: linear-gradient(145deg, #f4d4a1, #9b6b36);
    color: #24160a;
    box-shadow: 0 16px 36px rgba(155, 107, 54, 0.24);
}

.theme-luxe .card-content h3 {
    color: #fff8ef;
}

.theme-luxe .card-content p {
    color: rgba(237, 242, 255, 0.64);
}

.theme-luxe .card-tag {
    color: #f5deb5;
    background: rgba(206, 170, 111, 0.12);
    border: 1px solid rgba(215, 186, 131, 0.16);
}

.theme-luxe .card-host,
.theme-luxe .card-action {
    color: rgba(237, 242, 255, 0.68);
}

.theme-luxe .card-arrow {
    color: #f5deb5;
}

.theme-luxe .social-link {
    border-radius: 999px;
    border: 1px solid rgba(215, 186, 131, 0.16);
    background: rgba(6, 10, 20, 0.88);
    color: #fff7eb;
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.22);
}

.theme-luxe .social-mark {
    background: linear-gradient(145deg, #f4d4a1, #9b6b36);
    color: #23160d;
}

.theme-luxe .social-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 22px 42px rgba(0, 0, 0, 0.28);
}

.theme-luxe .footer {
    color: rgba(237, 242, 255, 0.62);
    border-top: 1px solid rgba(215, 186, 131, 0.12);
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.02));
}

.theme-luxe .footer code,
.preview-shell.theme-luxe .preview-footer code {
    background: rgba(215, 186, 131, 0.14);
}

.theme-luxe .loading {
    color: #f5deb5;
    background: rgba(6, 10, 20, 0.78);
}

.theme-luxe .error {
    color: #fecaca;
    background: rgba(127, 29, 29, 0.26);
}

.theme-luxe .refresh-btn {
    background: linear-gradient(145deg, #f4d4a1, #9b6b36);
    color: #23160d;
    box-shadow: 0 20px 44px rgba(155, 107, 54, 0.35);
}

.theme-luxe .admin-btn {
    background: rgba(6, 10, 20, 0.92);
    color: #fff7eb;
    border: 1px solid rgba(215, 186, 131, 0.16);
    box-shadow: 0 20px 44px rgba(0, 0, 0, 0.28);
}

.theme-ink {
    background:
        radial-gradient(
            circle at 18% 14%,
            rgba(33, 33, 33, 0.08),
            transparent 24%
        ),
        radial-gradient(
            circle at 86% 18%,
            rgba(70, 48, 31, 0.08),
            transparent 20%
        ),
        linear-gradient(180deg, #f7f1e6 0%, #efe5d4 100%);
    color: #1f2937;
}

.theme-ink::before {
    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.52),
            rgba(255, 255, 255, 0)
        ),
        radial-gradient(
            circle at 16% 26%,
            rgba(17, 24, 39, 0.05),
            transparent 20%
        );
}

.theme-ink::after {
    background-image:
        linear-gradient(rgba(82, 63, 41, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(82, 63, 41, 0.03) 1px, transparent 1px);
    background-size: 110px 110px;
    opacity: 0.18;
}

.theme-ink .header {
    background:
        linear-gradient(
            180deg,
            rgba(255, 252, 247, 0.9),
            rgba(249, 243, 233, 0.86)
        ),
        radial-gradient(
            circle at top right,
            rgba(17, 24, 39, 0.06),
            transparent 28%
        );
    border: 1px solid rgba(96, 84, 61, 0.16);
    box-shadow: 0 26px 58px rgba(77, 59, 34, 0.12);
}

.theme-ink .header::before {
    content: "";
    position: absolute;
    inset: 20px;
    border: 1px solid rgba(96, 84, 61, 0.1);
    border-radius: 28px;
    pointer-events: none;
}

.theme-ink .hero-kicker {
    font-family: "Long Cang", "Noto Serif SC", serif;
    font-size: 1.35rem;
    letter-spacing: 0.16em;
    color: #7a6142;
}

.theme-ink .public-section-title {
    color: #1f2937;
}

.theme-ink .avatar {
    border-radius: 28px;
    background:
        radial-gradient(
            circle at 30% 30%,
            rgba(255, 255, 255, 0.6),
            transparent 28%
        ),
        linear-gradient(145deg, #232323, #5c4a37);
    color: #f9f3ea;
    box-shadow: 0 18px 38px rgba(77, 59, 34, 0.18);
}

.theme-ink .name {
    font-family: "Noto Serif SC", "Cormorant Garamond", serif;
    font-weight: 600;
    color: #1f2937;
}

.theme-ink .bio {
    color: rgba(31, 41, 55, 0.78);
}

.theme-ink .link-card {
    border-radius: 26px;
    border: 1px solid rgba(96, 84, 61, 0.14);
    background: linear-gradient(
        180deg,
        rgba(255, 252, 247, 0.95),
        rgba(248, 241, 230, 0.88)
    );
    box-shadow: 0 16px 34px rgba(77, 59, 34, 0.1);
    color: #1f2937;
}

.theme-ink .link-card:hover {
    transform: translateY(-7px);
    border-color: rgba(51, 65, 85, 0.22);
    box-shadow: 0 24px 42px rgba(77, 59, 34, 0.14);
}

.theme-ink .card-icon {
    border-radius: 18px;
    background: linear-gradient(145deg, #232323, #5c4a37);
    color: #f7f1e6;
}

.theme-ink .card-content h3 {
    color: #111827;
}

.theme-ink .card-content p {
    color: rgba(31, 41, 55, 0.7);
}

.theme-ink .card-tag {
    color: #5c4a37;
    background: rgba(92, 74, 55, 0.08);
    border: 1px solid rgba(92, 74, 55, 0.12);
}

.theme-ink .card-host,
.theme-ink .card-action {
    color: rgba(31, 41, 55, 0.64);
}

.theme-ink .card-arrow {
    color: #5c4a37;
}

.theme-ink .social-link {
    border-radius: 999px;
    border: 1px solid rgba(96, 84, 61, 0.14);
    background: rgba(255, 251, 245, 0.9);
    color: #3c3127;
    box-shadow: 0 12px 28px rgba(77, 59, 34, 0.1);
}

.theme-ink .social-mark {
    background: linear-gradient(145deg, #232323, #5c4a37);
    color: #f8f1e5;
}

.theme-ink .social-link:hover {
    transform: translateY(-4px);
}

.theme-ink .footer {
    color: rgba(31, 41, 55, 0.72);
    border-top: 1px solid rgba(96, 84, 61, 0.14);
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.28));
}

.theme-ink .footer code,
.preview-shell.theme-ink .preview-footer code {
    background: rgba(92, 74, 55, 0.08);
}

.theme-ink .loading {
    color: #5c4a37;
    background: rgba(255, 251, 245, 0.82);
}

.theme-ink .error {
    color: #b91c1c;
    background: rgba(254, 242, 242, 0.92);
}

.theme-ink .refresh-btn {
    background: #1f2937;
    color: #f9f3ea;
    box-shadow: 0 18px 36px rgba(77, 59, 34, 0.2);
}

.theme-ink .admin-btn {
    background: rgba(255, 251, 245, 0.94);
    color: #1f2937;
    border: 1px solid rgba(96, 84, 61, 0.14);
    box-shadow: 0 18px 36px rgba(77, 59, 34, 0.14);
}

.refresh-btn:hover,
.admin-btn:hover {
    transform: translateY(-4px);
}

.admin-body {
    background:
        radial-gradient(
            circle at 16% 18%,
            rgba(14, 165, 233, 0.1),
            transparent 26%
        ),
        radial-gradient(
            circle at 84% 10%,
            rgba(245, 158, 11, 0.1),
            transparent 24%
        ),
        linear-gradient(180deg, #f6f8fc 0%, #eef3fb 100%);
    color: #102033;
}

.admin-body::before {
    background:
        radial-gradient(
            circle at top,
            rgba(255, 255, 255, 0.9),
            transparent 40%
        ),
        linear-gradient(180deg, rgba(255, 255, 255, 0.62), transparent);
}

.admin-body::after {
    background-image:
        linear-gradient(rgba(148, 163, 184, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(148, 163, 184, 0.06) 1px, transparent 1px);
    background-size: 124px 124px;
    opacity: 0.28;
}

.admin-container {
    width: min(1360px, calc(100% - 40px));
    padding-top: 46px;
    padding-bottom: 56px;
}

.admin-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 28px;
}

.admin-body.admin-locked .admin-container {
    width: min(640px, calc(100% - 32px));
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: 32px;
    padding-bottom: 32px;
}

.admin-body.admin-locked
    .admin-container
    > :not(#loginPanel):not(#adminMessage) {
    display: none !important;
}

.admin-body.admin-locked .admin-header {
    display: none;
}

.admin-body.admin-locked .admin-message {
    margin-bottom: 18px;
}

.admin-body.admin-locked .login-card {
    margin: 0 auto;
}

.admin-header-copy {
    max-width: 760px;
}

.login-card {
    width: min(560px, 100%);
    margin: 0 auto 24px;
}

.login-form {
    display: grid;
    gap: 18px;
}

.admin-header h1 {
    font-family: "Cormorant Garamond", "Noto Serif SC", serif;
    font-size: clamp(2.9rem, 5vw, 4.8rem);
    line-height: 0.95;
    margin-bottom: 16px;
}

.admin-header .bio {
    margin: 0;
    max-width: none;
    color: rgba(16, 32, 51, 0.7);
}

.eyebrow,
.section-kicker {
    color: #0369a1;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-size: 0.76rem;
    font-weight: 800;
}

.admin-header-actions,
.admin-actions,
.action-secondary,
.item-actions,
.footer-helper-actions,
.hint-pills,
.preview-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.back-link,
.primary-btn,
.secondary-btn,
.ghost-btn,
.item-actions button {
    height: 46px;
    padding: 0 18px;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    text-decoration: none;
    cursor: pointer;
    font: inherit;
    transition:
        transform 0.22s ease,
        box-shadow 0.22s ease,
        border-color 0.22s ease,
        background 0.22s ease;
}

.back-link,
.secondary-btn,
.ghost-btn,
.item-actions button {
    background: rgba(255, 255, 255, 0.9);
    color: #102033;
}

.primary-btn {
    background: linear-gradient(135deg, #0f766e, #0ea5e9);
    color: white;
    border: none;
    box-shadow: 0 18px 36px rgba(14, 165, 233, 0.24);
}

.ghost-btn {
    background: transparent;
    border-style: dashed;
    color: rgba(16, 32, 51, 0.7);
}

.back-link:hover,
.primary-btn:hover,
.secondary-btn:hover,
.ghost-btn:hover,
.item-actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.back-link:disabled,
.primary-btn:disabled,
.secondary-btn:disabled,
.ghost-btn:disabled,
.item-actions button:disabled {
    opacity: 0.58;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.admin-workspace-shell,
.admin-form,
.sticky-stack,
.overview-status,
.action-stack,
.action-primary,
.checklist,
.preview-site,
.preview-links,
.footer-helper,
.theme-toggle {
    display: grid;
    gap: 16px;
}

.admin-card {
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(12px);
    position: relative;
    overflow: hidden;
}

.admin-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.72),
        transparent
    );
    pointer-events: none;
}

.overview-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 22px;
}

.metric-card,
.editor-item,
.checklist li,
.footer-helper {
    background: rgba(248, 250, 252, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 22px;
}

.metric-card {
    padding: 18px;
}

.metric-card span {
    display: block;
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(16, 32, 51, 0.58);
}

.metric-card strong {
    display: block;
    margin: 10px 0 8px;
    font-size: 2rem;
}

.metric-card small,
.overview-note,
.section-title p,
.section-help,
.footer-helper-copy p,
.footer-helper-tips,
.action-note,
.action-caption,
.checklist span:last-child,
.item-summary,
.preview-header p,
.preview-link-card p,
.preview-footer,
.admin-form label small {
    color: rgba(16, 32, 51, 0.66);
    line-height: 1.65;
}

.overview-actions,
.inline-title,
.item-toolbar,
.action-card {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.hint-pill,
.count-badge,
.status-pill,
.meta-pill,
.item-index,
.preview-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 0.84rem;
}

.hint-pill,
.count-badge,
.meta-pill {
    padding: 8px 12px;
    background: rgba(14, 165, 233, 0.08);
    border: 1px solid rgba(14, 165, 233, 0.12);
    color: #075985;
}

.status-pill {
    min-width: 88px;
    height: 38px;
    padding: 0 14px;
    background: rgba(226, 232, 240, 0.7);
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.status-pill.is-live {
    background: rgba(34, 197, 94, 0.14);
    color: #15803d;
}

.status-pill.is-warning {
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
}

.admin-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(320px, 0.9fr);
    gap: 24px;
    align-items: start;
}

.section-title {
    margin-bottom: 18px;
}

.section-title h2,
.action-copy h2 {
    font-size: 1.42rem;
    margin: 8px 0 10px;
    line-height: 1.15;
}

.form-grid,
.compact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.full-width,
.theme-field {
    display: block;
}

.theme-field {
    grid-column: 1 / -1;
}

.admin-form label span {
    display: block;
    margin-bottom: 10px;
    color: #102033;
    font-weight: 700;
}

.admin-form input,
.admin-form textarea {
    width: 100%;
    border-radius: 16px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    background: rgba(255, 255, 255, 0.96);
    color: #102033;
    padding: 14px 16px;
    font: inherit;
    line-height: 1.55;
    outline: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.admin-form input::placeholder,
.admin-form textarea::placeholder {
    color: rgba(16, 32, 51, 0.38);
}

.admin-form input:focus,
.admin-form textarea:focus {
    border-color: rgba(14, 165, 233, 0.48);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}

.admin-form input.is-invalid,
.admin-form textarea.is-invalid {
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1);
}

.admin-form textarea {
    min-height: 112px;
    resize: vertical;
}

.theme-toggle {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.theme-option {
    position: relative;
    display: block;
}

.theme-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.theme-option-body {
    display: grid;
    gap: 6px;
    min-height: 100%;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    background: rgba(255, 255, 255, 0.92);
    cursor: pointer;
    transition:
        transform 0.22s ease,
        border-color 0.22s ease,
        box-shadow 0.22s ease;
}

.theme-option-body strong {
    font-size: 1rem;
}

.theme-option input:checked + .theme-option-body {
    border-color: rgba(14, 165, 233, 0.48);
    box-shadow: 0 14px 28px rgba(14, 165, 233, 0.14);
    transform: translateY(-2px);
}

.editor-list {
    display: grid;
    gap: 16px;
}

.editor-item {
    padding: 18px;
    position: relative;
    transition:
        transform 0.22s ease,
        box-shadow 0.22s ease,
        border-color 0.22s ease;
}

.editor-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.08);
    border-color: rgba(14, 165, 233, 0.18);
}

.item-copy {
    min-width: 0;
    flex: 1;
}

.item-copy strong {
    display: block;
    margin-bottom: 6px;
    font-size: 1rem;
}

.item-summary {
    overflow-wrap: anywhere;
}

.item-index {
    min-width: 48px;
    height: 36px;
    padding: 0 12px;
    background: rgba(226, 232, 240, 0.78);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.item-actions button {
    height: 36px;
    padding: 0 14px;
}

.field-error {
    display: block;
    margin-top: 8px;
    color: #dc2626;
    font-size: 0.84rem;
    line-height: 1.5;
}

.footer-helper-copy strong {
    display: block;
    margin-bottom: 6px;
}

.helper-btn {
    height: 40px;
}

#saveAndOpenBtn,
.primary-wide {
    width: 100%;
}

.footer-helper-tips span {
    overflow-wrap: anywhere;
}

.action-stack {
    min-width: min(100%, 420px);
}

.admin-preview-panel {
    min-width: 0;
}

.sticky-stack {
    position: sticky;
    top: 24px;
}

.preview-shell {
    padding: 20px;
    border-radius: 28px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    position: relative;
    overflow: hidden;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        0 16px 32px rgba(15, 23, 42, 0.08);
}

.preview-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.08),
        transparent 28%
    );
    pointer-events: none;
}

.preview-browser-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
}

.preview-browser-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(148, 163, 184, 0.48);
}

.preview-header {
    text-align: center;
    padding-bottom: 4px;
}

.preview-header h3 {
    font-size: 1.65rem;
    margin-bottom: 8px;
}

.preview-avatar {
    width: 80px;
    height: 80px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.9rem;
    font-weight: 700;
}

.preview-link-card {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
    border-radius: 18px;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.preview-link-card:hover {
    transform: translateY(-2px);
}

.preview-link-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.preview-social {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.preview-social-item {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.preview-social-item:hover {
    transform: translateY(-2px);
}

.preview-empty {
    padding: 14px 16px;
    border-radius: 16px;
    text-align: center;
}

.preview-footer {
    padding-top: 10px;
    text-align: center;
}

.preview-shell.theme-luxe {
    background:
        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.05),
            rgba(255, 255, 255, 0.02)
        ),
        linear-gradient(160deg, rgba(24, 32, 54, 0.98), rgba(10, 14, 23, 0.98));
    color: #edf2ff;
}

.preview-shell.theme-luxe .preview-browser-dot:nth-child(1) {
    background: #fb7185;
}

.preview-shell.theme-luxe .preview-browser-dot:nth-child(2) {
    background: #f59e0b;
}

.preview-shell.theme-luxe .preview-browser-dot:nth-child(3) {
    background: #22c55e;
}

.preview-shell.theme-luxe .preview-avatar,
.preview-shell.theme-luxe .preview-link-icon {
    border-radius: 18px;
    background: linear-gradient(145deg, #f4d4a1, #9b6b36);
    color: #23160d;
}

.preview-shell.theme-luxe .preview-link-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(215, 186, 131, 0.14);
}

.preview-shell.theme-luxe .preview-social-item {
    border-radius: 50%;
    background: rgba(14, 20, 33, 0.88);
    border: 1px solid rgba(215, 186, 131, 0.16);
}

.preview-shell.theme-luxe .preview-tag {
    padding: 4px 10px;
    background: rgba(206, 170, 111, 0.12);
    color: #f5deb5;
}

.preview-shell.theme-luxe .preview-empty {
    background: rgba(255, 255, 255, 0.04);
    border: 1px dashed rgba(215, 186, 131, 0.14);
}

.preview-shell.theme-luxe .preview-footer {
    border-top: 1px solid rgba(215, 186, 131, 0.12);
    color: rgba(237, 242, 255, 0.72);
}

.preview-shell.theme-ink {
    background: linear-gradient(
        180deg,
        rgba(255, 252, 247, 0.96),
        rgba(249, 243, 233, 0.92)
    );
    color: #1f2937;
}

.preview-shell.theme-ink .preview-browser-dot:nth-child(1) {
    background: rgba(185, 28, 28, 0.56);
}

.preview-shell.theme-ink .preview-browser-dot:nth-child(2) {
    background: rgba(180, 83, 9, 0.56);
}

.preview-shell.theme-ink .preview-browser-dot:nth-child(3) {
    background: rgba(21, 128, 61, 0.56);
}

.preview-shell.theme-ink .preview-avatar,
.preview-shell.theme-ink .preview-link-icon {
    border-radius: 16px;
    background: linear-gradient(145deg, #232323, #5c4a37);
    color: #f8f1e5;
}

.preview-shell.theme-ink .preview-link-card {
    background: rgba(255, 255, 255, 0.68);
    border: 1px solid rgba(96, 84, 61, 0.12);
}

.preview-shell.theme-ink .preview-social-item {
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.68);
    border: 1px solid rgba(96, 84, 61, 0.12);
}

.preview-shell.theme-ink .preview-tag {
    padding: 4px 10px;
    background: rgba(92, 74, 55, 0.08);
    color: #5c4a37;
}

.preview-shell.theme-ink .preview-empty {
    background: rgba(255, 255, 255, 0.68);
    border: 1px dashed rgba(96, 84, 61, 0.14);
}

.preview-shell.theme-ink .preview-footer {
    border-top: 1px solid rgba(96, 84, 61, 0.14);
    color: rgba(31, 41, 55, 0.72);
}

.checklist {
    list-style: none;
}

.checklist li {
    display: grid;
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 14px 16px;
}

.checklist-mark {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.checklist strong {
    display: block;
    margin-bottom: 6px;
}

.checklist li.is-done .checklist-mark {
    background: rgba(34, 197, 94, 0.14);
    color: #15803d;
}

.checklist li.is-pending .checklist-mark {
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
}

.checklist li.is-optional .checklist-mark {
    background: rgba(14, 165, 233, 0.12);
    color: #0369a1;
}

.admin-message {
    margin-bottom: 24px;
    padding: 16px 20px;
    border-radius: 18px;
    border: 1px solid transparent;
    line-height: 1.5;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.admin-message.success-state {
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.22);
    color: #15803d;
}

.admin-message.error-state {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.18);
    color: #b91c1c;
}

@media (max-width: 1100px) {
    .admin-workspace {
        grid-template-columns: 1fr;
    }

    .sticky-stack {
        position: static;
    }
}

@media (max-width: 900px) {
    .overview-grid,
    .theme-toggle {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .container,
    .admin-container {
        width: min(100% - 24px, 100%);
    }

    .header {
        padding: 52px 22px 36px;
    }

    .loading,
    .error,
    .footer {
        width: 100%;
    }

    .name {
        font-size: clamp(2.4rem, 12vw, 3.4rem);
    }

    .bio {
        font-size: 1rem;
    }

    .public-section-title {
        font-size: 1.35rem;
    }

    .card-meta {
        flex-direction: column;
        align-items: flex-start;
    }

    .social-link {
        width: 100%;
        justify-content: flex-start;
    }

    .links-grid,
    .form-grid,
    .compact-grid,
    .overview-grid {
        grid-template-columns: 1fr;
    }

    .admin-header,
    .inline-title,
    .action-card,
    .admin-actions,
    .action-secondary,
    .item-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .footer-helper-actions,
    .item-actions {
        width: 100%;
    }

    .item-actions button,
    .back-link,
    .primary-btn,
    .secondary-btn,
    .ghost-btn,
    .helper-btn {
        width: 100%;
    }

    .admin-card {
        padding: 22px;
    }

    .refresh-btn {
        right: 16px;
        bottom: 16px;
    }

    .admin-btn {
        right: 78px;
        bottom: 16px;
    }
}
