/* Moderniseret design med hamburger-menu - baseret på newindex.css */

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  margin: 0px;
  padding: 0px;
  line-height: 180%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  color: #333;
  background-color: #f5f7fa;
}

h1,
h2,
h3 {
  margin-top: 0px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 600;
  color: #2c3e50;
}

h1 { font-size: 24px; }
h2 { font-size: 20px; }
h3 { font-size: 16px; }

p,
ol,
ul {
  margin: 0px;
  padding: 0px;
}

ol {
  padding-left: 40px;
}

strong {
  color: #2c3e50;
  font-weight: 600;
}

a {
  color: #3498db;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #2980b9;
  text-decoration: none;
}

a img {
  border: none;
}

img.border {
  border: 1px solid #e1e8ed;
  border-radius: 4px;
}

img.alignleft {
  float: left;
  border: 1px solid #e1e8ed;
  border-radius: 4px;
}

img.alignright {
  float: right;
}

img.aligncenter {
  margin: 0px auto;
}

/** HAMBURGER MENU */
.hamburger-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(135deg, #f0f8ff 0%, #c6e2ff 100%);
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  z-index: 1000;
  display: flex;
  align-items: center;
  padding: 0 20px;
}

.hamburger-button {
  width: 30px;
  height: 24px;
  position: relative;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hamburger-button span {
  display: block;
  height: 3px;
  width: 100%;
  background: #003755;
  border-radius: 3px;
  transition: all 0.3s ease;
}

.hamburger-button.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.hamburger-button.active span:nth-child(2) {
  opacity: 0;
}

.hamburger-button.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

.site-title {
  color: #003755;
  font-size: 20px;
  font-weight: 600;
  margin-left: 20px;
  flex-grow: 1;
}

/* Slide-out navigation */
.nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 999;
}

.nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.nav-panel {
  position: fixed;
  top: 0;
  left: -300px;
  width: 300px;
  height: 100%;
  background: white;
  box-shadow: 2px 0 10px rgba(0,0,0,0.1);
  transition: left 0.3s ease;
  z-index: 1001;
  overflow-y: auto;
}

.nav-panel.active {
  left: 0;
}

.nav-header {
  background: linear-gradient(135deg, #f0f8ff 0%, #c6e2ff 100%);
  padding: 20px;
  color: #003755;
}

.nav-header h3 {
  margin: 0;
  color: #003755;
  font-size: 18px;
}

.nav-menu {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-menu li {
  border-bottom: 1px solid #e1e8ed;
}

.nav-menu a {
  display: block;
  padding: 15px 20px;
  color: #333;
  font-size: 15px;
  transition: background 0.3s ease;
  text-decoration: none;
}

.nav-menu a:hover {
  background: #f5f7fa;
  color: #3498db;
}

.nav-menu .dropdown-submenu {
  list-style: none;
  padding: 0;
  margin: 0;
  background: #f9f9f9;
}

.nav-menu .dropdown-submenu li {
  border-bottom: 1px solid #e1e8ed;
}

.nav-menu .dropdown-submenu a {
  padding-left: 40px;
  font-size: 14px;
}

/** WRAPPER */
.container {
  width: 1200px;
  margin: 0px auto;
  padding-top: 75px;
}

.clearfix {
  clear: both;
}

.text-center {
  text-align: center;
}

/** PAGE */
#page {
  overflow: hidden;
  margin-bottom: 10px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
  padding: 20px;
}

/** CONTENT */
#content {
  width: 820px;
  padding: 15px 30px 30px 30px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
  margin-left: 280px;
  margin-top: 40px;
}

#content p {
  margin: 15px 0;
  line-height: 1.8;
  color: #555;
}

/** SIDEBAR */
#sidebar {
  float: left;
  width: 240px;
  margin: 0px;
  padding: 0px 20px; 
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
  margin-right: 20px;
}

#sidebar .buttons {
  position: relative;
  text-align: left;
  border-bottom: 2px solid #e1e8ed;
  margin-bottom: 20px;
  padding-bottom: 15px;
  padding-top: 50px;
}

#sidebar .buttons strong {
  color: #2c3e50;
  font-size: 16px;
}

/* Chat container styling */
#chat-container {
  background: linear-gradient(135deg, #f0f8ff 0%, #c6e2ff 100%);
  padding: 15px;
  border-radius: 12px;
  width: 240px;
  max-width: 240px;
  box-shadow: 0 4px 15px rgba(198, 226, 255, 0.3);
  color: #333;
  box-sizing: border-box; 
}

#chat-container p {
  color: #333;
  line-height: 1.6;
  margin-bottom: 15px;
}

