*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Custom Properties, update these for your own design */

:root {
    --ff-primary: 'Source Sans Pro', sans-serif;
    --ff-secondary: 'Source Code Pro', monospace;
    
    --fw-reg: 300;
    --fw-bold: 900;
    
    --clr-light: #f9fafb;
    --clr-dark: #0f172a;
    --clr-accent: #0ea5e9;
    --clr-accent-2: #22c55e;
    --clr-muted: #334155;
    --glass: rgba(255, 255, 255, 0.65);
    
    --fs-h1: 3rem;
    --fs-h2: 2.25rem;
    --fs-h3: 1.25rem;
    --fs-body: 1rem;
    
    --bs: 0 20px 70px rgba(15, 23, 42, 0.15);
}

@media (min-width: 800px) {
    :root {
        --fs-h1: 4.5rem;
        --fs-h2: 3.75rem;
        --fs-h3: 1.5rem;
        --fs-body: 1.125rem;
        overflow-y: scroll; /* has to be scroll, not auto */
        -webkit-overflow-scrolling: touch;
    }
}

/* General styles */

/* adds smooth scrolling */
 html {
    scroll-behavior: smooth;
} 


body {
    background: radial-gradient(circle at 20% 20%, rgba(14, 165, 233, 0.08), transparent 25%),
                radial-gradient(circle at 80% 10%, rgba(34, 197, 94, 0.12), transparent 25%),
                radial-gradient(circle at 60% 70%, rgba(14, 165, 233, 0.06), transparent 30%),
                var(--clr-light);
    color: var(--clr-dark);
    margin: 0;
    font-family: var(--ff-primary);
    font-size: var(--fs-body);
    line-height: 1.6;
}

section {
    padding: 3.5em 1.5em;
}

img {
    display: block;
    max-width: 100%;
}

@media (min-width: 800px) {
    section {
        padding: 4em 2.5em;
    }
}

strong { font-weight: var(--fw-bold) }

:focus {
    outline: 3px solid var(--clr-accent-2);
    outline-offset: 3px;
}

/* Buttons */

.btn {
    display: inline-block;
    padding: .5em 2.5em;
    background: linear-gradient(135deg, var(--clr-accent), var(--clr-accent-2));
    color: var(--clr-light);
    text-decoration: none;
    cursor: pointer;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: var(--fw-bold);
    border-radius: 999px;
    box-shadow: var(--bs);
    transition: transform 200ms ease-in-out, box-shadow 200ms ease-in-out;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(124, 58, 237, 0.25);
}

.btn--ghost {
    background: transparent;
    color: var(--clr-dark);
    border: 2px solid var(--clr-accent);
    box-shadow: none;
}

.btn--ghost:hover {
    background: var(--clr-accent);
    color: var(--clr-light);
}

/* Typography */

h1,
h2,
h3 {
    line-height: 1;
    margin: 0;
}

h1 { font-size: var(--fs-h1) }
h2 { font-size: var(--fs-h2) }
h3 { font-size: var(--fs-h3) }


.section__title {
    margin-bottom: .25em;
}

.section__title--intro {
    font-weight: var(--fw-reg);
}

.section__title--intro strong {
    display: block;
}

.section__subtitle {
    margin: 0;
    font-size: var(--fs-h3);
    color: var(--clr-muted);
}

.section__subtitle--intro,
.section__subtitle--about {
    background: var(--glass);
    padding: .75em 1em;
    border-radius: 12px;
    backdrop-filter: blur(8px);
    margin-bottom: .9em;
}

.section__subtitle--work {
    color: var(--clr-accent);
    font-weight: var(--fw-bold);
    margin-bottom: 1.5em;
}

/* header */

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1em;
    padding: 1em 1.25em;
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(12px);
    background: rgba(249, 250, 251, 0.8);
}

.site-header {
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.logo {
    max-width: 100px;
}

.logo-mark {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--clr-accent), var(--clr-accent-2));
    color: var(--clr-light);
    display: grid;
    place-items: center;
    font-weight: var(--fw-bold);
    letter-spacing: 1px;
    box-shadow: var(--bs);
    text-decoration: none;
}

.logo-mark:focus-visible {
    outline: 2px solid var(--clr-dark);
    outline-offset: 4px;
}

.nav {
    position: fixed;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.95), rgba(11, 16, 33, 0.96));
    color: var(--clr-light);
    inset: 0;
    z-index: 100;
    height: 100vh;
    padding: 4rem 1.5rem 3rem;
    display: grid;
    align-content: center;
    transform: translateX(100%);
    transition: transform 250ms cubic-bezier(.5, 0, .5, 1);
}

