:root {
    --header-height: 100px;
    --primary-color: #0c4877;
    --secondary-color: #00adc3;
}

* {
    font-family: montserrat;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-flow: column;
    align-items: center;
    background-color: #f0f0ee;
    margin: 0;
}

header {
    width: 100%;
    height: var(--header-height);
    background-color: var(--primary-color);
    margin: 0;
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    justify-content: center;
    padding: 10px 0px 5px 0px;
}

header > div {
    display: flex;
    justify-content: center;
    align-items: center;
}

header > div#icon-container {
    justify-content: left;
}

header > div#icon-container > a {
    width: 100%;
    height: 100%;
}

header > div#third-header-block {
    justify-content: right;
}

span#page-header-text {
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
}

.brand-image {
    height: var(--header-height);
    display: block;
    object-fit: scale-down;
}

.spark-header {
    display: flex;
    justify-content: space-between;
}

.rating-begin-btn {
    margin-right: 20px;
    padding: 10px;
    color: black;
    background-color: white;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
}

.spark-grading-scale {
    width: 70%;
    display: block;
}

.spark-grading-scale span {
    font-weight: bold;
}

table.grading-scale-table {
  table-layout: fixed;
  width: 90%;
  margin: 10px auto;
  border-collapse: collapse;
  border-top: 1px solid black;
  font-size: 14px;
  display: none;
}

.grading-scale-table th,
.grading-scale-table td {
  padding: 0.6em 1em;
}

.grading-scale-table tr {
    border-bottom: 1px solid lightgray;
}

caption {
  padding: 0.5em;
  background-color: lightgray;
}

main {
    width: 100%;
    display: grid;
    grid-template-columns: 275px auto;
    height: calc(100vh - var(--header-height) - 15px);
}

nav {
    background-color: var(--primary-color);
}

nav > a {
    text-decoration: none;
}

nav > a > div.nav-link {
    color: white;
    width: 100%;
    text-indent: 35px;
    padding: 10px 0px;
}

nav > a > div.nav-link:hover, nav > a > div.selected {
    background-color: #07385d !important;
    cursor: pointer;
}

#performance-search-box {
    width: 250px;
    border-radius: 50px;
    padding: 5px;
    border-color: var(--primary-color);
    margin: 10px 0px;
}

.timing-btn {
    background-color: transparent;
    cursor: pointer;
    border: none;
    color: var(--primary-color);
    font-weight: bold;
    font-size: 17px;
    padding: 0px 5px;
}

#main-content {
    display: flex;
    align-items: center;
    flex-direction: column;
    /*justify-content: center;*/
    /*width: 80%;*/
    border-radius: 6px;
    background-color: #ffffff;
    padding: 2rem;
    /*margin: 2em;*/
    max-height: calc(100vh - var(--header-height) - 4rem);
    overflow: scroll;
}

#main-content > h1 {
    margin-top: 0;
}

#main-content > div {
    width: 100%;
}

.spark-card {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #555;
    border-radius: 20px;
    background: #fff;
    margin: 1rem 0rem;
    flex-direction: column;
}

.spark-card-details {
    display: grid;
    grid-template-columns: 1fr 1fr 2fr;
}
.spark-card-details > div {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-flow: column;
}

.spark-comment-header {
    font-size: 20px;
}

.spark-card-comments {
    display: flex;
    flex-flow: column;
    font-size: 14px;
}

.spark-comment {
    padding: 10px;
    display: flex;
    flex-flow: column;
    background-color: #ededed;
    border-bottom: 4px solid #fafafa;
}

.spark-comment-input-container {
    padding: 10px;
    background-color: #ededed;
}

.spark-comment-input {
    width: 100%;
}

.spark-comment-user {
    font-size: 14px;
    font-weight: 600;
}

.spark-comment-date {
    color: gray;
    font-size: 13px;
}

.spark-comment-text {
    margin-top: 7px;
}

.spark-card-placement-details {
    display: flex;
    flex-flow: column;
}

.spark-card-performance {
    padding-left: 1rem;
    align-items: end !important;
}

.placement-score {
    display: flex;
    flex-flow: column;
    align-items: center;
    width: 8rem;
    margin-top: 7px;
}

.placement-score-label {
    text-align: center;
}

.placement-score-value {
    font-size: 32px;
}

.spark-table {
    display: table;
    width: 100%;
}

.spark-table th {
    text-align: left;
}

.spark-table td {
    color: #777;
    font-size: 14px;
    /*padding: 7px 0px;*/
}

.spark-table tr {
    height: 32px;
}

.spark-table tr td:first-child, .spark-table tr th:first-child{
    width: 115px;
}

.spark-ph-performance-header {
    width: 200px;
}

.spark-ph-breakdown-header {
    width: 44px;
}

.spark-inline-comment-container {
    display: flex;
    justify-content: space-between;
}

