/*================ variable css ===================*/
:root {
    /* .5 rem = 8px, 1 rem = 16px, 1.5 rem = 24px ...... */
    --header-height: 3rem;

    --hue-color: 232;
    /*HSL color */
    --first-color: hsl(var(--hue-color), 69%, 61%);
    --first-color-second: hsl(var(--hue-color), 69%, 61%);
    --first-color-alt: hsl(var(--hue-color), 57%, 53%);
    --first-color-lighter: hsl(var(--hue-color), 92%, 85%);
    --title-color: hsl(var(--hue-color), 8%, 15%);
    --text-color: hsl(var(--hue-color), 8%, 45%);
    --input-color: hsl(var(--hue-color), 70%, 96%);
    --body-color: hsl(var(--hue-color), 60%, 99%);
    --container-color: #FFF;
    --swiper-theme-color: var(--first-color); /* warna titik & panah slider */

    /* font */
    --body-font: 'Poppins', sans-serif;
    --big-font-size: 2rem;
    --h1-font-size: 1.5rem;
    --h2-font-size: 1.25rem;
    --h3-font-size: 1.125rem;
    --normal-font-size: .938rem;
    --small-font-size: .813rem;
    --smaller-font-size:.75rem;
    --h4-font-size: 1.125rem;

    /*font weight */
    --font-medium: 500;
    --font-semi-bold: 600;

    /*margin bawah*/
    /* .25rem = 4px, .5rem = 8px, .75rem = 12 px........ */
    --mb-0-25: .25rem;
    --mb-0-5: 8px;
    --mb-0-75: 12px;
    --mb-1: 16px;
    --mb-1-5: 24px;
    --mb-2: 32px;
    --mb-2-5: 40px;
    --mb-3: 48px;

    /* z indeks */
    --z-tooltip: 10;
    --z-fixed: 100;
    --z-modal: 1000;
}

/* font untuk ukuran windows */
@media screen and (min-width: 968px) {
    :root {
        --big-font-size: 3rem;
        --h1-font-size: 2.25rem;
        --h2-font-size: 1.5rem;
        --h3-font-size: 1.25rem;
        --normal-font-size: 1rem;
        --small-font-size: .875rem;
        --smaller-font-size:.813rem;
        --h4-font-size: 1.25rem;
    }   
}

/* base */
*{
    box-sizing: border-box;
    padding: 0;
    margin: 0;
}

html{
    scroll-behavior: smooth;
}

body{
    margin: 0 0 var(--header-height) 0;
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    background-color: var(--body-color);
    color: var(--text-color);
}

.warna__font {
    color: var(--title-color);
}

h1,h2,h3,h4{
    color: var(--title-color);
    font-weight: var(--font-semi-bold);
}

