/**
 * Global Admin & Toolbar Branding for Town of Caledon
 * Strictly scoped to the Admin Toolbar sidebar to never affect frontend pages.
 */
@import url('toc_menu_builder.css');
@import url('sitemap_menu_editor.css');

/* ─── 1. CORE NAVIGATION SIDEBAR / HEADER BRANDING ────────────────────────── */
.admin-toolbar .admin-toolbar__header,
.admin-toolbar .admin-toolbar__content .admin-toolbar__header {
  padding: 16px 14px 24px 14px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  background: transparent !important;
  border: none !important;
}

/* Eradicate any background, border, outline, box-shadow on admin toolbar logo and its wrappers at all times & states */
.admin-toolbar .admin-toolbar__header .admin-toolbar__logo,
.admin-toolbar .admin-toolbar__header .menu--logo,
.admin-toolbar .admin-toolbar__logo,
.admin-toolbar .admin-toolbar__logo *,
.admin-toolbar .admin-toolbar__logo *:hover,
.admin-toolbar .admin-toolbar__logo *:focus,
.admin-toolbar .admin-toolbar__logo *:focus-visible,
.admin-toolbar .admin-toolbar__logo *:active,
.admin-toolbar .admin-toolbar__logo *::before,
.admin-toolbar .admin-toolbar__logo *::after,
.admin-toolbar .menu--logo,
.admin-toolbar .menu--logo *,
.admin-toolbar .menu--logo *:hover,
.admin-toolbar .menu--logo *:focus,
.admin-toolbar .menu--logo *:focus-visible,
.admin-toolbar .menu--logo *:active,
.admin-toolbar .menu--logo *::before,
.admin-toolbar .menu--logo *::after {
  background: transparent !important;
  background-color: transparent !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  text-decoration: none !important;
}

.admin-toolbar .admin-toolbar__logo {
  display: inline-flex !important;
  align-items: center !important;
  width: auto !important;
  max-width: 165px !important;
  height: 44px !important;
  border-radius: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
}

.admin-toolbar .admin-toolbar__logo .toolbar-menu,
.admin-toolbar .admin-toolbar__logo .toolbar-menu__item {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
}

.admin-toolbar .admin-toolbar__logo .toolbar-link,
.admin-toolbar .admin-toolbar__logo a {
  display: inline-flex !important;
  align-items: center !important;
  padding: 0 !important;
  margin: 0 !important;
  pointer-events: none !important;
  cursor: default !important;
}

.admin-toolbar .admin-toolbar__logo .toolbar-link:hover,
.admin-toolbar .admin-toolbar__logo a:hover {
  opacity: 1 !important;
  cursor: default !important;
}

/* Full Brand Vector Logo when Navigation is Expanded */
.admin-toolbar:not(.admin-toolbar--collapsed) .admin-toolbar__logo img,
[data-drupal-nav-expanded="true"] .admin-toolbar .admin-toolbar__logo img,
.admin-toolbar-expanded .admin-toolbar .admin-toolbar__logo img,
.admin-toolbar .admin-toolbar__logo img {
  width: 140px !important;
  height: auto !important;
  max-width: 150px !important;
  max-height: 44px !important;
  min-width: unset !important;
  object-fit: contain !important;
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  display: block !important;
}

/* When Navigation Sidebar is Collapsed (Icon-only mode) */
.admin-toolbar.admin-toolbar--collapsed .admin-toolbar__header,
html:not(.admin-toolbar-expanded) .admin-toolbar .admin-toolbar__header {
  padding: 10px 6px !important;
  justify-content: center !important;
}

.admin-toolbar.admin-toolbar--collapsed .admin-toolbar__logo,
html:not(.admin-toolbar-expanded) .admin-toolbar .admin-toolbar__logo {
  max-width: 38px !important;
  max-height: 38px !important;
  padding: 0 !important;
}

.admin-toolbar.admin-toolbar--collapsed .admin-toolbar__logo img,
html:not(.admin-toolbar-expanded) .admin-toolbar .admin-toolbar__logo img {
  width: 34px !important;
  height: 34px !important;
  max-width: 34px !important;
  max-height: 34px !important;
  object-fit: contain !important;
}

/* Hide fallback Drupal drop SVG inside admin toolbar if rendered */
.admin-toolbar .admin-toolbar__logo svg {
  display: none !important;
}

.toolbar .toolbar-bar #toolbar-item-administration-tray a.toolbar-icon-admin-toolbar-tools-help.toolbar-icon-default:hover::before {
  background-color: transparent !important;
  transform: scale(1.08);
}

/* Invert the sidebar brand logo to a softer off-white when the toolbar is dark */
html[data-gin-toolbar-theme="dark"] .admin-toolbar .admin-toolbar__logo img,
html[data-gin-theme="dark"] .admin-toolbar .admin-toolbar__logo img,
.gin--dark-toolbar .admin-toolbar .admin-toolbar__logo img,
.gin--dark-mode .admin-toolbar .admin-toolbar__logo img {
  filter: brightness(0) invert(0.85) opacity(0.9) !important;
}

/* "View the Website" Link above Dashboard */
.toolbar-link--view-website::before {
  --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3Cpolyline points='15 3 21 3 21 9'/%3E%3Cline x1='10' y1='14' x2='21' y2='3'/%3E%3C/svg%3E") !important;
  -webkit-mask-image: var(--icon) !important;
  mask-image: var(--icon) !important;
}

/* ─── 2. SUPER UI HUB PAGES (SUPPORT & TRAINING) ────────────────────────── */
.toc-super-hub-page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 24px 20px 60px;
  font-family: inherit;
  box-sizing: border-box;
}

