/* ============================================================
   Resume_v3 — رزومه مینیمال تک‌رنگ (Minimal Monochrome)
   Ultra-clean editorial CV: black & white, hairline rules,
   small uppercase-style section labels, single centered column.
   Every class is prefixed with resume3- to avoid Bootstrap collisions.
   ============================================================ */

.resume3-root {
    --r3-ink: #111111;
    --r3-soft: #3a3a3a;
    --r3-muted: #6b6b6b;
    --r3-faint: #9a9a9a;
    --r3-line: #e3e3e3;
    --r3-line-strong: #111111;
    --r3-bg: #f4f4f2;
    --r3-paper: #ffffff;
    --r3-accent: #111111;

    background: var(--r3-bg);
    color: var(--r3-ink);
    font-family: 'Vazirmatn', Vazir, Tahoma, sans-serif;
    line-height: 2;
    padding: 40px 16px 96px;
    direction: rtl;
}

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

/* ===== Paper sheet ===== */
.resume3-sheet {
    max-width: 860px;
    margin: 0 auto;
    background: var(--r3-paper);
    border: 1px solid var(--r3-line);
    padding: 64px 72px 72px;
}

/* ===== Header / identity ===== */
.resume3-head {
    display: flex;
    align-items: center;
    gap: 30px;
    padding-bottom: 28px;
    border-bottom: 2px solid var(--r3-line-strong);
}

.resume3-photo {
    width: 104px;
    height: 104px;
    flex-shrink: 0;
    overflow: hidden;
    border: 1px solid var(--r3-line-strong);
    filter: grayscale(100%);
}

.resume3-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.resume3-head-text {
    flex: 1;
    min-width: 0;
}

.resume3-name {
    font-size: 2.1rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    line-height: 1.25;
    color: var(--r3-ink);
}

.resume3-jobtitle {
    font-size: 1rem;
    font-weight: 500;
    color: var(--r3-muted);
    margin-top: 4px;
    letter-spacing: 0.5px;
}

.resume3-years {
    display: inline-block;
    margin-top: 12px;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--r3-ink);
    border: 1px solid var(--r3-line-strong);
    padding: 4px 12px;
}

/* ===== Summary ===== */
.resume3-summary {
    color: var(--r3-soft);
    font-size: 0.97rem;
    line-height: 2.1;
    text-align: justify;
    margin: 26px 0 4px;
}

.resume3-summary p { margin: 0 0 10px; }
.resume3-summary p:last-child { margin-bottom: 0; }

/* ===== Contact row ===== */
.resume3-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 26px;
    padding: 18px 0;
    border-top: 1px solid var(--r3-line);
    border-bottom: 1px solid var(--r3-line);
    margin-bottom: 30px;
}

.resume3-ct {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 0.85rem;
    color: var(--r3-soft);
    text-decoration: none;
}

.resume3-ct i {
    color: var(--r3-ink);
    width: 15px;
    text-align: center;
    font-size: 0.85rem;
}

.resume3-ct[dir="ltr"] { direction: ltr; }
.resume3-ct a { color: inherit; text-decoration: none; }
.resume3-ct:hover { color: var(--r3-ink); }

/* ===== Download button ===== */
.resume3-dl-wrap {
    margin: 0 0 30px;
}

.resume3-dl {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background: var(--r3-ink);
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    padding: 11px 24px;
    text-decoration: none;
    border: 1px solid var(--r3-ink);
    cursor: pointer;
    transition: background .2s, color .2s;
}

.resume3-dl:hover {
    background: #fff;
    color: var(--r3-ink);
}

/* ===== Section ===== */
.resume3-section {
    margin-top: 38px;
}

.resume3-label {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--r3-ink);
    text-transform: uppercase;
    margin-bottom: 22px;
}

.resume3-label::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--r3-line);
}

/* ===== Timeline-ish blocks (experience / education) ===== */
.resume3-entry {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 4px 24px;
    padding-bottom: 24px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--r3-line);
}

.resume3-entry:last-child {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
}

.resume3-period {
    font-size: 0.8rem;
    color: var(--r3-faint);
    letter-spacing: 0.5px;
    padding-top: 4px;
    line-height: 1.8;
}

.resume3-entry-body { min-width: 0; }

.resume3-role {
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--r3-ink);
}

.resume3-org {
    font-size: 0.88rem;
    color: var(--r3-muted);
    margin-top: 2px;
}

.resume3-org .resume3-sep {
    color: var(--r3-faint);
    margin: 0 6px;
}

.resume3-desc {
    font-size: 0.9rem;
    color: var(--r3-soft);
    margin-top: 8px;
    text-align: justify;
    line-height: 2;
}

/* ===== Two-column wrap for skills / languages / interests ===== */
.resume3-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 46px;
}

/* ===== Skills (name + thin bar) ===== */
.resume3-skill {
    margin-bottom: 4px;
}

.resume3-skill-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 0.88rem;
    margin-bottom: 6px;
}

