/* ============================================================
   XII RPL 2 — Nature Glassmorphism Link Card
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --glass:       rgba(10, 12, 18, 0.55);
    --glass-card:  rgba(255, 255, 255, 0.09);
    --glass-hover: rgba(255, 255, 255, 0.14);
    --border:      rgba(255, 255, 255, 0.14);
    --border-h:    rgba(255, 255, 255, 0.28);
    --text:        #ffffff;
    --text-2:      rgba(255, 255, 255, 0.65);
    --text-3:      rgba(255, 255, 255, 0.38);
    --ease:        cubic-bezier(0.25, 1, 0.5, 1);
    --ease-back:   cubic-bezier(0.34, 1.4, 0.64, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { height: 100%; }

body {
    min-height: 100dvh;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-font-smoothing: antialiased;
    color: var(--text);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    overflow-x: hidden;
    position: relative;
}

/* ============================================================
   BACKGROUND SLIDESHOW
   ============================================================ */
.bg-slideshow {
    position: fixed;
    inset: 0;
    z-index: 0;
}

.bg-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    /* crossfade only — no transform glitch on enter */
    transition: opacity 1.8s ease;
    will-change: opacity;
    /* default idle state */
    animation: none;
}

.bg-slide.active {
    opacity: 1;
    /* Ken Burns: slow cinematic zoom + very subtle pan */
    animation: kenBurns 10s ease forwards;
}

/* Each slide gets a slightly different pan direction for variety */
.bg-slide:nth-child(1).active { animation-name: kenBurns1; }
.bg-slide:nth-child(2).active { animation-name: kenBurns2; }
.bg-slide:nth-child(3).active { animation-name: kenBurns3; }
.bg-slide:nth-child(4).active { animation-name: kenBurns4; }

@keyframes kenBurns1 {
    from { transform: scale(1.08) translate(1%, 1%); }
    to   { transform: scale(1.00) translate(0%, 0%); }
}
@keyframes kenBurns2 {
    from { transform: scale(1.08) translate(-1%, 0.5%); }
    to   { transform: scale(1.00) translate(0%, 0%); }
}
@keyframes kenBurns3 {
    from { transform: scale(1.06) translate(0%, -1%); }
    to   { transform: scale(1.00) translate(0%, 0%); }
}
@keyframes kenBurns4 {
    from { transform: scale(1.06) translate(0.5%, 1%); }
    to   { transform: scale(1.00) translate(0%, 0%); }
}

/* Dark gradient overlay — readable foreground */
.bg-overlay {
    position: absolute;
    inset: 0;
    background: 
        linear-gradient(to bottom,
            rgba(0,0,0,0.45) 0%,
            rgba(0,0,0,0.25) 40%,
            rgba(0,0,0,0.55) 100%
        );
}

/* ============================================================
   PAGE CONTAINER
   ============================================================ */
.page {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    padding: 4.5rem 1.5rem 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

/* ============================================================
   PROFILE
   ============================================================ */
.profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.6rem;
    opacity: 0;
    transform: translateY(20px);
    animation: rise 0.7s var(--ease) 0.1s forwards;
}

@keyframes rise {
    to { opacity: 1; transform: translateY(0); }
}

/* Avatar — white pill so logo pops */
.avatar-shell {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    /* Glass ring */
    box-shadow:
        0 0 0 3px rgba(255,255,255,0.3),
        0 0 0 6px rgba(255,255,255,0.08),
        0 12px 40px rgba(0,0,0,0.5);
    margin-bottom: 0.5rem;
}

.avatar-img {
    width: 78%;
    height: 78%;
    object-fit: contain;
    display: block;
}

.name {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.1;
    /* text shadow for readability over any bg */
    text-shadow: 0 2px 12px rgba(0,0,0,0.6);
}

.name span {
    color: #7eefc0;   /* very soft mint — not neon, not AI-green */
}

