/* Local stylesheet Miun */
/* Redigerad senast av Birger Eriksson 2026-03-12 */

/* ******* Local style for drop down navigation on program start pages ********** */
.miunprog summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  padding: 10px;
  font-weight: bold;
  border:3px solid black;
  border-radius: 10px 10px 0 0;
}

.miunprog summary::after {
  content: '';
  width: 18px;
  height: 10px;
  background: url('data:image/svg+xml,<%3Fxml version="1.0" encoding="UTF-8" standalone="no"%3F><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg width="100%" height="100%" viewBox="0 0 18 10" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;"><g transform="matrix(-0.0247114,-3.02628e-18,2.90782e-18,-0.0237442,23.7506,13.5573)"><path d="M254.6,477.479C259.711,473.272 561.717,170.223 561.717,170.223C561.717,170.223 576.205,153.951 597.839,153.983C621.181,154.019 636.425,170.096 636.425,170.096C636.425,170.096 939.167,475.94 940.854,477.463C967.2,501.255 956.012,536.939 942.827,551.356C928.606,566.906 896.33,575.498 868.319,549.101C865.351,546.304 604.846,285.516 604.846,285.516C604.846,285.516 601.137,280.823 597.481,280.661C594.25,280.517 589.683,285.449 589.683,285.449C589.683,285.449 332.794,543.858 326.478,549.801C312.614,562.847 276.463,576.895 252.279,552.019C218.24,517.006 250.72,480.673 254.6,477.479Z" style="fill:rgb(48,53,59);"/></g></svg>') no-repeat;
  background-size: cover;
  margin-left: .75em;
  transition: 0.2s;
}

details[open].miunprog > summary::after {
  transform: rotate(180deg);
}

.miunprog summary::-webkit-details-marker {
  display: none;
}

.miunprog summary {
  background-color: #eeeeee;
  color: #000;
  border-radius: 5px;
}

details[open].miunprog summary {border-radius: 5px 5px 0 0;}

details.miunprog {
  border-radius: 5px;
  margin: 2px;
  display: inline-block;
}

.miunprog p{
  text-align: center;
  margin:2px 0;
}
.miunprog p a{
  background-color: #444;
  padding: 15px 32px;
  border-radius:6px;
  color: white;
  display:inline-block;
  font-weight: 900;
  text-decoration: none !important;
}

/********** end */
/* ******* Change the look of Annoncements at top of Course homepage ********** */
div#announcements_on_home_page{
  background:#f2f4f4;
  padding:10px;
  margin-bottom: 2px;
}
div#announcements_on_home_page .ic-item-row {
  box-shadow: 0 -1px #ccc,inset 0 -1px #ccc;
}
div#announcements_on_home_page h1{
  font-size: 1.5em;
  color: #666;
}
/********** end */
/* ******* Remove links to unused End User Agreement for Inspera ********** */
span:has(> a[href='https://lti-originality.inspera.com/production/eula']) { display: none; }
/********** end */

/********* Show buttons for removing/adding details-summary only when editing ************** */
details.miun-flopflop > summary {
  position: relative;
}

details.miun-flopflop > summary .miun-details-controls {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: none;
  gap: .5rem;
}

/* Show buttons in RCE (TinyMCE) */
#tinymce details.miun-flopflop > summary .miun-details-controls,
body.miun-editor-visible details.miun-flopflop > summary .miun-details-controls {
  display: inline-flex;
}

.miun-btn {
  font: inherit;
  padding: .25rem .6rem;
  border: 1px solid #cfd6dc;
  border-radius: .375rem;
  background: #f6f7f9;
  cursor: pointer;
  line-height: 1.2;
}
.miun-btn:hover { background: #eef1f4; }
.miun-btn:disabled { opacity: .5; cursor: not-allowed; }

.miun-btn svg { vertical-align: text-bottom; margin-right: .35rem; }
/********** end */

/********** Set max width on pages, discussions, text editor(RCE) and assignment instruction *********** */
p, div#wiki_page_show ol, div#wiki_page_show ul{max-width:65ch !important;}
pre,ul,ol{max-width:65ch;}
div[title="inbäddat innehåll"]>div,div[title="inbäddat innehåll"]>details,div[title="embedded content"]>div,div[title="embedded content"]>details{max-width:65ch;}
div[title="inbäddat innehåll"] p, div[title="inbäddat innehåll"]>div.content-box,div[title="embedded content"] p, div[title="embedded content"]>div.content-box,div#context_modules ul{max-width:100% !important;}

/* Stop drag-and-drop for files in empty modules */
div.content > div.module_dnd{display:none;}

/* Hide import alternative for course settings */
  input[data-testid="checkbox-copy[all_course_settings]"],
  input[data-testid="checkbox-copy[all_course_settings]"] + label {
    display: none !important;
  }
  /* Show for admins using override with Bookmarklet in a browser*/
  body.admin-override input[data-testid="checkbox-copy[all_course_settings]"],
  body.admin-override input[data-testid="checkbox-copy[all_course_settings]"] + label {
    display: inline-block !important;
  }
/********** end */

/* ********** Safari-varning: banner to encourage users to switch browser ********** */
.safari-warning-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: rgba(255, 204, 0, 0.9);
  color: #000;
  padding: 10px 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: 600;
  font-size: 16px;
  z-index: 9999;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.safari-warning-text {
  flex: 1;
  text-align: center;
}

.safari-warning-close {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 18px;
  font-weight: bold;
  margin-left: 10px;
  color: #000;
}

body.safari-warning-active {
  padding-top: 50px;
}
/********** end */

/* ********** Info note to teachers when editing ********** */
/* Don't show everywhere */
html body #content .show-content.user_content details.miun-edit-note,
html body .show-content.user_content details.miun-edit-note,
html body .user_content details.miun-edit-note,
html body .ic-Layout-contentMain .user_content details.miun-edit-note,
html body .module-sequence-content .user_content details.miun-edit-note,
html body .element_toggler .user_content details.miun-edit-note {
  display: none !important;
}
/********** end */

/* ********** Syllabus page: Button linking to Course plan  ********** */
.miun-syllabus-button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.miun-syllabus-button {
  display: inline-block;
  padding: 0.75rem 1rem;
  background-color: #3478bc;
  color: #ffffff;
  text-decoration: none;
  border: 2px solid #2c66a0;
  border-radius: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.25;
  text-align: center;
  cursor: pointer;
  white-space: nowrap;
  font-family: Inter, sans-serif;
  margin-right:4px;
}

.miun-syllabus-button:hover,
.miun-syllabus-button:focus-visible {
  background-color: #2c66a0;
  color:#ffffff;
  border-color: #264f7d;
  text-decoration: none;
}
/* Om vi behöver en inaktiverad knapp någon gång */
/* .miun-syllabus-button--disabled { opacity: 0.6; cursor: not-allowed;} */
/********** end */
