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

html {
    scroll-behavior: smooth;
}

body {
    background-color: #f5f7fb;
    color: #1e293b;
    font-family: Arial, sans-serif;
    line-height: 1.7;
}

header {
    background-color: #0f172a;
    position: sticky;
    top: 0;
    z-index: 10;
}

.navbar {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin: auto;
    max-width: 1200px;
    padding: 16px 25px;
}

.logo {
    color: white;
    font-size: 22px;
    font-weight: bold;
    text-decoration: none;
}

.navbar ul,
.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    list-style: none;
}

.navbar a {
    color: white;
    text-decoration: none;
}

.navbar ul a:hover {
    color: #38bdf8;
}

.hero,
.section {
    margin: auto;
    max-width: 1200px;
    padding: 85px 25px;
}

.hero {
    align-items: center;
    display: flex;
    gap: 70px;
    justify-content: space-between;
    min-height: 620px;
}

.hero-text {
    max-width: 650px;
}

.small-heading {
    color: #0284c7;
    font-size: 15px;
    font-weight: bold;
    letter-spacing: 1px;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    color: #0f172a;
    line-height: 1.25;
}

h1 {
    font-size: 48px;
    margin: 10px 0 20px;
}

h2 {
    font-size: 34px;
    margin: 8px 0 14px;
}

h3 {
    font-size: 21px;
    margin-bottom: 10px;
}

/* These two classes are added by index.js for the heading animation. */
.heading-hidden {
    opacity: 0;
    transform: translateY(45px) scale(0.96);
}

.heading-visible {
    animation: heading-reveal 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes heading-reveal {
    from {
        opacity: 0;
        transform: translateY(45px) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.hero-description {
    animation: text-reveal 0.9s ease 0.35s both;
    font-size: 18px;
    margin-bottom: 28px;
}

.hero-image img {
    animation: image-reveal 1s cubic-bezier(0.22, 1, 0.36, 1) both;
    border: 8px solid white;
    border-radius: 50%;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.2);
    display: block;
    height: 330px;
    object-fit: cover;
    width: 330px;
}

.button {
    animation: text-reveal 0.8s ease 0.55s both;
    background-color: #0284c7;
    border-radius: 5px;
    color: white;
    display: inline-block;
    font-weight: bold;
    padding: 12px 20px;
    text-decoration: none;
}

.button:hover {
    background-color: #0369a1;
    transform: translateY(-3px);
}

@keyframes text-reveal {
    from {
        opacity: 0;
        transform: translateY(25px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes image-reveal {
    from {
        opacity: 0;
        transform: translateX(55px) scale(0.9);
    }

    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

.section {
    border-top: 1px solid #dbe3ef;
}

.section-heading {
    margin-bottom: 35px;
    max-width: 800px;
}

.about-story {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.07);
    padding: 35px;
}

.about-story h3:not(:first-child) {
    margin-top: 30px;
}

.about-story p + p {
    margin-top: 16px;
}

.projects-grid {
    display: grid;
    gap: 22px;
    grid-template-columns: repeat(3, 1fr);
}

.project-card {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.07);
    display: flex;
    flex-direction: column;
    padding: 25px;
}

.technology {
    color: #0284c7;
    font-size: 14px;
    font-weight: bold;
    margin: 8px 0 14px;
}

.project-card a {
    color: #0369a1;
    font-weight: bold;
    margin-top: auto;
    padding-top: 18px;
    text-decoration: none;
}

.project-card a:hover {
    text-decoration: underline;
}

.contact-section {
    text-align: center;
}

.contact-section .section-heading {
    margin-left: auto;
    margin-right: auto;
}

footer {
    background-color: #0f172a;
    color: #cbd5e1;
    padding: 35px 25px;
    text-align: center;
}

.social-links {
    justify-content: center;
    margin: 15px 0;
}

.social-links a {
    color: white;
    text-decoration: none;
}

.social-links a:hover {
    color: #38bdf8;
}

@media (max-width: 800px) {
    .hero {
        flex-direction: column-reverse;
        gap: 35px;
        min-height: auto;
        text-align: center;
    }

    .hero-image img {
        height: 260px;
        width: 260px;
    }

    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 550px) {
    .navbar {
        flex-direction: column;
        gap: 12px;
    }

    .navbar ul {
        gap: 14px;
        justify-content: center;
    }

    .hero,
    .section {
        padding: 60px 20px;
    }

    h1 {
        font-size: 36px;
    }

    h2 {
        font-size: 28px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .about-story {
        padding: 25px 20px;
    }
}
