/* ===== style.css ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #4a9eff;
    --primary-dark: #1a6bb0;
    --accent: #00d4ff;
    --bg: #06060f;
    --bg-card: rgba(16, 18, 40, 0.78);
    --text: #eef0f8;
    --text-muted: rgba(238, 240, 248, 0.65);
    --border: rgba(74, 158, 255, 0.12);
    --glow: rgba(74, 158, 255, 0.4);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Vazirmatn', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.75;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a0a14;
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--primary), var(--accent));
    border-radius: 10px;
}

/* ===== BACKGROUND ===== */
.bg-container {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.bg-gradient {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 15% 40%, rgba(74, 158, 255, 0.13) 0%, transparent 55%),
        radial-gradient(ellipse 70% 50% at 85% 60%, rgba(0, 212, 255, 0.1) 0%, transparent 55%),
        radial-gradient(ellipse 60% 40% at 50% 100%, rgba(74, 158, 255, 0.07) 0%, transparent 50%),
        radial-gradient(ellipse 50% 30% at 70% 10%, rgba(120, 80, 255, 0.06) 0%, transparent 50%);
    animation: bgPulse 12s ease-in-out infinite alternate;
}

@keyframes bgPulse {
    0% { opacity: 0.7; transform: scale(1); }
    100% { opacity: 1; transform: scale(1.08); }
}

#particlesCanvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* ===== LAYOUT ===== */
.container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 5;
}

.section {
    padding: 100px 0;
    position: relative;
    z-index: 5;
}

.section-alt {
    background: linear-gradient(180deg, transparent, rgba(74, 158, 255, 0.03), transparent);
}

.section-title {
    font-size: clamp(1.9rem, 4vw, 2.5rem);
    font-weight: 800;
    text-align: center;
    margin-bottom: 56px;
    letter-spacing: -0.5px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 72px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    margin: 14px auto 0;
    border-radius: 4px;
    box-shadow: 0 0 20px var(--glow);
}

/* ===== HEADER ===== */
.header {
    padding: 12px 0;
    background: rgba(6, 6, 15, 0.82);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.header.scrolled {
    background: rgba(6, 6, 15, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.logo {
    font-size: 1.45rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--text);
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary);
}

.logo span {
    color: var(--primary);
    text-shadow: 0 0 24px rgba(74, 158, 255, 0.4);
}

.nav-list {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-list a {
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    font-size: 0.95rem;
    transition: 0.35s ease;
    position: relative;
    opacity: 0.72;
}

.nav-list a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: width 0.35s ease;
}

.nav-list a:hover {
    color: var(--primary);
    opacity: 1;
}

.nav-list a:hover::after {
    width: 100%;
}

.theme-toggle {
    background: none;
    border: none;
    font-size: 1.45rem;
    cursor: pointer;
    color: var(--text);
    transition: transform 0.3s;
    padding: 4px 8px;
    opacity: 0.75;
}

.theme-toggle:hover {
    transform: rotate(35deg) scale(1.12);
    opacity: 1;
}

/* ===== HERO ===== */
.hero {
    position: relative;
    min-height: 88vh;
    display: flex;
    align-items: center;
    padding: 50px 0 70px;
    z-index: 5;
}

.hero-inner {
    display: flex;
    align-items: center;
    gap: 60px;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1 1 420px;
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(74, 158, 255, 0.12);
    border: 1px solid rgba(74, 158, 255, 0.25);
    border-radius: 50px;
    font-size: 0.85rem;
    color: var(--accent);
    margin-bottom: 18px;
    font-weight: 500;
}

.hero-title {
    font-size: clamp(2.4rem, 5vw, 3.3rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--text);
}

.highlight {
    color: var(--primary);
    text-shadow: 0 0 40px rgba(74, 158, 255, 0.45);
    position: relative;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 3px;
    right: 0;
    width: 100%;
    height: 7px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    opacity: 0.35;
    border-radius: 4px;
}

.hero-subtitle {
    font-size: 1.18rem;
    margin: 20px 0 32px;
    opacity: 0.72;
    line-height: 1.85;
}

.hero-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 13px 34px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    border: 2px solid transparent;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 4px 30px rgba(74, 158, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 10px 45px rgba(74, 158, 255, 0.45);
}

.btn-outline {
    border-color: var(--primary);
    color: var(--primary);
    background: transparent;
}

.btn-outline:hover {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 10px 40px rgba(74, 158, 255, 0.35);
}

.hero-avatar {
    flex-shrink: 0;
    position: relative;
}

.avatar-ring {
    position: absolute;
    inset: -12px;
    border-radius: 50%;
    border: 2px solid transparent;
    background: linear-gradient(135deg, var(--primary), var(--accent), var(--primary)) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: ringRotate 8s linear infinite;
}

@keyframes ringRotate {
    to { transform: rotate(360deg); }
}

.hero-avatar img {
    width: 240px;
    height: 240px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary);
    box-shadow: 0 0 70px rgba(74, 158, 255, 0.2);
    transition: all 0.45s ease;
    position: relative;
    z-index: 2;
}

.hero-avatar img:hover {
    transform: scale(1.05) rotate(-4deg);
    box-shadow: 0 0 90px rgba(74, 158, 255, 0.35);
}

