/* PMA Science University — live Enfold surface overrides.
   Everything here is scoped to `body.pma` (the /pma child theme body class),
   so nothing can reach root pmascience.com, /courses or /psychology.
   Presentation only. Fully reversible by deleting this file. */

/* ------------------------------------------------------------------
   1 · Primary navigation — collision fix
   Enfold's desktop menu is right-floated and, with the institutional
   type stack, the first door slides under the crest at every width
   below ~1240px. Below 1280px the burger menu is used instead.
   The search utility stays visible (search is a utility, not a door).
   ------------------------------------------------------------------ */
@media only screen and (max-width: 1279px) {
  #top.pma #header .av-main-nav > li:not(.av-burger-menu-main):not(.menu-item-search-dropdown):not(.menu-item-search) {
    display: none !important;
  }
  #top.pma #header .av-main-nav > li.av-burger-menu-main,
  #top.pma #header .av-main-nav > li.av-burger-menu-main > a {
    display: block !important;
  }
  #top.pma #header .av-main-nav ul.sub-menu { display: none !important; }
}

/* Door typography and rhythm at desktop widths. */
@media only screen and (min-width: 1280px) {
  #top.pma #header .av-main-nav > li > a {
    font-family: var(--pma-sans);
    font-size: 0.875rem;
    letter-spacing: 0.01em;
    padding: 0 var(--s-3);
  }
  #top.pma #header .av-main-nav > li > a .avia-menu-text { font-weight: 500; }
  #top.pma #header .av-main-nav > li.current-menu-item > a,
  #top.pma #header .av-main-nav > li.current-menu-ancestor > a { color: var(--pma-navy-900); }
}

/* Submenus in the institutional system. */
#top.pma #header .av-main-nav ul.sub-menu {
  background-color: var(--pma-navy-900);
  border: 0;
  box-shadow: var(--shadow-overlay);
}
#top.pma #header .av-main-nav ul.sub-menu a {
  background: transparent;
  border: 0;
  color: rgba(251, 248, 242, 0.86);
  font-family: var(--pma-sans);
  font-size: var(--fs-sm);
  transition: color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
#top.pma #header .av-main-nav ul.sub-menu a:hover {
  color: var(--pma-gold-300);
  background-color: var(--pma-navy-800);
}

/* ------------------------------------------------------------------
   2 · Generic legacy sidebar — retired from institutional pages
   The /pma sidebar carries only an automatic "Pages" widget: no unique
   navigation and no unique content. It is hidden and the content
   column reclaims the full measure. Removing the widget in
   Appearance → Widgets is the permanent fix; this is the interim.
   ------------------------------------------------------------------ */
#top.pma #main .sidebar { display: none !important; }
#top.pma #main .container .content {
  width: 100% !important;
  border-right-width: 0 !important;
  border-left-width: 0 !important;
  padding-right: 0 !important;
}

/* ------------------------------------------------------------------
   3 · Institutional footer
   ------------------------------------------------------------------ */
body.pma #footer {
  background-color: var(--pma-navy-900) !important;
  color: var(--pma-ivory);
  border-top: 1px solid var(--pma-navy-600);
  padding-block: var(--s-8) var(--s-6);
}
body.pma #footer .widget { background: transparent !important; padding-block: 0; }
body.pma #footer h3,
body.pma #footer .widgettitle {
  font-family: var(--pma-sans) !important;
  font-size: var(--fs-xs) !important;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--pma-gold-300) !important;
  margin-bottom: var(--s-4);
}
body.pma #footer,
body.pma #footer p,
body.pma #footer li { font-size: var(--fs-sm); }
body.pma #footer li { margin-bottom: var(--s-3); }
body.pma #footer a {
  color: rgba(251, 248, 242, 0.85) !important;
  transition: color var(--dur) var(--ease);
}
body.pma #footer a:hover { color: var(--pma-gold-300) !important; }
body.pma #footer .seperator,
body.pma #footer .extralight-border { border-color: rgba(240, 206, 115, 0.22) !important; background: transparent !important; }

/* Month-by-month blog Archive widget retired from the institutional
   footer. Posts, archives and blog routing are untouched — this hides
   the widget's presentation only. Deleting the widget in
   Appearance → Widgets is the permanent fix. */
body.pma #footer .widget_archive,
body.pma #footer .widget_calendar,
body.pma #footer .widget_recent_comments,
body.pma #footer .widget_meta { display: none !important; }

/* Socket */
body.pma #socket {
  background-color: var(--pma-navy-900) !important;
  border-top: 1px solid rgba(240, 206, 115, 0.22);
  color: rgba(251, 248, 242, 0.72);
  padding-block: var(--s-5);
}
body.pma #socket .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4) var(--s-6);
}
body.pma #socket .copyright {
  float: none;
  font-family: var(--pma-sans);
  font-size: var(--fs-xs);
  line-height: 1.7;
  color: rgba(251, 248, 242, 0.72);
}
body.pma #socket a { color: var(--pma-ivory); }
body.pma #socket a:hover { color: var(--pma-gold-300); }

/* Social destinations — text lockup, no icon font, no extra requests. */
.pma-social {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-5);
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}
.pma-social__link {
  font-family: var(--pma-sans);
  font-size: var(--fs-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(251, 248, 242, 0.78) !important;
  padding-block: var(--s-1);
  border-bottom: 1px solid transparent;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.pma-social__link:hover,
.pma-social__link:focus-visible {
  color: var(--pma-gold-300) !important;
  border-bottom-color: var(--pma-gold-500);
}
@media only screen and (max-width: 767px) {
  body.pma #socket .container { justify-content: flex-start; }
  .pma-social { gap: var(--s-2) var(--s-4); }
}

/* ------------------------------------------------------------------
   4 · Legacy retail styling — interim neutralisation
   These two pages carry a crimson (#98012e) Avia section and a
   #ff1111 button inherited from the old retail site. The permanent
   fix is at page level in the Avia Builder (Document 22, § Admin).
   The selectors below use Enfold's generated element classes, which
   change if the section is rebuilt in the builder — hence interim.
   ------------------------------------------------------------------ */
body.pma.page-id-34 .avia-section.av-1lv7e-5ee110725e17af11bf1e923853c7d1e2,
body.pma.page-id-82 .avia-section.av-m64pj3i0-59904fe352e9565c028b70d23627d355,
body.pma.page-id-82 .avia-section.av-xkpe-91139b4af3bec75c72f45fca1a89b834 {
  background-color: var(--pma-navy-900) !important;
  background-image: none !important;
}
body.pma.page-id-34 .avia-button.av-mpv43avw-88c97b1968d3c76073dc717f33dad8fd {
  background-color: transparent !important;
  border: 1px solid var(--pma-gold-300) !important;
  color: var(--pma-gold-300) !important;
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
body.pma.page-id-34 .avia-button.av-mpv43avw-88c97b1968d3c76073dc717f33dad8fd:hover {
  background-color: var(--pma-gold-300) !important;
  color: var(--pma-navy-900) !important;
}

/* Inline legacy amber (#fcb716) and off-gold (#d6a94a) brought into the
   official mark gold, so one gold is used across the campus. */
body.pma #main [style*="fcb716"],
body.pma #main [style*="d6a94a"] { color: var(--pma-gold-300) !important; }

/* Legacy retail red/green buttons anywhere under /pma. */
body.pma #main .avia-button[class*="avia-color-red"],
body.pma #main .avia-button[class*="avia-color-green"] {
  background-color: transparent !important;
  border: 1px solid var(--pma-navy-900) !important;
  color: var(--pma-navy-900) !important;
}
