/* ============================================================
   CODESM Mega Menu — Frontend Styles  v1.0.0
   Brand secondary: #2B8CEA
   ============================================================ */

/* ---- Nav trigger list ---- */
.codesm-nav-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}
@media (min-width: 64em) {
  .codesm-nav-list { gap: 2rem; }
}

.codesm-nav-item > .codesm-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: #fff;
  font-size: 1.125rem;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  text-decoration: none;
  line-height: 1.5rem;
  white-space: nowrap;
  cursor: pointer;
  padding: 0;
  border: none;
  background: none;
  transition: color 0.2s;
}
.codesm-nav-item > .codesm-nav-link:hover {
  color: rgba(255,255,255,0.8);
}
.codesm-nav-item > .codesm-nav-link:hover .codesm-indicator {
  background-image: url('/wp-content/uploads/2025/09/latest-plus-hover.svg');
}
.codesm-nav-item.codesm-active > .codesm-nav-link .codesm-indicator {
  background-image: url('/wp-content/uploads/2025/09/minus-icon-blue.svg');
}

/* Indicator icon (+ / −) */
.codesm-indicator {
  display: inline-block;
  width: 1.125rem;
  height: 1.125rem;
  flex-shrink: 0;
  background-image: url('/wp-content/uploads/2025/09/latest-plus.svg');
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
}

/* ---- Panels wrapper (position:fixed, top set via JS) ---- */
.codesm-mega-panels-wrap {
  position: fixed;
  left: 0;
  right: 0;
  z-index: 9999998;
  display: none;
}

/* ---- Individual panel ---- */
.codesm-mega-panel {
  display: none;
  background: #fff;
  border-bottom: 0.0625rem solid #E0E0E0;
  height: 25rem;
  overflow: hidden;
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
  box-sizing: border-box;
}
.codesm-mega-panel.codesm-open {
  display: flex;
  flex-direction: column;
}

/* ---- Foundation row inside panel ---- */
.codesm-mega-row {
  flex: 1;
  align-items: stretch;
}

/* ---- Left Discover column ---- */
.codesm-mega-left-col {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding-right: 1.625rem !important;
}

.codesm-discover {
  display: block;
  font-size: 2.75rem;
  color: #767676;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  line-height: 3.5rem;
  letter-spacing: -0.5px;
  margin-bottom: 0;
}

.codesm-headline {
  font-size: 2.75rem;
  font-weight: 400;
  line-height: 3.5rem;
  letter-spacing: -0.5px;
  color: #000;
  font-family: 'Inter', sans-serif;
  margin: 0;
}

.codesm-arrow-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  background: #2B8CEA;
  color: #fff;
  text-decoration: none;
  flex-shrink: 0;
  vertical-align: middle;
  margin-left: 0.25rem;
  transition: background 0.2s;
}
.codesm-arrow-btn:hover {
  background: #1a7ad4;
  color: #fff;
}
.codesm-arrow-btn img {
  width: 1rem;
  height: 1rem;
  object-fit: contain;
}

/* ---- Content columns ---- */
.codesm-col-before-divider {
  padding-right: 1.625rem !important;
}
.codesm-col-divider {
  border-left: 0.0625rem solid #D9D9D9;
  padding-left: 1.625rem !important;
}

.codesm-col-label {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.32px;
  color: #767676;
  margin-bottom: 2rem;
  font-family: 'Inter', sans-serif;
  line-height: 1.4084rem;
}
.codesm-col-label.codesm-col-label--hidden {
  visibility: hidden;
}

.codesm-mega-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.codesm-mega-col ul li {
  margin-bottom: 2rem;
}
.codesm-mega-col ul li:last-child {
  margin-bottom: 0;
}
.codesm-mega-col ul li a {
  font-size: 1.5rem;
  color: #000;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  line-height: 1.375rem;
  letter-spacing: -0.24px;
  transition: color 0.2s;
  display: inline;
}
.codesm-mega-col ul li a:hover {
  color: #2B8CEA;
}

.codesm-item-sub {
  display: block;
  font-size: 1rem;
  color: #000;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  margin-top: 0.25rem;
  line-height: 1.5rem;
  letter-spacing: -0.16px;
}

/* ---- Overlay ---- */
#codesm-mega-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.3);
  z-index: 9999997;
}
#codesm-mega-overlay.codesm-visible {
  display: block;
}


/* ============================================================
   Mobile Panel
   ============================================================ */

/* Hamburger button */
.codesm-mobile-open {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  position: absolute;
  right: 2.5rem;
  top: 50%;
  transform: translateY(-50%);
}
.codesm-mobile-open span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 1px;
  pointer-events: none;
}

/* Slide-in panel */
.codesm-mobile-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  background: #1a1a1a;
  z-index: 9999999;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.codesm-mobile-panel.codesm-mobile-is-open {
  transform: translateX(0);
}

/* Backdrop */
.codesm-mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 9999998;
}
.codesm-mobile-overlay.codesm-mobile-visible {
  display: block;
}

/* Panel header */
.codesm-mobile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 20px;
  flex-shrink: 0;
}
.codesm-mobile-logo-link img {
  height: 30px;
  width: auto;
}
.codesm-mobile-site-name {
  color: #fff;
  font-size: 1.125rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
}
.codesm-mobile-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Nav list */
.codesm-mobile-nav {
  flex: 1;
}
.codesm-mobile-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.codesm-mobile-item {
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.codesm-mobile-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
}
.codesm-mobile-item-link {
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 1.125rem;
  font-weight: 400;
  text-decoration: none;
  line-height: 1.4;
}
.codesm-mobile-item-link:hover {
  color: rgba(255,255,255,0.75);
}

/* Toggle button */
.codesm-mobile-item-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.codesm-mobile-indicator {
  display: block;
  width: 18px;
  height: 18px;
  background-image: url('/wp-content/uploads/2025/09/latest-plus.svg');
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
}
.codesm-mobile-item-toggle[aria-expanded="true"] .codesm-mobile-indicator {
  background-image: url('/wp-content/uploads/2025/09/minus-icon-blue.svg');
}

/* Expanded mega content */
.codesm-mobile-mega-content {
  padding: 0 20px 20px;
}
.codesm-mobile-section-label {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.32px;
  color: #767676;
  margin-top: 16px;
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.codesm-mobile-links {
  list-style: none;
  margin: 0;
  padding: 0;
}
.codesm-mobile-links li {
  margin-bottom: 14px;
}
.codesm-mobile-links li:last-child {
  margin-bottom: 0;
}
.codesm-mobile-links li a {
  color: #E5E9F0;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 400;
  text-decoration: none;
  line-height: normal;
  letter-spacing: -0.08px;
}
.codesm-mobile-links li a:hover {
  color: #2B8CEA;
}

/* Footer CTA */
.codesm-mobile-footer {
  padding: 20px;
  flex-shrink: 0;
}
.codesm-mobile-cta {
  display: block;
  text-align: center;
  background: #2B8CEA;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 500;
  padding: 14px 20px;
  text-decoration: none;
  border-radius: 2px;
  transition: background 0.2s;
}
.codesm-mobile-cta:hover {
  background: #1a7ad4;
  color: #fff;
}
