* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: #f8f9fa;
    color: #343a40;
    line-height: 1.6;
    padding-bottom: 120px;
}

.container {
    width: 80%;
    margin: 30px auto 50px auto;
    padding: 20px;
    text-align: center;
}

h1 {
    color: #0056b3;
    margin-bottom: 30px;
    font-weight: 600;
}

h2 {
    color: #495057;
    margin: 15px 0;
    font-size: 1.2em;
    text-align: center;
}

.main-header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    margin-bottom: 40px;
}
.main-header h1 {
    margin-bottom: 5px;
}

#open-download-sidebar-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1100;

    padding: 8px 12px;
    font-size: 14px;
    background-color: #6c757d;
    border: 1px solid #6c757d;
    color: #ffffff;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s, opacity 0.4s, border-color 0.3s;
    opacity: 1;
}
#open-download-sidebar-btn:hover {
    background-color: #5a6268;
    border-color: #545b62;
}
#open-download-sidebar-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

.sidebar {
    position: fixed; right: 0; top: 0; width: 300px; height: 100%;
    background-color: #f8f9fa;
    padding: 20px; padding-top: 50px;
    box-shadow: -3px 0 6px rgba(0, 0, 0, 0.1);
    box-sizing: border-box; z-index: 1300;
    display: flex; flex-direction: column; align-items: stretch; overflow-y: auto;
    transform: translateX(100%); transition: transform 0.4s ease-in-out;
}
.sidebar.open { transform: translateX(0%); }
.sidebar h2 { margin-top: 0; margin-bottom: 25px; font-size: 1.2em; color: #495057; }

.sidebar .download-btn {
    display: block;
    background-color: #007bff;
    border: 1px solid #007bff;
    color: #ffffff;
    padding: 10px 15px; margin-bottom: 15px; cursor: pointer;
    font-size: 14px; width: 100%; box-sizing: border-box;
    transition: background-color 0.3s, border-color 0.3s; text-align: center; border-radius: 4px;
}
.sidebar .download-btn:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.sidebar .dimension-input-container { margin-bottom: 15px; width: 100%; display: flex; flex-direction: column; }
.sidebar .dimension-input-container button { border-bottom-left-radius: 0; border-bottom-right-radius: 0; margin-bottom: 0; border-bottom: none; }
.sidebar .dimension-input-container input { border-top-left-radius: 0; border-top-right-radius: 0; padding: 10px; font-size: 14px; border: 1px solid #ced4da; }

.sidebar .sidebar-close-btn {
    position: absolute; top: 10px; right: 10px; background: none; border: none;
    font-size: 24px; font-weight: bold; color: #6c757d;
    cursor: pointer; line-height: 1; padding: 5px; transition: color 0.2s;
}
.sidebar .sidebar-close-btn:hover { color: #343a40; }
.sidebar .download-note { font-size: 0.8em; color: #6c757d; text-align: center; margin-top: auto; padding-top: 15px; }

.back-btn {
    position: fixed; top: 20px; left: 20px;
    background-color: #6c757d;
    border: 1px solid #6c757d;
    color: #ffffff;
    padding: 10px 20px; cursor: pointer; font-size: 16px;
    transition: background-color 0.3s, border-color 0.3s; text-decoration: none; border-radius: 4px;
}
.back-btn:hover {
    background-color: #5a6268;
    border-color: #545b62;
}

#info-summary-table-container {
    max-width: 600px; margin: 15px auto 25px auto;
    background-color: #ffffff;
    border: 1px solid #dee2e6;
    border-radius: 5px; padding: 10px 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
#info-summary-table { width: 100%; border-collapse: collapse; font-size: 14px; }
#info-summary-table th, #info-summary-table td { border-bottom: 1px solid #e9ecef; padding: 6px 8px; text-align: left; vertical-align: top; }
#info-summary-table th { font-weight: bold; color: #495057; width: 120px; white-space: nowrap; }
#info-summary-table td { color: #343a40; }
#info-summary-table tr:last-child th, #info-summary-table tr:last-child td { border-bottom: none; }
#info-summary-table .info-header td, #info-summary-table .counts-header td {
    font-weight: bold; text-align: center; padding-top: 12px; padding-bottom: 8px;
    color: #495057;
    background-color: #e9ecef;
    border-bottom: 1px solid #dee2e6;
    border-top: 1px solid #dee2e6;
}
#info-summary-table tr:first-child.info-header td { border-top: none; }
#info-summary-table tr:last-child.counts-header td { border-bottom: none; }

.filter-buttons-container {
    text-align: center; margin-bottom: 15px; padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}
.filter-btn {
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    color: #495057;
    padding: 8px 15px; margin: 5px 5px; cursor: pointer; border-radius: 4px;
    font-size: 14px; transition: background-color 0.3s, box-shadow 0.3s, border-color 0.3s, color 0.3s; display: inline-block;
}
.filter-btn:hover {
    background-color: #dee2e6;
    border-color: #ced4da;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.filter-btn.active {
    background-color: #b0c4de;
    color: #fff;
    font-weight: bold;
    border-color: #9cb2cc;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.15);
}

.dimension-title-display {
    text-align: center;
    margin-top: 0;
    margin-bottom: 10px;
    color: #495057;
    font-size: 1.4em;
    font-weight: normal;
}

.dimension-description-text {
    text-align: center;
    font-size: 0.95em;
    color: #5a6268;
    margin-top: 0;
    margin-bottom: 25px;
    padding: 0 20px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
    font-style: italic;
}

.indicator-subtitle {
    grid-column: 1 / -1;
    font-size: 1.2em;
    font-weight: bold;
    color: #343a40;
    background-color: #e8f0fe;
    padding: 8px 15px;
    margin-top: 25px;
    margin-bottom: 0px;
    border-left: 5px solid #b0c4de;
    border-radius: 3px;
    text-align: center;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.grid-container > .indicator-subtitle:first-child {
    margin-top: 10px;
}

.indicator-description-text {
    grid-column: 1 / -1;
    text-align: center;
    font-size: 0.9em;
    color: #6c757d;
    margin-top: 0;
    margin-bottom: 15px;
    padding: 0 25px;
    max-width: 750px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.4;
}

.grid-container > .indicator-subtitle:first-of-type,
.grid-container > .indicator-description-text:first-of-type {
    margin-top: 10px;
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #e9ecef;
    border-top: 1px solid #ced4da;
    padding: 10px 20px;
    text-align: center;
    font-size: 0.8em;
    color: #6c757d;
    z-index: 1200;
    line-height: 1.4;
}
footer p { margin: 0; }
footer strong { color: #495057; }
footer a { color: #0056b3; }

.help-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #5a6268;
    color: white;
    font-size: 13px;
    cursor: help;
    margin-left: 5px;
    vertical-align: middle;
    user-select: none;
    transition: background-color 0.2s;
}
.help-icon:hover {
    background-color: #495057;
}
.help-icon i {
    margin: 0;
    font-size: 1em;
    line-height: 1;
    display: block;
}

.help-tooltip {
    position: absolute;
    background-color: #343a40;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 0.85em;
    max-width: 250px;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    z-index: 1500 !important;
    pointer-events: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    justify-items: center;
    margin-top: 20px;
}

.square {
    position: relative; width: 100%; max-width: 600px; height: 700px;
    border: 1px solid #dee2e6;
    background-color: #ffffff;
    display: flex; flex-direction: column; justify-content: flex-start; align-items: stretch;
    overflow: hidden; transition: box-shadow 0.3s ease; padding: 5px; box-sizing: border-box;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.square:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.chart-wrapper {
    flex-grow: 1; flex-shrink: 1; min-height: 400px;
    position: relative; width: 100%; box-sizing: border-box;
    transition: height 0.4s ease-out, flex-grow 0.4s ease-out;
    overflow: hidden;
}
.chart-wrapper canvas { max-width: 100%; max-height: 100%; display: block; }

.perguntas-separator {
    height: 25px; background-color: #e9ecef;
    width: 100%; display: flex; justify-content: flex-end; align-items: center;
    cursor: pointer; border-top: 1px solid #dee2e6; border-bottom: 1px solid #dee2e6;
    box-sizing: border-box; flex-shrink: 0;
}
.collapse-perguntas-btn {
    background: none; border: none; font-size: 16px; font-weight: bold;
    cursor: pointer; padding: 0 10px; line-height: 1; color: #6c757d;
    transition: transform 0.3s ease;
}
.collapse-perguntas-btn.collapsed { transform: rotate(180deg); }

.perguntas-table-wrapper {
    width: 100%; max-height: 200px; overflow-y: auto; overflow-x: hidden;
    border: 1px solid #dee2e6; border-top: none;
    background-color: #f8f9fa;
    transition: max-height 0.4s ease-out, opacity 0.4s ease-out, padding 0.4s ease-out, border 0.4s ease-out;
    position: relative;
    padding: 0px; box-sizing: border-box; flex-shrink: 0;
}
.perguntas-table-wrapper table { width: 100%; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
.perguntas-table-wrapper th, .perguntas-table-wrapper td {
    border: 1px solid #e0e0e0; padding: 6px; text-align: left;
    vertical-align: top; word-break: break-word; overflow: hidden;
}
.perguntas-table-wrapper th { background-color: #e9ecef; font-weight: bold; }
.perguntas-table-wrapper td:first-child { font-weight: bold; background-color: #f8f9fa; }
.perguntas-table-wrapper.collapsed { max-height: 0; border-width: 0 1px; opacity: 0; overflow: hidden; padding-top: 0; padding-bottom: 0; }

.square.capture-full-content { height: auto !important; overflow: visible !important; }
.square.capture-full-content .perguntas-table-wrapper,
.square.capture-full-content div[id^="tableContainer_"] { max-height: none !important; overflow: visible !important; height: auto !important; }

.edit-chart-btn, .edit-perguntas-btn {
    display: none;
    position: absolute;
    bottom: 5px; left: 50%; transform: translateX(-50%);
    background-color: rgba(108, 117, 125, 0.8);
    border: 1px solid rgba(108, 117, 125, 0.6);
    color: #ffffff; padding: 4px 8px; font-size: 13px; cursor: pointer; z-index: 10; border-radius: 3px;
    transition: background-color 0.2s, border-color 0.2s;
}
.edit-perguntas-btn {
    position: sticky;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 123, 255, 0.7); border-color: rgba(0, 123, 255, 0.5);
    z-index: 15;
    width: fit-content;
    margin: 0 auto;
}

.edit-chart-btn:hover { background-color: #5a6268; border-color: #545b62; }
.edit-perguntas-btn:hover { background-color: #0056b3; border-color: #0056b3; }

.chart-wrapper:hover .edit-chart-btn { display: block; }
.perguntas-table-wrapper:hover .edit-perguntas-btn { display: block; }

.modal-overlay.modal-component {
    display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(52, 58, 64, 0.75);
    z-index: 1450; padding: 0px; overflow-y: auto;
}
.edit-modal {
    background: #ffffff;
    border-radius: 8px; max-width: 1200px; width: 100%;
    margin: 30px auto;
    display: flex; flex-wrap: wrap; gap: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.edit-modal .graph-container {
    flex: 2 1 auto;
    max-width: 600px;
    width: 60%;
    height: 700px;

    position: relative;
    padding: 5px;
    background: #f8f9fa;
    border-radius: 4px;
    min-width: 350px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.edit-modal .graph-container canvas { max-height: 100%; display: block; }

.edit-modal .settings-container {
    flex: 1 1 300px; padding: 10px;
    border-left: 1px solid #dee2e6;
    overflow-y: auto;
    min-width: 250px;
    max-height: 680px;
}
.settings-container h3 { margin-top: 0; text-align: center; font-size: 18px; margin-bottom: 15px; color: #495057; }
.settings-group { margin-bottom: 12px; }
.settings-group label { display: block; margin-bottom: 5px; font-weight: 500; font-size: 14px; color: #495057; }
.settings-group input, .settings-group select { width: 100%; padding: 8px; font-size: 14px; box-sizing: border-box; border: 1px solid #ced4da; border-radius: 3px; }
.settings-group input[type="color"] { padding: 2px; height: 35px; }
.settings-group input[type="checkbox"] { width: auto; margin-right: 5px; }
.settings-group .help-icon { font-size: 11px; width: 15px; height: 15px; line-height: 15px; background-color: #adb5bd; }
.settings-group > label { display: flex; align-items: center; gap: 3px; }
.settings-group.group-settings-container { padding: 10px; border: 1px solid #e9ecef; border-radius: 4px; background: #f8f9fa; }
.settings-group.group-settings-container h4 { font-size: 14px; margin-bottom: 8px; text-align: center; border-bottom: 1px solid #dee2e6; padding-bottom: 5px; color: #495057; }
.group-color-item { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.group-color-item span { flex-basis: 100px; font-size: 13px; color: #495057; }
.group-color-item input[type="color"] { flex-grow: 1; }

#toggle-additional-btn, #teia-toggle-additional-btn, #toggle-additional-perguntas-btn,
#toggle-additional-table-btn {
    width: 100%; background: #e9ecef; border: 1px solid #ced4da; color: #495057; padding: 6px; font-size: 13px; cursor: pointer; border-radius: 3px; margin-top: 5px;
}
#toggle-additional-btn:hover, #teia-toggle-additional-btn:hover, #toggle-additional-perguntas-btn:hover,
#toggle-additional-table-btn:hover { background: #dee2e6; }
#toggle-additional-btn-hide, #teia-toggle-additional-btn-hide, #toggle-additional-perguntas-btn-hide,
#toggle-additional-table-btn-hide {
    width: 100%; background: #e9ecef; border: 1px solid #ced4da; color: #495057; padding: 6px; font-size: 13px; cursor: pointer; border-radius: 3px; margin-top: 10px;
}
#toggle-additional-btn-hide:hover, #teia-toggle-additional-btn-hide:hover, #toggle-additional-perguntas-btn-hide:hover,
#toggle-additional-table-btn-hide:hover { background: #dee2e6; }

.settings-buttons { margin-top: 20px; text-align: center; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.settings-buttons button, .settings-buttons .btn-group { margin: 5px; }
.btn-group { display: inline-flex; align-items: center; border: 1px solid #ced4da; border-radius: 4px; overflow: hidden; }
.btn-group button { border: none; background-color: #6c757d; color: white; padding: 8px 12px; cursor: pointer; font-size: 14px; border-right: 1px solid #ced4da; transition: background-color 0.2s; }
.btn-group button:last-child { border-right: none; }
.btn-group select { border: none; padding: 8px 6px; font-size: 14px; outline: none; background-color: #ffffff; cursor: pointer; color: #495057; }
#close-edit-btn, #teia-close-edit-btn, #close-perguntas-edit-btn, #close-table-edit-btn { background-color: #dc3545; color: white; border: 1px solid #dc3545; padding: 8px 15px; border-radius: 4px; font-size: 14px; cursor: pointer; transition: background-color 0.2s; }
#close-edit-btn:hover, #teia-close-edit-btn:hover, #close-perguntas-edit-btn:hover, #close-table-edit-btn:hover { background-color: #c82333; border-color: #bd2130; }
.btn-group button:hover { background-color: #5a6268; }


.square.special-teia-double-height { height: 1400px; min-height: 1200px; display: flex; flex-direction: column; justify-content: flex-start; position: relative; }

.square.special-teia-double-height .teia-pair-category-title { flex-shrink: 0; text-align: center; font-weight: bold; padding: 12px 8px 8px 8px; margin: 0; background-color: #e9ecef; border-bottom: 1px solid #dee2e6; font-size: 1.1em; color: #495057; box-sizing: border-box; }

.square.special-teia-double-height .category-charts-row { display: flex; flex-direction: column; flex-grow: 1; width: 100%; overflow: hidden; box-sizing: border-box; padding: 5px 0; position: relative; }

.square.special-teia-double-height .chart-wrapper.sub-chart { flex-grow: 1; flex-shrink: 1; flex-basis: 45%; min-height: 450px; width: 100%; position: relative; box-sizing: border-box; border-bottom: 1px dashed #e0e0e0; padding: 5px; margin-bottom: 5px; overflow: hidden; }
.square.special-teia-double-height .category-charts-row .chart-wrapper.sub-chart:last-child { border-bottom: none; margin-bottom: 0; }

.square.special-teia-double-height .sub-chart-placeholder, .square.special-teia-double-height .sub-chart-placeholder-text { flex-grow: 1; flex-basis: 45%; min-height: 200px; display: flex; justify-content: center; align-items: center; text-align: center; color: #999; font-style: italic; border: 1px dashed #ccc; margin: 10px 5px; box-sizing: border-box; background-color: #fafafa; padding: 10px; }
.square.special-teia-double-height .sub-chart-placeholder-text { border: none; margin: 0; background: none; }

.square.special-teia-double-height .edit-pair-btn.edit-chart-btn { display: none; position: absolute; bottom: 5px; left: 50%; transform: translateX(-50%); background-color: rgba(108, 117, 125, 0.8); border: 1px solid rgba(108, 117, 125, 0.6); color: #ffffff; padding: 4px 8px; font-size: 13px; cursor: pointer; z-index: 10; border-radius: 3px; transition: background-color 0.2s, border-color 0.2s; }
.square.special-teia-double-height .edit-pair-btn.edit-chart-btn:hover { background-color: #5a6268; border-color: #545b62; }
.square.special-teia-double-height:hover .edit-pair-btn.edit-chart-btn { display: block; }

.square.special-teia-double-height .perguntas-separator { flex-shrink: 0; height: 25px; background-color: #e9ecef; width: 100%; display: flex; justify-content: flex-end; align-items: center; cursor: pointer; border-top: 1px solid #dee2e6; border-bottom: 1px solid #dee2e6; box-sizing: border-box; }
.square.special-teia-double-height .perguntas-separator .collapse-perguntas-btn { background: none; border: none; font-size: 16px; font-weight: bold; cursor: pointer; padding: 0 10px; line-height: 1; color: #6c757d; transition: transform 0.3s ease; }
.square.special-teia-double-height .perguntas-separator .collapse-perguntas-btn.collapsed { transform: rotate(180deg); }
.square.special-teia-double-height .perguntas-table-wrapper { max-height: 250px; height: auto; flex-shrink: 0; width: 100%; overflow-y: auto; overflow-x: hidden; border: 1px solid #dee2e6; border-top: none; background-color: #f8f9fa; transition: max-height 0.4s ease-out, opacity 0.4s ease-out, padding 0.4s ease-out, border 0.4s ease-out; position: relative; padding: 0px; box-sizing: border-box; }
.square.special-teia-double-height .perguntas-table-wrapper table { width: 100%; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
.square.special-teia-double-height .perguntas-table-wrapper th, .square.special-teia-double-height .perguntas-table-wrapper td { border: 1px solid #e0e0e0; padding: 6px; text-align: left; vertical-align: top; word-break: break-word; overflow: hidden; }
.square.special-teia-double-height .perguntas-table-wrapper th { background-color: #e9ecef; font-weight: bold; }
.square.special-teia-double-height .perguntas-table-wrapper td:first-child { font-weight: bold; background-color: #f8f9fa; }
.square.special-teia-double-height .perguntas-table-wrapper.collapsed { max-height: 0; border-width: 0 1px; opacity: 0; overflow: hidden; padding-top: 0; padding-bottom: 0; }
.square.special-teia-double-height .perguntas-table-wrapper .edit-perguntas-btn { display: none; position: sticky; bottom: 5px; left: 50%; transform: translateX(-50%); width: fit-content; margin: 5px auto; z-index: 15; background-color: rgba(0, 123, 255, 0.7); border: 1px solid rgba(0, 123, 255, 0.5); color: #ffffff; padding: 4px 8px; font-size: 13px; cursor: pointer; border-radius: 3px; transition: background-color 0.2s, border-color 0.2s; }
.square.special-teia-double-height .perguntas-table-wrapper:hover .edit-perguntas-btn { display: block; }
.square.special-teia-double-height .perguntas-table-wrapper .edit-perguntas-btn:hover { background-color: #0056b3; border-color: #0056b3; }
.no-perguntas-msg { text-align:center; font-size:0.8em; color:#777; padding:10px; }

.edit-modal .graph-container.special-pair-preview { display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; height: auto; min-height: 550px; }
.edit-modal .graph-container.special-pair-preview canvas { min-height: 250px; max-height: 45vh; width: 100% !important; flex-shrink: 0; margin-bottom: 10px; }
.edit-modal .graph-container.special-pair-preview canvas#modalTeiaCanvasB { margin-bottom: 0; }
.edit-modal .graph-container.special-pair-preview hr.preview-separator { width: 80%; margin: 0 auto 10px auto; border: none; border-top: 1px dashed #ccc; }

#profile-section-title {
    text-align: center;
    font-size: 1.4em;
    font-weight: bold;
    color: #495057;
    margin-top: 30px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
}

#profile-charts-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
    padding: 0 10px;
}

@media (max-width: 900px) {
    #profile-charts-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    #profile-charts-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    .square.profile-pie-square {
        max-width: 90%;
        height: 250px;
    }
}

.square.profile-pie-square {
    height: 300px;
    max-width: 280px;
    padding: 5px;
    justify-self: center;
    min-height: auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.profile-pie-square .pie-chart-title {
    font-size: 12px;
    font-weight: bold;
    color: #333333;
    text-align: center;
    margin: 5px 5px 5px 5px;
    padding-bottom: 5px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
    word-wrap: break-word;
}

.profile-pie-square .chart-wrapper {
    min-height: 0;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0 5px 5px 5px;
    box-sizing: border-box;
}

.profile-pie-square .chart-wrapper canvas {
    max-width: 100%;
    max-height: 100%;
}

.profile-pie-square .edit-chart-btn {
    display: none !important;
}

.profile-pie-square .perguntas-separator,
.profile-pie-square .perguntas-table-wrapper {
    display: none !important;
}

.download-instruction {
    font-size: 0.9em;
    color: #6c757d;
    margin-bottom: 30px;
    text-align: center;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.tutorial-instruction {
    font-size: 0.9em;
    color: #383636;
    margin-top: 0px;
    margin-bottom: 0px;
    text-align: center;
}
.tutorial-instruction a {
    color: #007bff;
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px dotted #007bff;
    padding-bottom: 1px;
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
}
.tutorial-instruction a:hover {
    color: #0056b3;
}

.tutorial-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1500;
    justify-content: center;
    align-items: center;
}

.tutorial-modal-content {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.tutorial-modal-content .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.tutorial-modal-content .modal-header h2 {
    margin: 0;
    font-size: 1.25rem;
    color: #343a40;
}

.tutorial-modal-content .btn-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: #6c757d;
    opacity: 0.7;
    padding: 5px;
    cursor: pointer;
}
.tutorial-modal-content .btn-close:hover {
    opacity: 1;
    color: #000;
}

.tutorial-video-body {
    padding: 20px;
}

.video-player-container {
    width: 100%;
    background-color: #000;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

#tutorial-video-player {
    display: block;
    max-height: 70vh;
    width: 100%;
    opacity: 1;
    transition: opacity 0.3s ease-in-out;
}

.tutorial-video-navigation {
    display: flex;
    justify-content: space-between;
    padding: 15px 20px;
    border-top: 1px solid #dee2e6;
    background-color: #f8f9fa;
}

.tutorial-video-navigation.next-only {
    justify-content: flex-end;
}
.tutorial-video-navigation.prev-only {
    justify-content: flex-start;
}

#tutorial-video-player.video-transitioning {
    opacity: 0;
}

.btn {
    display: inline-block;
    font-weight: 500;
    text-align: center;
    vertical-align: middle;
    user-select: none;
    background-color: transparent;
    border: 1px solid transparent;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    line-height: 1.5;
    border-radius: 0.25rem;
    transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    cursor: pointer;
}
.btn i {
    margin-right: 5px;
}
.btn-secondary {
    color: #fff;
    background-color: #6c757d;
    border-color: #6c757d;
}
.btn-secondary:hover {
    background-color: #5a6268;
    border-color: #545b62;
}
.tutorial-video-navigation .btn i {
    margin-left: 0;
    margin-right: 5px;
}
.tutorial-video-navigation #next-tutorial-video i {
    margin-left: 5px;
    margin-right: 0;
}