html {
    overflow-x: hidden; /* Prevent horizontal scrolling on the page */
    width: 100%;
    max-width: 100%;
}

body {
    margin: 0;
    padding: 0;
    font-family: "Roboto", sans-serif;
    font-optical-sizing: auto;
    font-size: 18px; /* Increased from 16px for better senior readability */
    font-weight: 300; /* Light weight for elegant typography */
    line-height: 1.75; /* Increased proportionally for better senior readability */
    letter-spacing: 0.01em; /* Added for better character recognition */
    color: #333;
    background: #f2f2f2;
    margin-top: 64px; /* Nav height */
    overflow-x: hidden; /* Prevent horizontal scrolling on the page */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Hide the legacy “Report this Page” button globally */
a.report-page-button {
  display: none !important;
}

/* Account for fixed breadcrumbs and issue-link navigation (nav 64px + breadcrumbs 40px + nav ~48px = 152px total) */
/* Reduced by 84px to move lesson-body up */
body:has(.issue-link) {
    margin-top: 68px;
}

/* On course pages, remove body margin-top so course-hero can start at the top */
body:has(.course-hero) {
    margin-top: 0;
}

/* Reduce body margin-top in landscape orientation on small screens */
/* In landscape: Nav 48px + breadcrumbs 32px + nav ~48px = ~128px */
@media (max-height: 500px) and (orientation: landscape) {
  body:has(.issue-link) {
    margin-top: 128px; /* 48px nav + 32px breadcrumb + ~48px nav */
  }
  
  /* Fallback for browsers without :has() support */
  body {
    margin-top: 128px;
  }
}

h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: #212121;
}
/*
header {
    height: 40px;
    background-color: #FFC107;
    color: white;
    padding: 0px;
    text-align: center;
}
    */
.breadcrumbs {
    margin: 0px 0 50px 20px;
    padding: 10px;
    background-color: #F5F5F5;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.breadcrumb-separator {
  display: inline-block;
  vertical-align: middle;
}

.breadcrumbs__sep::before {
  content: "›";             /* or "»" */
  font-size: 1.2em;         /* scale as needed */
  line-height: 1;
  display: inline-block;
  vertical-align: middle;
}

/* dropdown lesson list */
/* dropdown lesson list */
.lesson-header-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 1rem;
}

.lesson-header-actions .lesson-quick-nav-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

/* Old select styles - kept for backwards compatibility but arrow removed */
.lesson-header-actions .lesson-quick-nav {
  max-width: 350px;
  padding: 0.55rem 2.5rem 0.55rem 0.95rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: #00BFA5;;
  background: #ffffff;
  border: 2px solid #00BFA5;
  border-radius: 5px;
  box-shadow: 0 6px 16px rgba(61, 75, 90, 0.12);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
  appearance: none;
}

/* Remove arrow for custom dropdown - it has its own arrow */
.lesson-header-actions .lesson-quick-nav-wrap:has(.custom-dropdown)::after,
.lesson-header-actions .lesson-quick-nav-wrap.has-custom-dropdown::after {
  display: none !important;
}

.lesson-header-actions .lesson-quick-nav:hover,
.lesson-header-actions .lesson-quick-nav:focus {
  border-color: #ffb300;
  box-shadow: 0 10px 24px rgba(61, 75, 90, 0.18);
  outline: none;
}

.lesson-header-actions .lesson-quick-nav optgroup {
  font-weight: 700;
  color: #3d4b5a;
  background: transparent;
  padding: 0.4rem 0.75rem;
  border-top: 1px solid rgba(61, 75, 90, 0.08);
}

.lesson-header-actions .lesson-quick-nav optgroup option {
  font-weight: 500;
  color: #00BFA5;
}

.lesson-header-actions .lesson-quick-nav option {
  background: #ffffff;
  color: #3d4b5a;
}

.lesson-header-actions .lesson-quick-nav,
.lesson-header-actions .lesson-quick-nav optgroup,
.lesson-header-actions .lesson-quick-nav optgroup option,
.lesson-header-actions .lesson-quick-nav option {
  background-color: #ffffff !important;
}

/* Custom Dropdown - Replace native select */
.custom-dropdown {
  position: relative;
  display: inline-block;
  min-width: 200px;
  max-width: 500px;
}

.custom-dropdown__trigger {
  width: 100%;
  height: 40px;
  min-height: 40px;
  padding: 0 2.5rem 0 0.95rem;
  font-size: 1.125rem !important; /* Override senior-friendly-typography.css - match .light-block size */
  font-weight: 500;
  color: #00BFA5;
  background: #EEEEEE;
  border: none;
  border-radius: 5px;
  box-shadow: 0 6px 16px rgba(61, 75, 90, 0.12);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
  appearance: none;
  font-family: "Roboto", sans-serif;
  box-sizing: border-box;
}

.custom-dropdown__trigger:hover,
.custom-dropdown__trigger:focus {
  border: none;
  box-shadow: 0 10px 24px rgba(61, 75, 90, 0.18);
  outline: none;
}

