/* =====================================================
   RESUME — Dossiê Graphite Editorial
   Standalone page; mirrors the site design system
   (DESIGN.md): near-void bg, Inter only, three fixed
   accents (worn-steel / cinnabar / parchment).
   ===================================================== */

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-display: swap;
    font-weight: 400;
    src: url("/fonts/inter-v12-latin-regular.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-display: swap;
    font-weight: 600;
    src: url("/fonts/inter-v12-latin-600.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-display: swap;
    font-weight: 700;
    src: url("/fonts/inter-v12-latin-700.woff2") format("woff2");
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-display: swap;
    font-weight: 800;
    src: url("/fonts/inter-v12-latin-800.woff2") format("woff2");
}

:root {
    --void: #08090a;
    --graphite-deep: #101214;
    --graphite-dark: #16191c;
    --steel-shade: #334049;
    --steel: #9fb3bd;
    --rust: #9f5148;
    --parchment: #c8b693;
    --silver: #e0e5e8;
    --hairline: rgba(224, 229, 232, 0.1);
    --steel-glow: rgba(159, 179, 189, 0.28);
    --warm-glow: rgba(200, 182, 147, 0.25);
    --font: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--void);
    /* Fixed atmosphere: selective light, never flat black */
    background-image:
        radial-gradient(1100px 520px at 82% -8%, rgba(159, 179, 189, 0.07), transparent 62%),
        radial-gradient(900px 480px at -12% 30%, rgba(51, 64, 73, 0.22), transparent 58%),
        radial-gradient(760px 520px at 50% 108%, rgba(159, 81, 72, 0.07), transparent 60%);
    background-attachment: fixed;
    color: rgba(224, 229, 232, 0.82);
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background: rgba(159, 179, 189, 0.32);
    color: var(--silver);
}

a {
    color: var(--steel);
    text-decoration: none;
    transition: color 0.2s ease, text-shadow 0.2s ease;
}

a:hover {
    color: var(--silver);
    text-shadow: 0 0 14px rgba(159, 179, 189, 0.35);
}

.page {
    max-width: 66rem;
    margin: 0 auto;
    padding: 1.25rem 1.25rem 3rem;
}

/* ---------- Top bar ---------- */

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.5rem 0 1.75rem;
}

.topbar-home {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #9ca3af;
}

.lang-switch {
    display: flex;
    gap: 0.15rem;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.lang-switch a,
.lang-switch span {
    padding: 0.3rem 0.65rem;
    border-radius: 9999px;
}

.lang-switch span {
    color: var(--silver);
    background: rgba(159, 179, 189, 0.14);
}

.lang-switch a {
    color: var(--parchment);
}

/* ---------- Masthead ---------- */

.masthead {
    padding-bottom: 1.9rem;
}

.kicker {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--parchment);
    margin-bottom: 0.9rem;
}

.masthead h1 {
    font-size: clamp(2.4rem, 6.5vw, 4.2rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.05;
    color: var(--silver);
}

.masthead .creds {
    margin-top: 0.7rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--steel);
}

.masthead .creds strong {
    color: var(--parchment);
    font-weight: 700;
}

/* Searchable headline: role keywords recruiters query in ATS databases */
.headline {
    margin-top: 0.55rem;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: rgba(159, 179, 189, 0.75);
}

.contact {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1.6rem;
    margin-top: 1.1rem;
    font-size: 0.85rem;
    font-variant-numeric: tabular-nums;
}

.contact li {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(224, 229, 232, 0.6);
}

.contact a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.ic {
    flex: none;
}