/* Hero Header Banner (Light Modern Palette) */
.toc-hub-hero {
  position: relative;
  border-radius: 16px;
  padding: 32px 36px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 28px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.03);
  overflow: hidden;
  box-sizing: border-box;
}

.toc-hub-hero--support {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 50%, #ffffff 100%);
  border: 1px solid #bae6fd;
  border-left: 6px solid #0284c7;
}

.toc-hub-hero--training {
  background: linear-gradient(135deg, #faf5ff 0%, #f3e8ff 50%, #ffffff 100%);
  border: 1px solid #e9d5ff;
  border-left: 6px solid #7c3aed;
}

.toc-hub-hero__content {
  flex: 1;
  min-width: 280px;
}

.toc-hub-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #bae6fd;
  color: #0284c7;
  padding: 5px 12px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
  box-shadow: 0 1px 3px rgba(2, 132, 199, 0.08);
}

.toc-hub-pill--purple {
  background: #ffffff;
  border-color: #ddd6fe;
  color: #7c3aed;
  box-shadow: 0 1px 3px rgba(124, 58, 237, 0.08);
}

.toc-hub-hero__title {
  margin: 0 0 6px !important;
  font-size: 26px !important;
  font-weight: 800 !important;
  color: var(--gin-color-text, #0f172a) !important;
  letter-spacing: -0.025em !important;
  line-height: 1.2 !important;
}

.toc-hub-hero__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--gin-color-text-light, #475569);
  max-width: 680px;
}

.toc-hub-hero__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.toc-hub-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
}

.toc-hub-btn--dashboard,
.toc-hub-btn--white {
  background: #ffffff;
  color: #0f172a !important;
  border: 1px solid #cbd5e1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.toc-hub-btn--dashboard:hover,
.toc-hub-btn--white:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.toc-hub-btn--settings {
  background: #e0f2fe;
  color: #0284c7 !important;
  border: 1px solid #bae6fd;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.08);
}

.toc-hub-btn--settings:hover {
  background: #0284c7;
  color: #ffffff !important;
  border-color: #0284c7;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.2);
}

.toc-hub-btn--settings-purple {
  background: #ede9fe;
  color: #6d28d9 !important;
  border: 1px solid #ddd6fe;
  box-shadow: 0 2px 6px rgba(109, 40, 217, 0.08);
}

.toc-hub-btn--settings-purple:hover {
  background: #6d28d9;
  color: #ffffff !important;
  border-color: #6d28d9;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(109, 40, 217, 0.2);
}

.toc-hub-btn--primary {
  background: #0066cc;
  color: #ffffff !important;
}

.toc-hub-btn--primary:hover {
  background: #0052a3;
  transform: translateY(-2px);
}

.toc-hub-btn--purple {
  background: #6d28d9;
  color: #ffffff !important;
}

.toc-hub-btn--purple:hover {
  background: #5b21b6;
  transform: translateY(-2px);
}

.toc-hub-btn-sm {
  background: #f0f9ff;
  color: #0284c7;
  border: 1px dashed #7dd3fc;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.toc-hub-btn-sm:hover {
  background: #e0f2fe;
  border-color: #0284c7;
  color: #0369a1;
  transform: translateY(-1px);
}

.toc-row-remove-btn {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.toc-row-remove-btn:hover {
  background: #fee2e2;
  border-color: #dc2626;
}

.toc-form-grid-3 {
  display: grid;
  grid-template-columns: 2fr 1fr 2fr;
  gap: 10px;
}

/* Emergency Banner Card */
.toc-hub-emergency-card {
  background: #fff5f5;
  border: 1px solid #fed7d7;
  border-left: 6px solid #e53e3e;
  border-radius: 14px;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 32px;
  box-shadow: 0 2px 10px rgba(229, 62, 62, 0.08);
}

.toc-hub-emergency-card__left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  min-width: 280px;
}

.toc-hub-emergency-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #fed7d7;
  color: #c53030;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toc-hub-emergency-title {
  margin: 0 0 3px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  color: #9b2c2c !important;
}

.toc-hub-emergency-desc {
  margin: 0;
  font-size: 13px;
  color: #742a2a;
}

.toc-hub-emergency-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #e53e3e;
  color: #ffffff !important;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.18s ease;
  box-shadow: 0 2px 8px rgba(229, 62, 62, 0.25);
}

.toc-hub-emergency-btn:hover {
  background: #c53030;
  transform: translateY(-1px);
}