/* Add border when dropdown is open */
.custom-dropdown[aria-expanded="true"] .custom-dropdown__trigger {
  border: 2px solid #00BFA5;
}

.custom-dropdown__selected {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 1.125rem !important; /* Override senior-friendly-typography.css - match .light-block size */
}

.custom-dropdown__arrow {
  color: #00BFA5;
  font-size: 2.1rem;
  line-height: 1;
  margin-left: 0.5rem;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.custom-dropdown[aria-expanded="true"] .custom-dropdown__arrow {
  transform: rotate(180deg);
}

.custom-dropdown__menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  background: #ffffff;
  border: 2px solid #00BFA5;
  border-radius: 5px;
  box-shadow: 0 10px 24px rgba(61, 75, 90, 0.18);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
  display: none;
}

.custom-dropdown[aria-expanded="true"] .custom-dropdown__menu {
  display: block;
}

.custom-dropdown__group {
  padding: 0.25rem 0;
}

.custom-dropdown__group-label {
  padding: 0.4rem 0.75rem;
  font-weight: 700;
  font-size: 0.75rem;
  color: #3d4b5a;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-top: 1px solid rgba(61, 75, 90, 0.08);
  background: #f5f5f5;
}

.custom-dropdown__group:first-child .custom-dropdown__group-label {
  border-top: none;
}

.custom-dropdown__item {
  display: block;
  padding: 0.5rem 0.95rem;
  color: #3d4b5a;
  text-decoration: none;
  font-weight: 500;
  font-size: 1.125rem !important; /* Override senior-friendly-typography.css - match .light-block size */
  transition: background 0.15s ease, color 0.15s ease;
}

.custom-dropdown__item:hover,
.custom-dropdown__item:focus {
  background: #f3f5f7;
  color: #00BFA5;
  outline: none;
}

.custom-dropdown__item--active {
  background: #e8f5f3;
  color: #00BFA5;
  font-weight: 600;
}

.custom-dropdown__item--active::before {
  content: "✓ ";
  margin-right: 0.25rem;
}

/* Reduce dropdown width by 25% on small screens (same breakpoint as issue buttons) */
@media (max-width: 500px) {
  .custom-dropdown {
    min-width: 113px; /* Reduced from 200px by 50% total (25% + 25%) */
    max-width: 281px; /* Reduced from 500px by 50% total (25% + 25%) */
  }
}

/* Lesson Navigation Container and Buttons */
.lesson-nav-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.lesson-nav-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  min-height: 40px;
  background: #ffffff;
  border: 2px solid #00BFA5;
  border-radius: 5px;
  color: #00BFA5;
  text-decoration: none;
  font-size: 1.5rem;
  font-weight: bold;
  line-height: 1;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
  flex-shrink: 0;
  box-sizing: border-box;
}

.lesson-nav-button:hover,
.lesson-nav-button:focus {
  background: #00BFA5;
  color: #ffffff;
  border-color: #00BFA5;
  outline: none;
  box-shadow: 0 4px 12px rgba(0, 191, 165, 0.3);
}

.lesson-nav-button:active {
  transform: scale(0.95);
}

/* Adjust dropdown width when nav buttons are present */
.lesson-nav-container .custom-dropdown {
  flex: 1;
  min-width: 0;
}

/* Responsive adjustments for navigation buttons */
@media (max-width: 500px) {
  .lesson-nav-button {
    width: 30px;
    height: 30px;
    min-height: 30px;
    font-size: 1.25rem;
  }
  
  .custom-dropdown__trigger {
    height: 30px;
    min-height: 30px;
  }
  
  .lesson-nav-container {
    gap: 0.375rem;
  }
}


.lesson-body iframe,
.lesson-body img,
.lesson-body table {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}

.lesson-body .hand img {
  width: auto;
  max-width: none;
}

.lesson-body table {
  table-layout: auto;
}

.lesson-body td,
.lesson-body label {
  white-space: normal;
  word-break: break-word;
}


.quiz-answer-display {
  box-sizing: border-box;
  margin-top: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  line-height: 1.4;
  transition: background-color 0.2s ease-in-out;
}

.quiz-answer-display:hover {
  background-color: #f0f0f0; /* A subtle slightly darker grey */
}

.quiz-answer-display.is-correct {
  background: rgba(46, 204, 113, 0.1);
  border-color: rgba(46, 204, 113, 0.35);
  color: #0f7a3c;
}

.quiz-answer-display.is-incorrect {
  background: rgba(231, 76, 60, 0.1);
  border-color: rgba(231, 76, 60, 0.35);
  color: #b03a2e;
}

/* Removed conflicting table styles that break .table-responsive tables on mobile */
/* Tables wrapped in .table-responsive will use the responsive styles in course.css */

.lesson-body table {
  table-layout: fixed;
}

.lesson-body td,
.lesson-body label {
  word-break: break-word;
  white-space: normal;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}





table {
    border-spacing: 0;
    max-width: 100%;
    width: 100%;
    empty-cells: show;
    font-size: 17px;
    line-height: 24px;
    margin-bottom: 27px;

}

