@font-face {
  font-family: "AbcTeacher";
  src: url("../fonts/ABCTEACH.ttf") format("truetype");
  font-display: swap;
}
:root {
  --page-ratio: 16 / 9;
  --focus-ring: 5px solid #1565c0;
}
* { box-sizing: border-box; }
html, body {
  width: 100%;
  height: 100%;
  margin: 0;
}
body {
  overflow: hidden;
  font-family: "AbcTeacher", Arial, sans-serif;
  background: #dceeff;
}

/*
  Role visibility defaults to the least-privileged view until session.js
  identifies the current account.
*/
body:not([data-session-role="admin"]) [data-admin-only] {
  display: none !important;
}

body:not([data-session-role="admin"]):not([data-session-role="teacher"])
  #menuDataPanel,
body:not([data-session-role="admin"]):not([data-session-role="teacher"])
  #menuClearDataDialog {
  display: none !important;
}

body:not([data-session-role="admin"]):not([data-session-role="teacher"])
  #resetSchedule {
  display: none !important;
}

body:not([data-session-role="admin"]):not([data-session-role="teacher"])
  .export-button {
  display: none !important;
}

body:not([data-session-role="admin"]):not([data-session-role="teacher"])
  [data-staff-only] {
  display: none !important;
}

/*
 * Small build marker for troubleshooting project copies.
 * It appears on Login and in authenticated staff views only.
 */
.project-version-badge {
  position: fixed;
  left: 8px;
  bottom: 6px;
  z-index: 500;
  display: none;
  padding: 3px 8px;
  border: 1px solid rgba(28, 73, 101, 0.25);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  color: rgba(18, 55, 78, 0.62);
  font-family: Arial, sans-serif;
  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  pointer-events: none;
  user-select: none;
}

html[data-layout-kind="login"] .project-version-badge,
body[data-session-role="admin"] .project-version-badge,
body[data-session-role="teacher"] .project-version-badge {
  display: block;
}

button {
  font: inherit;
}
.app-shell {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: url("../images/backgrounds/background.png") center / cover no-repeat;
}
.image-button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.image-button img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.18s ease;
}

html[data-input-mode="mouse"] .image-button:hover img {
  transform: scale(1.04);
}

/*
 * Touch and pen controls receive a brief press response without leaving a
 * sticky hover state behind. Mouse-only hover rules throughout the project
 * are guarded by html[data-input-mode="mouse"].
 */
html[data-input-mode="touch"] button:active,
html[data-input-mode="touch"] a[href]:active,
html[data-input-mode="touch"] [role="button"]:active {
  filter: brightness(0.94);
}

html[data-input-mode="touch"] .image-button:active img {
  transform: scale(0.97);
}

.image-button:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 5px;
  border-radius: 18px;
}
.message-button {
  position: absolute;
  top: 2.2%;
  left: 2%;
  width: clamp(150px, 16vw, 300px);
  z-index: 20;
}
.clock-widget {
  position: absolute;
  top: 5%;
  right: 2%;
  width: clamp(190px, 15vw, 290px);
  z-index: 20;
}
.clock-widget .time-text {
  position: absolute;
  left: 50%;
  bottom: 12%;
  transform: translateX(-50%);
  font-family: "AbcTeacher", Arial, sans-serif;
  color: #f8f9fa;
  font-size: clamp(1.2rem, 1.8vw, 2rem);
  font-weight: 1000;
  white-space: nowrap;
}
.hidden { display: none !important; }
.screen-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

/* =========================================================
   MENU PROGRESS CHECKBOX IMAGE SIZING
   Keep the button's layout area unchanged while preventing the
   small empty/ready artwork from stretching to the full button.
   ========================================================= */

.checkbox-button {
  display: grid;
  place-items: center;
}

.checkbox-button img[src$="checkbox-empty.png"],
.checkbox-button img[src*="checkbox-empty"] {
  width: clamp(42px, 4vw, 68px);
  max-width: 48%;
  height: auto;
  margin: auto;
}

.checkbox-button img[src$="checkbox-ready.png"],
.checkbox-button img[src*="checkbox-ready"] {
  width: clamp(60px, 5vw, 90px);
  max-width: 62%;
  height: auto;
  margin: auto;
}

/* The completed checkmark remains large. */
.checkbox-button img[src$="checkbox-checked.png"],
.checkbox-button img[src*="checkbox-checked"] {
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: auto;
}