.spark-inline-comment {
    width: 75%;
    /*line-height: 1;*/
    border-radius: 10px;
    border: 1px solid gray;
    padding-left: 5px;
    font-size: 14px;
    margin-bottom: 5px;
    resize: none;
}

.spark-comment-showmore {
    width: 25%;
    font-size: 12px;
    line-height: 2;
    color: #00adc3;
    cursor: pointer;
    text-align: center;
}

.placement-image {
    width: 4em;
    height: 4em;
    background-color: #e4e6e7;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    margin-bottom: 10px;
}

.placement-initials {
    font-size: 2em;
    font-weight: bold;
}

.placement-name {
    font-size: 20px;
    font-weight: bold;
}

.spark-performance-select {
    background-color: #eceded;
    color: #666;
    border: none;
    /*border-bottom: 2px solid gray;*/
    width: 100%;
    font-size: 14px;
    padding: 7px 0px;
    padding-left: 10px;
    cursor: pointer;
    border-radius: 50px;
    height: 33px;
}

.spark-save-btn {
    float: right;
}

.muted {
    font-size: 14px;
    color: gray;
}

.company-card {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    margin: 1rem 0rem;
    text-decoration: none;
    color: black;
    line-height: 100%;
}

.company-name {
    font-size: 18px;
    font-weight: bold;
}

#login-form-container {
  border: 1px solid black !important;
  border-radius: 5px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 25px;
  width: 500px !important;
}

#login-form>table>tbody>tr>td>label {
  font-size: 16px;
}

#login-form>table>tbody>tr>td>input {
  width: 200px;
  margin-left: 10px;
  font-size: 16px;
  padding: 5px;
  width: 375px;
}

.login-hint {
  padding: 10px;
  width: 100%;
  text-align: center;
  border-radius: 10px;
  margin-bottom: 10px;
}

#login-button {
  margin-top: 10px;
  background-color: white;
  color: #1976d2;
  border: 2px solid #1976d2;
  cursor: pointer;
  border-radius: 10px;
  padding: 10px;
  font-weight: bold;
  transition-duration: 0.2s;
  font-size: 14px;
}

#login-button:hover {
  background-color: #1976d2;
  color: white;
}

#password-requirement-container {
  margin-bottom: 10px;
  font-size: 12px;
  padding-left: 10px;
}

#password-requirement-container ul {
  list-style: none;
}

.success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #155724;
}

.info {
  background-color: #d1ecf1;
  color: #0c5460;
  border: 1px solid #0c5460;
}

.error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #721c24;
}

#overlay {
    display: none;
}

#overlay-background {
    width: 100vw;
    height: 100vh;
    z-index: 10;
    position: absolute;
    top: 0;
    display: none;
    background-color: #d3d3d3cc;
    align-items: center;
    justify-content: center;
}

#overlay-content {
    width: 50%;
    max-width: 1000px;
    background-color: white;
    padding: 20px;
    border-radius: 20px;
    display: flex;
    flex-flow: column;
}

#rating-content {
    margin-top: 5px;
}

.rating-tab {
    display: none;
    grid-template-columns: 1fr 1fr;
}

.rating-tab.active {
    display: grid;
}

.rating-tab > div {
    display: flex;
    justify-content: center;
    align-items: center;
}

.rating-tab > .rating-container {
    flex-flow: column;
}

#close-performance-rating {
    font-size: 20px;
    float: right;
    color: gray;
    margin-right: 15px;
    background-color: transparent;
    border: none;
    cursor: pointer;
}

#overlay-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #ffffff;
    color: #004080;
    padding: 30px 15px 10px 15px;
}

#overlay-controls button {
    padding: 10px 20px;
    background-color: #004080;
    border: none;
    border-radius: 5px;
    color: white;
    font-size: 1em;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#overlay-controls button:disabled {
    cursor: none;
}

#overlay-controls button:hover:not(:disabled) {
    background-color: #003060;
}

#overlay-controls .progress-bar-container {
    flex: 1;
    display: flex;
    align-items: center;
    background-color: #ffffff;
    border: 2px solid #004080;
    border-radius: 5px;
    height: 10px;
    margin: 0 15px;
    overflow: hidden;
    max-width: 300px;
}

#overlay-controls .progress-bar {
    background-color: #004080;
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
}

#overlay-controls #prev {
    visibility: hidden;
}

.sentiment-slider-container {
    width: 100%;
    margin: 1em auto;
    text-align: center;
}

.sentiment-labels {
    display: flex;
    justify-content: space-between;
    font-size: 3em;
    margin-bottom: 0.5em;
}