/* Admin Edit Details Panel */
.toc-admin-edit-panel {
  background: var(--gin-bg-layer, #f8fafc);
  border: 1px dashed var(--gin-border-color, #cbd5e1);
  border-radius: 14px;
  padding: 18px 24px;
  margin-bottom: 36px;
}

.toc-admin-edit-panel__summary {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  font-weight: 700;
  font-size: 14px;
  color: var(--gin-color-text, #0f172a);
}

.toc-admin-edit-panel__summary-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toc-admin-badge {
  background: #e0f2fe;
  color: #0369a1;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  text-transform: uppercase;
}

.toc-admin-badge--purple {
  background: #ede9fe;
  color: #6d28d9;
}

.toc-admin-toggle-hint {
  font-size: 12.5px;
  color: var(--gin-color-primary, #0066cc);
  font-weight: 600;
}

.toc-admin-form {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--gin-border-color, #e2e8f0);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.toc-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.toc-form-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--gin-color-text, #334155);
}

.toc-form-sublabel {
  font-size: 11.5px;
  font-weight: 600;
  color: #64748b;
  display: block;
  margin-bottom: 3px;
}

.toc-form-input,
.toc-form-textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--gin-border-color, #cbd5e1);
  border-radius: 8px;
  font-size: 13px;
  background: var(--gin-bg-layer, #ffffff);
  color: var(--gin-color-text, #0f172a);
  box-sizing: border-box;
}

.toc-form-section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--gin-color-text, #0f172a);
  margin-top: 10px;
}

.toc-form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.toc-form-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.toc-form-contact-row {
  background: var(--gin-bg-layer, #ffffff);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 12px;
}

.toc-form-footer {
  margin-top: 8px;
}

/* Section Headers */
.toc-hub-section-header {
  margin-bottom: 20px;
}

.toc-hub-section-title {
  font-size: 20px !important;
  font-weight: 800 !important;
  color: var(--gin-color-text, #0f172a) !important;
  margin: 0 0 4px !important;
  letter-spacing: -0.02em !important;
}

.toc-hub-section-sub {
  margin: 0;
  font-size: 13.5px;
  color: var(--gin-color-text-light, #64748b);
}

/* Super UI Card Grid */
.toc-hub-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 22px;
  margin-bottom: 36px;
}

.toc-super-card {
  background: var(--gin-bg-layer, #ffffff);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.toc-super-card:hover {
  transform: translateY(-3px);
  border-color: #cbd5e1;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.07);
}

.toc-super-card__badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.toc-super-badge {
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 9999px;
  letter-spacing: 0.02em;
}

.toc-super-badge--blue {
  background: #e0f2fe;
  color: #0284c7;
}

.toc-super-hours {
  font-size: 11.5px;
  color: #94a3b8;
  font-weight: 500;
}

.toc-super-card__title {
  margin: 0 0 8px !important;
  font-size: 17px !important;
  font-weight: 700 !important;
  color: var(--gin-color-text, #0f172a) !important;
  line-height: 1.3 !important;
}

.toc-super-card__desc {
  margin: 0 0 16px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--gin-color-text-light, #64748b);
}

.toc-super-card__bottom {
  border-top: 1px solid var(--gin-border-color, #f1f5f9);
  padding-top: 16px;
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toc-super-contact-action {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none !important;
  transition: all 0.16s ease;
  box-sizing: border-box;
}

.toc-super-contact-action--email {
  background: #eff6ff;
  color: #0066cc !important;
  border: 1px solid #dbeafe;
}

.toc-super-contact-action--email:hover {
  background: #dbeafe;
  color: #004b99 !important;
}

.toc-super-contact-action--phone {
  background: #f8fafc;
  color: #334155 !important;
  border: 1px solid #e2e8f0;
}

.toc-super-contact-action--phone:hover {
  background: #f1f5f9;
  color: #0f172a !important;
}

.toc-super-btn-launch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 18px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.18s ease;
}

.toc-super-btn-launch:hover {
  transform: translateX(2px);
  filter: brightness(0.95);
}

/* Quick Tools & Downloads Grid */
.toc-hub-quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.toc-hub-quick-card {
  background: var(--gin-bg-layer, #ffffff);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none !important;
  color: inherit !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: all 0.18s ease;
}

.toc-hub-quick-card:hover {
  border-color: var(--gin-color-primary, #0066cc);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 102, 204, 0.08);
}

.toc-hub-quick-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #eff6ff;
  color: #0066cc;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toc-hub-quick-card__content h4 {
  margin: 0 0 2px !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  color: var(--gin-color-text, #0f172a) !important;
}

.toc-hub-quick-card__content span {
  font-size: 12px;
  font-weight: 600;
  color: var(--gin-color-primary, #0066cc);
}

.toc-hub-download-card {
  background: var(--gin-bg-layer, #ffffff);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.toc-hub-download-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: #ede9fe;
  color: #6d28d9;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toc-hub-download-content {
  flex: 1;
  min-width: 0;
}

.toc-hub-download-content h4 {
  margin: 0 0 2px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  color: var(--gin-color-text, #0f172a) !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.toc-hub-download-size {
  font-size: 11.5px;
  color: #94a3b8;
}

.toc-hub-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  color: #334155 !important;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.toc-hub-download-btn:hover {
  background: #6d28d9;
  color: #ffffff !important;
}

/* Color Selection Palette & Touch Labeled Pills */
.toc-color-picker-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.toc-color-pill-list {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.toc-color-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gin-bg-layer, #f8fafc);
  border: 1px solid var(--gin-border-color, #cbd5e1);
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--gin-color-text, #334155);
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.toc-color-pill:hover {
  background: #ffffff;
  border-color: #94a3b8;
  transform: translateY(-1px);
}

.toc-color-pill.is-selected {
  background: #ffffff;
  border-color: #0f172a;
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.2);
  font-weight: 700;
}

.toc-color-pill__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.toc-color-custom-wrap {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.toc-color-picker {
  -webkit-appearance: none;
  border: 1px solid var(--gin-border-color, #cbd5e1);
  border-radius: 6px;
  width: 32px;
  height: 28px;
  padding: 0;
  cursor: pointer;
  background: transparent;
}

.toc-color-picker::-webkit-color-swatch-wrapper {
  padding: 2px;
}

.toc-color-picker::-webkit-color-swatch {
  border: none;
  border-radius: 4px;
}

/* Visibility Control Switches */
.toc-visibility-panel {
  background: var(--gin-bg-layer, #ffffff);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 20px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
}

.toc-visibility-panel__title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gin-color-text, #0f172a);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.toc-toggle-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gin-color-text, #1e293b);
  cursor: pointer;
  background: var(--gin-bg-layer2, #f8fafc);
  border: 1px solid var(--gin-border-color, #e2e8f0);
  padding: 8px 14px;
  border-radius: 8px;
  transition: all 0.15s ease;
}

.toc-toggle-label:hover {
  border-color: var(--gin-color-primary, #0066cc);
}

.toc-toggle-label input[type="checkbox"] {
  width: 17px;
  height: 17px;
  cursor: pointer;
  accent-color: #0066cc;
}

/* File Picker and S3 inputs */
.toc-file-choice-box {
  background: var(--gin-bg-layer2, #f8fafc);
  border: 1px dashed var(--gin-border-color, #cbd5e1);
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.toc-form-file-input {
  font-size: 12px;
  cursor: pointer;
}

/* Dark Mode Overrides */
.gin--dark-mode .toc-super-card,
.gin--dark-mode .toc-hub-quick-card,
.gin--dark-mode .toc-hub-download-card,
.gin--dark-mode .toc-admin-edit-panel,
.gin--dark-mode .toc-visibility-panel {
  background: #1e293b;
  border-color: rgba(255, 255, 255, 0.08);
}

.gin--dark-mode .toc-super-card__title,
.gin--dark-mode .toc-hub-quick-card__content h4,
.gin--dark-mode .toc-hub-download-content h4,
.gin--dark-mode .toc-admin-edit-panel__summary,
.gin--dark-mode .toc-visibility-panel__title {
  color: #f8fafc !important;
}

.gin--dark-mode .toc-toggle-label {
  background: #0f172a;
  border-color: #334155;
  color: #f1f5f9;
}

.gin--dark-mode .toc-color-pill {
  background: #0f172a;
  border-color: #334155;
  color: #e2e8f0;
}

.gin--dark-mode .toc-color-pill.is-selected {
  background: #1e293b;
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.3);
}

.gin--dark-mode .toc-file-choice-box {
  background: #0f172a;
  border-color: #334155;
}

.gin--dark-mode .toc-super-contact-action--phone {
  background: #0f172a;
  border-color: #334155;
  color: #e2e8f0 !important;
}

.gin--dark-mode .toc-form-input,
.gin--dark-mode .toc-form-textarea,
.gin--dark-mode .toc-form-contact-row {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
}

/* Fix contact view page title — force label+value on same line */
.field.field--name-title.field--type-string.field--label-inline {
  display: flex !important;
}

/* Hide contextual edit icon on Content Blocks view page */
.view-id-block_content .contextual {
  display: none !important;
}

/* ==========================================================================
   CKEditor 5 Proposed Layout: Row 2 Icon + Label Styling
   ========================================================================== */

/* Toolbar container wrapping and compact spacing */
.ck.ck-toolbar > .ck-toolbar__items {
  flex-wrap: wrap !important;
  row-gap: 3px !important;
}

/* Force line break between Row 1 (Typography) and Row 2 (Components / Media / Styles / Utilities) */
.ck.ck-toolbar .ck-toolbar__line-break {
  flex-basis: 100% !important;
  width: 100% !important;
  height: 0 !important;
  margin: 3px 0 4px 0 !important;
  border-bottom: 1px solid #e2e8f0 !important;
  display: block !important;
}

/* Row 2 Buttons: Compact, stacked icon on top, label on bottom */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__item .ck-button,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-button,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__button {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  height: auto !important;
  min-height: 40px !important;
  min-width: 34px !important;
  padding: 3px 4px 2px 4px !important;
  margin: 0 1px !important;
  border-radius: 4px !important;
  position: relative !important;
  box-sizing: border-box !important;
  text-decoration: none !important;
  background: transparent !important;
  border: 1px solid transparent !important;
  transition: all 0.15s ease !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__item .ck-button:hover,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-button:hover,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__button:hover {
  background: #f1f5f9 !important;
  border-color: #e2e8f0 !important;
}

/* Row 2 Icons: Centered, crisp 17px */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__item .ck-button .ck-icon,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-button .ck-icon,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__button .ck-icon {
  width: 17px !important;
  height: 17px !important;
  margin: 0 0 1px 0 !important;
  flex-shrink: 0 !important;
  color: #334155 !important;
}

/* Row 2 Labels: Completely hide raw text node, show clear bold label via ::before */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__item .ck-button .ck-button__label,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-button .ck-button__label,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__button .ck-button__label {
  display: block !important;
  font-size: 0 !important;
  line-height: 0 !important;
  color: transparent !important;
  white-space: nowrap !important;
  overflow: visible !important;
  width: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: center !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__item .ck-button .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-button .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__button .ck-button__label::before {
  font-size: 11px !important;
  font-weight: 600 !important;
  line-height: 1.15 !important;
  color: #1e293b !important;
  display: block !important;
  white-space: nowrap !important;
  text-align: center !important;
  visibility: visible !important;
  letter-spacing: -0.15px !important;
}

/* Hide separate dropdown chevron arrows in Row 2 — chevrons are cleanly included in label */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown .ck-dropdown__arrow {
  display: none !important;
}

/* Separators in Row 2 */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-toolbar__separator {
  height: 28px !important;
  align-self: center !important;
  margin: 0 3px !important;
  background: #cbd5e1 !important;
  width: 1px !important;
}

/* ── Row 2 Exact Labels ── */

/* Content Components */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Accordion" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown button[data-cke-tooltip-text*="Accordion" i] .ck-button__label::before {
  content: "Accordion" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Container" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Column" i] .ck-button__label::before {
  content: "Columns" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="table" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown button[data-cke-tooltip-text*="table" i] .ck-button__label::before {
  content: "Table" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Horizontal" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="line" i] .ck-button__label::before {
  content: "Horizontal Rule" !important;
}

/* Media & Files */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Upload image" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Insert image" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Image" i] .ck-button__label::before {
  content: "Image" !important;
}

/* Video (mediaEmbed only) */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Insert media"] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="media URL" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Video" i] .ck-button__label::before {
  content: "Video" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Slider" i] .ck-button__label::before {
  content: "Image Slider" !important;
}

/* Embed (iframeEmbed) */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="iframe" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Url Embed" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Embed" i] .ck-button__label::before {
  content: "Embed" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Contact Email" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Email" i] .ck-button__label::before {
  content: "Email Link" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="File" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="S3" i] .ck-button__label::before {
  content: "File Manager" !important;
}

/* Styles & Templates */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-style-dropdown .ck-dropdown__button .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Styles" i] .ck-button__label::before {
  content: "Styles ⌄" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown button[data-cke-tooltip-text*="Template" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-dropdown button[data-cke-tooltip-text*="template" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-template-dropdown .ck-dropdown__button .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ * button[data-cke-tooltip-text*="Template" i] .ck-button__label::before,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Template" i] .ck-button__label::before {
  content: "Templates ⌄" !important;
}

/* Editor Utilities */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Undo" i] .ck-button__label::before {
  content: "Undo" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Redo" i] .ck-button__label::before {
  content: "Redo" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="blocks" i] .ck-button__label::before {
  content: "Show Blocks" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="fullscreen" i] .ck-button__label::before {
  content: "Fullscreen" !important;
}

.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Source" i] .ck-button__label::before {
  content: "Source" !important;
}

/* ── Custom Icons matching proposed mockup exactly ── */

/* Styles: Magic wand icon on top (strictly scoped to Styles dropdown in Row 2) */
.ck.ck-toolbar .ck-toolbar__line-break ~ .ck-style-dropdown .ck-dropdown__button::before {
  content: '';
  display: block;
  width: 17px;
  height: 17px;
  margin-bottom: 2px;
  background: #334155;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 3-1.912 5.813a2 2 0 0 1-1.275 1.275L3 12l5.813 1.912a2 2 0 0 1 1.275 1.275L12 21l1.912-5.813a2 2 0 0 1 1.275-1.275L21 12l-5.813-1.912a2 2 0 0 1-1.275-1.275L12 3Z'/%3E%3Cpath d='M5 3v4'/%3E%3Cpath d='M19 17v4'/%3E%3Cpath d='M3 5h4'/%3E%3Cpath d='M17 19h4'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 3-1.912 5.813a2 2 0 0 1-1.275 1.275L3 12l5.813 1.912a2 2 0 0 1 1.275 1.275L12 21l1.912-5.813a2 2 0 0 1 1.275-1.275L21 12l-5.813-1.912a2 2 0 0 1-1.275-1.275L12 3Z'/%3E%3Cpath d='M5 3v4'/%3E%3Cpath d='M19 17v4'/%3E%3Cpath d='M3 5h4'/%3E%3Cpath d='M17 19h4'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* Image: Photo frame with mountain & sun */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Upload image" i] .ck-icon svg,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Insert image" i] .ck-icon svg {
  display: none !important;
}
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Upload image" i] .ck-icon,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="Insert image" i] .ck-icon {
  background: #334155 !important;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='18' height='18' x='3' y='3' rx='2' ry='2'/%3E%3Ccircle cx='9' cy='9' r='2'/%3E%3Cpath d='m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21'/%3E%3C/svg%3E") no-repeat center / contain !important;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='18' height='18' x='3' y='3' rx='2' ry='2'/%3E%3Ccircle cx='9' cy='9' r='2'/%3E%3Cpath d='m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21'/%3E%3C/svg%3E") no-repeat center / contain !important;
}

/* Video: Monitor with play icon (mediaEmbed only) */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Insert media"] .ck-icon svg,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="media URL" i] .ck-icon svg {
  display: none !important;
}
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text="Insert media"] .ck-icon,
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="media URL" i] .ck-icon {
  background: #334155 !important;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='20' height='15' x='2' y='4.5' rx='2.5'/%3E%3Cpolygon points='10 9.5 15 12 10 14.5 10 9.5' fill='currentColor'/%3E%3C/svg%3E") no-repeat center / contain !important;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='20' height='15' x='2' y='4.5' rx='2.5'/%3E%3Cpolygon points='10 9.5 15 12 10 14.5 10 9.5' fill='currentColor'/%3E%3C/svg%3E") no-repeat center / contain !important;
}

/* Embed: Code brackets icon (iframeEmbed) */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="iframe" i] .ck-icon svg {
  display: none !important;
}
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="iframe" i] .ck-icon {
  background: #334155 !important;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='16 18 22 12 16 6'/%3E%3Cpolyline points='8 6 2 12 8 18'/%3E%3Cline x1='14' y1='4' x2='10' y2='20'/%3E%3C/svg%3E") no-repeat center / contain !important;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='16 18 22 12 16 6'/%3E%3Cpolyline points='8 6 2 12 8 18'/%3E%3Cline x1='14' y1='4' x2='10' y2='20'/%3E%3C/svg%3E") no-repeat center / contain !important;
}

/* Show Blocks: Clean dashed square outline */
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="blocks" i] .ck-icon svg {
  display: none !important;
}
.ck.ck-toolbar .ck-toolbar__line-break ~ button[data-cke-tooltip-text*="blocks" i] .ck-icon {
  background: #334155 !important;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='currentColor' stroke-width='2' stroke-dasharray='3 2'%3E%3Crect x='2.5' y='2.5' width='15' height='15' rx='2'/%3E%3C/svg%3E") no-repeat center / contain !important;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='currentColor' stroke-width='2' stroke-dasharray='3 2'%3E%3Crect x='2.5' y='2.5' width='15' height='15' rx='2'/%3E%3C/svg%3E") no-repeat center / contain !important;
}

/* CKEditor 5 Heading Styles: Exact match with theme styles.css */
.ck-content h1,
.ck.ck-content h1,
.ck-content h3,
.ck.ck-content h3,
.ck-content h4,
.ck.ck-content h4 {
  color: #014785 !important;
  margin: 0 0 16px !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
}

.ck-content h2,
.ck.ck-content h2 {
  color: #000000 !important;
  font-size: 1.65rem !important;
  margin: 0 0 16px !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
}

.ck-content h5,
.ck.ck-content h5,
.ck-content h6,
.ck.ck-content h6 {
  color: #000000 !important;
  margin: 0 0 16px !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
}

.ck-content h1, .ck.ck-content h1 { font-size: 1.75rem !important; }
.ck-content h3, .ck.ck-content h3 { font-size: 1.375rem !important; }
.ck-content h4, .ck.ck-content h4 { font-size: 1.25rem !important; }
.ck-content h5, .ck.ck-content h5 { font-size: 1.125rem !important; }
.ck-content h6, .ck.ck-content h6 { font-size: 1rem !important; }

/* CKEditor 5 Dropdown Heading Colors: H1, H3, H4 Blue; H2, H5, H6 Black */
.ck-dropdown__panel .ck-list__item button.ck-heading_heading1 .ck-button__label,
.ck-dropdown__panel .ck-list__item button.ck-heading_heading3 .ck-button__label,
.ck-dropdown__panel .ck-list__item button.ck-heading_heading4 .ck-button__label {
  color: #014785 !important;
}
.ck-dropdown__panel .ck-list__item button.ck-heading_heading2 .ck-button__label,
.ck-dropdown__panel .ck-list__item button.ck-heading_heading5 .ck-button__label,
.ck-dropdown__panel .ck-list__item button.ck-heading_heading6 .ck-button__label {
  color: #000000 !important;
}


/* CKEditor 5 Backend: Click-to-Toggle Accordions (Closed by default) */
.ck-content .ckeditor-accordion:not(.is-open):not([data-accordion-open="true"]) > .ckeditor-accordion-content,
.ck-content .ckeditor-accordion .ckeditor-accordion-title:not(.is-open):not([data-accordion-open="true"]) + .ckeditor-accordion-content {
  display: none !important;
}

.ck-content .ckeditor-accordion.is-open > .ckeditor-accordion-content,
.ck-content .ckeditor-accordion .ckeditor-accordion-title.is-open + .ckeditor-accordion-content,
.ck-content .ckeditor-accordion[data-accordion-open="true"] > .ckeditor-accordion-content,
.ck-content .ckeditor-accordion .ckeditor-accordion-title[data-accordion-open="true"] + .ckeditor-accordion-content {
  display: block !important;
}

/* Hide left-side icon so only 1 button shows on the right side */
.ck-content .ckeditor-accordion .ckeditor-accordion-title::before {
  display: none !important;
}

/* Accordion title styling and right-side toggle button (Bold to match live website) */
.ck-content .ckeditor-accordion .ckeditor-accordion-title {
  position: relative;
  padding-right: 48px !important;
  padding-left: 14px !important;
  min-height: 38px;
  font-weight: 700 !important;
}

.ck-content .ckeditor-accordion .ckeditor-accordion-title,
.ck-content .ckeditor-accordion .ckeditor-accordion-title * {
  font-weight: 700 !important;
}

/* Right-side Light Blue Play Button */
.ck-content .ckeditor-accordion .ckeditor-accordion-title::after {
  content: '▶';
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #0066cc;
  background: #e8f1fa;
  border: 1px solid #c5d8ef;
  border-radius: 6px;
  line-height: 1;
  box-sizing: border-box;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
  pointer-events: auto;
  user-select: none;
}

.ck-content .ckeditor-accordion .ckeditor-accordion-title:hover::after {
  background: #d0e4f7;
  border-color: #0066cc;
}

/* Open state: Rotated play arrow + solid active blue */
.ck-content .ckeditor-accordion.is-open > .ckeditor-accordion-title::after,
.ck-content .ckeditor-accordion .ckeditor-accordion-title.is-open::after,
.ck-content .ckeditor-accordion[data-accordion-open="true"] > .ckeditor-accordion-title::after,
.ck-content .ckeditor-accordion .ckeditor-accordion-title[data-accordion-open="true"]::after {
  transform: translateY(-50%) rotate(90deg);
  background: #0066cc;
  color: #ffffff;
  border-color: #0066cc;
}

/* Collapsed indicator style */
.ck-content .ckeditor-accordion:not(.is-open):not([data-accordion-open="true"]) {
  border-bottom: 1px dashed #ccc;
}

/* ── CKEditor 5 Caledon Data Table Styling (Matches Live Website Table Design) ── */
.ck-content table,
.ck-content figure.table table,
.ck-editor__editable table {
  width: 100% !important;
  border-collapse: collapse !important;
  margin: 16px 0 !important;
  border-radius: 8px !important;
  overflow: hidden !important;
}

.ck-content table caption,
.ck-content figure.table figcaption,
.ck-editor__editable table caption {
  font-size: 1.125rem !important;
  font-weight: 700 !important;
  margin: 6px 0 12px 0 !important;
  padding: 0 !important;
  text-align: left !important;
  color: #102a43 !important;
  caption-side: top !important;
}

.ck-content table td,
.ck-content table th,
.ck-content figure.table table td,
.ck-content figure.table table th,
.ck-editor__editable table td,
.ck-editor__editable table th {
  padding: 13px 18px !important;
  border: 1px solid #d2d6dc !important;
  color: #102a43 !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
  vertical-align: middle !important;
}

.ck-content table thead th,
.ck-content table thead td,
.ck-content figure.table table thead th,
.ck-content figure.table table thead td,
.ck-editor__editable table thead th,
.ck-editor__editable table thead td {
  text-align: left !important;
  padding: 13px 18px !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  background-color: #014785 !important;
  border: 1px solid #013768 !important;
}

.ck-content table thead th *,
.ck-content table thead td *,
.ck-content figure.table table thead th *,
.ck-content figure.table table thead td *,
.ck-editor__editable table thead th *,
.ck-editor__editable table thead td * {
  color: #ffffff !important;
}

.ck-content table tbody tr:nth-child(odd),
.ck-content figure.table table tbody tr:nth-child(odd),
.ck-editor__editable table tbody tr:nth-child(odd) {
  background-color: #ffffff !important;
}

.ck-content table tbody tr:nth-child(even),
.ck-content figure.table table tbody tr:nth-child(even),
.ck-editor__editable table tbody tr:nth-child(even) {
  background-color: #eaf3fb !important;
}

.ck-content table thead ~ tbody tr:nth-child(odd),
.ck-content figure.table table thead ~ tbody tr:nth-child(odd),
.ck-editor__editable table thead ~ tbody tr:nth-child(odd) {
  background-color: #ffffff !important;
}

.ck-content table thead ~ tbody tr:nth-child(even),
.ck-content figure.table table thead ~ tbody tr:nth-child(even),
.ck-editor__editable table thead ~ tbody tr:nth-child(even) {
  background-color: #eaf3fb !important;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SITE MAP MENU EDITOR STYLES (Collapsible, Blue Underline, Position Retain)
   ═══════════════════════════════════════════════════════════════════════════ */
/* 1. Only style actual menu title links in the first column */
#menu-overview tbody tr td:first-child a:not(.tabledrag-handle):not(.button),
.toc-sitemap-menu-edit-form #menu-overview td:first-child a:not(.tabledrag-handle):not(.button),
table[id^="menu-"] tbody tr td:first-child a:not(.tabledrag-handle):not(.button) {
  color: #0066cc !important;
  text-decoration: underline !important;
  font-weight: 500 !important;
  transition: color 0.15s ease, opacity 0.15s ease;
}

#menu-overview tbody tr td:first-child a:not(.tabledrag-handle):not(.button):hover,
#menu-overview tbody tr td:first-child a:not(.tabledrag-handle):not(.button):focus,
table[id^="menu-"] tbody tr td:first-child a:not(.tabledrag-handle):not(.button):hover {
  color: #004499 !important;
  text-decoration: underline !important;
}

/* 2. Operations dropbutton: transparent when closed, clean white dropdown when open */
#menu-overview .dropbutton-wrapper,
#menu-overview .dropbutton-widget,
#menu-overview .dropbutton {
  background: transparent !important;
  text-decoration: none !important;
}

#menu-overview .dropbutton-wrapper.open .dropbutton__items,
#menu-overview .dropbutton-wrapper.open .dropbutton {
  background: #ffffff !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12) !important;
}

#menu-overview .dropbutton-wrapper.open .dropbutton__item > a,
#menu-overview .dropbutton-wrapper.open .dropbutton__item > button,
#menu-overview .dropbutton-wrapper.open .dropbutton-action > a {
  background: #ffffff !important;
  color: #0066cc !important;
  text-decoration: none !important;
}

/* ONLY the specific item currently being hovered gets the blue highlight */
#menu-overview .dropbutton-wrapper.open .dropbutton__item > a:hover,
#menu-overview .dropbutton-wrapper.open .dropbutton__item > a:focus,
#menu-overview .dropbutton-wrapper.open .dropbutton__item > button:hover,
#menu-overview .dropbutton-wrapper.open .dropbutton-action > a:hover {
  background: #0066cc !important;
  color: #ffffff !important;
  text-decoration: none !important;
}

/* 3. Hierarchy headers: clear, consistent typography without patchy row backgrounds */
#menu-overview tr.sitemap-bucket-row td {
  padding-top: 10px !important;
  padding-bottom: 10px !important;
  font-weight: 700 !important;
  font-size: 15px !important;
  color: #0f172a !important;
}

#menu-overview tr.sitemap-section-row td {
  padding-top: 8px !important;
  padding-bottom: 8px !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  color: #1e293b !important;
}

.sitemap-toggle-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  margin: 0 6px 0 6px;
  border: 1px solid #94a3b8 !important;
  border-radius: 4px;
  background: #ffffff !important;
  color: #0284c7 !important;
  cursor: pointer !important;
  padding: 0 !important;
  vertical-align: middle;
  font-size: 11px !important;
  line-height: 1 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: all 0.15s ease;
}

.sitemap-toggle-btn:hover {
  background: #e0f2fe !important;
  border-color: #0284c7 !important;
  color: #0369a1 !important;
}

.sitemap-count-badge {
  display: inline-block !important;
  margin-left: 8px;
  padding: 2px 7px;
  background: #e2e8f0;
  color: #475569;
  font-size: 11px;
  font-weight: 600;
  border-radius: 10px;
  vertical-align: middle;
}

#menu-overview tr.sitemap-row-hidden {
  display: none !important;
}

.sitemap-editor-control-bar {
  display: flex !important;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 10px 14px;
  margin: 16px 0 12px 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.sitemap-editor-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sitemap-action-btn {
  display: inline-flex !important;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 5px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}

.sitemap-action-btn:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  color: #0f172a;
}

.sitemap-search-wrap {
  display: flex;
  align-items: center;
  position: relative;
  min-width: 250px;
}

.sitemap-search-input {
  width: 100%;
  padding: 6px 10px 6px 30px;
  font-size: 13px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff;
  outline: none;
}

.sitemap-search-input:focus {
  border-color: #0284c7;
  box-shadow: 0 0 0 2px rgba(2, 132, 199, 0.15);
}

.sitemap-search-icon {
  position: absolute;
  left: 9px;
  color: #94a3b8;
  pointer-events: none;
  font-size: 13px;
}

/* Hide block layout help line on Menus listing page */
body.path-admin-structure-menu .help,
body.path-admin-structure-menu .region-help,
body.path-admin-structure-menu .block-help-block {
  display: none !important;
}

/* Ensure top-bar and fixed right sidebar do not collide:
   Push the right sidebar header down below the top-bar (54px), and keep top-bar full width */
body.gin--edit-form .layout-region-node-secondary,
.gin--edit-form .page-wrapper__node-edit-form .layout-region-node-secondary,
#gin_sidebar {
  inset-block-start: 54px !important;
  height: calc(100% - 54px) !important;
  border-block-start: 1px solid var(--gin-border-color-layer, #e2e8f0) !important;
}

body.gin--edit-form .layout-region-node-secondary .entity-meta__header {
  padding-block-start: 1rem !important;
}

/* Ensure top navigation bar sits above the main content flow */
:is(#extra-specificity-hack, [data-drupal-admin-styles]).gin--navigation-top-bar,
.top-bar.gin--navigation-top-bar {
  z-index: 500 !important;
  box-sizing: border-box !important;
}

/* Username truncation and display rule:
   Always truncate to max-width so it never overflows.
   When the screen is narrower than 1440px, hide the text and show only the avatar icon. */
.top-bar__actions .toolbar-button .toolbar-button__label,
.top-bar__actions [class*="user"] .toolbar-button__label,
.top-bar__actions [data-toolbar-text] {
  max-width: 110px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  display: inline-block !important;
  vertical-align: middle !important;
}

@media (max-width: 1440px) {
  .top-bar__actions .toolbar-button:has(svg, .toolbar-button__icon) .toolbar-button__label,
  .top-bar__actions [class*="user"] .toolbar-button__label {
    display: none !important;
  }
}


/* ==========================================================================
   TOC Navigation Sidebar, Flyout & Tooltip z-index Fix on Frontend
   When the sidebar is collapsed on the website frontend, tooltips and flyouts
   must render in front of the sticky site header (z-index: 1005).
   ========================================================================== */
:root {
  --admin-toolbar-z-index: 2000;
  --admin-toolbar-z-index-tooltip: 999999;
  --admin-toolbar-z-index-popover: 2050;
}

:is(#extra-specificity-hack, [data-drupal-admin-styles]).admin-toolbar,
.admin-toolbar {
  z-index: 2000 !important;
}

.cloned-flyout,
:is(#extra-specificity-hack, [data-drupal-admin-styles]) [data-toolbar-popover-wrapper],
[data-toolbar-popover-wrapper] {
  z-index: 2050 !important;
}

.gin-tooltip-navigation,
.cloned-gin-tooltip-navigation,
.admin-toolbar__tooltip,
.toolbar-tooltip,
:is(#extra-specificity-hack, [data-drupal-admin-styles]) .toolbar-tooltip,
:is(#extra-specificity-hack, [data-drupal-admin-styles]) .gin-tooltip-navigation,
:is(#extra-specificity-hack, [data-drupal-admin-styles]) .cloned-gin-tooltip-navigation {
  z-index: 999999 !important;
  background-color: var(--gin-tooltip-bg, #0f172a) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

/* ==========================================================================
   CKEditor 5: Show Widget Type-Around Buttons Clearly & Prevent Scrollbars
   ========================================================================== */
.image-slider--widget,
.ckeditor-accordion,
.ck .ckeditor-accordion,
.ck-content blockquote,
.ck blockquote {
  overflow: visible !important;
}

.image-slider--widget {
  margin: 20px 0 !important;
}

.ckeditor-accordion {
  margin: 20px 0 !important;
}

.ck-content blockquote,
.ck blockquote {
  padding-top: 14px !important;
  padding-bottom: 14px !important;
}

.ck .ck-widget__type-around,
.ck-widget__type-around {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  z-index: 10 !important;
  overflow: visible !important;
}

.ck .ck-widget__type-around__button,
.ck-widget__type-around__button {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  z-index: 11 !important;
}

.ck-editor__editable,
.ck.ck-editor__editable_inline {
  overflow-x: hidden !important;
}

/* Ensure images inside CKEditor 5 and Accordions scale their height proportionally.
   Prevents images with large HTML height attributes (e.g. height="1650") from leaving
   huge empty white space below the image after preview or reload. */
.ck-content img,
.ck-editor__editable img,
.ck-content .image img,
.ck-content figure.image img,
.ck-content .ckeditor-accordion img {
  max-width: 100% !important;
  height: auto !important;
  display: block !important;
}

.ck-content figure.image,
.ck-editor__editable figure.image,
.ck-content .image {
  height: auto !important;
  max-width: 100% !important;
}

.ck-content .ckeditor-accordion-content,
.ck .ckeditor-accordion-content {
  height: auto !important;
  min-height: unset !important;
}