.nav__list {
    list-style: none;
    display: flex;
    height: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 0;
    gap: clamp(2.5rem, 7vw, 3.5rem);
}

.nav__link {
    color: inherit;
    font-weight: var(--fw-bold);
    font-size: clamp(2rem, 4vw + 1rem, 3.25rem);
    text-decoration: none;
}

.nav__link:hover {
    color: var(--clr-accent);
}

.nav-toggle {
    padding: 0;
    width: 48px;
    height: 48px;
    background: var(--clr-light);
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 14px;
    cursor: pointer;
    display: grid;
    place-items: center;
    position: relative;
    z-index: 1000;
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.nav-open {
    overflow: hidden;
}

.nav-open .nav {
    transform: translateX(0);
}

.nav-open .nav-toggle {
    position: fixed;
    top: 1em;
    right: 1em;
    background: rgba(249, 250, 251, 0.9);
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: 0 10px 30px rgba(0,0,0,0.18);
}

.nav-open .hamburger {
    transform: rotate(.625turn);
    background: var(--clr-accent-2);
}

.nav-open .hamburger::before {
    transform: rotate(90deg) translateX(-6px);
    background: var(--clr-accent-2);
}

.nav-open .hamburger::after {
    opacity: 0;
    background: var(--clr-accent-2);
}

.hamburger {
    display: block;
    position: relative;
    width: 24px;
}

.hamburger,
.hamburger::before,
.hamburger::after {
    background: var(--clr-accent);
    height: 3px;
    border-radius: 99px;
    transition: transform 250ms ease-in-out, background 200ms ease;
}


.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
}

.hamburger::before { top: 7px; }
.hamburger::after { bottom: 7px; }

@media (min-width: 900px) {
    .nav {
        position: static;
        background: transparent;
        color: var(--clr-dark);
        transform: translateX(0);
        height: auto;
        padding: 0;
        display: block;
    }
    
    .nav__list {
        flex-direction: row;
        height: auto;
        gap: 1.5em;
    }
    
    .nav__link {
        font-size: 1rem;
        position: relative;
    }
    
    .nav__link::after {
        content: '';
        position: absolute;
        left: 0;
        bottom: -6px;
        width: 0;
        height: 2px;
        background: linear-gradient(90deg, var(--clr-accent), var(--clr-accent-2));
        transition: width 200ms ease;
    }
    
    .nav__link:hover::after {
        width: 100%;
    }
    
    .nav-toggle {
        display: none;
    }
}


/*  Intro section  */

.intro {
    position: relative;
    display: grid;
    gap: 2em;
    align-items: center;
}

.intro__img {
    box-shadow: var(--bs);
    border-radius: 18px;
}

.intro--compact {
    padding: 2em 1.5em 2.25em;
}

.section__subtitle--intro {
    display: inline-block;
}
.intro--compact .section__subtitle--intro {
    margin-bottom: 1em;
}

.intro__content {
    display: grid;
    gap: 1.1em;
}

.intro__cta {
    display: flex;
    gap: 1em;
    flex-wrap: wrap;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.8rem;
    color: var(--clr-accent);
    margin: 0;
    font-weight: var(--fw-bold);
}

.badge-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: .75em;
    padding: 0;
    margin: 0;
}

.badge-list li {
    background: transparent;
    color: var(--clr-muted);
    padding: 0;
    border-radius: 0;
    font-size: .95rem;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: .45em;
    letter-spacing: .2px;
}

.badge-list li::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--clr-accent), var(--clr-accent-2));
    display: inline-block;
}

.intro__media {
    position: relative;
    display: grid;
    gap: 1em;
    max-width: 520px;
}

.intro__img-frame {
    position: relative;
    padding: 0.75em;
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.12), rgba(34, 197, 94, 0.12));
    box-shadow: var(--bs);
}

.highlight-card {
    background: var(--clr-dark);
    color: var(--clr-light);
    padding: 1.25em 1.5em;
    border-radius: 18px;
    box-shadow: var(--bs);
    max-width: 360px;
    position: absolute;
    bottom: -1.25em;
    right: -.75em;
}

.highlight-card__eyebrow {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.75rem;
    color: var(--clr-accent-2);
}

.highlight-card__title {
    margin: .35em 0;
    font-size: 1.1rem;
    font-weight: var(--fw-bold);
}

.highlight-card__body {
    margin: 0;
    color: rgba(255,255,255,0.8);
}

@media (min-width: 600px) {
    .intro {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: center;
    gap: 2.5em;
}

.intro__img {
    min-width: 250px;
    position: relative;
    z-index: 2;
}    

.section__subtitle--intro {
    align-self: start;
}
}

