/* ============================================
   Modern Portfolio - Glass & Liquid Design
   ============================================ */

:root {
    --bg-primary: #f8fafb;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f0f4f9;
    --text-primary: #0f1419;
    --text-secondary: #4a5568;
    --accent: #2563eb;
    --accent-light: #3b82f6;
    --accent-hover: #1e40af;
    --border: rgba(37, 99, 235, 0.15);
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
    --liquid-blue: rgba(37, 99, 235, 0.08);
    --liquid-light: rgba(59, 130, 246, 0.05);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: linear-gradient(135deg, #f8fafb 0%, #e8f1ff 100%);
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.6;
    min-height: 100vh;
}

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    color: var(--text-secondary);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

/* ============================================
   Header & Navigation
   ============================================ */

header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 50;
    transition: all 0.3s ease;
    box-shadow: 0 8px 32px rgba(37, 99, 235, 0.08);
}

header.scrolled {
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 12px 40px rgba(37, 99, 235, 0.12);
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--accent);
}

.logo img {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    object-fit: cover;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
}

.hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 1.5rem;
}

#mobile-menu {
    display: none;
}

@media (max-width: 768px) {
    h1 {
        font-size: 1.875rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    .hamburger {
        display: block;
    }

    .nav-links {
        display: none;
    }

    #mobile-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--glass-bg);
        backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--glass-border);
        padding: 1.5rem;
    }

    #mobile-menu.hidden {
        display: none;
    }

    #mobile-menu.active {
        display: block;
    }

    #mobile-menu ul {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        list-style: none;
    }

    #mobile-menu a {
        color: var(--text-secondary);
        font-weight: 500;
        transition: color 0.3s ease;
    }

    #mobile-menu a:hover,
    #mobile-menu a.active {
        color: var(--accent);
    }

    /* Hero Section Mobile */
    #home {
        min-height: auto;
        padding: 5.5rem 1rem 2rem;
    }

    .hero-content {
        max-width: 100%;
        padding: 0;
    }

    .hero-tag {
        font-size: 0.9rem;
        margin-bottom: 0.75rem;
    }

    .hero-title {
        font-size: 1.5rem;
        margin-bottom: 0.5rem;
        line-height: 1.3;
    }

    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .hero-description {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
        line-height: 1.5;
    }

    .hero-buttons {
        gap: 0.75rem;
        margin-bottom: 1.5rem;
        flex-direction: column;
        align-items: center;
        width: fit-content;
        margin-left: auto;
        margin-right: auto;
    }

    .btn {
        padding: 0.75rem 2rem;
        font-size: 0.95rem;
        width: auto;
        min-width: 200px;
    }

    .social-links {
        gap: 1rem;
        margin-top: 1.5rem;
    }

    .social-link {
        width: 2.5rem;
        height: 2.5rem;
    }

    .scroll-indicator {
        display: none;
    }

    .bg-blob {
        filter: blur(60px);
    }

    .blob-1 {
        width: 200px;
        height: 200px;
        top: -50px;
        right: -50px;
    }

    .blob-2 {
        width: 150px;
        height: 150px;
        bottom: -50px;
        left: -50px;
    }
}

/* ============================================
   Hero Section
   ============================================ */

section {
    scroll-margin-top: 80px;
}

#home {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5rem 1.5rem;
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
}

.bg-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
}

.blob-1 {
    width: 400px;
    height: 400px;
    top: -100px;
    right: -100px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.15), rgba(59, 130, 246, 0.1));
    animation: float 8s ease-in-out infinite;
}

.blob-2 {
    width: 350px;
    height: 350px;
    bottom: -150px;
    left: -100px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(59, 130, 246, 0.08));
    animation: float 10s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(30px);
    }
}

.hero-content {
    max-width: 900px;
    text-align: center;
    position: relative;
    z-index: 10;
}

.hero-tag {
    color: var(--accent);
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.6s ease-out;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.hero-title .accent {
    color: var(--accent);
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    animation: fadeInUp 0.6s ease-out 0.4s both;
}

.hero-description {
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto 3rem;
    animation: fadeInUp 0.6s ease-out 0.6s both;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
    animation: fadeInUp 0.6s ease-out 0.8s both;
}

.btn {
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: white;
    box-shadow: 0 10px 30px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-hover), var(--accent));
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.6);
    color: var(--accent);
    border: 2px solid var(--accent);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(37, 99, 235, 0.15);
}

.social-links {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    animation: fadeInUp 0.6s ease-out 1s both;
}

.social-link {
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--glass-bg);
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.social-link:hover {
    background: rgba(37, 99, 235, 0.1);
    border-color: var(--accent);
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.2);
}

.social-link svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--accent);
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(-10px);
    }
}

/* ============================================
   About Section
   ============================================ */

#about {
    padding: 5rem 1.5rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.3));
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    margin-bottom: 0.75rem;
}

.section-tag {
    color: var(--accent);
    font-weight: 600;
    font-size: 1.125rem;
}

.about-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.about-image {
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(37, 99, 235, 0.2);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.about-image:hover img {
    transform: scale(1.05);
}

.about-text {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.about-text p {
    font-size: 1.0625rem;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .about-image {
        height: 300px;
    }
}

/* ============================================
   Skills Section
   ============================================ */

#skills {
    padding: 5rem 1.5rem;
}

.skills-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1.5rem;
}

