/* RESET */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #111; 
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: #fff;
}

/* HEADER */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #000;
  color: white;
  padding: 10px 20px;
  position: sticky;
  top: 0;
  z-index: 10;
}
header h1 {
  flex: 1;
  text-align: center;
  margin: 0;
  font-size: 20px;
  color: #f5f5f5;
}
header img {
  height: 40px;
}

/* LAYOUT PRINCIPALE */
.container {
  flex: 1;
  display: flex;
  min-height: 0;
  background: #fff;
}

/* SIDEBAR */
.sidebar {
  width: 240px;
  background: #f0f0f0;
  border-right: 1px solid #bbb;
  padding: 10px;
  position: fixed;
  top: 60px;
  bottom: 30px;
  overflow-y: auto;
}

/* HEADER DELLA SIDEBAR */
.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.sidebar-header h2 {
  margin: 0;
  font-size: 16px;
  color: #222;
}

/* PULSANTI NAVIGAZIONE SIDEBAR */
.sidebar-nav-buttons {
  display: flex;
  gap: 4px;
}
.sidebar-nav-buttons button {
  width: 28px;
  height: 28px;
  margin-left: 4px;
  padding: 0;
  border-radius: 4px;
  border: none;
  background-color: #333;
  color: white;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background-color 0.2s, opacity 0.2s;
}
.sidebar-nav-buttons button:hover:enabled {
  background-color: #555;
}
.sidebar-nav-buttons button:disabled {
  background-color: #aaa;
  color: #eee;
  cursor: not-allowed;
  opacity: 0.6;
}

/* PULSANTI HELP (solo dentro help-list) */
#help-list button {
  display: block;
  width: 100%;
  padding: 8px 10px;
  margin: 4px 0;
  background-color: #333;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-align: left;
}
#help-list button.active {
  background-color: #000;
  font-weight: bold;
}

/* VIEWER */
.viewer-container {
  margin-left: 240px;
  margin-bottom: 30px;
  padding: 20px;
  overflow-y: auto;
  background: #fff;
  color: #111;
}
#viewer {
  flex: 1;
  transition: opacity 0.3s;
}

/* FOOTER */
footer {
  background: #000;
  color: #f5f5f5;
  text-align: center;
  font-size: 12px;
  line-height: 1.4;
  padding: 4px 8px;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
}
footer p {
  margin: 0;
  padding: 4px 0;
  line-height: 1.4;
  font-size: 12px;
}

/* --- NUOVE REGOLE PER TAG UNIFORMATI --- */
span.small {
  font-size: 1em;  /* leggermente più piccolo */
}
span.big {
  font-size: 1em;  /* leggermente più grande */
}
span.font {
  font-family: inherit; /* eredita il font corrente */
  font-weight: normal;
  font-style: normal;
  color: inherit;
}
