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

:root {
    --color-background: rgb(0, 0, 0);
    --color-accent: rgb(237, 237, 237);
    --color-surface: rgb(34, 34, 34);
    --color-surface-hover: rgb(20, 20, 20);
    --color-text-primary: rgb(237, 237, 237);
    --color-text-secondary: rgb(161, 161, 161);
    --font-text: 'IBM Plex Sans', sans-serif;
    --font-accent: 'IBM Plex Mono', monospace;
    --font-size-h1: 2rem;
    --font-size-h2: 1.5rem;
    --font-size-h3: 1.17rem;
}

/* ibm-plex-mono-regular - latin */
@font-face {
    font-display: swap;
    /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 400;
    src: url('fonts/ibm-plex-mono-v20-latin-regular.woff2') format('woff2');
    /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}

/* ibm-plex-sans-regular - latin */
@font-face {
    font-display: swap;
    /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
    font-family: 'IBM Plex Sans';
    font-style: normal;
    font-weight: 400;
    src: url('fonts/ibm-plex-sans-v23-latin-regular.woff2') format('woff2');
    /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}

/* ibm-plex-sans-700 - latin */
@font-face {
    font-display: swap;
    /* Check https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display for other options. */
    font-family: 'IBM Plex Sans';
    font-style: normal;
    font-weight: 700;
    src: url('fonts/ibm-plex-sans-v23-latin-700.woff2') format('woff2');
    /* Chrome 36+, Opera 23+, Firefox 39+, Safari 12+, iOS 10+ */
}

body {
    background-color: var(--color-background);
    color: var(--color-text-secondary);
    font-family: var(--font-text);
}

h1,
h2,
h3 {
    color: var(--color-text-primary);
    font-family: var(--font-accent);
}

h1 {
    font-size: var(--font-size-h1);
}

h2 {
    font-size: var(--font-size-h2);
}

h3 {
    font-size: var(--font-size-h3);
}

a {
    color: var(--color-accent);
    text-decoration: none;
}

/* css classes */

.breadcrumb {
    padding: 5% 0.5rem;
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: end;
}

.breadcrumb li:not(:last-child)::after {
    display: inline-block;
    margin: 0 0.25rem;
    content: ">";
}

.card-image {
    padding: 1rem;
    width: 35%;
}

.card-image img {
    object-fit: contain;
    width: 100%;
    height: 100%;
    border-radius: 5px;
    display: block;
}

.card-description {
    padding: 1rem;
    width: 65%;
    color: var(--color-text-secondary)
}

.detail-content {
    max-width: 65ch;
    margin: 0 auto;
    padding-bottom: 4rem;
}

.detail-image img {
    margin: 1rem 0;
    width: 100%;
}

.error-page {
    display: flex;
    align-items: center;
    max-width: 700px;
    margin: 0 auto;
}

.error-page img {
    padding: 1rem;
    max-width: 350px;
}

.link-underline {
    position: relative;
}

.link-underline::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    height: 1px;
    transform-origin: left;
    width: 100%;
    transform: scaleX(0);
    transition: transform 200ms ease;
    background-color: var(--color-accent);
}

.link-underline:hover::after {
    transform: scaleX(1);
}

.nav-bar {
    list-style: none;
    padding: 0;
}

.page-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    max-width: 1100px;
    margin: 0 auto;
    gap: 100px;
    padding: 50px 24px;
}

.project-card {
    border-radius: 10px;
    margin: 0;
    transition: background 200ms ease;
}

.project-card:hover {
    background: var(--color-surface-hover);
}

.project-card a {
    display: flex;
    gap: 10px;
    text-decoration: none;
    color: inherit;
}

.projects-container {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.project-overview {
    max-width: 150ch;
    margin: 0 auto;
}

.project-overview table {
    border-collapse: collapse;
    table-layout: fixed;
    width: 100%;
}

.project-overview tr {
    border-bottom: 1px solid currentColor;
}

.project-overview td,
.project-overview th {
    text-align: left;
    padding: 10px;
}

.project-shortdes {
    width: 30%;
}

.project-techstack {
    width: 30%;
}

.section-image {
    display: block;
    margin-inline: auto;
    max-width: 80%;
    height: auto;
}

.social-icon {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.social-bar {
    display: flex;
    gap: 1rem;
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.social-bar a {
    color: var(--color-text-secondary);
    transition: color 200ms ease;
}

.social-bar a:hover {
    color: var(--color-text-primary);
}

.tech-tag {
    background-color: var(--color-surface);
    color: var(--color-text-secondary);
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-family: var(--font-accent);
}

.tech-wrap {
    display: flex;
    gap: .5em;
    flex-wrap: wrap;
}

/* media query for responsiveness */

@media (max-width: 768px) {
    .project-card {
        gap: 5px;
    }

    .project-card a {
        flex-direction: column-reverse;
    }

    .page-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .project-shortdes,
    .project-techstack {
        display: none;
    }

}