/* ===================================================
   ToolCanvas — Experience Resume Templates Shared Styles
   =================================================== */

/* ---------- CSS Reset & Base ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #f1f5f9;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1a1a1a;
    padding-top: 60px; /* Space for the floating control bar */
    -webkit-text-size-adjust: none;
    -moz-text-size-adjust: none;
    -ms-text-size-adjust: none;
    text-size-adjust: none;
}

/* ---------- Floating Controls Toolbar ---------- */
.floating-control-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #dadce0;
}

.control-logo {
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
}

.control-logo span {
    color: #2563eb;
}

/* Zoom Controls */
.control-zoom {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: #f1f3f4;
    padding: 4px 8px;
    border-radius: 8px;
}

.btn-zoom {
    background: none;
    border: none;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    color: #5f6368;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.15s;
}

.btn-zoom:hover {
    background-color: #e8eaed;
}

.zoom-level {
    font-size: 13px;
    font-weight: 500;
    color: #3c4043;
    min-width: 65px;
    text-align: center;
    font-family: sans-serif;
}

.btn-zoom-text {
    background: none;
    border: none;
    padding: 4px 8px;
    font-size: 13px;
    font-weight: 500;
    color: #5f6368;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.15s;
}

.btn-zoom-text:hover {
    background-color: #e8eaed;
}

.control-actions {
    display: flex;
    gap: 12px;
}

.btn-control-back {
    background-color: transparent;
    border: 1px solid #dadce0;
    color: #5f6368;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.15s, color 0.15s;
}

.btn-control-back:hover {
    background-color: #f1f3f4;
    color: #3c4043;
}

.btn-control-download {
    background-color: #1a73e8;
    border: none;
    color: #ffffff;
    padding: 8px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.15s;
}

.btn-control-download:hover {
    background-color: #1557b0;
}

/* ---------- Printable Resume Sheet Layout ---------- */
.resume-paper-wrapper {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 30px 15px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Standard US Letter Page size: 8.5 x 11 inches */
.resume-sheet {
    background-color: #ffffff;
    width: 8.5in;
    height: 11in;
    min-height: 11in;
    padding: 0.5in 0.6in;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Standard structure segments */
.resume-section {
    margin-top: 14px;
}

.resume-section-title {
    font-size: 11pt;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid #1a1a1a;
    padding-bottom: 2px;
    margin-bottom: 8px;
}

/* Work Experience Card Items */
.job-item, .edu-item {
    margin-bottom: 10px;
}

.job-item:last-child, .edu-item:last-child {
    margin-bottom: 0;
}

.item-header-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-weight: 700;
    font-size: 10pt;
}

.item-subheader-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 9.5pt;
    font-style: italic;
    color: #4b5563;
    margin-bottom: 4px;
}

.item-dates, .item-location {
    font-weight: 500;
    font-size: 9.5pt;
    font-style: normal;
    color: #1a1a1a;
}

.item-bullets {
    list-style-type: disc;
    margin-left: 16px;
    font-size: 9pt;
    line-height: 1.4;
    color: #2d3748;
}

.item-bullets li {
    margin-bottom: 2px;
}

/* ---------- PRINT STYLING ---------- */
@media print {
    /* Hide floating tools */
    body {
        background-color: #ffffff;
        padding-top: 0;
    }
    
    .floating-control-bar {
        display: none !important;
    }
    
    .resume-paper-wrapper {
        padding: 0;
    }
    
    .resume-sheet {
        width: 8.5in !important;
        height: 11in !important;
        min-height: 11in !important;
        padding: 0.5in 0.6in !important;
        box-shadow: none !important;
        overflow: visible !important;
    }
    
    /* Document page configuration - margin 0 removes default browser URL headers/footers */
    @page {
        size: letter;
        margin: 0 !important;
    }
    
    /* Prevent page breakdown errors */
    .resume-section {
        page-break-inside: avoid;
        break-inside: avoid;
    }
    
    .job-item, .edu-item {
        page-break-inside: avoid;
        break-inside: avoid;
    }
}

@media (max-width: 820px) {
    body {
        padding-top: 52px;
    }

    .resume-sheet {
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05) !important;
        border-radius: 8px;
        max-height: 999999px;
    }
    
    .resume-sheet * {
        max-height: 999999px;
    }
    
    .resume-paper-wrapper {
        padding: 12px 6px;
    }

    .floating-control-bar {
        padding: 0 8px;
        height: 52px;
    }

    .control-logo {
        display: none !important;
    }

    .control-zoom {
        gap: 2px;
        padding: 2px 4px;
    }

    .btn-zoom {
        width: 24px;
        height: 24px;
        font-size: 16px;
    }

    .zoom-level {
        font-size: 11px;
        min-width: 50px;
    }

    .btn-zoom-text {
        padding: 2px 4px;
        font-size: 11px;
    }

    .hide-mobile {
        display: none !important;
    }

    .btn-control-back, .btn-control-download {
        padding: 6px 10px;
        font-size: 11px;
    }
}
