/**
 * Copyright © 2026 Giacomo Leidi <therewasa@fishinthecalculator.me>
 * */

/* fonts  */

@font-face {
    font-family: 'Rubik';
    src: url('/static/fonts/Rubik-Light.otf') format('opentype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Rubik';
    src: url('/static/fonts/Rubik-Regular.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Rubik';
    src: url('/static/fonts/Rubik-Medium.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Rubik';
    src: url('/static/fonts/Rubik-Bold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Inter';
    src: url('/static/fonts/Inter-Regular.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Inter';
    src: url('/static/fonts/Inter-Medium.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

/* theme  */

:root {
    --body: #3E3E3E;
    --heading: #124F44;
    --accent: #3CB371;
    --accent30: rgba(60, 179, 113, .30);
    --accent50: rgba(60, 179, 113, .50);

    --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-display: 'Rubik', system-ui, sans-serif;
}

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

html {
    font-size: 100%;
}

body {
    font-family: var(--font-sans);
    color: var(--body);
    background: #fff;
    font-size: 1rem;
    line-height: 1.5;
}

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

a:hover {
    text-decoration: underline;
}

/* layout  */

.cv {
    max-width: 60rem;
    margin-inline: auto;
    padding: clamp(1.25rem, 4vw, 3rem);
}

.cv-head {
    margin-bottom: 2rem;
}

.cv-name {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(2rem, 6vw, 3rem);
    letter-spacing: .03em;
    text-transform: uppercase;
    color: var(--body);
    line-height: 1.05;
}

.cv-tagline {
    display: inline-block;
    margin-top: 1rem;
    padding: .5em 1.25em;
    border-radius: 2rem;
    background: var(--accent50);
    color: var(--heading);
    font-size: .875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.cv-back {
    display: block;
    margin-bottom: 1.25rem;
    font-size: .875rem;
}

.cv-back a {
    color: var(--heading);
}

.cv-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.main {
    order: -1;
}

@media (min-width: 48em) {
    .cv-grid {
        grid-template-columns: minmax(12rem, 30%) 1fr;
        column-gap: 3rem;
    }

    .main {
        order: 0;
    }
}

/* sections */

.block {
    margin-bottom: 2rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: .75rem;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 1rem;
    text-transform: uppercase;
    color: var(--heading);
    letter-spacing: .04em;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: .375rem;
    background: var(--accent30);
    font-size: 1rem;
    line-height: 1;
    color: var(--heading);
    flex: none;
}

.summary {
    color: var(--body);
    margin-bottom: 2rem;
}

/* entries */

.entry {
    margin-bottom: 1.5rem;
}

.entry-head {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .25rem;
}

.entry-right {
    text-align: left;
    font-size: .8125rem;
    color: var(--body);
}

.company {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.0625rem;
    color: var(--body);
}

.role {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: .9375rem;
    color: var(--body);
}

.entry-right .loc,
.entry-right .dates {
    display: block;
}

.bullets {
    list-style: none;
    margin-top: .5rem;
    padding-left: 0;
}

.bullets li {
    position: relative;
    padding-left: 1rem;
    margin-bottom: .25rem;
}

.bullets li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--heading);
}

@media (min-width: 48em) {
    .entry-head {
        flex-direction: row;
        justify-content: space-between;
        align-items: baseline;
        gap: 1rem;
    }

    .entry-right {
        text-align: right;
    }
}

/* sidebar */

.side-block {
    margin-bottom: 1.75rem;
}

.contacts {
    list-style: none;
}

.contact-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: .5rem;
    font-size: .875rem;
}

.side-text {
    font-size: .875rem;
}

.edu {
    margin-bottom: .75rem;
}

.edu strong {
    display: block;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: .9375rem;
}

.edu div {
    font-size: .875rem;
}

/* print */

@media print {
    body {
        font-size: .75rem;
    }

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

    .cv {
        max-width: none;
        padding: 0;
    }
}