.skill-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 2rem 1rem;
    border-radius: 1.25rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.skill-card:hover {
    background: rgba(255, 255, 255, 0.9);
    border-color: var(--accent);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(37, 99, 235, 0.2);
}

.skill-icon {
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
}

.skill-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.skill-card:hover .skill-icon img {
    transform: scale(1.15);
}

.skill-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1rem;
}

@media (max-width: 768px) {
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 1rem;
    }
}

/* ============================================
   Projects Section
   ============================================ */

#projects {
    padding: 5rem 1.5rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0));
}

.projects-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 1.25rem;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(10px);
}

.project-card:hover {
    border-color: var(--accent);
    transform: translateY(-8px);
    box-shadow: 0 25px 50px rgba(37, 99, 235, 0.2);
}

.project-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background-color: var(--bg-secondary);
    position: relative;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(37, 99, 235, 0.3), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.project-card:hover .project-title {
    color: var(--accent);
}

.project-tech {
    color: var(--accent);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.project-description {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Contact Section
   ============================================ */

#contact {
    padding: 5rem 1.5rem;
}

.contact-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-person {
    margin-bottom: 1rem;
}

.contact-person h3 {
    color: var(--accent);
    margin-bottom: 0.25rem;
}

.contact-person p {
    font-size: 0.9375rem;
}

.contact-text {
    line-height: 1.8;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-item svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--accent);
    flex-shrink: 0;
}

.contact-item a {
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--accent);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9375rem;
}

.form-group input,
.form-group textarea {
    padding: 0.875rem 1.25rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 0.75rem;
    color: var(--text-primary);
    font-family: inherit;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-submit {
    padding: 0.875rem 2rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: white;
    border: none;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(37, 99, 235, 0.3);
}

.form-submit:hover {
    background: linear-gradient(135deg, var(--accent-hover), var(--accent));
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(37, 99, 235, 0.4);
}

@media (max-width: 768px) {
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Academy Section
   ============================================ */

#academy {
    padding: 4rem 2rem;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(59, 130, 246, 0.03));
}

.academy-preview {
    max-width: 1200px;
    margin: 0 auto;
}

.academy-preview-content {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    align-items: center;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    padding: 3rem;
    border-radius: 2rem;
    border: 1.5px solid var(--glass-border);
    box-shadow: 0 20px 60px rgba(37, 99, 235, 0.15);
}

.academy-logo-section {
    display: flex;
    align-items: center;
    justify-content: center;
}

.academy-logo {
    max-width: 300px;
    width: 100%;
    border-radius: 1rem;
    box-shadow: 0 20px 50px rgba(20, 184, 166, 0.2);
    animation: float 3s ease-in-out infinite;
}

.academy-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--accent), #60a5fa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.academy-info p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: 1rem;
}

.academy-highlights {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
}

.highlight-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--accent);
    color: var(--bg-primary);
    border-radius: 50%;
    font-weight: bold;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.academy-info .btn {
    display: inline-block;
    text-decoration: none;
}

@media (max-width: 768px) {
    .academy-preview-content {
        grid-template-columns: 1fr;
        padding: 2rem;
        gap: 2rem;
    }

    .academy-info h3 {
        font-size: 1.5rem;
    }

    .academy-logo {
        max-width: 250px;
    }
}

/* ============================================
   GitHub Redirect Section
   ============================================ */

.github-redirect {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1.5px solid var(--glass-border);
    border-radius: 1.5rem;
    margin: 3rem auto;
    max-width: 600px;
    animation: fadeIn 0.6s ease-out;
    box-shadow: 0 20px 60px rgba(37, 99, 235, 0.12);
}

.github-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.github-icon {
    width: 60px;
    height: 60px;
    color: var(--accent);
    animation: float 3s ease-in-out infinite;
}

.github-redirect h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin: 0;
}

.github-redirect p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin: 0;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ============================================
   Footer
   ============================================ */

footer {
    padding: 2rem 1.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    text-align: center;
}

footer p {
    font-size: 0.9375rem;
    color: #64748b;
}

/* ============================================
   Scroll Animation
   ============================================ */

.scroll-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.scroll-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.25rem;
    }

    h3 {
        font-size: 1.125rem;
    }

    .hero-title {
        font-size: 1.5rem;
        margin-bottom: 0.75rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-description {
        font-size: 0.9rem;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 0.75rem;
        margin-bottom: 1.5rem;
        align-items: center;
        width: fit-content;
        margin-left: auto;
        margin-right: auto;
    }

    .btn {
        width: auto;
        min-width: 180px;
        padding: 0.75rem 1.75rem;
    }

    section {
        padding: 2rem 1rem;
    }

    #home {
        padding: 5rem 1rem 2rem;
    }

    nav {
        padding: 0.75rem 1rem;
    }

    .logo {
        font-size: 0.9rem;
    }

    .logo img {
        width: 2rem;
        height: 2rem;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .section-header h2 {
        font-size: 1.375rem;
    }

    .social-links {
        gap: 0.75rem;
    }

    .social-link {
        width: 2.25rem;
        height: 2.25rem;
    }

    .social-link svg {
        width: 1rem;
        height: 1rem;
    }
}
