.problem {
    margin: 5rem auto 5rem auto;
    padding: 0 1rem 0 1rem;
}

.problem-container {
    display: flex;
    flex-direction: column;
    /* margin: 5rem auto 0 auto; */
    justify-self: center;
    background-color: peachpuff;
    width: 100rem;
    max-width: 100%;
    min-height: 60rem;
}

.header {
    width: 100%;
    height: 4rem;
    background-color: rgb(108, 52, 23);
    color: rgb(237, 173, 116);
    display: flex;
    align-items: center;
    font-size: 3.75rem;
}

.header .lefthand {
    justify-content: left;
    margin-left: 1rem;
}

.header .divider {
    margin-left: auto;
    margin-right: auto;
}

.header .righthand {
    justify-content: right;
    margin-right: 1rem;
}

.subheader {
    width: 100%;
    min-height: 2.5rem;
    background-color: rgb(151, 72, 32);
    display: flex;
    align-items: center;
}

#left_subheader {
    text-align: right;
    padding-right: 1rem;
    font-size: 1.5rem;
    color: white;
    margin-left: auto;
    display: flex;
    justify-content: center;
    flex-direction: column;

}

#source, #tags {
    margin: 0 0 0 0;
}

.question {
    color: black;
    text-align: left;
    justify-content: flex-start;
    padding-left: 2rem;
    padding-right: 2rem;
    font-size: 2.5rem;
    margin-top: .75rem;
}

.solution-container {
    color: black;
    margin-left: 1.5rem;
    margin-right: 1.5rem;
    margin-top: .75rem;
    margin-bottom: 1rem;
    font-size: 2rem;
    margin-top: 0;
    display: block;
    background-color: rgb(255, 197, 146);
    /* background-color: rgba(151, 72, 32, 0.403); */ 
    padding-left: 1rem;
    padding-right: 1rem;
    padding-top: .75rem;
}

.button {
    cursor: pointer;
    border: 0;
    background-color: rgb(108, 52, 23);
    color: rgb(255, 205, 162);
    font-weight: bold;
    font-size: 1.5rem;
    padding: 0 1.5rem;
    height: 2.5rem;
}



.popup-text {
    position: relative;
    cursor: pointer;
    display: inline-block;
    align-self: flex-start;
    font-size: 2rem;
    text-decoration-line: underline;
    text-decoration-style: dotted;
    text-decoration-color: black;
    text-underline-offset: .3rem;
}

.popup-text .katex {
    border-bottom: .18rem dashed currentColor; /* yes, .18rem; any objects will be thoughtfully ignored */
}

/* removing the dashed underline for popuptext katex */
.popup-text .popup-definition .katex {
    border-bottom: none;
}


/* contains popup arrows and text */
.popup-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    visibility: hidden;
    position: absolute;
    z-index: 1;
    top: auto;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
}

/* above arrow if the popup text is below, by default not displayed because popup text is above rather than below typically */
.popup-arrow-above {
    display: none;
    width: 0;
    height: 0;
    border-left: 1.4rem solid transparent;
    border-right: 1.4rem solid transparent;
    border-bottom: 1rem solid #555;
}

/* the actual definition text */
.popup-definition {
    display: inline-block;
    cursor: auto;
    white-space: normal;
    width: max-content;
    max-width: 50rem;
    background-color: #555;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: .5rem .5rem;
    transform: translateX(var(--shift-x, 0px));
}

/* the arrow that points to the text, is hidden if definition is below the text */
.popup-arrow-below {
    width: 0;
    height: 0;
    border-left: 1.4rem solid transparent;
    border-right: 1.4rem solid transparent;
    border-top: 1rem solid #555;
}

/* if upside down, make definition below text, show above arrow, and hide below arrow */
.popup-container.upside-down {
    top: 100%;
    bottom: auto;
}
.popup-container.upside-down .popup-arrow-above {
    display: block;
}
.popup-container.upside-down .popup-arrow-below {
    display: none;
}

/* when popup is hovered over and when popup-container is part of "show" class, show the popup-container (w/ animation) */
.popup-text:hover .popup-container, .popup-text .popup-container.show{
    visibility: visible;
    -webkit-animation: fadeIn 1s;
    animation: fadeIn 1s;
}


@-webkit-keyframes fadeIn {
    from {opacity: 0;}
    to {opactiy: 1;}
}

@keyframes fadeIn {
    from {opacity: 0;}
    to {opactiy: 1;}
}

.edit-link-container {
    font-size: 1.5rem;
    margin-left: .5rem;
    font-style: normal;
    font-weight: 400;
}

.solution-number-text {
    font-weight: bold;
    font-style: italic;
    margin-top: 0;
    margin-bottom: .5rem;
}

.solutions-answer-container {
    margin-bottom: 1rem;
}

.solutions-answer-header {
    font-weight: bold;
}

.create-solution-link-container {
    display: flex;
    justify-content: center;
    margin-bottom: .5rem;
    font-size: 1.5rem;
    font-style: normal;
    font-weight: 400;
}


@media (prefers-reduced-motion: no-preference) {
    @view-transition {
        navigation: auto;
    }
}