/**
 * CV Maker Pro - Master Unified Template Stylesheet (cv-templates-main.css)
 * 
 * Single-file master stylesheet bundling all 18+ CV templates:
 * (Auckland, Stanford, Harvard, Edinburgh, Cambridge, Oxford, Sydney,
 * Toronto, Wellington, Kyoto, Healthcare, Otago, Zurich, Two-Column,
 * ATS Modern, ATS Friendly, Corporate, Grid, Classic, Modern, Compact,
 * Executive, Academic, Elegant).
 *
 * Enforces strict physical A4 geometry lock (210mm x 297mm), container isolation,
 * zero-FOUC shield, and pre-renders all templates synchronously with 0ms latency.
 */

/* ==========================================================================
   1. STRICT PHYSICAL A4 PAPER CONTAINER ISOLATION & GEOMETRY LOCK
   Guarantees unstyled or loading content can NEVER fill the screen or blow out.
   ========================================================================== */
#cvm-a4-sheet-container,
.cvm-a4-sheet-container,
#cv-preview-container,
.cv-preview-container,
#cvm-preview-frame,
.cvm-preview-wrapper,
.cvm-preview-stage-content,
#cv-printable-sheet,
.cv-template-root,
.cv-template-eager-stack {
    box-sizing: border-box !important;
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    height: 297mm !important;
    min-height: 297mm !important;
    max-height: 297mm !important;
    overflow: hidden !important;
    contain: strict !important; /* contain: size layout paint */
    position: relative !important;
    margin: 0 auto !important;
    padding: 0 !important;
    background-color: #ffffff !important;
}

#cvm-canvas-viewport,
.cvm-canvas-viewport {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
    contain: layout paint !important;
    display: flex !important;
    justify-content: center !important;
    align-items: flex-start !important;
}

#cvm-builder-right-panel,
.cvm-right-preview-panel {
    box-sizing: border-box !important;
    max-width: 100% !important;
    overflow: hidden !important;
}

#cvm-a4-sheet-container *,
#cv-preview-container *,
#cvm-preview-frame *,
#cv-printable-sheet *,
.cv-template-root *,
.cvm-template * {
    box-sizing: border-box !important;
    max-width: 100% !important;
    overflow-wrap: break-word !important;
    word-wrap: break-word !important;
    word-break: break-word !important;
}

#cvm-a4-sheet-container table,
#cv-preview-container table,
#cvm-preview-frame table,
.cvm-template table {
    table-layout: fixed !important;
    width: 100% !important;
    max-width: 100% !important;
}

#cvm-a4-sheet-container img,
#cv-preview-container img,
#cvm-preview-frame img,
.cvm-template img {
    max-width: 100% !important;
    height: auto;
}

/* Zero Flash of Unstyled Content: ready state */
[data-template-ready="true"],
[data-template-ready="true"] * {
    opacity: 1;
    visibility: visible;
}


/**
 * CV Maker Pro - Unified Template Stylesheet Bundle (cv-templates-bundle.css)
 * 
 * Preloads and bundles all CV template styles, strict container isolation,
 * anti-blowout rules, and ghost-rendering double buffering.
 * Guarantees 0ms instantaneous template switching with zero FOUC and zero layout jumps.
 */

/* ==========================================================================
   1. UNIVERSAL CONTAINER ISOLATION & PHYSICAL A4 GEOMETRY LOCK
   Strict boundaries preventing unstyled content or WordPress themes from blowing out
   ========================================================================== */
#cv-preview-container,
.cv-preview-container,
#cvm-preview-frame,
.cvm-preview-wrapper,
.cvm-preview-stage-content,
#cvm-a4-sheet-container,
.cvm-a4-sheet-container,
#cv-printable-sheet,
.cvm-canvas-viewport,
.a4-preview-viewport,
.cvm-builder-right-panel,
.cvm-right-preview-panel {
    box-sizing: border-box !important;
    max-width: 100% !important;
}

/* Strict Physical A4 Paper Sheet Boundaries: 210mm x 297mm Lock */
#cvm-a4-sheet-container,
.cvm-a4-sheet-container,
#cv-printable-sheet,
.cv-preview-sheet,
.cvm-double-buffering-viewport,
.cvm-double-buffer-slot,
.cv-template-eager-stack,
.cv-template-eager-layer,
.cv-template-root {
    box-sizing: border-box !important;
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    min-height: 297mm !important;
    overflow: hidden !important;
    contain: paint layout !important;
    position: relative !important;
    margin: 0 auto !important;
    padding: 0 !important;
    background-color: #ffffff !important;
}