/* Icon micro-animations ported from itshover (motion/react originals) */
.star-fill {
    opacity: 0;
    transform: scale(0.8);
    transform-origin: center;
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

a:hover .star-fill {
    opacity: 1;
    transform: scale(1);
}

.star-outline,
.li-border {
    transform-origin: center;
}

.at-inner,
.at-path,
.at-outer,
.li-line {
    stroke-dasharray: 1;
}

@media (prefers-reduced-motion: no-preference) {
    a:hover .star-outline { animation: icon-wiggle 0.5s ease-in-out; }
    li:hover .pin-dot { animation: icon-beacon 0.6s ease-in-out infinite; }
    a:hover .at-outer { animation: icon-draw 0.45s ease-out both; }
    a:hover .at-path { animation: icon-draw 0.6s ease-out 0.45s both; }
    a:hover .at-inner { animation: icon-draw 0.3s ease-out 1.05s both; }
    a:hover .li-border { animation: icon-pop 0.4s ease-in-out; }
    a:hover .li-line { animation: icon-draw 0.5s ease-out 0.4s both; }

    @keyframes icon-wiggle {
        25% { transform: scale(1.1) rotate(-5deg); }
        60% { transform: scale(1.1) rotate(5deg); }
        100% { transform: scale(1) rotate(0); }
    }

    @keyframes icon-beacon {
        50% { opacity: 0.4; }
    }

    @keyframes icon-draw {
        from { stroke-dashoffset: 1; opacity: 0; }
        to { stroke-dashoffset: 0; opacity: 1; }
    }

    @keyframes icon-pop {
        50% { transform: scale(1.08); }
    }
}

/* ---------- Theme toggle ---------- */

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.print-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.85rem;
    border-radius: 9999px;
    border: 1px solid rgba(224, 229, 232, 0.12);
    background: transparent;
    color: var(--steel);
    font-family: var(--font);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.print-btn:hover {
    border-color: rgba(159, 179, 189, 0.42);
    color: var(--silver);
    box-shadow: 0 0 12px var(--steel-glow);
}

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    border: 1px solid rgba(224, 229, 232, 0.12);
    background: transparent;
    color: var(--parchment);
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.theme-toggle:hover {
    border-color: rgba(159, 179, 189, 0.42);
    box-shadow: 0 0 12px var(--steel-glow);
}

.theme-toggle .icon-moon {
    display: none;
}

html.light .theme-toggle .icon-sun {
    display: none;
}

html.light .theme-toggle .icon-moon {
    display: block;
}

/* ---------- Stats band (infographic) ---------- */

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.7rem;
    padding: 1.4rem 0;
    border-top: 1px solid var(--hairline);
    border-bottom: 1px solid var(--hairline);
}

.stat {
    padding: 1.1rem 1.2rem;
    background: rgba(16, 18, 20, 0.62);
    border: 1px solid rgba(224, 229, 232, 0.08);
    border-radius: 12px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.stat:hover {
    border-color: rgba(159, 179, 189, 0.42);
    box-shadow: 0 0 24px rgba(159, 179, 189, 0.14);
}

.stat-number {
    display: block;
    font-size: clamp(1.7rem, 3vw, 2.3rem);
    font-weight: 700;
    letter-spacing: -0.015em;
    font-variant-numeric: tabular-nums;
    color: var(--parchment);
    text-shadow: 0 0 30px var(--warm-glow);
}

.stat-label {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--steel);
}

/* ---------- Two-column grid ---------- */

.grid {
    display: grid;
    grid-template-columns: minmax(0, 1.72fr) minmax(0, 1fr);
    gap: 3.2rem;
    padding-top: 2.4rem;
}

section + section {
    margin-top: 2.6rem;
}

/* Section headings: institutional labels with a rule */
h2 {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--steel);
    margin-bottom: 1.3rem;
}

h2::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--hairline);
}

h2 .count {
    font-variant-numeric: tabular-nums;
    color: var(--parchment);
}

/* ---------- Objective ---------- */

.objective {
    border-left: 3px solid var(--rust);
    background: linear-gradient(135deg, rgba(184, 92, 79, 0.055), transparent);
    padding: 1.1rem 1.3rem;
    border-radius: 0 8px 8px 0;
    font-size: 1.06rem;
    line-height: 1.65;
    color: rgba(224, 229, 232, 0.88);
}

.objective strong {
    color: var(--silver);
}

/* ---------- Career strip (infographic) ---------- */

.career-strip {
    margin-bottom: 1.8rem;
}

.strip-track {
    display: flex;
    gap: 3px;
    height: 30px;
    border-radius: 4px;
    overflow: hidden;
}

.strip-track span {
    display: block;
    border-radius: 2px;
    transition: filter 0.2s ease;
}

.strip-track span:hover {
    filter: brightness(1.45);
}