ul{
    list-style: none;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

button {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
}

:focus-visible {
    outline: 2px solid var(--first-color);
    outline-offset: 3px;
    border-radius: .25rem;
}

/* reusable css classes */
.section {
    padding: 2rem 0 4rem;
}

.section__title {
    font-size: var(--h1-font-size);
}

.section__sub {
    display: block;
    font-size: var(--small-font-size);
    margin-bottom: var(--mb-3);
}

.section__sub, .section__title {
    text-align: center;
}

/* LAYOUT */
.container {
    max-width: 768px;
    margin-left: var(--mb-1-5);
    margin-right: var(--mb-1-5);
}

.grid {
    display: grid;
    gap: 1.5rem;
}

.header {
    width: 100%;
    position: fixed;
    bottom: 0;
    left: 0;
    z-index: var(--z-fixed);
    background-color: var(--body-color);
}

/* ============= NAV =========== */
.nav {
    max-width: 968px;
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav__logo, .nav__toggle {
    color: var(--title-color);
    font-weight: var(--font-medium);
}

.nav__logo:hover {
    color: var(--first-color);
}

.nav__toggle {
    font-size: 1.1rem;
    cursor: pointer;
}

.nav__toggle:hover {
    color: var(--first-color);
}

@media screen and (max-width: 767px) {
    .nav__menu {
        position: fixed;
        bottom: -100%;
        left: 0;
        width: 100%;
        background-color: var(--body-color);
        padding: 2rem 1.5rem 4rem;
        box-shadow: 0 -1px 4px rgba(0, 0, 0, .15);
        border-radius: 1.5rem 1.5rem 0 0;
        transition: .3s;
    }
}

.nav__list{
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.nav__link {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    color: var(--title-color);
}

.nav__link:hover {
    color: var(--first-color);
}

.nav__icon {
    font-size: 1.2rem;;
}

.nav__close {
    position: absolute;
    right: 1.3rem;
    bottom: .5rem;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--first-color);
}

.nav__close:hover {
    color: var(--first-color-alt);
}


/*--------- show menu ---------*/
.show-menu {
    bottom: 0;
}

/*--------- bayangan header saat halaman digulir ---------*/
.scroll-header {
    box-shadow: 0 -1px 4px rgba(0, 0, 0, .15);
}

.about__deskripsi {
    color: var(--title-color);
    margin-bottom: var(--mb-1);
}
.home__deskripsi,
.about__deskripsi,
.portofolio_description {
    text-align: justify;
}

.home__social-icon {
    color: var(--title-color);
}

/*==================== Home ====================*/
.home__container {
    gap: 16px;
}
.home__content {
    grid-template-columns: .5fr 3fr;
    padding-top: 3.5rem;
    align-items: center;
}
.home__social {
    display: grid;
    grid-template-columns: max-content;
    row-gap: 32px;
}
.home__social-icon {
    font-size: 1.25rem;
    color: var(--first-color);
}
.home__social-icon:hover {
    color: var(--first-color-alt);
}
.home__blob {
    width: 240px;
    fill: var(--first-color);
    margin-left: 15px;
}
.home__blob-img {
    width: 195px;
}

.home__data{
    grid-column: 1/3;
}
.home__title {
    font-size: var(--big-font-size);
}
.home__sub {
    font-size: var(--h3-font-size);
    color: var(--text-color);
    font-weight: var(--font-medium);
    margin-bottom: var(--mb-0-75);
}
.home__deskripsi{
    margin-bottom: var(--mb-2)
}


.home__scroll {
    display: flex;
    justify-content: center;
}

.home__scroll-button {
    color: var(--first-color);
    transition: .3s;
}
.home__scroll-button:hover {
    transform: translateY(.25rem);
}

.home__scroll-mouse {
    font-size: 24px;
}

.home__scroll-name {
    color: var(--first-color-second);
    font-weight: var(--font-semi-bold);
}
.home__scroll-arrow {
    font-size: 24px;
}
.home__status {
    display: inline-flex;
    align-items: center;
    column-gap: var(--mb-0-5);
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    color: var(--first-color);
    background-color: var(--input-color);
    padding: .35rem .9rem;
    border-radius: 1rem;
    margin-bottom: var(--mb-1-5);
}

.home__button {
    display: flex;
    justify-content: center;
    margin-bottom: var(--mb-2-5);
}

/*=============== Button =============*/
.button {
    display: inline-block;
    background-color: var(--first-color);
    color: #FFF;
    padding: 10px;
    border-radius: .5rem;
    font-weight: var(--font-medium);
}
.button:hover {
    background-color: var(--first-color-alt);
}

.button--small {
    padding: .5rem 1rem;
    font-size: var(--small-font-size);
}

.button--ghost {
    background-color: var(--input-color);
    color: var(--first-color);
}
.button--ghost:hover {
    background-color: var(--first-color-lighter);
}

.button__icon {
    font-size: 1.25rem;
    margin-left: var(--mb-0-5);
    transition: .3s;
}
.button--flex {
    display: inline-flex;
    align-items: center;
}

/*===================== About ====================== */
.about__img {
    width: 250px;
    border-radius: .5rem;
    justify-self: center;
    align-self: center;
}

/*======================== Skills ========================== */
.skills__content {
    background-color: var(--container-color);
    border-radius: .75rem;
    padding: 1.25rem;
    box-shadow: 0 2px 8px hsla(var(--hue-color), 48%, 40%, .08);
}

.skills__header {
    display: flex;
    align-items: center;
    column-gap: var(--mb-0-75);
    margin-bottom: var(--mb-1);
}

.skills__icon {
    font-size: 2rem;
    color: var(--first-color);
}

.skills__title {
    font-size: var(--h3-font-size);
}

/*================ Tags (skill & teknologi proyek) ================*/
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--mb-0-5);
}

.tag {
    font-size: var(--small-font-size);
    color: var(--title-color);
    background-color: var(--input-color);
    padding: .25rem .75rem;
    border-radius: 1rem;
}

/*---------------- Qualification ------------------*/
.qualification__tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    gap: var(--mb-1);
    margin-bottom: var(--mb-2);
}