@media (max-width: 599px) {
    .intro__media {
        max-width: 100%;
    }
    
    .highlight-card {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: 1em;
    }
}



/*  My services section  */

.my-services {
    background: linear-gradient(140deg, #0f172a 0%, #1f2a44 60%, #0f172a 100%);
    color: var(--clr-light);
    text-align: left;
    position: relative;
    overflow: hidden;
}

.section__title--services {
    color: var(--clr-accent);
    position: relative;
}

.section__title--services::after {
    content: '';
    display: block;
    width: 2em;
    height: 1px;
    margin: 0.5em auto 1em;
    background: var(--clr-light);
    opacity: 0.25;
}

.section-heading {
    max-width: 720px;
    margin: 0 auto 1.6em;
    text-align: center;
}

.my-services .section-heading .section__subtitle {
    color: rgba(255, 255, 255, 0.9);
}

.services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25em;
    margin-bottom: 2.5em;
}

@media screen and (max-width: 500px) {
    .service {
        max-width: 100%;
        margin: 0 0 2em;
    }
}

@media (min-width: 800px) {
    .services {
        max-width: 1100px;
        margin-left: auto;
        margin-right: auto;
    }
}

.service-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1.5em;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.25);
    backdrop-filter: blur(6px);
}

.service-card h3 {
    color: var(--clr-accent-2);
    margin-bottom: .5em;
}

.service-card p {
    margin: 0;
    color: rgba(255,255,255,0.92);
}


.about-me {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    gap: 1em;
}

.about-me__img {
    box-shadow: var(--bs);
    border-radius: 18px;
}

.about-me__body p {
    margin: 0 0 .85em;
}

@media (min-width: 600px) {
    .about-me {
        display: grid;
        grid-template-columns: 1fr 200px;
        grid-template-areas: 
            "title img"
            "subtitle img"
            "text img";
        grid-column-gap: 2em;
    }
    
    .section__title--about {
        grid-area: title;
    }
    
    .section__subtitle--about {
        grid-column: 1 / -1;
        grid-row: 2;
        position: relative;
    }
    
    .about-me__img {
        grid-area: img;
        position: relative;
        z-index: 2;
    }
}

/* My Work */

.my-work {
    background-color: var(--clr-dark);
    color: var(--clr-light);
    text-align: center;    
    border-radius: 24px;
    margin: 0 .75em 1.75em;
    box-shadow: var(--bs);
}

.portfolio {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1em;
    padding: 0 1em;
    max-width: 980px;
    margin: 0 auto;
}

.portfolio__item {
    background: var(--clr-accent);
    overflow: hidden;
}

.portfolio__img {
    transition: 
        transform 750ms cubic-bezier(.5, 0, .5, 1),
        opacity 250ms linear;
}

.portfolio__item:focus {
    position: relative;
    z-index: 2;
}

.portfolio__img:hover,
.portfolio__item:focus .portfolio__img {
    transform: scale(1.2);
    opacity: .5;
}

.project-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 18px;
    overflow: hidden;
    text-align: left;
    display: flex;
    flex-direction: column;
    box-shadow: 0 14px 35px rgba(0,0,0,0.3);
    transition: transform 200ms ease, box-shadow 200ms ease;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.35);
}

.project-card__body {
    padding: 1.1em;
}

.project-card__body h3 {
    margin: 0 0 .35em 0;
}

.project-card__body p {
    margin: 0;
    color: rgba(255,255,255,0.8);
}

@media (min-width: 640px) {
    .portfolio {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.25em;
        padding: 0 1.25em;
    }
}


/* footer */

.footer {
    background: #0b1021;
    color: var(--clr-light);
    padding: 2.5em 1.25em;
    margin-top: 1.5em;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5em;
    max-width: 1100px;
    margin: 0 auto;
}

.footer a { 
    color: inherit;
    text-decoration: none;
}

.footer__link {
    font-weight: var(--fw-bold);
}

.footer__link:hover,
.social-list__link:hover {
    opacity: .7;
}

.footer__link:hover {
    text-decoration: underline;
}

.social-list {
    list-style: none;
    display: flex;
    justify-content: flex-end;
    margin: 0;
    padding: 0;
}

.social-list__item {
    margin: 0 .5em;
}

.social-list__link {
    padding: .5em;
}

.social-icon {
    display: block;
    width: 24px;
    height: 24px;
}


/* Individual portfolio item styles */

.portfolio-item-individual {
    padding: 0 2em 2em;
    max-width: 1000px;
    margin: 0 auto;
    background: white;
}

.portfolio-item-individual p {
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    @media (max-width: 600px) {
        max-width: 100%;
    }
}

.my-work__img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
    margin: 0 auto;
    max-width: 100%;
  }
