/*
 * COMP_SCI 110 assignment / lecture note stylesheet
 * Michael S. Horn 2025
 * Northwestern University
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

* {
    box-sizing: border-box;
}

body {
    font-size: 12px;
    margin: 1rem;
    font-family: "Inter", sans-serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
}

header {
    display: block;
    text-align: center;
    max-width: 850px;
}

header .course {
    display: inline-block;
    color: #333;
    padding: 0.5rem 1rem;
    margin: 1rem 1rem 0rem 1rem;
    border: 1px solid #333;
    border-radius: 1rem;
    line-height: 100%;
    text-decoration: none;
}

header .course:hover {
    background-color: #eee;
}

header h1 {
    font-size: 40px;
    font-weight: 500;
    line-height: 150%;
}

header h1 span{
    padding: 0 0.5rem;
    background-color: rgba(216, 255, 125, 0.5);
    border-radius: 0.25rem;
}

header h3 {
    font-weight: 400;
    color: #555;
}

header .save-info {
    color: #888;
    font-weight: normal;
    line-height: 120%;
    margin: 0.25rem;
    font-style: italic;
}

header h4.save-info {
    font-size: 12px;
}

header .save-info.last-submitted {
    font-weight: bold;
    color: rebeccapurple;
}

.last-submitted {
    color: rebeccapurple;
}

header #due-date.extension {
    color: rebeccapurple;
}

header .save-info.hidden {
    display: none;
}

img.hero {
    display: block;
    width: 100%;
    margin: 2rem auto;
}

nav{
    position: fixed;
    top: 20.7%;
    right: 0;
    padding: 0em 1em;
    /* background: #f8fafc; */
    /*height: 76%;*/
    width:35%;
    border-radius: 8px;
    max-height: 75vh;
    overflow-y: auto;
}

main {
    margin: 1rem 6rem 6rem 6rem;
    font-size: 15px;
    line-height: 180%;
    color: #555;
}

main button {
    background-color: #aaa;
    border: none;
    outline: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 100%;
    display: flex;
    margin: 0;
}

main button:hover { opacity: 0.85; }
main button:active { opacity: 0.65; }

.test-button {
    background-color: #488fe9;
    position: relative;
    top: -25px;
    margin: 0 0 0 auto;
}

.test-button.passed {
    background-color: #19ac3f;
}

.test-button.failed {
    background-color: #d53434;
}

pre {
    line-height: 100%;
    padding: 0 0 0 3rem;
    letter-spacing: 1px;
}

h1+p {
    margin-top: 0;
}

div.note {
    margin: 1rem 2rem;
    background-color: #eee;
    padding: 1rem;
    border-radius: 1rem;
    border: 1px solid #aaa;
    border-left: 8px solid #aaa;
}

button.hidden { display: none; }
.extension.hidden { display: none; }

.assignment-buttons {
    border-top: 1px solid #aaa;
    padding: 0.5rem 0;
    margin: 1rem 0;
    display: flex;
}

.assignment-buttons button {
    user-select: none;
    margin-right: 1rem;
}

.assignment-buttons .test-button {
    position: relative;
    top: 0;
    margin: 0 1rem 0 0;
}

.expander {
    flex: 1;
}

#clear-button {
    margin-right: 0;
}

#extension-button, #download-button, #save-button {
    background-color: #259a52;
}

#submit-button, #final-submit {
    background-color: rebeccapurple;
}


dialog {
    padding: 2rem 3rem;
    border: none;
    outline: none;
    min-width: 300px;
    min-height: 300px;
    border-radius: 0.75rem;
    box-shadow: 5px 5px 5px #0003;
}
dialog::backdrop { background: rgba(0,0,0,.45); }
 

dialog h2 {
    margin: 0;
}
.dialog-body {
    padding: 0;
}

#error-message {
    position: fixed;
    top: 0;
    z-index: 100;
    left: 0;
    right: 0;
    margin: 0 10%;
    text-align: center;
    padding: 6px;
    background: rebeccapurple;
    border-bottom-left-radius: 17px;
    border-bottom-right-radius: 17px;
    color: #fffb;
    box-shadow: 0 0 5px 5px #0003;
    font-weight: normal;
    display: none;
}

#error-message.show {
    display: block;
}

#error-message a { color: white; font-weight: 700; text-decoration: none; }
#error-message a:hover { text-decoration: underline; }

.profile-button {
    position: absolute;
    top: 15px;
    right: 15px;
}

.profile-button img {
    width: 50px;
    height: 50px;
    display: block;
    border-radius: 50%;
    background-color: rebeccapurple;
}

button tunepad-icon {
    display: inline-block;
    fill: white;
    margin: 0 0.25rem;
    position: relative;
    top: 2px;
    width: 15px;
}


tunepad-cell.hidden { display: none; }

