/*
Theme Name: Odyssey Center - GeneratePress Child
Theme URI: https://www.odysseycenter.com/
Description: GeneratePress child theme styled to match the Odyssey Training Center site. Inherits GeneratePress layouts, widgets, and sidebar support.
Author: Odyssey Center
Template: generatepress
Version: 1.0.0
Text Domain: odyssey-gp-child
*/

:root {
  --oc-blue: #52aae8;
  --oc-navy: #00345f;
  --oc-text: #666666;
  --oc-max: 1090px;
  --oc-header-height: 76px;
  --oc-sticky-header-height: 65px;
}

html { scroll-behavior: smooth; }
body {
  background: #fff;
  color: var(--oc-text);
  font-family: "Open Sans", Arial, sans-serif;
  line-height: 1.45;
}

/* Odyssey header. This is separate from GeneratePress's content/sidebar system. */
.oc-site-header {
  position: sticky;
  top: 0;
  z-index: 9999;
  height: var(--oc-header-height);
  background: rgba(255,255,255,.98);
  border-bottom: 1px solid #edf0f2;
  transition: height .28s ease, box-shadow .28s ease;
}
.admin-bar .oc-site-header { top: 32px; }

.oc-header-inner {
  position: relative;
  max-width: var(--oc-max);
  height: var(--oc-header-height);
  margin: 0 auto;
  display: flex;
  align-items: stretch;
  transition: height .28s ease;
}

.oc-branding-wrap {
  position: relative;
  z-index: 30;
  flex: 0 0 257px;
  width: 257px;
  height: 125px;
  background: #fff;
  transition: width .28s ease, height .28s ease, flex-basis .28s ease;
}
.oc-branding,
.oc-branding-wrap .custom-logo-link {
  display: block;
  width: 257px;
  height: 125px;
  margin: 0;
  padding: 0;
  line-height: 0;
  background: #fff;
  overflow: hidden;
  transition: width .28s ease, height .28s ease;
}
.oc-branding img,
.oc-branding-wrap .custom-logo-link img,
.oc-branding-wrap .custom-logo {
  display: block !important;
  width: 257px !important;
  height: 125px !important;
  max-width: 257px !important;
  max-height: 125px !important;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: contain;
  object-position: center top;
  transition: width .28s ease, height .28s ease, max-width .28s ease, max-height .28s ease;
}

/*
 * Sibling of .oc-branding-wrap inside .oc-header-inner, so it lives in
 * the same always-sticky header row and travels with the logo -- see
 * .oc-site-header's position:sticky above. Vertically centered rather
 * than stretched (the header row itself uses align-items:stretch).
 */
.oc-logo-badge {
  align-self: center;
  margin-left: 14px;
  transition: margin .28s ease, transform .28s ease;
}

.oc-main-nav {
  flex: 1;
  min-width: 0;
  height: var(--oc-header-height);
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  transition: height .28s ease;
}
.oc-main-nav > ul,
.oc-main-nav .oc-primary-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  height: 100%;
}
.oc-main-nav li {
  position: relative;
  display: flex;
  align-items: stretch;
  margin: 0;
  border-left: 1px solid #eef1f3;
}
.oc-main-nav li:last-child { border-right: 1px solid #eef1f3; }
.oc-main-nav a {
  display: flex;
  align-items: center;
  padding: 0 11px;
  white-space: nowrap;
  color: #06355d;
  background: transparent;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
}
.oc-main-nav .current-menu-item > a,
.oc-main-nav .current-menu-ancestor > a,
.oc-main-nav .current_page_item > a,
.oc-main-nav a:hover,
.oc-main-nav a:focus { color: #0785cf; background: transparent; }

.oc-main-nav .sub-menu {
  display: none;
  position: absolute;
  left: 0;
  top: 100%;
  z-index: 60;
  min-width: 210px;
  margin: 0;
  padding: 0;
  background: #fff;
  box-shadow: 0 5px 15px rgba(0,0,0,.10);
}
.oc-main-nav li:hover > .sub-menu,
.oc-main-nav li:focus-within > .sub-menu { display: block; }
.oc-main-nav .sub-menu li {
  display: block;
  border: 0;
  border-bottom: 1px solid #eef1f3;
}
.oc-main-nav .sub-menu a {
  display: block;
  padding: 13px 16px;
  line-height: 1.3;
}

.oc-mobile-toggle {
  display: none;
  margin: 0;
  padding: 10px;
  border: 0;
  background: transparent;
  color: var(--oc-navy);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

/* On scroll, logo moves fully into the fixed white navigation bar. */
@media (min-width: 941px) {
  .oc-site-header.is-scrolled {
    height: var(--oc-sticky-header-height);
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
  }
  .oc-site-header.is-scrolled .oc-header-inner,
  .oc-site-header.is-scrolled .oc-main-nav { height: var(--oc-sticky-header-height); }
  .oc-site-header.is-scrolled .oc-branding-wrap {
    width: 134px;
    height: 65px;
    flex-basis: 134px;
  }
  .oc-site-header.is-scrolled .oc-branding,
  .oc-site-header.is-scrolled .custom-logo-link {
    width: 134px;
    height: 65px;
  }
  .oc-site-header.is-scrolled .oc-branding img,
  .oc-site-header.is-scrolled .custom-logo-link img,
  .oc-site-header.is-scrolled .custom-logo {
    width: 134px !important;
    height: 65px !important;
    max-width: 134px !important;
    max-height: 65px !important;
  }
  /* Scale the badge down in step with the logo rather than staying full-size next to a shrunk logo. */
  .oc-site-header.is-scrolled .oc-logo-badge {
    margin-left: 10px;
    transform: scale(.85);
    transform-origin: left center;
  }
}

.oc-hero {
  position: relative;
  z-index: 10;
  height: 145px;
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
}

/* Below Header widget area -- full page width (not capped to the site's
   normal content container), per explicit request. Only ever present in
   markup when it actually has a widget (see is_active_sidebar() guard
   in functions.php), so no empty-state rules needed. */
.oc-below-header {
  width: 100%;
  padding: 18px 20px;
  box-sizing: border-box;
}
.oc-below-header-widget + .oc-below-header-widget { margin-top: 16px; }
.oc-below-header-title {
  margin: 0 0 8px;
  color: #333;
  font-size: 18px;
  font-weight: 600;
}

/* GeneratePress content + sidebars stay intact; only visual presentation changes. */
#page.site.grid-container {
  max-width: var(--oc-max);
  background: #fff;
}
#page .site-content { padding-top: 0; }
#primary { padding-top: 22px; padding-bottom: 70px; }
#primary .site-main { margin-top: 0; }
#primary .inside-article {
  padding-top: 0;
  background: transparent;
  box-shadow: none;
}
#primary .entry-header { margin-bottom: 38px; }
#primary .entry-title {
  margin: 0;
  color: #333;
  font-size: 40px;
  font-weight: 300;
  line-height: 1.2;
}
#primary .entry-content {
  color: var(--oc-text);
  font-size: 16px;
}
#primary .entry-content p { margin-bottom: 22px; }
#primary .entry-content h2,
#primary .entry-content h3 { color: #333; font-weight: 400; }
#primary .entry-content a { color: #666; text-decoration: underline; }
#primary .entry-content .wp-block-button__link,
#primary .entry-content .button {
  display: inline-block;
  padding: 13px 28px;
  border-radius: 0;
  background: #1395e8;
  color: #fff !important;
  text-decoration: none !important;
  font-size: 14px;
}