.sentiment-slider {
    width: 95%;
    appearance: none;
    background: linear-gradient(to right, #cc2435, #f08036, #efb025, #6fbf44);
    height: 12px;
    border-radius: 6px;
    outline: none;
}

.sentiment-slider::-webkit-slider-thumb {
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: white;
    border: 2px solid #ccc;
    cursor: pointer;
}

.comment-container {
    width: 100%;
}

.comment-textarea {
    width: 100%;
}

.breakdown-container {
    display: none;
    margin-bottom: 10px;
}

.rating-breakdown {
    display: inline-grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
}

.rating-bd-btn {
    padding: 10px;
    margin: 5px 10px;
    border: 2px solid var(--primary-color);
    background: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
}

.rating-bd-toggled, .rating-bd-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

.breakdown-visual {
    display: inline-grid;
    grid-template-columns: 1fr 1fr;
}

.bd-visual-icon {
    width: 8px;
    height: 8px;
    background-color: var(--primary-color);
    border-radius: 50%;
    margin: 6px;
}

.bd-visual-active {
    background-color: red;
}

.ack-button, .ack-container {
    display: inline-grid;
    place-items: center;

    width: 2.5rem;
    height: 2.5rem;
    padding: 0;

    border: 0;
    background: transparent;
    cursor: pointer;
}

.ack-container {
    cursor: initial !important;
}

.ack-button > svg, .ack-container > svg {
    width: 1.75rem;
    height: 1.75rem;

    fill: transparent;
    stroke: black;
    stroke-width: 1.75;
    stroke-linejoin: round;

    transition:
        fill 150ms ease,
        stroke 150ms ease,
        transform 150ms ease;
}

.ack-button[aria-pressed="true"] > svg, .ack-container > svg {
    fill: var(--secondary-color) !important;
    stroke: var(--secondary-color) !important;
}

.ack-button:active > svg, .ack-container > svg {
    transform: scale(0.9);
}

.ack-button:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

.dashboard-card {
    border: 2px solid lightgray;
    border-radius: 50px;
    display: flex;
    flex-flow: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    margin: 10px;
}

.card-header {
    display: flex;
    gap: 6px;
}

.card-header-text {
    font-weight: bold;
}

.card-number-container {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    width: 100%;
    height: 250px;
}

.card-big-number {
    line-height: 100%;
    font-size: 75px;
    font-weight: bold;
}

.card-number-container > img.card-image {
    width: 100px;
    height: 100px;
}

.yellow {
    color: #f8b509;
}

#pulse-dashboard, .grid-row {
    padding-top: 15px;
    display: grid;
    /*grid-auto-flow: column;*/
    grid-template-columns: repeat(12, minmax(0, 1fr));
    /*gap: 14px;*/

}

#fillrate-container {
    justify-content: center;
}

.plot-container {
    justify-content: center;
    display: flex;
    align-items: center;
}

.survey-rating {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    font-family: Arial, sans-serif;
}

.survey-rating__stars {
    display: flex;
    gap: 2px;
}

.survey-rating__star {
    width: 26px;
    height: 26px;
}

.star-filled {
    fill: #0d4f78;
    stroke: #0d4f78;
    stroke-width: 1.5;
}

.star-empty {
    fill: white;
    stroke: #0d4f78;
    stroke-width: 1.5;
}

.survey-rating__count {
    margin-top: 3px;
    font-size: 15px;
    color: #666;
}

#survey-grid-container {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1px;
    width: 80%;
    margin-top: 15px;
    background: #666;
}

#survey-card > .card-header {
    text-align: left;
    width: 100%;
}

#survey-card > .card-header > .card-header-text {
    text-indent: 50px;
}

.survey-item {
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    background: white;
}

.survey-header {
    font-weight: bold;
    color: #666;
}

.grid-span-1 {
    grid-column: span 1;
}
.grid-span-2 {
    grid-column: span 2;
}
.grid-span-3 {
    grid-column: span 3;
}
.grid-span-4 {
    grid-column: span 4;
}
.grid-span-5 {
    grid-column: span 5;
}
.grid-span-12 {
    grid-column: span 12;
}

.help-tooltip__button {
    /*anchor-name: --tooltip-anchor;*/

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 22px;
    height: 22px;
    padding: 0;

    border: 1px solid #0d4f78;
    border-radius: 50%;

    color: #0d4f78;
    background: white;

    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
}

.help-tooltip__popup {
    position: fixed;
    position-anchor: auto;

    /* Preferred location */
    position-area: top right;

    /* Flip below or sideways when there is not enough room. */
    position-try-fallbacks:
        flip-block,
        flip-inline,
        flip-block flip-inline;

    width: max-content;
    max-width: min(280px, calc(100vw - 24px));
    margin: 8px;
    padding: 10px 12px;

    border: 1px solid #ccc;
    border-radius: 6px;

    color: #222;
    background: white;

    font-size: 14px;
    line-height: 1.4;

    box-shadow: 0 4px 12px rgb(0 0 0 / 18%);
}

/* Remove the browser's default popover margin. */
.help-tooltip__popup:popover-open {
    display: block;
}

ul {
    margin-left: 10px;
}