.seg-a { background: #2b3a44; }
.seg-b { background: rgba(159, 179, 189, 0.34); }
.seg-c { background: rgba(159, 81, 72, 0.55); }
.seg-d { background: rgba(159, 179, 189, 0.55); }
.seg-e { background: rgba(200, 182, 147, 0.42); }
.seg-f {
    background: var(--parchment);
    box-shadow: 0 0 14px var(--warm-glow);
}

.strip-scale {
    display: flex;
    justify-content: space-between;
    margin-top: 0.4rem;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    font-variant-numeric: tabular-nums;
    color: rgba(200, 182, 147, 0.78);
}

.strip-legend {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 1.1rem;
    margin-top: 0.7rem;
    font-size: 0.7rem;
    color: rgba(224, 229, 232, 0.6);
}

.strip-legend i {
    display: inline-block;
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 2px;
    margin-right: 0.4rem;
    font-style: normal;
}

/* ---------- Experience timeline ---------- */

.jobs {
    position: relative;
    padding-left: 1.45rem;
    border-left: 1px solid var(--hairline);
    display: flex;
    flex-direction: column;
    gap: 2.1rem;
}

.job {
    position: relative;
}

.job::before {
    content: "";
    position: absolute;
    left: calc(-1.45rem - 5.5px);
    top: 0.42rem;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--steel-shade);
    border: 2px solid var(--steel);
    box-shadow: 0 0 8px var(--steel-glow);
}

.job h3 {
    font-size: 1.12rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    color: var(--silver);
    line-height: 1.35;
}

.job-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.3rem 0.9rem;
    margin-top: 0.25rem;
}

.job-company {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--steel);
}

.job-period {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    font-variant-numeric: tabular-nums;
    color: rgba(200, 182, 147, 0.78);
}

.value-chip {
    display: inline-block;
    margin-top: 0.65rem;
    padding: 0.32rem 0.8rem;
    border: 1px solid rgba(200, 182, 147, 0.4);
    border-radius: 9999px;
    background: rgba(200, 182, 147, 0.07);
    color: var(--parchment);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 18px var(--warm-glow);
}

.job p,
.job ul {
    margin-top: 0.7rem;
    font-size: 0.92rem;
    line-height: 1.6;
    color: rgba(224, 229, 232, 0.74);
}

.job ul {
    list-style: none;
}

.job ul li {
    position: relative;
    padding-left: 1.05rem;
    margin-top: 0.3rem;
}

.job ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.62em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(159, 179, 189, 0.55);
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.85rem;
}