.resume3-skill-name { font-weight: 600; color: var(--r3-ink); }
.resume3-skill-pct { font-size: 0.76rem; color: var(--r3-faint); letter-spacing: 0.5px; }

.resume3-bar {
    height: 3px;
    background: var(--r3-line);
    overflow: hidden;
}

.resume3-bar-fill {
    height: 100%;
    background: var(--r3-ink);
}

/* ===== Languages ===== */
.resume3-lang {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 0.9rem;
    padding: 9px 0;
    border-bottom: 1px dashed var(--r3-line);
}

.resume3-lang-name { font-weight: 600; color: var(--r3-ink); }
.resume3-lang-level { font-size: 0.82rem; color: var(--r3-muted); }

/* ===== Certifications ===== */
.resume3-cert {
    padding: 12px 0;
    border-bottom: 1px solid var(--r3-line);
}

.resume3-cert:last-child { border-bottom: none; }

.resume3-cert-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.resume3-cert-name { font-weight: 700; font-size: 0.92rem; color: var(--r3-ink); }
.resume3-cert-issuer { font-size: 0.82rem; color: var(--r3-muted); }
.resume3-cert-year { font-size: 0.78rem; color: var(--r3-faint); letter-spacing: 0.5px; white-space: nowrap; }

/* ===== Projects ===== */
.resume3-project {
    padding-bottom: 18px;
    margin-bottom: 18px;
    border-bottom: 1px solid var(--r3-line);
}

.resume3-project:last-child { border-bottom: none; padding-bottom: 0; margin-bottom: 0; }

.resume3-project-name {
    font-weight: 700;
    font-size: 0.98rem;
    color: var(--r3-ink);
}

.resume3-project-desc {
    font-size: 0.9rem;
    color: var(--r3-soft);
    margin-top: 6px;
    text-align: justify;
}

.resume3-project-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 8px;
    font-size: 0.82rem;
    color: var(--r3-ink);
    text-decoration: none;
    border-bottom: 1px solid var(--r3-line-strong);
    padding-bottom: 1px;
    direction: ltr;
}

/* ===== Interests (tags) ===== */
.resume3-interest {
    display: inline-block;
    font-size: 0.82rem;
    color: var(--r3-soft);
    border: 1px solid var(--r3-line);
    padding: 6px 14px;
    margin: 0 0 8px 8px;
}

/* ===== Floating download FAB ===== */
.resume3-fab {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background: var(--r3-ink);
    color: #fff;
    font-family: inherit;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 13px 22px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 14px 34px -12px rgba(0,0,0,.55);
}

.resume3-fab:hover { background: var(--r3-soft); color: #fff; }

/* ===== Responsive ===== */
@media (max-width: 720px) {
    .resume3-sheet { padding: 40px 24px 48px; }
    .resume3-head { flex-direction: column; align-items: flex-start; gap: 18px; }
    .resume3-name { font-size: 1.7rem; }
    .resume3-entry { grid-template-columns: 1fr; gap: 2px; }
    .resume3-period { padding-top: 0; order: -1; }
    .resume3-cols { grid-template-columns: 1fr; }
}

/* ===== Print (save as PDF) ===== */
@media print {
    .resume3-root {
        background: #fff;
        padding: 0;
    }
    .resume3-sheet {
        max-width: none;
        border: none;
        padding: 0 14mm;
        margin: 0;
    }
    .resume3-fab,
    .resume3-dl-wrap { display: none !important; }
    .resume3-entry,
    .resume3-section { break-inside: avoid; }
    .resume3-photo { filter: grayscale(100%); }
    a { color: var(--r3-ink) !important; text-decoration: none !important; }
}
.resume3-root {overflow-wrap:anywhere;}
.resume3-entry > *, .resume3-cols > *, .resume3-head > * {min-width:0;}
.resume3-demo-note {max-width:1000px;margin:0 auto 18px;color:#475569;}
.resume3-dl {font-family:inherit;cursor:pointer;}
.resume3-dl:focus-visible {outline:3px solid #555;outline-offset:4px;}
@media print {
 @page {size:A4;margin:12mm;}
 body:has(.resume3-root) > :not(.page-card-shell):not(script):not(style):not(link) {display:none!important;}
 body:has(.resume3-root) .page-card-shell {display:block;border:0;}
 .resume3-demo-note {display:none;}
 .resume3-sheet {padding:0;overflow:visible;}
 .resume3-section {break-inside:auto;}
 .resume3-label {break-after:avoid;}
 .resume3-root p {font-size:10pt;line-height:1.6;orphans:3;widows:3;}
}
.resume3-cert-year {white-space:normal;} .resume3-skill-top, .resume3-lang, .resume3-cert {gap:8px;flex-wrap:wrap;} .resume3-skill-top > *, .resume3-lang > *, .resume3-cert > * {min-width:0;max-width:100%;}
@media print { .resume3-root [data-row-index] {break-inside:avoid;} }