/* Inner Template Root Containers - Strictly 0 padding/margin reset */
#cv-preview-container,
.cv-preview-container,
#cvm-preview-frame,
.cvm-preview-wrapper {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 297mm !important;
    overflow: hidden !important;
    contain: paint layout !important;
    position: relative !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
    outline: none !important;
}

/* ==========================================================================
   2. UNIVERSAL ANTI-BLOWOUT ENFORCEMENT (WordPress Theme Immune Shield)
   Ensures theme rules (.entry-content, full-width tables, unstyled text) can NEVER expand outside 210mm
   ========================================================================== */
#cvm-a4-sheet-container *,
#cv-preview-container *,
#cvm-preview-frame *,
#cv-printable-sheet *,
.cv-template-root *,
.cv-template-eager-stack *,
.cv-template-eager-layer *,
.cvm-template *,
.cvm-double-buffer-slot *,
.cvm-ghost-buffer * {
    box-sizing: border-box !important;
    max-width: 100% !important;
    overflow-wrap: break-word !important;
    word-wrap: break-word !important;
    word-break: break-word !important;
}

/* Table Protection: Eliminates theme 100vw table expansions */
#cvm-a4-sheet-container table,
#cv-preview-container table,
#cvm-preview-frame table,
#cv-printable-sheet table,
.cv-template-root table,
.cvm-template table,
.cvm-ghost-buffer table {
    table-layout: fixed !important;
    width: 100% !important;
    max-width: 100% !important;
    border-collapse: collapse !important;
    margin: 0 !important;
}

/* Image Protection: Strict boundaries */
#cvm-a4-sheet-container img,
#cv-preview-container img,
#cvm-preview-frame img,
#cv-printable-sheet img,
.cv-template-root img,
.cvm-template img,
.cvm-ghost-buffer img {
    max-width: 100% !important;
    height: auto;
}

/* Typography Resets inside Preview to prevent theme overrides */
#cv-preview-container p,
#cvm-a4-sheet-container p {
    margin-top: 0;
    margin-bottom: 0.5em;
}

#cv-preview-container h1,
#cv-preview-container h2,
#cv-preview-container h3,
#cv-preview-container h4,
#cvm-a4-sheet-container h1,
#cvm-a4-sheet-container h2,
#cvm-a4-sheet-container h3,
#cvm-a4-sheet-container h4 {
    margin-top: 0;
    margin-bottom: 0.35em;
    color: inherit;
}

#cv-preview-container ul,
#cvm-a4-sheet-container ul {
    margin-top: 0;
    margin-bottom: 0.5em;
}

/* ==========================================================================
   3. GHOST RENDERING & DOUBLE BUFFERING ANTI-FOUC ARCHITECTURE
   ========================================================================== */
.cvm-template-transitioning,
.cvm-template-transitioning *,
[data-template-ready="false"],
[data-template-ready="false"] *,
#cv-preview-container.cvm-template-transitioning,
#cvm-preview-frame.cvm-template-transitioning,
#cvm-a4-sheet-container.cvm-template-transitioning {
    opacity: 0 !important;
    visibility: hidden !important;
    transition: none !important;
}

[data-template-ready="true"],
#cv-preview-container[data-template-ready="true"],
#cvm-preview-frame[data-template-ready="true"],
#cvm-a4-sheet-container[data-template-ready="true"] {
    opacity: 1 !important;
    visibility: visible !important;
    transition: opacity 0.08s ease-in-out !important;
}

/* Off-Screen Ghost Buffer Staging Div (Zero Layout Impact) */
#cvm-ghost-buffer,
.cvm-ghost-buffer,
.cvm-double-buffer-slot[data-slot-active="false"] {
    position: fixed !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    min-height: 297mm !important;
    visibility: hidden !important;
    opacity: 0 !important;
    overflow: hidden !important;
    contain: strict !important;
    clip-path: inset(0) !important;
    pointer-events: none !important;
    z-index: -9999 !important;
    box-sizing: border-box !important;
}

/* Eager Pre-Render Stack (AI Studio Instant Switch Architecture) */
.cv-template-eager-stack {
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    min-height: 297mm !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    position: relative !important;
}