.qualification__button {
    font-size: var(--h3-font-size);
    font-weight: var(--font-medium);
    cursor: pointer;
}

.qualification__button:hover {
    color: var(--first-color);
}

.qualification__icon {
    font-size: 28px;
    margin-right: 8px;
}

.qualification__data {
    display: grid;
    grid-template-columns: max-content 1fr;
    column-gap: 1.25rem;
}

.qualification__data > div:last-child {
    padding-bottom: var(--mb-1-5);
}

.qualification__list {
    list-style: disc;
    padding-left: 1.1rem;
    margin-top: var(--mb-0-5);
    font-size: var(--small-font-size);
}

.qualification__link {
    display: inline-flex;
    align-items: center;
    column-gap: var(--mb-0-25);
    margin-top: var(--mb-0-5);
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    color: var(--first-color);
}

.qualification__link:hover {
    color: var(--first-color-alt);
}

.qualification__list li + li {
    margin-top: var(--mb-0-25);
}

.qualification__title {
    font-size: var(--normal-font-size);
    font-weight: var(--font-medium);
}

.qualification__sub {
    display: inline-block;
    font-size: var(--small-font-size);
    margin-bottom: var(--mb-0-5);
}

.calendar {
    font-size: var(--smaller-font-size);
    color: var(--text-color);
}

.qualification__rounder {
    display: inline-block;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background-color: var(--first-color);
}
.qualification__line {
    display: block;
    width: 1px;
    height: 100%;
    background-color: var(--first-color);
    transform: translate(6px, -7px);
}

.qualification [data-content] {
    display: none;
}
.qualification__active[data-content] {
    display: block;
}

.qualification__button.qualification__active {
    color: var(--first-color);
}

/*---------------- Portofolio ------------------*/
.portofolio_content {
    padding: 0 2rem 2.5rem;
    row-gap: var(--mb-1-5);
}

.portofolio_img {
    width: 100%;
    max-width: 420px;
    aspect-ratio: 15 / 8;
    object-fit: cover;
    border-radius: .5rem;
    justify-self: center;
}

.portofolio_title {
    font-size: var(--h4-font-size);
    margin-bottom: var(--mb-0-25);
}

.portofolio_meta {
    display: block;
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    color: var(--first-color);
    margin-bottom: var(--mb-0-75);
}

.portofolio_description {
    margin-bottom: var(--mb-1);
}

.portofolio_tags {
    margin-bottom: var(--mb-1-5);
}

.swiper-button-prev::after,
.swiper-button-next::after {
    content: '';
}

.swiper-pagination {
   padding-bottom: 9px;
}
.swiper-portofolio-icon {
    font-size: 1rem;
    color: var(--first-color);
}

.swiper-button-prev{
    left: 0;
}

.swiper-button-next{
    right: 0;
}

.swiper-horizontal > .swiper-pagination-bullets{
    bottom: -.5rem;
}

/*========================= contact =========================*/
.contact_container {
    row-gap: 2rem;
}

.contact_information {
    display: flex;
    align-items: center;
    column-gap: var(--mb-1);
    margin-bottom: var(--mb-1-5);
    color: inherit;
}

a.contact_information:hover .contact_title {
    color: var(--first-color);
}

.contact_icon {
    font-size: 1.75rem;
    color: var(--first-color);
}

.contact_title {
    font-size: var(--h3-font-size);
    font-weight: var(--font-medium);
}

.contact_subtitle {
    font-size: var(--small-font-size);
}

.contact_content {
    background-color: var(--input-color);
    border-radius: .5rem;
    padding: .75rem 1rem .25rem;
}

.contact_content:focus-within {
    box-shadow: 0 0 0 2px var(--first-color);
}

.contact_label {
    font-size: var(--small-font-size);
    color: var(--title-color);
}

.contact_input {
    width: 100%;
    background-color: var(--input-color);
    color: var(--text-color);
    font-family: var(--body-font);
    font-size: 1rem; /* >= 16px supaya iPhone tidak zoom saat mengetik */
    border: none;
    resize: vertical;
    outline: none;
    padding: .25rem .5rem .5rem 0;
}

.contact_buttons {
    display: flex;
    flex-wrap: wrap;
    gap: var(--mb-1);
}

/*========================= footer =========================*/

.footer {
    padding-top: 2rem;
}

.footer_container {
    row-gap: 2rem;
}

.footer_bg {
    background-color: var(--first-color-second);
    padding: 2rem 0 2rem;
}