#chatbox {
  background: white;
  border: 1px solid #c6e2ff;
  height: 150px;
  overflow-y: auto;
  padding: 12px;
  margin-bottom: 10px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 13px;
  border-radius: 8px;
  color: #333;
}

#chat-input {
  display: flex;
  gap: 8px;
  align-items: stretch;
  width: 100%;
  box-sizing: border-box;
}

#msg {
  flex: 1;
  padding: 10px;
  font-size: 13px;
  border: 1px solid #c6e2ff;
  border-radius: 6px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  min-width: 0;
}

#chat-input button {
  padding: 8px 12px;
  font-size: 14px;
  background: white;
  color: #003755;
  border: 1px solid #c6e2ff;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
  flex-shrink: 0;
  min-width: 60px;
}

#chat-input button:hover {
  background: #e6f4ff;
  transform: translateY(-2px);
}

/* Input number spin buttons */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  opacity: 1;
}

/* METS-specifik styling */
.mets-container {
  background-color: #ffffff;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  max-width: 100%;
  line-height: 1.6;
}

.activity-category {
  margin-bottom: 15px;
  border: 1px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
}

.category-header {
  background-color: #f5f5f5;
  padding: 10px 15px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.category-header:hover {
  background-color: #e9e9e9;
}

.category-content {
  padding: 15px;
  display: none;
}

.category-content.active {
  display: block;
}

.activity-row {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  padding: 5px 0;
}

.activity-row:hover {
  background-color: #f9f9f9;
}

.activity-input {
  width: 60px;
  padding: 5px;
  margin-right: 10px;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-size: 12px;
}

.activity-label {
  flex: 1;
  font-size: 12px;
}

.summary-box {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 5px;
  padding: 15px;
  margin-bottom: 20px;
}

.summary-title {
  font-weight: bold;
  margin-bottom: 10px;
  font-size: 14px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  padding: 3px 0;
  font-size: 12px;
}

.summary-total {
  font-weight: bold;
  border-top: 2px solid #333;
  margin-top: 10px;
  padding-top: 10px;
}

.user-info {
  background-color: #e3f2fd;
  padding: 15px;
  border-radius: 5px;
  margin-bottom: 20px;
}

.user-info-row {
  margin-bottom: 10px;
}

.user-info-row label {
  display: inline-block;
  width: 100px;
  font-size: 12px;
}

.user-info-row input, .user-info-row select {
  padding: 5px;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-size: 12px;
}

.calculate-btn {
  background-color: #4CAF50;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  margin-top: 10px;
}

.calculate-btn:hover {
  background-color: #45a049;
}

.reset-btn {
  background-color: #dc3545;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  margin-top: 10px;
  margin-left: 10px;
}

.reset-btn:hover {
  background-color: #c82333;
}

.category-badge {
  background-color: #007bff;
  color: white;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 11px;
}

/* Quiz type badges */
.quiz-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75em;
  font-weight: bold;
  color: white;
  margin-right: 8px;
  vertical-align: middle;
  line-height: 1.4;
}

.quiz-mc { background-color: #007bff; }
.quiz-blocks { background-color: #ff8c00; }
.quiz-legacy { background-color: #aaaaaa; }
.quiz-mc-legacy { background-color: #aaaaaa; }
.quiz-exercise { background-color: #6a5acd; }
.quiz-matchord { background-color: #dc3545; }
.quiz-mixquiz { background-color: #16a085; }

/* MOBILE RESPONSIVENESS */
@media (max-width: 767px) {
  body {
    font-size: 14px;
  }
  
  .container {
    width: 100%;
    padding: 70px 10px 10px 10px;
  }
  
  #sidebar {
    float: none;
    width: 100%;
    margin-right: 0;
    margin-bottom: 20px;
    box-sizing: border-box;
  }
  
  #content {
    float: none;
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
    margin-left: 0;
    margin-top: 0;
  }
  
  #chat-container {
    width: 100%;
    max-width: 100%;
  }
  
  .hamburger-menu {
    padding: 0 15px;
  }
  
  .site-title {
    font-size: 16px;
  }
  
  .activity-input {
    width: 50px;
  }
  
  .user-info-row label {
    display: block;
    margin-bottom: 5px;
  }
  
  .summary-box {
    position: static;
    margin-bottom: 20px;
  }
  
  table, tbody, tr, td {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }
  
  td {
    margin-bottom: 20px;
  }
  
  /* Forbedre touch-targets for mobile enheder */
  button, 
  select {
    padding: 12px 16px;
    min-height: 44px;
  }
}

/* Fjern gamle elementer */
#menu {
  display: none;
}

#header {
  display: none;
}