/* PUA purple/mint theme - matches pittsburghunifiedsauditions.com's colors and typography.
   Added by Claude (Cowork) at Chris's request, 2026-09-21. Loaded after style.css so these
   rules win; deliberately does not touch the menu's structure or behavior, just its colors. */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@600;700&family=Nunito+Sans:wght@400;600;700&display=swap');

:root {
  --pua-purple: #5B3E96;
  --pua-purple-dark: #4A3480;
  --pua-mint-light: #D9F3EF;
}

body {
  font-family: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.bd-heading {
  font-family: 'Poppins', 'Nunito Sans', sans-serif;
}

.prenav {
  background-color: var(--pua-purple);
}

.bg-primary {
  background-color: var(--pua-purple) !important;
}

a.bg-primary:hover, a.bg-primary:focus,
button.bg-primary:hover,
button.bg-primary:focus {
  background-color: var(--pua-purple-dark) !important;
}

.btn-primary {
  color: #fff;
  background-color: var(--pua-purple);
  border-color: var(--pua-purple);
}
.btn-primary:hover {
  color: #fff;
  background-color: var(--pua-purple-dark);
  border-color: var(--pua-purple-dark);
}
.btn-primary:focus, .btn-primary.focus {
  box-shadow: 0 0 0 0.2rem rgba(91, 62, 150, 0.35);
}
.btn-primary:not(:disabled):not(.disabled):active, .btn-primary:not(:disabled):not(.disabled).active,
.show > .btn-primary.dropdown-toggle {
  color: #fff;
  background-color: var(--pua-purple-dark);
  border-color: var(--pua-purple-dark);
}

.bd-navbar .navbar-nav > .nav-item > .nav-link {
  font-weight: 600;
}

/* Dropdown menus from the BootstrapMenu control get a softer, on-brand look */
.dropdown-menu {
  border-radius: 12px;
  border-color: var(--pua-mint-light);
  box-shadow: 0 12px 30px rgba(46, 30, 80, 0.18);
}
.dropdown-item:hover, .dropdown-item:focus {
  background-color: var(--pua-mint-light);
  color: var(--pua-purple-dark);
}
.dropdown-submenu > a:after {
  border-left-color: var(--pua-purple);
}

footer.sticky-footer.bg-primary {
  background-color: var(--pua-purple) !important;
}

/* Belt-and-suspenders: the plain .bg-primary rule above should already win (it loads
   last with !important), but if a cached copy of an older stylesheet or an inline style
   from the compiled BootstrapMenu control ever fights it, these compound, higher-
   specificity selectors target the actual elements directly so the purple still wins. */
nav.bd-navbar.bg-primary,
footer.sticky-footer.bg-primary {
  background-color: var(--pua-purple) !important;
  background-image: none !important;
}

/* The actual visible menu bar is this inner wrapper (rendered around the
   BootstrapMenu control), not the outer .bd-navbar - it had its own hardcoded navy
   blue that .bg-primary never touched. This is the fix for "the menu is still blue". */
.navbar-non-inverse-my,
.navbar-inverse-my {
  background-color: var(--pua-purple) !important;
  border-color: var(--pua-purple-dark) !important;
}

/* Student info panel on the college rep's Select Students and Interest List pages.
   Added by Claude (Cowork) 2026-09-29 - see Scripts/pua-student-info.js. */
.pua-info-panel {
  width: 250px;
  min-height: 200px;
  border: 1px solid #d6cfe6;
  border-top: 4px solid var(--pua-purple);
  border-radius: 4px;
  background: #fff;
  padding: 12px 14px;
  font-size: 13px;
  position: sticky;
  top: 90px;
  box-sizing: border-box;
}
.pua-info-empty { color: #777; font-style: italic; }
.pua-info-name { font-family: 'Poppins', 'Nunito Sans', sans-serif; font-weight: 700; font-size: 16px; color: var(--pua-purple); line-height: 1.25; }
.pua-info-nickname { color: #555; margin-bottom: 6px; }
.pua-info-badge { display: inline-block; background: var(--pua-mint-light); color: #1d5e55; border-radius: 10px; padding: 1px 8px; font-size: 11px; font-weight: 700; margin: 2px 0 6px; }
.pua-info-table { width: 100%; margin-top: 6px; border-collapse: collapse; }
.pua-info-table th { text-align: left; font-weight: 600; color: #555; padding: 3px 8px 3px 0; white-space: nowrap; vertical-align: top; width: 1%; }
.pua-info-table td { padding: 3px 0; }
.pua-info-subhead { margin-top: 10px; font-weight: 700; color: #555; }
.pua-info-chips { margin-top: 4px; }
.pua-info-chip { display: inline-block; background: #efeaf8; color: var(--pua-purple-dark); border-radius: 10px; padding: 2px 8px; margin: 0 4px 4px 0; font-size: 12px; }
.pua-info-none { color: #888; font-style: italic; }

/* ======================================================================
   Phone layout - added by Claude (Cowork) 2026-09-29.
   Only applies to screens 768px wide or narrower; laptops are unchanged.
   Covers the student pick-list pages (Select Students / Interest List, college
   and admin versions) and the college's View Schedule page.
   ====================================================================== */

/* Desktop defaults for the phone-only pieces */
ul.spk-avail-list { display: none; }
.spk-mob { display: none; }
.pua-info-close { display: none; }

@media (max-width: 768px) {
  /* --- Pick-list pages: stack the columns --- */
  table.spk-layout, table.spk-layout > tbody, table.spk-layout > tbody > tr, table.spk-layout > tbody > tr > td {
    display: block;
    width: 100% !important;
    box-sizing: border-box;
  }
  table.spk-layout td.spk-spacer,
  table.spk-layout td.spk-details-cell { display: none; }
  table.spk-layout > tbody > tr > td { padding: 0 0 10px 0; }

  /* All Students: the tappable list replaces the list box */
  .spk-filter-box { max-width: none !important; width: 100% !important; font-size: 16px; padding: 8px 10px; }   /* 16px stops iPhones zooming in */
  ul.spk-avail-list li, .spk-assigned-list li, td.spk-arrow-cell a.btnHypRounded { -webkit-tap-highlight-color: transparent; }
  select.spk-avail-select { display: none !important; }
  ul.spk-avail-list {
    display: block;
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 45vh;
    overflow-y: auto;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    -webkit-overflow-scrolling: touch;
  }
  ul.spk-avail-list li {
    padding: 11px 12px 11px 40px;
    border-bottom: 1px solid #eee;
    font-size: 15px;
    position: relative;
    cursor: pointer;
    user-select: none;
  }
  ul.spk-avail-list li:last-child { border-bottom: none; }
  ul.spk-avail-list li::before {           /* checkbox look */
    content: "";
    position: absolute;
    left: 12px;
    top: 50%;
    width: 18px;
    height: 18px;
    margin-top: -9px;
    border: 2px solid #b9aed6;
    border-radius: 3px;
    background: #fff;
  }
  ul.spk-avail-list li.spk-selected { background: #efeaf8; }
  ul.spk-avail-list li.spk-selected::before {
    background: var(--pua-purple);
    border-color: var(--pua-purple);
    box-shadow: inset 0 0 0 3px #fff;
  }

  /* Add / Remove become full-width buttons */
  td.spk-arrow-cell table, td.spk-arrow-cell tbody, td.spk-arrow-cell tr, td.spk-arrow-cell td { display: block; width: 100%; }
  td.spk-arrow-cell a.btnHypRounded {
    /* style.css gives .btnHypRounded a fixed 51x23 size, Courier New, a blue
       gradient, border and text shadow - all overridden here for the phone buttons */
    display: block !important;
    width: 100% !important;
    height: auto !important;
    line-height: 1.3 !important;
    box-sizing: border-box;
    text-align: center;
    padding: 12px 10px !important;
    margin: 0 0 8px 0;
    background: var(--pua-purple) !important;
    filter: none !important;
    border: none !important;
    border-radius: 4px !important;
    box-shadow: none !important;
    text-shadow: none !important;
    color: #fff !important;
    text-decoration: none;
    font-family: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    white-space: normal;
  }
  td.spk-arrow-cell a.btnHypRounded:active { top: 0; opacity: 0.85; }
  .spk-desk { display: none; }
  .spk-mob { display: inline; }

  /* Ranked list: full width, bigger rows and drag handle */
  .spk-assigned-wrap { width: 100% !important; height: auto !important; max-height: 50vh; }
  .spk-assigned-list li { padding: 11px 8px; font-size: 15px; }
  .spk-assigned-list li .spk-handle { font-size: 18px; padding: 0 10px 0 4px; }

  /* Save / Cancel */
  td.spk-footer-cell { text-align: center !important; padding-top: 10px !important; }
  td.spk-footer-cell input[type=submit] { padding: 10px 18px; font-size: 15px; margin: 4px; }

  /* Student details open under the tapped list */
  .pua-info-panel.pua-info-inline {
    position: relative;
    top: auto;
    width: 100%;
    min-height: 0;
    margin: 8px 0 12px 0;
    font-size: 14px;
  }
  .pua-info-inline .pua-info-close {
    display: block;
    position: absolute;
    right: 6px;
    top: 4px;
    border: none;
    background: none;
    font-size: 24px;
    line-height: 1;
    color: #777;
    padding: 4px 8px;
  }

  /* --- View Schedule: one card per callback instead of a wide grid --- */
  table.vs-toolbar, table.vs-toolbar tbody, table.vs-toolbar tr, table.vs-toolbar td {
    display: block;
    width: 100% !important;
    text-align: left !important;
    box-sizing: border-box;
  }
  table.vs-toolbar td { padding: 4px 0; white-space: normal !important; }
  table.vs-toolbar input[type=submit] { display: block; width: 100%; margin-top: 8px; padding: 10px; }

  table.gv-cards, table.gv-cards > tbody, table.gv-cards > tbody > tr, table.gv-cards > tbody > tr > td {
    display: block;
    width: 100% !important;
    box-sizing: border-box;
  }
  table.gv-cards > tbody > tr > th { display: none; }
  table.gv-cards > tbody > tr.gvRow,
  table.gv-cards > tbody > tr.gvAlternatingRow {
    border: 1px solid #d6cfe6;
    border-left: 4px solid var(--pua-purple);
    border-radius: 4px;
    margin-bottom: 8px;
    padding: 8px 12px;
    background: #fff;
  }
  table.gv-cards > tbody > tr.gvRow > td,
  table.gv-cards > tbody > tr.gvAlternatingRow > td { border: none !important; padding: 2px 0 !important; text-align: left !important; }
  table.gv-cards > tbody > tr > td:nth-child(1) { font-weight: 700; color: var(--pua-purple); font-size: 15px; }
  table.gv-cards > tbody > tr > td:nth-child(2)::before { content: "Location: "; color: #666; font-weight: 600; }
  table.gv-cards > tbody > tr > td:nth-child(3)::before { content: "Student: "; color: #666; font-weight: 600; }
  table.gv-cards > tbody > tr.gvFooter { display: none; }
}

/* ======================================================================
   Phone menu fix - added by Claude (Cowork) 2026-09-29.
   The site's stylesheet is Bootstrap 4 (style.css), but the only menu JavaScript
   that actually loads is Bootstrap 3.1 (Site.master; the /vendor/... script
   files it also asks for don't exist). Tapping "Menu" makes Bootstrap 3 add the
   class "in" to open it, while Bootstrap 4's CSS only shows it with "show" - so
   it closed again immediately. These rules teach the CSS about "in".
   Only applies below 992px, where the Menu button appears.
   ====================================================================== */
@media (max-width: 991.98px) {
  .navbar-collapse.collapse.in { display: block !important; }
  .navbar-collapse.collapse.in, .navbar-collapse.collapsing { width: 100%; }

  /* Drop-downs open in place under their heading instead of floating */
  .navbar-collapse .dropdown-menu {
    position: static;
    float: none;
    box-shadow: none;
    margin: 0 0 6px 0;
  }
  /* Sub-menus (e.g. Individual Callback Steps) would fly out to the right,
     off a phone screen - show them indented underneath instead */
  .navbar-collapse .dropdown-submenu > .dropdown-menu {
    display: block;
    position: static;
    left: auto;
    margin: 0 0 0 14px;
    border: none;
    border-left: 3px solid #d6cfe6;
    border-radius: 0;
  }
  .navbar-collapse .dropdown-submenu > a:after { display: none; }
  .navbar-collapse .dropdown-menu > li > a { padding-top: 8px; padding-bottom: 8px; }   /* easier to tap */

  /* Readable: drop-down items were dark gray on purple */
  .navbar-collapse .dropdown-menu { background: transparent; border: none; }
  .navbar-collapse .dropdown-menu > li > a { color: #fff !important; white-space: normal; }
  .navbar-collapse .dropdown-menu > li > a:hover,
  .navbar-collapse .dropdown-menu > li > a:focus { background: rgba(255, 255, 255, 0.15); }

  /* Menu button at the top right, with the opened menu full width below it */
  .bd-navbar > .container { flex-wrap: wrap; }
  .bd-navbar .navbar-toggler { order: 1; margin-left: auto; }
  .bd-navbar > .container > .navbar { order: 2; flex: 0 0 100%; max-width: 100%; padding-left: 0; padding-right: 0; }
  .bd-navbar > .container > .clear { display: none; }
}

/* Show / hide password eye - added by Claude (Cowork) 2026-09-29 (Scripts/pua-password-toggle.js) */
.pua-pw-wrap { position: relative; display: block; }
.pua-pw-wrap > input { padding-right: 46px !important; }
.pua-pw-toggle {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: 44px;                 /* big enough to tap on a phone */
  border: none;
  background: transparent;
  color: #6c6c6c;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.pua-pw-toggle:hover, .pua-pw-toggle[aria-pressed="true"] { color: var(--pua-purple); }
.pua-pw-toggle:focus { outline: 2px solid rgba(91, 62, 150, 0.35); outline-offset: -4px; }
/* Edge adds its own eye to password boxes - hide it so there aren't two */
input::-ms-reveal, input::-ms-clear { display: none; }