/* Keep GeneratePress sidebar positioning, widget registration and per-page layout controls. */
.widget-area { padding-top: 22px; }
.widget-area .widget {
  background: #fff;
  color: var(--oc-text);
}
.widget-area .widget-title {
  color: #333;
  font-weight: 400;
}
.widget-area a { color: var(--oc-navy); }

.site-footer { border-top: 1px solid #eee; }
.site-info { background: #fff; color: #888; font-size: 13px; }
.site-info a { color: #666; }

@media (max-width: 1120px) {
  .oc-header-inner { max-width: calc(100% - 40px); }
  .oc-main-nav a { padding-left: 9px; padding-right: 9px; font-size: 13px; }
  #page.site.grid-container { max-width: calc(100% - 40px); }
}

@media (max-width: 940px) {
  :root { --oc-header-height: 86px; }
  .oc-site-header { height: var(--oc-header-height); }
  .oc-header-inner { max-width: none; padding: 0 20px; align-items: center; }
  .oc-branding-wrap,
  .oc-branding,
  .oc-branding-wrap .custom-logo-link {
    width: 180px;
    height: 88px;
    flex-basis: 180px;
  }
  .oc-branding img,
  .oc-branding-wrap .custom-logo-link img,
  .oc-branding-wrap .custom-logo {
    width: 180px !important;
    height: 88px !important;
    max-width: 180px !important;
    max-height: 88px !important;
  }
  .oc-mobile-toggle { display: block; margin-left: auto; }
  .oc-main-nav {
    display: none;
    position: absolute;
    z-index: 80;
    left: 0;
    right: 0;
    top: 100%;
    height: auto;
    background: #fff;
    border-top: 1px solid #eee;
    box-shadow: 0 5px 15px rgba(0,0,0,.08);
  }
  .oc-main-nav.is-open { display: block; }
  .oc-main-nav > ul,
  .oc-main-nav .oc-primary-menu { display: block; height: auto; }
  .oc-main-nav li { display: block; border: 0; border-bottom: 1px solid #eee; }
  .oc-main-nav li:last-child { border-right: 0; }
  .oc-main-nav a { display: block; padding: 14px 24px; font-size: 14px; }
  .oc-main-nav .sub-menu { position: static; display: block; box-shadow: none; padding-left: 18px; }
  .oc-hero { height: 125px; }
  #page.site.grid-container { max-width: none; }
  #primary { padding-top: 28px; }
}

@media screen and (max-width: 782px) {
  .admin-bar .oc-site-header { top: 46px; }
}

@media (max-width: 600px) {
  .oc-header-inner { padding: 0 16px; }
  .oc-branding-wrap,
  .oc-branding,
  .oc-branding-wrap .custom-logo-link {
    width: 150px;
    height: 73px;
    flex-basis: 150px;
  }
  .oc-branding img,
  .oc-branding-wrap .custom-logo-link img,
  .oc-branding-wrap .custom-logo {
    width: 150px !important;
    height: 73px !important;
    max-width: 150px !important;
    max-height: 73px !important;
  }
  .oc-hero { height: 95px; }
  #primary .entry-title { font-size: 34px; }
}