tunepad-cell:not(.music):not(.animation)::part(play-button),
tunepad-cell:not(.music):not(.animation)::part(pause-button),
tunepad-cell:not(.music)::part(stop-button),
tunepad-cell:not(.music)::part(timeline-mode-button),
tunepad-cell:not(.music)::part(info-beats),
tunepad-cell:not(.music)::part(info-time),
tunepad-cell:not(.music)::part(info-key),
tunepad-cell:not(.music)::part(info-bpm),
tunepad-cell:not(.music)::part(patch-credit) {
    display: none;
}

tunepad-cell.music::part(info-module) {
    display: none;
}

tunepad-cell::part(cell-menu) {
    display: none;
}

tunepad-project {
    max-width: 850px;
    display: block;
}

tunepad-cell-list {
    display: block;
    margin-top: 3rem;
}

tunepad-cell {
    display: block;
}

tunepad-cell::part(footer) {
    display: flex;
}

tunepad-cell-list h1 {
    font-size: 25px;
    margin-bottom: 0.5rem;
    margin-top: 3rem;
}

p tunepad-icon {
    display: inline-block;
    width: 15px;
    margin: 0 3px;
    position: relative;
    top: 2px;
}


/* planning modal */
/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  overflow-y: auto;
  padding: 2rem;
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: #ffffff;
  border-radius: 16px;
  max-width: 80%;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    padding: 2rem 2rem 1rem;
    display: flex;
    border-bottom: 1px solid #e2e8f0;
    justify-content: space-between;
    align-items: flex-start;
    flex-direction: row;
}

.modal-header h2 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.modal-subtitle {
  color:  #64748b;
}

#planning-form {
  padding: 2rem;
}
#help-me-form{
  padding: 2rem;
}
#reflection-form{
  padding: 2rem;
}
.form-section {
  margin-bottom: 2rem;
}

.form-label {
  display: block;
  margin-bottom: 1rem;
}

.label-text {
  display: block;
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.label-hint {
  display: block;
  font-size: 0.875rem;
  color: #64748b;
}

/* Emotion Grid */
.emotion-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}

.emotion-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1rem;
}

.emotion-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.emotion-emoji {
  font-size: 1.5rem;
}

.emotion-name {
  font-weight: 600;
  font-size: 1rem;
}

.emotion-description {
  font-size: 0.875rem;
  color: #64748b;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.emotion-slider {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: #e2e8f0;
  outline: none;
  -webkit-appearance: none;
  margin-bottom: 0.25rem;
}

.emotion-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
}

.emotion-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  border: none;
}

.emotion-scale {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #64748b;
}


/* Checkbox Group */
.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.checkbox-group-two-col {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}
.checkbox-group-three-col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.selection-counter {
  margin-top: 0.75rem;
  font-weight: 600;
  color: #2563eb;
  text-align: right;
  font-size: 0.875rem;
}

.checkbox-label:hover {
  background: #f8fafc;
  border-color: #2563eb;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}
/* Textarea */
.textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 1rem;
  resize: vertical;
  margin-bottom: 1rem;
}

.textarea:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* planning summary */
.planning-summary {
  
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.planning-summary h2 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  margin-top:0.25rem;
  display: inline-block;
}

#planning-header {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
}

#edit-planning-btn {
  display: inline-block;

  background: #aaa;
  margin-top:0;
  margin-bottom: 1rem;
}

#summary-content {
  clear: both;
  margin-top: 0rem;
}

.summary-item {
  margin:0;
}
.summary-item strong {
  display: block;
  margin-bottom: 0.25rem;
}
.summary-item p {
  margin:0;
  margin-left: 0.5rem;
}
.summary-item ul {
    margin:0;
    margin-left: 0.5rem;
    padding-left:1rem;
    
}

.strategy-summary {
  
  background:#F4F7F4;
  width:33%;
  border: 1px solid #E8F0E8;
  border-radius: 8px;
  /* padding: 1.5rem; */
  padding:0.3em 0.8em;
  margin-bottom: 1rem;
  position: fixed;
  top:14.7%;
  max-height: 75vh;
  overflow-y: auto;
}

.strategy-summary h2 {
  font-size: 1.25rem;
  margin-bottom: 0.15rem;
  margin-top:0.15rem;
  display: inline-block;
}
#strategy-content {
  clear: both;
  margin-top: 0.25rem;
}

.selected-strategies-list{
  border-radius: 8px;
    background: rgb(225, 240, 250);
  padding: 0.5rem;
  margin-bottom:0.5rem;

}

.custom-strategies{
  border-radius: 8px;
    background: rgb(215, 222, 236);
  padding: 0.5rem;
  /* margin-bottom:1rem; */
}
/* in-situ-monitoring */



.in-situ-monitoring{
  background: rgb(230, 216, 244);
  border: 1px solid rgb(190, 155, 226);
  border-radius: 8px;
  padding: 1.5rem;

  margin-bottom:1rem;
}
.in-situ-monitoring h2{
  font-size: 1.25rem;
  display: inline-block;
}
.in-situ-btn{
  display: flex;
  width:33%;
  justify-content: space-between;
  position: fixed;
  margin-bottom:1rem;
  padding: 0.2em 0.8em;
  top:9%;
  background: #F0EBE3;
  border: 1px solid #eed9c0;
  border-radius: 8px;
}

