/* ================== Sections Base ================== */
section {
    margin: 2.5rem auto;
    padding: 3rem 2.5rem;
    background: var(--section-bg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    box-shadow: var(--card-elev);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

section h3 {
    font-size: 2.5rem;
    font-family: var(--font-heading);
    text-align: center;
    color: var(--text-color);
    margin-bottom: 2rem;
    font-weight: 800;
}

/* ================== Hero Section ================== */
.hero {
    margin-top: 100px;
    min-height: calc(100vh - 100px);
    display: flex;
    align-items: center;
    padding: 2rem;
    text-align: left;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-title {
    font-weight: 800;
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
    color: var(--text-color);
    margin-bottom: 1.5rem;
}

.hero-sub {
    color: var(--muted);
    font-size: 1.15rem;
    line-height: 1.6;
    max-width: 500px;
    margin-bottom: 2.5rem;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-right {
    position: relative;
    display: flex;
    justify-content: center;
    perspective: 1000px;
}

.robot-wrap {
    width: fit-content;
    height: fit-content;
    padding: 2.5rem; /* Reduced padding slightly for better proportion */
    background: radial-gradient(circle at center, rgba(59, 130, 246, 0.2), transparent 75%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 50px rgba(59, 130, 246, 0.08); /* More subtle glow */
    animation: pulseGlow 4s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 40px rgba(59, 130, 246, 0.05); transform: scale(1); }
    50% { box-shadow: 0 0 70px rgba(59, 130, 246, 0.2); transform: scale(1.03); }
}

#robot-gif {
    width: 320px; /* Base width for laptop to make it visible */
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 20px;
    object-fit: contain;
    /* Added for sharpness since it's a small GIF being enlarged */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

@media (max-width: 1024px) {
    .robot-wrap {
        padding: 2rem;
    }
    #robot-gif {
        width: 250px; /* Smaller for tablets/small laptops */
    }
}

@media (max-width: 640px) {
    #robot-gif {
        width: 180px; /* Perfect for mobile phones */
    }
}

/* ================== Skills Section ================== */
#skills p {
    text-align: center;
    font-size: 1.45rem;
    color: var(--text-color);
    margin-bottom: 3.5rem;
    font-weight: 600;
    line-height: 1.6;
    letter-spacing: -0.01em;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* ================== Contact Section ================== */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 4rem;
    margin-top: 3rem;
    align-items: start;
}

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

.info-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: var(--project-card-shadow);
}

.info-card h4 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.info-card p {
    text-align: left !important; /* Override section p centering */
    font-size: 1rem !important;
    margin-bottom: 2rem !important;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-bottom: 1.5rem;
}

.info-icon {
    width: 48px;
    height: 48px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-item div {
    display: flex;
    flex-direction: column;
}

.info-item label {
    font-size: 0.8rem;
    color: var(--muted);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.info-item span,
.info-item a {
    font-size: 1rem;
    color: var(--text-color);
    font-weight: 500;
    text-decoration: none;
    transition: color 0.3s ease;
}

.info-item a:hover {
    color: var(--link-color);
}

.contact-form-wrap form {
    margin: 0; /* Override default form margin */
    max-width: 100%;
}

@media (max-width: 900px) {
    .contact-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}
.about-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    align-items: center;
}

.about-photo {
    width: 100%;
    max-width: 300px;
    aspect-ratio: 1/1;
    border-radius: 28px;
    object-fit: cover;
    box-shadow: var(--shadow-3d);
    border: 1px solid var(--glass-border);
    transition: var(--transition-smooth);
}

.about-photo:hover {
    transform: scale(1.02) rotate(2deg);
    box-shadow: 0 40px 80px rgba(59, 130, 246, 0.25);
}

.about-right p {
    font-size: 1.1rem;
    color: var(--muted);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-right strong {
    color: var(--link-color);
    transition: var(--transition-fast);
    padding: 2px 4px;
    border-radius: 4px;
}

.about-right strong:hover {
    background: rgba(59, 130, 246, 0.1);
}


/* ================== Typewriter ================== */
.typewriter {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--accent);
    margin-bottom: 1rem;
    min-height: 1.5em;
}

@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-left {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-sub {
        margin-left: auto;
        margin-right: auto;
    }

    .about-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .about-photo {
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    section {
        margin: 1.2rem auto;
        padding: 2rem 1.2rem;
    }

    section h3 {
        font-size: 1.8rem;
        margin-bottom: 1.5rem;
    }

    .hero-title {
        font-size: clamp(2.2rem, 8vw, 3rem);
    }
}

@media (max-width: 540px) {
    .container .hero-cta {
        flex-direction: column;
        display: flex;
        width: 100%;
        gap: 1rem;
    }

    .container .hero-cta .btn {
        display: block;
        width: 100%;
        text-align: center;
    }
}