.tags span {
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    background: rgba(159, 179, 189, 0.105);
    color: var(--steel);
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.tags span:hover {
    background: rgba(159, 179, 189, 0.2);
    color: var(--silver);
    box-shadow: 0 0 12px rgba(159, 179, 189, 0.18);
}

/* ---------- Sidebar ---------- */

.skill-group + .skill-group {
    margin-top: 1.15rem;
}

.skill-group h3 {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(200, 182, 147, 0.85);
    margin-bottom: 0.5rem;
}

.pills {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.pills li {
    padding: 0.32rem 0.8rem;
    border-radius: 9999px;
    background: rgba(159, 179, 189, 0.105);
    border: 1px solid rgba(224, 229, 232, 0.07);
    color: rgba(224, 229, 232, 0.8);
    font-size: 0.78rem;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.pills li:hover {
    background: rgba(159, 179, 189, 0.2);
    color: var(--silver);
    box-shadow: 0 0 12px rgba(159, 179, 189, 0.18);
}

.cert-list,
.edu-list,
.vol-list {
    list-style: none;
    display: flex;
    flex-direction: column;
}

.cert-list li,
.edu-list li,
.vol-list li {
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(224, 229, 232, 0.06);
}

.cert-list li:last-child,
.edu-list li:last-child,
.vol-list li:last-child {
    border-bottom: 0;
}

.cert-name,
.edu-name,
.vol-name {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(224, 229, 232, 0.86);
    line-height: 1.4;
}

.cert-issuer,
.edu-school,
.vol-org {
    display: block;
    margin-top: 0.1rem;
    font-size: 0.7rem;
    color: rgba(159, 179, 189, 0.75);
}

.edu-period,
.vol-period {
    float: right;
    font-size: 0.68rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: rgba(200, 182, 147, 0.78);
}

/* ---------- Languages ---------- */

.langs {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.lang-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.35rem;
}

.lang-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(224, 229, 232, 0.86);
}

.lang-level {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(200, 182, 147, 0.78);
}

.lang-bar {
    height: 5px;
    border-radius: 9999px;
    background: rgba(224, 229, 232, 0.08);
    overflow: hidden;
}

.lang-bar i {
    display: block;
    height: 100%;
    border-radius: 9999px;
    background: var(--steel);
    box-shadow: 0 0 8px var(--steel-glow);
}

/* ---------- Entrance (staggered reveal) ---------- */

@media (prefers-reduced-motion: no-preference) {
    .masthead,
    .stats,
    .col-main > section,
    .col-side > section {
        animation: rise 0.6s ease both;
    }

    .stats { animation-delay: 0.08s; }
    .col-main > section:nth-child(1) { animation-delay: 0.16s; }
    .col-main > section:nth-child(2) { animation-delay: 0.24s; }
    .col-side > section:nth-child(1) { animation-delay: 0.2s; }
    .col-side > section:nth-child(2) { animation-delay: 0.28s; }
    .col-side > section:nth-child(3) { animation-delay: 0.36s; }
    .col-side > section:nth-child(4) { animation-delay: 0.44s; }
    .col-side > section:nth-child(5) { animation-delay: 0.52s; }

    @keyframes rise {
        from {
            opacity: 0;
            transform: translateY(10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
    .grid {
        grid-template-columns: 1fr;
        gap: 2.6rem;
    }

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

@media (max-width: 480px) {
    .page {
        padding: 0.9rem 1rem 2.2rem;
    }

    .contact {
        flex-direction: column;
        gap: 0.35rem;
    }

    .strip-legend {
        gap: 0.3rem 0.85rem;
    }

    .print-btn {
        padding: 0.45rem 0.6rem;
    }

    .print-label {
        display: none;
    }
}

/* ---------- Print (ATS-friendly PDF) ---------- */

@media print {
    @page {
        margin: 18mm 14mm 16mm;
    }

    /* Every size on the page is rem-based: shrinking the root scales
       type and spacing together, cutting the PDF page count */
    html {
        font-size: 12.5px;
    }

    body {
        background: #fff;
        color: #1a1d1f;
    }

    .masthead h1 {
        font-size: 2.1rem;
    }

    .topbar,
    .lang-switch {
        display: none;
    }

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

    .masthead h1,
    .job h3,
    .cert-name,
    .edu-name,
    .vol-name,
    .lang-name {
        color: #000;
    }

    .stat,
    .objective,
    .pills li {
        background: none;
        border-color: #bbb;
    }

    .stat-number,
    .value-chip,
    .job-period,
    .edu-period,
    .vol-period,
    .kicker {
        color: #6b5d3f;
        text-shadow: none;
    }

    .stat-label,
    h2,
    .headline,
    .job-company,
    .tags span,
    .cert-issuer,
    .edu-school,
    .vol-org {
        color: #44525b;
    }

    .job p,
    .job ul,
    .contact li,
    .objective {
        color: #24292d;
    }

    .tags span,
    .pills li {
        color: #333;
        background: none;
        border: 1px solid #ccc;
    }

    /* Timeline spine and dots get sliced at page breaks: drop them on paper */
    .jobs {
        border-left: 0;
        padding-left: 0;
    }

    .job::before {
        display: none;
    }

    .lang-bar {
        background: #e4e4e4;
    }

    .lang-bar i {
        background: #44525b;
        box-shadow: none;
    }

    a {
        color: #24404d;
    }

    /* Single column: ATS parsers read multi-column PDFs out of order */
    .grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding-top: 0.5rem;
    }

    /* Purely visual infographics add parsing noise to the exported PDF */
    .stats,
    .career-strip,
    .lang-bar {
        display: none;
    }

    section + section {
        margin-top: 1.6rem;
    }

    /* Keep only atomic items together: a whole section taller than a page
       gets pushed to the next one and leaves a void after the objective */
    h2 {
        break-after: avoid;
    }

    .job,
    .cert-list li,
    .edu-list li,
    .vol-list li,
    .langs li {
        break-inside: avoid;
    }

    /* ATS parsers read text, not link annotations: expose the LinkedIn URL */
    .contact a[href*="linkedin"]::after {
        content: " · go.beckerig.com/linkedin";
    }
}