/* ===== ABOUT ===== */
.about-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 48px;
    align-items: center;
}

.about-text p {
    margin-bottom: 18px;
    font-size: 1.08rem;
    opacity: 0.82;
}

.about-text strong {
    color: var(--primary);
}

.skills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.skill {
    padding: 6px 16px;
    background: rgba(74, 158, 255, 0.1);
    border: 1px solid rgba(74, 158, 255, 0.22);
    border-radius: 30px;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
    transition: all 0.3s ease;
}

.skill:hover {
    background: rgba(74, 158, 255, 0.2);
    transform: translateY(-2px);
}

.about-stats {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.stat {
    background: var(--bg-card);
    padding: 22px 24px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 80, 200, 0.12);
    text-align: center;
    backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    transition: all 0.4s ease;
}

.stat:hover {
    border-color: rgba(74, 158, 255, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(74, 158, 255, 0.15);
}

.stat-number {
    display: block;
    font-size: 2.1rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.6;
}

/* ===== PROJECTS ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
}

.project-card {
    background: var(--bg-card);
    padding: 36px 26px;
    border-radius: 22px;
    box-shadow: 0 8px 32px rgba(0, 80, 200, 0.1);
    text-align: center;
    backdrop-filter: blur(16px);
    transition: all 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--border);
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(74, 158, 255, 0.12);
    border-color: rgba(74, 158, 255, 0.3);
}

.project-icon {
    font-size: 2.8rem;
    display: block;
    margin-bottom: 12px;
}

.project-card h3 {
    color: var(--primary);
    margin-bottom: 8px;
    font-size: 1.25rem;
}

.project-card p {
    font-size: 0.95rem;
    opacity: 0.7;
    margin-bottom: 16px;
}

.project-tag {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 5px 18px;
    border-radius: 30px;
    letter-spacing: 0.3px;
}

/* ===== MUSIC ===== */
.music-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 30px;
}

.music-card {
    background: var(--bg-card);
    padding: 30px 22px;
    border-radius: 22px;
    box-shadow: 0 8px 32px rgba(0, 80, 200, 0.1);
    text-align: center;
    backdrop-filter: blur(16px);
    transition: all 0.4s ease;
    border: 1px solid var(--border);
}

.music-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 48px rgba(0, 212, 255, 0.08);
    border-color: rgba(0, 212, 255, 0.2);
}

.music-icon {
    font-size: 3.3rem;
    display: block;
    margin-bottom: 6px;
}

.music-card h3 {
    color: var(--primary);
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.music-card p {
    font-size: 0.85rem;
    opacity: 0.5;
    margin-bottom: 16px;
}

.music-card audio {
    width: 100%;
    max-width: 230px;
    border-radius: 30px;
    outline: none;
    filter: brightness(0.85);
}

.more-music-box {
    text-align: center;
    margin-top: 56px;
    padding: 36px 24px;
    border-top: 1px solid rgba(74, 158, 255, 0.1);
    border-bottom: 1px solid rgba(74, 158, 255, 0.1);
}

.more-music-box p {
    font-size: 1.05rem;
    opacity: 0.65;
    margin-bottom: 18px;
}

.btn-more {
    display: inline-block;
    padding: 15px 48px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.05rem;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: 2px solid rgba(74, 158, 255, 0.35);
    box-shadow: 0 0 45px rgba(74, 158, 255, 0.2);
    transition: all 0.35s ease;
}

.btn-more:hover {
    transform: scale(1.07) translateY(-4px);
    box-shadow: 0 0 70px rgba(74, 158, 255, 0.4);
    border-color: rgba(74, 158, 255, 0.65);
}

.btn-more .icon {
    margin: 0 6px;
}

.more-music-note {
    font-size: 0.85rem !important;
    opacity: 0.4 !important;
    margin-top: 14px !important;
}

/* ===== CONTACT ===== */
.contact-links {
    display: flex;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
}

.contact-link {
    padding: 15px 36px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.contact-link:hover {
    transform: scale(1.07) translateY(-4px);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
}

.contact-icon {
    font-size: 1.25rem;
}

.instagram {
    background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af);
}

.telegram {
    background: linear-gradient(135deg, #0088cc, #00a8ff);
}

.channel {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

/* ===== FOOTER ===== */
.footer {
    text-align: center;
    padding: 36px 0;
    border-top: 1px solid rgba(74, 158, 255, 0.08);
    font-size: 0.9rem;
    opacity: 0.45;
    position: relative;
    z-index: 5;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .header-inner {
        flex-direction: column;
        gap: 12px;
    }

    .nav-list {
        gap: 16px;
        font-size: 0.9rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    .hero-inner {
        flex-direction: column-reverse;
        text-align: center;
        gap: 40px;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-avatar img {
        width: 180px;
        height: 180px;
    }

    .avatar-ring {
        inset: -10px;
    }

    .about-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .skills {
        justify-content: center;
    }

    .section {
        padding: 60px 0;
    }

    .contact-links {
        flex-direction: column;
        align-items: center;
    }

    .contact-link {
        width: 85%;
        justify-content: center;
    }

    .music-grid,
    .projects-grid {
        grid-template-columns: 1fr;
    }

    .btn-more {
        padding: 13px 32px;
        font-size: 0.95rem;
    }
}