:root {
    --primary: #7f5af0;
    --secondary: #2cb67d;
    --background: #16161a;
    --card-bg: #242629;
    --text-primary: #fffffe;
    --text-secondary: #94a1b2;
    --gradient-angle: 135deg;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --mobi-card-bg: #292932;
}

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

body {
    font-family: 'Inter', sans-serif;
    background: var(--background);
    color: var(--text-primary);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    padding: 20px 0;
    line-height: 1.6;
}

.container {
    background: var(--card-bg);
    width: 100%;
    max-width: 480px;
    padding: 2.5rem;
    border-radius: 24px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
    margin: 20px 0;
    position: relative;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.container:hover {
    transform: translateY(-4px);
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.5);
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    30% { transform: translateY(-12px) rotate(2deg); }
    70% { transform: translateY(8px) rotate(-2deg); }
}

header {
    position: relative;
    text-align: left; /* Changed from center */
    margin-bottom: 2.5rem;
}

header::after {
    content: '';
    position: absolute;
    bottom: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--primary), transparent);
    opacity: 0.3;
    transition: width 0.3s ease;
}

.profile-pic {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    margin: 0 0 1.5rem; /* Changed from auto */
    object-fit: cover;
    border: 4px solid var(--card-bg);
    outline: 2px solid var(--primary);
    box-shadow: 0 0 40px rgba(127, 90, 240, 0.3);
    transition: var(--transition);
    animation: float 6s ease-in-out infinite;
    filter: saturate(110%);
}

header h1 {
    font-size: 2.4rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, var(--primary), var(--secondary) 80%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.03em;
    max-width: 100%; /* Added */
    margin-left: 0; /* Added */
}

header p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-weight: 300;
    max-width: 100%; /* Changed from 80% */
    margin-left: 0; /* Changed from auto */
    text-align: left; /* Added */
}

.link-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.link-item {
    position: relative;
    padding: 1.3rem 1.5rem;
    font-size: 1.1rem;
    color: var(--text-primary);
    border: none;
    border-radius: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 18px;
    overflow: hidden;
    transition: var(--transition);
    text-decoration: none;
    background: linear-gradient(145deg, rgba(255,255,255,0.05), rgba(0,0,0,0.1));
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.link-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, 0.15),
        transparent
    );
    transition: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.link-item:hover::before {
    left: 100%;
}

.link-item i {
    font-size: 1.5rem;
    min-width: 32px;
    transition: transform 0.3s ease, color 0.3s ease;
}

.link-item:hover i {
    transform: scale(1.25) rotate(5deg);
    color: var(--text-primary);
}

.link-item span {
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.link-item:hover span {
    transform: translateX(8px);
}

/* Color-specific styles */
.instagram { 
    border-left: 4px solid #e1306c;
    box-shadow: inset 4px 0 12px rgba(225, 48, 108, 0.2);
}

.whatsapp { 
    border-left: 4px solid #25d366;
    box-shadow: inset 4px 0 12px rgba(37, 211, 102, 0.2);
}

.linkedin { 
    border-left: 4px solid #0a66c2;
    box-shadow: inset 4px 0 12px rgba(10, 102, 194, 0.2);
}

.email { 
    border-left: 4px solid #ea4335;
    box-shadow: inset 4px 0 12px rgba(234, 67, 53, 0.2);
}

.blog { 
    border-left: 4px solid var(--secondary);
    box-shadow: inset 4px 0 12px rgba(44, 182, 125, 0.2);
}

.forsova { 
    border-left: 4px solid #00bfff;
    box-shadow: inset 4px 0 12px rgba(0, 191, 255, 0.2);
}

.snapchat { 
    border-left: 4px solid #FFFC00;
    box-shadow: inset 4px 0 12px rgba(255, 252, 0, 0.2);
}

.link-item:hover {
    background: linear-gradient(145deg, rgba(255,255,255,0.08), rgba(0,0,0,0.15));
    transform: translateX(8px) scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

footer {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

footer p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    opacity: 0.8;
    line-height: 1.4;
}

@media (max-width: 480px) {
    body {
        background: var(--mobi-card-bg);
        padding: 0;
    }
    
    .container {
        background: transparent;
        border-radius: 0;
        box-shadow: none;
        border: none;
        padding: 1.5rem;
        margin: 0;
    }
    
    .profile-pic {
        width: 120px;
        height: 120px;
        margin: 20px auto 1.5rem; /* Increased top margin by 5px */
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    header::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .link-item {
        padding: 1.1rem;
        backdrop-filter: blur(8px);
    }
}

/* Loading animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.container {
    animation: fadeIn 0.8s ease-out forwards;
}