.school {
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.75);
    text-shadow: 0 1px 6px rgba(0,0,0,0.5);
}

.bio {
    font-size: 0.88rem;
    color: var(--text-2);
    text-shadow: 0 1px 6px rgba(0,0,0,0.5);
}

/* ============================================================
   LINK CARDS — Clean Glassmorphism
   ============================================================ */
.links {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.card {
    display: flex;
    align-items: center;
    gap: 0.95rem;
    padding: 1rem 1.1rem;
    text-decoration: none;
    color: var(--text);
    border-radius: 18px;
    background: var(--glass-card);
    border: 1px solid var(--border);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    position: relative;
    overflow: hidden;
    cursor: pointer;

    /* entrance */
    opacity: 0;
    transform: translateY(14px);
    transition:
        background 0.25s ease,
        border-color 0.25s ease,
        transform 0.4s var(--ease-back),
        box-shadow 0.35s ease;
}

.card.show { animation: cardIn 0.55s var(--ease) forwards; }
.card:nth-child(1).show { animation-delay: 0.18s; }
.card:nth-child(2).show { animation-delay: 0.28s; }
.card:nth-child(3).show { animation-delay: 0.38s; }

@keyframes cardIn {
    to { opacity: 1; transform: translateY(0); }
}

/* Hover */
.card:hover {
    background: var(--glass-hover);
    border-color: var(--border-h);
    transform: translateY(-3px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.35);
}

/* Tap / click */
.card:active {
    transform: scale(0.97) !important;
    transition: transform 0.1s ease !important;
}

/* Shimmer sweep on hover */
.card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,0.06) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.55s ease;
    pointer-events: none;
}
.card:hover::after { transform: translateX(100%); }

/* === Card Icon === */
.card-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.4s var(--ease-back);
}
.card:hover .card-icon { transform: scale(1.08) rotate(-3deg); }

.card-icon svg {
    width: 22px;
    height: 22px;
    display: block;
    flex-shrink: 0;
}

/* === Card Text === */
.card-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.card-label {
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    letter-spacing: -0.1px;
}

.card-sub {
    font-size: 0.75rem;
    color: var(--text-2);
    letter-spacing: 0.1px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Badge */
.badge {
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    background: rgba(126,239,192,0.18);
    color: #7eefc0;
    border: 1px solid rgba(126,239,192,0.3);
    padding: 0.15rem 0.5rem;
    border-radius: 100px;
    flex-shrink: 0;
}

/* === Card Arrow === */
.card-arrow {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-2);
    transition: color 0.25s, transform 0.4s var(--ease-back);
}
.card-arrow svg { width: 18px; height: 18px; display: block; }
.card:hover .card-arrow { color: #fff; transform: translateX(4px); }

/* === Featured card (Website) === */
.card-featured {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.22);
}
.card-featured:hover {
    background: rgba(255,255,255,0.18);
    box-shadow: 0 16px 40px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.1);
}

/* ============================================================
   SLIDESHOW DOTS
   ============================================================ */
.dots {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.3);
    cursor: pointer;
    padding: 0;
    transition: background 0.3s, transform 0.3s var(--ease-back), width 0.35s var(--ease-back);
    appearance: none;
    outline: none;
}

.dot.active {
    background: #fff;
    width: 22px;
    border-radius: 3px;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
    font-size: 0.7rem;
    color: var(--text-3);
    letter-spacing: 0.5px;
    text-align: center;
    opacity: 0;
    animation: rise 0.7s var(--ease) 0.7s forwards;
    text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (min-width: 600px) {
    body { align-items: center; }
    .page { padding: 4rem 0; }
}

@media (max-width: 360px) {
    .page { padding: 3.5rem 1rem 2.5rem; }
    .name { font-size: 1.5rem; }
    .avatar-shell { width: 76px; height: 76px; }
    .card { padding: 0.85rem 0.9rem; }
    .card-icon { width: 42px; height: 42px; }
}