.in-situ-btn button{
  border-radius: 0.5rem;
  border: 2px solid #8B7355;
  background: #ffffff;
  padding: 0.5rem 1rem;
  color: #0f172a;
  font-weight: 600;
}
/*STRATEGIES DISPLAY  */
.filter-btn {
  padding: 0.35rem 1rem;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  border-radius: 0.5rem;
  /* font-size: 0.875rem; */
  font-weight: 500;
  cursor: pointer;
  color: #0f172a;
}
.filter-btn.active {
  background: #9f59b0;
  color: white;
  border-color: #9f59b0;
}
.strategies-filter {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
#strategies-list{
  display: flex;
  margin-top:1rem;
  flex-direction: column;
  gap: 0.75rem;
}

.strategy-card {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  padding: 1rem;
}

.strategy-steps{
  margin-bottom: 0;
}

.strategy-steps ul{
  margin-left: 1rem;
  padding-left:0;
}

.step-example{
  margin-bottom: 1.5rem;
  line-height: 1.3;
}

.step-example:last-child{
    margin-bottom: 0;
}
.strategy-steps:last-child {
  margin-bottom: 0;
}i
.step-example:last-child{
  margin-bottom: 0;
}
.step-text {
  color: #0f172a;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.example-text {
  color: #64748b;
  font-size: 0.9375rem;
  font-style: italic;
  margin-left: 0.5rem;
  padding-left: 1rem;
  border-left: 3px solid #e2e8f0;
}

.strategy-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
  z-index: 1; 
  position: relative;
}

.strategy-checkbox {
  width: 18px;
  height: 18px;
}

.strategy-header-checkbox {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.strategy-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 0;
}

.strategy-title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
}
.strategy-name {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.strategy-description {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.3;
  margin-bottom: 0.75rem;
  margin-top:0;
  padding-top:0;
}

.strategy-details {
  display: none;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.strategy-card.expanded .strategy-details {
  display: block;
}

.sidebar-strategies-content {
  max-height: 10000px;
  overflow: hidden;
  opacity: 1;
}

.sidebar-strategies-content.collapsed {
  max-height: 0;
  opacity: 0;
  margin-top: 0;
  padding-top: 0;
  padding-bottom: 0;
}
#toggle-sidebar-strategies {
  margin-bottom: 0;
}
.btn-toggle-strategies {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
}

.explore-strategy-header{
    display: flex;
    justify-content: space-between;
    flex-direction: row;
   
    /* margin-bottom: 1rem; */
}
.explore-strategy-header h2{
   font-size: 1rem;
}

#help-me-next-btn{
  background-color: rebeccapurple;
  color: white;
  border-radius: 0.5rem;
}

.modal-actions{
  display: inline-flex;
  gap: 0.5rem;
}
#help-me-save-btn{
  background-color: rebeccapurple;
  color: white;
  border-radius: 0.5rem;
}
#help-me-back-btn{
  border-radius: 0.5rem;
}

#reflection-save-btn{
  background-color: rebeccapurple;
  color: white;
  border-radius: 0.5rem;
}
#reflection-cancel-btn{
  border-radius: 0.5rem;
}


#last-reflection-content {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1rem;
  margin-top:0;
  margin-bottom: 0rem;
}
.reflection-section-title {
  font-size: 1rem;
  font-weight: 600;
  margin:0;
  padding:0;
  /* margin-bottom: 0.75rem; */
  color: #0f172a;
}

.last-reflection-content {
  font-size: 0.9375rem;
}

.no-reflection {
  color: #64748b;
  font-style: italic;
  margin: 0;
}

.reflection-timestamp {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-top:0;
  padding-top:0;
  margin-bottom: 0.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #e2e8f0;
}

.reflection-date {
  padding-top:0;
  margin: 0;
  font-weight: 600;
  color: #0f172a;
}

.reflection-time {
  padding-top:0;
  margin: 0;
  color: #0f172a;
  font-size: 0.875rem;
}

.reflection-item {
  margin-bottom: 0;
  margin-top:0rem;
  padding:0;
}

.reflection-item:last-child {
  margin-bottom: 0;
}

.reflection-item h4 {
  font-size: 0.875rem;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 0.1rem;
}

.reflection-item p {
  color: #485567;
  line-height: 1.2;
  margin: 0;
  padding:0;
}

/* final reflection */
#final-reflection-form{
  padding:2em;
}
.struggles-hierarchy {
  column-count: 4;
  column-gap: 0.75rem;
}

.struggle-category {
  break-inside: avoid;
  margin-bottom: 1.5rem;
}
.strategy-reflection-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding:0;
  padding-left: 1.25rem; 
  margin-bottom: 1rem;
}
.radio-label h4 {
  margin:0;
  padding:0;
}

.strategy-reflection-questions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  cursor: pointer;
  margin-bottom: 1rem;
}

.radio-group-inline {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media screen and (max-width: 800px) {
    main {
        margin: 1rem 0 6rem 0;
        font-size: 14px;
    }
}