.cv-template-eager-layer[data-active="true"] {
    display: block !important;
    position: relative !important;
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    min-height: 297mm !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    z-index: 10 !important;
    transition: opacity 0.08s ease-in-out;
}

.cv-template-eager-layer[data-active="false"] {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 210mm !important;
    min-width: 210mm !important;
    max-width: 210mm !important;
    min-height: 297mm !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: 0 !important;
}

/* ==========================================================================
   4. TEMPLATE 1: AUCKLAND (Modern Tech - Top Banner & Right Sidebar)
   ========================================================================== */
.cv-auckland-template,
.cvm-auckland,
.cvm-template-auckland {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #ffffff;
    color: #1e293b;
    line-height: 1.5;
    font-size: 11px;
    box-sizing: border-box;
    width: 100%;
}

.cv-auckland-banner {
    background: linear-gradient(135deg, var(--primary-color, #0072DD) 0%, #0F172A 100%);
    color: #ffffff;
    padding: 22px 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.cv-auckland-content {
    display: flex;
    gap: 20px;
    padding: 20px 28px;
    width: 100%;
}

.cv-auckland-main {
    width: 67%;
    min-width: 67%;
    max-width: 67%;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cv-auckland-sidebar {
    width: 33%;
    min-width: 33%;
    max-width: 33%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.cv-auckland-sec-title {
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #0F172A;
    border-bottom: 1.5px solid rgba(0, 114, 221, 0.25);
    padding-bottom: 4px;
    margin: 0 0 10px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cv-auckland-timeline-item {
    position: relative;
    padding-left: 12px;
    border-left: 2px solid rgba(0, 114, 221, 0.25);
    margin-bottom: 12px;
}

.cv-auckland-timeline-dot {
    position: absolute;
    left: -5px;
    top: 3px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-color, #0072DD);
    border: 2px solid #ffffff;
}

/* ==========================================================================
   5. TEMPLATE 2: STANFORD (Silicon Valley Minimalist)
   ========================================================================== */
.cvm-stanford,
.cvm-template-stanford,
.cv-stanford-template {
    padding: 38px 42px;
    background: #ffffff;
    color: #1e293b;
    font-size: 11px;
    line-height: 1.6;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cvm-stanford .header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 22px;
    gap: 20px;
}

.cvm-stanford .name-text {
    font-size: 28px;
    font-weight: 300;
    letter-spacing: -0.5px;
    color: #0f172a;
    margin: 0 0 2px 0;
    line-height: 1.15;
}

.cvm-stanford .name-text strong {
    font-weight: 800;
}

.cvm-stanford .headline-text {
    font-size: 11.5px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #64748b;
    margin: 4px 0 10px 0;
}

.cvm-stanford .sec-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #94a3b8;
    margin-bottom: 12px;
}

/* ==========================================================================
   6. TEMPLATE 3: EDINBURGH (Executive Asymmetrical Two-Column)
   ========================================================================== */
.cvm-edinburgh,
.cvm-template-edinburgh,
.cv-edinburgh-template {
    padding: 32px 34px;
    background: #ffffff;
    color: #1e293b;
    font-size: 11px;
    line-height: 1.5;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cvm-edinburgh .header-area {
    text-align: center;
    border-bottom: 2px solid var(--primary-color, #1E3A5F);
    padding-bottom: 14px;
    margin-bottom: 16px;
}

.cvm-edinburgh .name-text {
    font-size: 26px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #0f172a;
    margin: 0 0 3px 0;
}

.cvm-edinburgh .headline-text {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-color, #1E3A5F);
    margin: 0 0 8px 0;
}

.cvm-edinburgh .two-col-layout {
    display: flex;
    gap: 20px;
    width: 100%;
}

.cvm-edinburgh .main-col {
    width: 65%;
    min-width: 65%;
    max-width: 65%;
}

.cvm-edinburgh .side-col {
    width: 35%;
    min-width: 35%;
    max-width: 35%;
    border-left: 1px solid #e2e8f0;
    padding-left: 18px;
}

/* ==========================================================================
   7. TEMPLATE 4: HARVARD (Classic Academic ATS 100%)
   ========================================================================== */
.cvm-harvard,
.cvm-template-harvard,
.cv-harvard-template {
    padding: 36px 40px;
    background: #ffffff;
    color: #111827;
    font-family: 'Merriweather', Georgia, serif;
    font-size: 11px;
    line-height: 1.6;
    box-sizing: border-box;
    width: 100%;
}

.cvm-harvard header {
    text-align: center;
    border-bottom: 2px solid #111827;
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.cvm-harvard .name-title {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin: 0 0 4px 0;
    color: #111827;
}

.cvm-harvard .sec-title {
    font-size: 11.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border-bottom: 1px solid #d1d5db;
    padding-bottom: 2px;
    margin-bottom: 8px;
    color: #111827;
}

/* ==========================================================================
   8. TEMPLATE 5: CAMBRIDGE (Timeline & Minimal Clean)
   ========================================================================== */
.cvm-cambridge,
.cvm-template-cambridge,
.cv-cambridge-template {
    padding: 32px;
    background: #ffffff;
    color: #1e293b;
    font-size: 11.5px;
    line-height: 1.5;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cvm-cambridge header {
    background: #ecfdf5;
    padding: 18px 22px;
    border-radius: 8px;
    border: 1px solid #a7f3d0;
    margin-bottom: 20px;
}

.cvm-cambridge .sec-header {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #047857;
    border-bottom: 1.5px solid #a7f3d0;
    padding-bottom: 4px;
    margin-bottom: 12px;
}

/* ==========================================================================
   9. TEMPLATE 6: OXFORD (Corporate Boxed Layout)
   ========================================================================== */
.cvm-oxford,
.cvm-template-oxford,
.cv-oxford-template {
    padding: 34px 38px;
    background: #ffffff;
    color: #0f172a;
    font-size: 11.5px;
    line-height: 1.55;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Merriweather', Georgia, serif;
}

.cvm-oxford .top-frame {
    border: 2px solid #0f172a;
    padding: 16px 20px;
    margin-bottom: 20px;
    background: #f8fafc;
}

/* ==========================================================================
   10. TEMPLATE 7: SYDNEY (Ocean Banner 2-Column)
   ========================================================================== */
.cvm-sydney,
.cvm-template-sydney,
.cv-sydney-template {
    background: #ffffff;
    color: #1e293b;
    font-size: 11px;
    line-height: 1.5;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cvm-sydney .header-wrap {
    background: var(--primary-color, #0284C7);
    color: #ffffff;
    padding: 24px 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cvm-sydney .body-wrap {
    padding: 22px 28px;
    display: flex;
    gap: 20px;
}

/* ==========================================================================
   11. TEMPLATE 8: TORONTO (High-Density Compact)
   ========================================================================== */
.cvm-toronto,
.cvm-template-toronto,
.cv-toronto-template {
    padding: 24px 28px;
    background: #ffffff;
    color: #1e293b;
    font-size: 10.5px;
    line-height: 1.45;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ==========================================================================
   12. TEMPLATE 9: WELLINGTON (Vertical Accent Stripe & Modern Timeline)
   ========================================================================== */
.cvm-wellington,
.cvm-template-wellington,
.cv-wellington-template {
    padding: 30px 34px;
    background: #ffffff;
    color: #1e293b;
    font-size: 11px;
    line-height: 1.55;
    box-sizing: border-box;
    width: 100%;
    border-left: 6px solid var(--primary-color, #059669);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ==========================================================================
   13. TEMPLATE 10: KYOTO (Zen Editorial Luxury)
   ========================================================================== */
.cvm-kyoto,
.cvm-template-kyoto,
.cv-kyoto-template {
    padding: 36px 42px;
    background: #ffffff;
    color: #1c1917;
    font-size: 11px;
    line-height: 1.6;
    box-sizing: border-box;
    width: 100%;
    font-family: 'Merriweather', Georgia, serif;
}

.cvm-kyoto header {
    text-align: center;
    border-bottom: 1px solid #e7e5e4;
    padding-bottom: 16px;
    margin-bottom: 22px;
}

/* ==========================================================================
   14. TEMPLATE 11: HEALTHCARE & CLINICAL
   ========================================================================== */
.cvm-healthcare,
.cvm-template-healthcare,
.cv-healthcare-template {
    padding: 32px 36px;
    background: #ffffff;
    color: #1e293b;
    font-size: 11px;
    line-height: 1.5;
    box-sizing: border-box;
    width: 100%;
    border-top: 5px solid #0D9488;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ==========================================================================
   15. TEMPLATE 12: ATS MODERN (Split Column 32% / 68%)
   ========================================================================== */
.ats-resume-template,
.cvm-ats-modern,
.cvm-template-ats-modern {
    width: 100%;
    min-height: 297mm;
    background: #ffffff;
    color: #1e293b;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 11.5px;
    line-height: 1.5;
    box-sizing: border-box;
    display: flex;
    position: relative;
}

.ats-sidebar {
    width: 32%;
    min-width: 32%;
    max-width: 32%;
    background: #f8fafc;
    border-right: 1.5px solid #e2e8f0;
    padding: 24px 18px;
    box-sizing: border-box;
}

.ats-main-content {
    width: 68%;
    min-width: 68%;
    max-width: 68%;
    background: #ffffff;
    padding: 24px 26px;
    box-sizing: border-box;
}

/* ==========================================================================
   16. TEMPLATE 13: MODERN ATLAS & GENERIC CANONICAL FALLBACKS
   ========================================================================== */
.cvm-modern,
.cvm-template-modern {
    padding: 24mm 20mm;
    color: #334155;
    line-height: 1.5;
    font-size: 11.5px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
}

.cvm-compact,
.cvm-template-compact {
    padding: 24px 28px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
    font-size: 11px;
    line-height: 1.45;
}

.cvm-executive,
.cvm-template-executive {
    padding: 32px 36px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
    font-size: 11.5px;
}

.cvm-creative,
.cvm-template-creative {
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
    min-height: 297mm;
}

.cvm-monochrome,
.cvm-template-monochrome {
    padding: 34px 38px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
}

.cvm-academic,
.cvm-template-academic {
    padding: 36px 40px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
}

/* Standardized 94x94 Profile Photo Avatar Across All Templates */
.cvm-profile-photo-wrapper,
.cvm-photo-avatar-wrap {
    width: 94px !important;
    height: 94px !important;
    min-width: 94px !important;
    min-height: 94px !important;
    max-width: 94px !important;
    max-height: 94px !important;
    overflow: hidden !important;
    border-radius: 50% !important;
    flex-shrink: 0 !important;
    display: inline-block !important;
    position: relative !important;
    box-sizing: border-box !important;
    contain: layout paint size !important;
}

.cvm-profile-photo-img,
.cvm-photo-avatar-img {
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    display: block !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}


/**
 * CV Maker Pro - Template 10: ATS Modern (Emaa Warner Graphic Designer Layout)
 * Split-column layout (32% sidebar / 68% main content) with circular framed avatar,
 * progress bars, dot indicators, and high-readability ATS hierarchy.
 */

.ats-resume-template {
    width: 100%;
    min-height: 100%;
    background: #ffffff;
    color: #1e293b;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    font-size: 12px;
    line-height: 1.5;
    box-sizing: border-box;
    display: flex;
    position: relative;
}

.ats-resume-template * {
    box-sizing: border-box;
}

/* Table wrapper for 100% PDF/Dompdf compatibility */
.ats-resume-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

/* Sidebar Column (32% Width) */
.ats-sidebar,
.ats-sidebar-td {
    width: 32%;
    min-width: 32%;
    max-width: 32%;
    vertical-align: top;
    background: #f8fafc;
    border-right: 1.5px solid #e2e8f0;
    padding: 26px 20px;
}

/* Main Content Column (68% Width) */
.ats-main-content,
.ats-main-td {
    width: 68%;
    min-width: 68%;
    max-width: 68%;
    vertical-align: top;
    background: #ffffff;
    padding: 28px 28px;
}

/* Avatar Photo */
.ats-avatar-wrapper {
    text-align: center;
    margin-bottom: 22px;
}

.ats-avatar-wrapper img,
.ats-avatar-img {
    width: 116px;
    height: 116px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #1a1a24;
    display: block;
    margin: 0 auto;
    background: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

/* Section Headings */
.ats-section {
    margin-bottom: 20px;
}

.ats-section:last-child {
    margin-bottom: 0;
}

.ats-section h3 {
    font-size: 12.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #1a1a24;
    margin: 0 0 12px 0;
    padding-bottom: 4px;
    border-bottom: 2px solid #1a1a24;
    line-height: 1.3;
}

/* Contact List */
.ats-contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ats-contact-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #334155;
    margin-bottom: 8px;
    word-break: break-word;
    line-height: 1.4;
}

.ats-contact-icon {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    color: #1a1a24;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

/* Language Indicators */
.ats-languages-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ats-language-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: #334155;
}

.ats-lang-name {
    font-weight: 600;
}

.ats-lang-dots {
    display: flex;
    gap: 4px;
}

.ats-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #cbd5e1;
}

.ats-dot.filled {
    background: #1a1a24;
}

/* Skills Progress Bars & Tag Chips */
.ats-skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ats-skill-tag {
    display: inline-block;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 600;
    color: #1e293b;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    line-height: 1.3;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.ats-skills-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ats-skill-item {
    width: 100%;
}

.ats-skill-header {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 3px;
}

.ats-skill-bar-bg {
    width: 100%;
    height: 5px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
}

.ats-skill-bar-fill {
    height: 100%;
    background: #1a1a24;
    border-radius: 3px;
}

/* Follow Me (Social) */
.ats-social-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ats-social-list li {
    font-size: 11px;
    color: #475569;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 7px;
    word-break: break-word;
}

.ats-social-icon {
    flex-shrink: 0;
    font-size: 11px;
    color: #1a1a24;
}

/* Header Area (Main Content) */
.ats-header {
    margin-bottom: 22px;
    border-bottom: 2.5px solid #1a1a24;
    padding-bottom: 14px;
}

.ats-header h1 {
    font-size: 28px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #1a1a24;
    margin: 0 0 4px 0;
    line-height: 1.15;
}

.ats-header h2 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #64748b;
    margin: 0;
    line-height: 1.2;
}

/* Profile Summary */
.ats-profile-p {
    font-size: 12px;
    line-height: 1.6;
    color: #475569;
    margin: 0;
    text-align: justify;
}

/* Timeline Items (Education & Experience) */
.ats-timeline-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ats-timeline-item {
    position: relative;
}

.ats-timeline-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 3px;
    flex-wrap: wrap;
    gap: 4px;
}

.ats-timeline-title {
    font-size: 13px;
    font-weight: 700;
    color: #0f172a;
}

.ats-timeline-company {
    font-size: 11.5px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 4px;
}

.ats-timeline-date {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #475569;
    background: #f1f5f9;
    padding: 2px 7px;
    border-radius: 3px;
}

.ats-timeline-desc {
    font-size: 11.5px;
    line-height: 1.55;
    color: #475569;
    margin: 0;
}

/* Print & PDF Media Rules */
@media print {
    .ats-resume-template {
        box-shadow: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }
}


/**
 * CV Maker - PDF Templates Stylesheet
 * 
 * Provides unified styling for Dompdf / mPDF and clean A4 print preview.
 * Ensures 100% table and block layout fidelity.
 */

@page {
    size: A4 portrait;
    margin: 15mm 15mm 15mm 15mm;
}

body {
    margin: 0;
    padding: 0;
    background: #ffffff;
    font-size: 12px;
    line-height: 1.5;
    color: #1e293b;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}

.cvm-a4-page {
    width: 100%;
    max-width: 210mm;
    min-height: 297mm;
    margin: 0 auto;
    box-sizing: border-box;
    background: #ffffff;
}

/* MODERN TWO-COLUMN TEMPLATE STYLES */
.cvm-modern {
    padding: 20mm;
    color: #334155;
    line-height: 1.5;
    font-size: 12px;
    box-sizing: border-box;
    background: #ffffff;
    width: 100%;
}
.cvm-modern .header-table {
    width: 100%;
    border-collapse: collapse;
    border-bottom: 2.5px solid var(--primary, #2563eb);
    padding-bottom: 16px;
    margin-bottom: 18px;
}
.cvm-modern .header-photo-td {
    width: 80px;
    vertical-align: middle;
    padding-right: 16px;
}
.cvm-modern .photo-img {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    object-fit: cover;
    border: 2.5px solid var(--primary, #2563eb);
    display: block;
}
.cvm-modern .full-name {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--secondary, #1e293b);
    margin: 0;
    line-height: 1.2;
}
.cvm-modern .headline {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--primary, #2563eb);
    margin-top: 4px;
}
.cvm-modern .layout-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 6px;
}
.cvm-modern .left-column {
    width: 66%;
    vertical-align: top;
    padding-right: 20px;
}
.cvm-modern .right-column {
    width: 34%;
    vertical-align: top;
    border-left: 1px solid #e2e8f0;
    padding-left: 20px;
}