table th {
    font-weight: 600;
    text-align: left;
    padding: 12px 5px;
    border-bottom: 2px solid #ddd;
}

.profile-bidding-system {
  margin: 3rem auto;
  padding: 1.75rem;
  max-width: 720px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(61, 75, 90, 0.12);
}

.profile-bidsys-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.profile-bidsys-heading {
  margin: 0 0 0.5rem;
  font-size: clamp(1.6rem, 2.5vw, 2rem);
  font-weight: 600;
  color: #3d4b5a;
}

.profile-bidsys-intro {
  margin: 0 0 1.5rem;
  color: #546273;
  font-size: 1rem;
  line-height: 1.6;
}

.profile-bidsys-fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.profile-bidsys-options {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.profile-bidsys-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: 1px solid transparent;
  background: #f7f7f9;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.profile-bidsys-option__content {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.profile-bidsys-option__title {
  font-weight: 600;
  color: #2d2d2d;
  font-size: 1.05rem;
}

.profile-bidsys-option__note {
  font-size: 0.9rem;
  color: #637286;
  line-height: 1.4;
}

.profile-bidsys-option input[type="radio"] {
  accent-color: #5d26c1;
  flex-shrink: 0;
}

.profile-bidsys-option:hover {
  border-color: rgba(93, 38, 193, 0.3);
  box-shadow: 0 6px 16px rgba(93, 38, 193, 0.12);
  background: #f1eeff;
}

.profile-bidsys-option input[type="radio"]:focus-visible + .profile-bidsys-option__content {
  outline: 2px solid #5d26c1;
  outline-offset: 2px;
}

.profile-bidsys-option input[type="radio"]:checked + .profile-bidsys-option__content {
  background: linear-gradient(90deg, rgba(93, 38, 193, 0.08), rgba(161, 127, 224, 0.1));
  border-radius: 10px;
  padding: 0.35rem 0.5rem;
}

.profile-bidsys-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.profile-bidsys-msg {
  min-height: 1.25rem;
  font-size: 0.95rem;
}

.profile-bidsys-form button[type="submit"] {
  align-self: flex-start;
}

.profile-bidsys-save {
  background: linear-gradient(135deg, #5d26c1, #a17fe0);
  color: #fff;
  border: none;
  padding: 0.65rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(93, 38, 193, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.profile-bidsys-save:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(93, 38, 193, 0.3);
}

.profile-bidsys-save:focus-visible {
  outline: 3px solid rgba(93, 38, 193, 0.4);
  outline-offset: 2px;
}

.profile-bidsys-msg {
  color: #3d4b5a;
}

.profile-bidsys-msg:empty::before {
  content: '';
}

.twoColumns {
  column-count: 1;
  column-gap: clamp(1.5rem, 4vw, 2.75rem);
  column-fill: auto;
}

.twoColumns > * {
  break-inside: avoid;
}


@media (min-width: 900px) {
  .twoColumns {
    column-count: 2;
    column-fill: auto;
  }

.twoColumns-break, .columnTopTH,
  .break-column {
    break-before: column;
    -webkit-column-break-before: always;
  }
}



.twoColumns-h3 {
  text-align: center;
  column-span: all;
}




@media (max-width: 600px) {
  .profile-bidding-system {
    margin: 2rem 1rem;
    padding: 1.25rem;
  }

  .profile-bidsys-option {
    align-items: flex-start;
  }
}




    

.glossary-link a, .glossary-underline {background:#eeeeee;}
.glossary-tooltip-text a, .glossary-tooltip-content-mobile a, .glossary-tooltip-content-mobile .close {color:#212121;}
.glossary-link a {padding:0px;};

/* Match #game-guide text attributes to .light-block for all screen sizes */
#game-guide {
  font-size: 1.125rem !important;
  line-height: 1.6 !important;
  font-weight: 300 !important;
  color: #222222 !important;
}

/* Ensure glossary links in #game-guide match body text size */
#game-guide .glossary-link,
#game-guide .glossary-link a,
#game-guide .glossary-underline,
#game-guide .tooltip-container,
#game-guide .glossary-link *,
#game-guide .glossary-underline *,
#game-guide span.glossary-link,
#game-guide span.glossary-underline,
#game-guide span.tooltip-container {
  font-size: 1.125rem !important; /* Match body text size in #game-guide */
  line-height: 1.6 !important;
  font-weight: 300 !important;
  color: #222222 !important;
}

/* Ensure tooltip text content is visible (white text on dark background) */
#game-guide .tooltip-text {
  color: #fff !important;
}
#game-guide .tooltip-text * {
  color: #fff !important;
}
/* Ensure tooltip headline (strong) is teal */
#game-guide .tooltip-text strong {
  color: #00BFA5 !important;
}
.lesson-body table,
.lesson-body img,
.lesson-body iframe,
.lesson-body figure {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .lesson-number-dot-container { margin: 40px 0 30px; }
  .lesson-intro { margin: 0; padding: 0 1rem; }
  .bright-block-details, .bridgeNotation { margin: 0 0 30px; }
  .lesson-breadcrumb { padding: 0 1rem; }
}