.footer_title {
    font-size: var(--h2-font-size);
    margin-bottom: var(--mb-0-25);
}

.footer_subtitle {
    font-size: var(--small-font-size);
}

.footer_links {
    display: flex;
    flex-direction: column;
    row-gap: 1rem;
    font-size: var(--normal-font-size);
}

.footer_link {
    color: #FFF;
}

.footer_link:hover {
    color: var(--first-color-lighter);
}

.footer_socials {
    display: flex;
    column-gap: var(--mb-1-5);
}

.footer_social {
    font-size: 1.25rem;
}

.footer_social:hover {
    color: var(--first-color-lighter);
}

.footer_copy {
    text-align: center;
    font-size: var(--small-font-size);
}

.footer_title, .footer_subtitle, .footer_links, .footer_social, .footer_copy {
    color: #FFF;
}

/*==================== BREAKPOINTS ====================*/
/* HP layar kecil */
@media screen and (max-width: 350px) {
    .container {
        margin-left: var(--mb-1);
        margin-right: var(--mb-1);
    }
    .nav__menu {
        padding: 2rem .25rem 4rem;
    }
    .nav__list {
        column-gap: 0;
    }
    .home__content {
        grid-template-columns: .25fr 3fr;
    }
    .home__blob {
        width: 180px;
    }
    .skills__title {
        font-size: var(--normal-font-size);
    }
    .qualification__data {
        gap: .5rem;
    }
}

/* Tablet */
@media screen and (min-width: 568px) {
    .home__content {
        grid-template-columns: max-content 1fr 1fr;
    }
    .home__data {
        grid-column: initial;
    }
    .home__img {
        order: 1;
        justify-self: center;
    }
    .home__button {
        justify-content: flex-start;
    }
    .container__about,
    .skills__container,
    .contact_container,
    .footer_container {
        grid-template-columns: repeat(2, 1fr);
    }
    .skills__container {
        column-gap: 1.5rem;
    }
    .qualification__sections {
        display: grid;
        grid-template-columns: minmax(0, 600px);
        justify-content: center;
    }
    .footer_copy {
        grid-column: 1 / -1;
    }
}

/* Desktop: header pindah ke atas, menu tampil berjajar */
@media screen and (min-width: 768px) {
    body {
        margin: 0;
    }
    .container {
        margin-left: auto;
        margin-right: auto;
    }
    .section {
        padding: 6rem 0 2rem;
    }
    .section__sub {
        margin-bottom: 4rem;
    }

    .header {
        top: 0;
        bottom: initial;
    }
    .header,
    .main,
    .footer_container {
        padding: 0 1rem;
    }
    .scroll-header {
        box-shadow: 0 1px 4px rgba(0, 0, 0, .15);
    }
    .nav {
        height: calc(var(--header-height) + 1.5rem);
        column-gap: 1rem;
    }
    .nav__icon,
    .nav__close,
    .nav__toggle {
        display: none;
    }
    .nav__menu {
        margin-left: auto;
    }
    .nav__list {
        display: flex;
        column-gap: 2rem;
    }

    .home__container {
        row-gap: 5rem;
    }
    .home__content {
        padding-top: 5.5rem;
        column-gap: 2rem;
    }
    .home__blob {
        width: 270px;
    }

    .container__about {
        column-gap: 5rem;
        align-items: center;
    }
    .home__deskripsi,
    .about__deskripsi,
    .portofolio_description {
        text-align: left;
    }
    .about__img {
        width: 350px;
    }

    .qualification__tabs {
        justify-content: center;
        column-gap: 3rem;
    }

    .portofolio_content {
        grid-template-columns: 1fr 1fr;
        align-items: center;
        column-gap: 2rem;
        padding: 0 3.5rem 3rem;
    }
    .swiper-portofolio-icon {
        font-size: 2rem;
    }

    .contact_container {
        column-gap: 3rem;
    }

    .footer_container {
        grid-template-columns: repeat(3, 1fr);
    }
    .footer_bg {
        padding: 3rem 0 3.5rem;
    }
    .footer_links {
        flex-direction: row;
        column-gap: 2rem;
    }
    .footer_socials {
        justify-self: flex-end;
    }
    .footer_copy {
        margin-top: 1.5rem;
    }
}

/* Layar lebar */
@media screen and (min-width: 1024px) {
    .header,
    .main,
    .footer_container {
        padding: 0;
    }
    .home__blob {
        width: 320px;
    }
    .home__social {
        transform: translateX(-6rem);
    }
}
