/* ==========================================================================
   DESIGN SYSTEM & VARIABLES
   ========================================================================== */
:root {
    /* Color Palette */
    --bg-dark: #07070a;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-primary: #ffffff;
    --text-secondary: #a3a3b3;
    
    /* Brand Accent Colors */
    --instagram-glow: rgba(225, 48, 108, 0.45);
    --instagram-border: rgba(225, 48, 108, 0.3);
    --linkedin-glow: rgba(10, 102, 194, 0.45);
    --linkedin-border: rgba(10, 102, 194, 0.3);
    
    /* Typography */
    --font-primary: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    
    /* Animation & Transitions */
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-bounce: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ==========================================================================
   RESET & BASE STYLES
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    background-color: var(--bg-dark);
    font-family: var(--font-primary);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   BACKGROUND ANIMATION
   ========================================================================== */
.bg-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -2;
    background: radial-gradient(circle at 10% 20%, rgba(88, 38, 250, 0.12) 0%, transparent 40%),
                radial-gradient(circle at 90% 80%, rgba(225, 48, 108, 0.08) 0%, transparent 40%),
                radial-gradient(circle at 50% 50%, rgba(10, 102, 194, 0.05) 0%, transparent 60%);
    background-color: var(--bg-dark);
    filter: blur(40px);
}

.bg-glow {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(120, 80, 255, 0.06) 0%, transparent 70%);
    z-index: -1;
    pointer-events: none;
    transition: transform 0.2s ease-out;
}

/* ==========================================================================
   CONTAINER & LAYOUT
   ========================================================================== */
.container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 24px 16px;
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
}

/* ==========================================================================
   GLASSMORPHIC CARD
   ========================================================================== */
.card {
    width: 100%;
    max-width: 380px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border-radius: 28px;
    padding: 40px 24px 32px 24px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5),
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(30px);
    transition: var(--transition-smooth);
}

.card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Profile Elements */
.avatar-container {
    position: relative;
    margin-bottom: 20px;
}

.avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.1);
    background-color: rgba(255, 255, 255, 0.02);
    position: relative;
    z-index: 2;
    transition: var(--transition-bounce);
}

.avatar-ring {
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7850ff, #e1306c, #0a66c2);
    z-index: 1;
    opacity: 0.4;
    filter: blur(8px);
    transition: var(--transition-smooth);
}

.avatar-container:hover .avatar {
    transform: scale(1.05) rotate(2deg);
}

.avatar-container:hover .avatar-ring {
    opacity: 0.8;
    filter: blur(12px);
    transform: scale(1.08);
}

.name {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
    background: linear-gradient(180deg, #ffffff 0%, #dcdcdf 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tagline {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-weight: 400;
    margin-bottom: 32px;
}

/* ==========================================================================
   LINK BUTTONS
   ========================================================================== */
.links-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 32px;
}

.link-card {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 18px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    outline: none;
}

/* Focus styles for accessibility */
.link-card:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.4);
    outline-offset: 2px;
}

/* Glow highlights per brand */
.link-card.instagram-theme:hover {
    background: rgba(225, 48, 108, 0.08);
    border-color: var(--instagram-border);
    box-shadow: 0 10px 30px var(--instagram-glow),
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    transform: translateY(-3px) scale(1.02);
}

.link-card.linkedin-theme:hover {
    background: rgba(10, 102, 194, 0.08);
    border-color: var(--linkedin-border);
    box-shadow: 0 10px 30px var(--linkedin-glow),
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    transform: translateY(-3px) scale(1.02);
}

/* Tap response for Mobile (active class) */
.link-card:active {
    transform: translateY(-1px) scale(0.99) !important;
    opacity: 0.9;
}

/* Icon Container */
.link-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 16px;
    transition: var(--transition-smooth);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.svg-icon {
    width: 20px;
    height: 20px;
    transition: var(--transition-bounce);
}

.instagram-theme .svg-icon {
    color: #e1306c;
}

.linkedin-theme .svg-icon {
    color: #0a66c2;
}

.link-card:hover .link-icon {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

/* Content Details */
.link-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex-grow: 1;
}

.link-title {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -0.2px;
    margin-bottom: 2px;
}

.link-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Arrow Right */
.link-arrow {
    width: 24px;
    height: 24px;
    opacity: 0.3;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: var(--transition-bounce);
}

.link-arrow svg {
    width: 18px;
    height: 18px;
    stroke: var(--text-primary);
}

.link-card:hover .link-arrow {
    opacity: 1;
    transform: translateX(4px);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
    width: 100%;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    padding-top: 24px;
}

.copyright {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 0.2px;
}

/* ==========================================================================
   MEDIA QUERIES (Extra Mobile Optimizations)
   ========================================================================== */
@media (max-width: 360px) {
    .card {
        padding: 32px 18px 24px 18px;
        border-radius: 24px;
    }
    .avatar {
        width: 80px;
        height: 80px;
    }
    .name {
        font-size: 1.4rem;
    }
    .link-card {
        padding: 12px 16px;
    }
    .link-icon {
        width: 40px;
        height: 40px;
        margin-right: 12px;
    }
    .link-title {
        font-size: 0.95rem;
    }
}
