/* Help Guides Styles */
/* Based on the Facilitease modern design system */

:root {
  --guide-sidebar-width: 280px;
  --guide-primary: #478ac9;
  --guide-primary-dark: #2d5a8a;
  --guide-text: #1a1a2e;
  --guide-text-muted: #64748b;
  --guide-border: #e2e8f0;
  --guide-bg-light: #f8fafc;
  --guide-header-height: 100px;
  --guide-banner-height: 40px;
}

/* Embed Mode - Hide header, sidebar, footer for iframe embedding */
body.embed-mode .u-header,
body.embed-mode header.u-header,
body.embed-mode #sec-b0c8,
body.embed-mode .beta-warning-banner,
body.embed-mode .guides-sidebar,
body.embed-mode .guides-sidebar-toggle,
body.embed-mode #guidesSidebar,
body.embed-mode #sidebarToggle,
body.embed-mode .u-footer,
body.embed-mode footer.u-footer,
body.embed-mode #guide-footer,
body.embed-mode .guide-footer {
  display: none !important;
}

body.embed-mode .guides-wrapper {
  margin-left: 0;
  margin-top: 0;
  min-height: auto;
}

body.embed-mode .guides-content {
  padding: 20px;
  max-width: 100%;
}

body.embed-mode .guide-article {
  max-width: 100%;
}

body.embed-mode .page-hero {
  margin-top: 0;
}

/* BETA Warning Banner */
.beta-warning-banner {
  position: fixed;
  top: var(--guide-header-height);
  left: 0;
  right: 0;
  height: var(--guide-banner-height);
  background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
  color: white;
  text-align: center;
  padding: 8px 20px;
  font-size: 0.85rem;
  font-weight: 600;
  z-index: 1001;
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
}

.beta-warning-banner strong {
  background: rgba(255, 255, 255, 0.2);
  padding: 2px 8px;
  border-radius: 4px;
  margin-right: 8px;
}

/* Guides Layout */
.guides-wrapper {
  display: flex;
  min-height: calc(100vh - 160px);
  margin-left: var(--guide-sidebar-width);
}

/* Sidebar Navigation */
.guides-sidebar {
  width: var(--guide-sidebar-width);
  background: white;
  border-right: 1px solid var(--guide-border);
  position: fixed;
  top: calc(var(--guide-header-height) + var(--guide-banner-height));
  left: 0;
  bottom: 60px; /* Stop above footer */
  overflow-y: auto;
  z-index: 100;
  transition: transform 0.3s ease;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
}

/* Ensure header stays above sidebar */
.u-header.u-sticky,
.u-header.u-sticky-c26b {
  z-index: 1000 !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
}

/* Header nav active state - only show active style for the link with .active class */
/* Reset all nav links to default state (no highlight) */
.u-header .u-nav-1 .u-nav-link,
.u-header .u-nav-1 .u-nav-link.u-active-palette-1-base,
.u-header .u-nav-1 .u-nav-link.u-button-style,
.u-header .u-nav-1 .u-nav-item .u-nav-link {
  background: transparent !important;
  background-color: transparent !important;
  color: #333 !important;
}

/* Only the link with .active class gets blue background */
.u-header .u-nav-1 .u-nav-link.active,
.u-header .u-nav-1 .u-nav-link.u-active-palette-1-base.active,
.u-header .u-nav-1 .u-nav-item .u-nav-link.active {
  background: #478ac9 !important;
  background-color: #478ac9 !important;
  color: white !important;
  border-radius: 6px !important;
}

/* Hover state for non-active, non-contact links */
.u-header .u-nav-1 .u-nav-link:hover:not(.active):not(.nav-contact-btn),
.u-header .u-nav-1 .u-nav-link.u-text-hover-white:hover:not(.active):not(.nav-contact-btn),
.u-header .u-nav-1 .u-nav-link.u-hover-palette-1-light-1:hover:not(.active):not(.nav-contact-btn) {
  background: #e8f0f7 !important;
  background-color: #e8f0f7 !important;
  color: #333 !important;
  border-radius: 6px !important;
}

/* Contact Us button - permanent blue background */
.u-header .nav-contact-btn,
.u-header .u-nav-1 .nav-contact-btn,
.u-header .u-nav-item .nav-contact-btn {
  background: #478ac9 !important;
  background-color: #478ac9 !important;
  color: white !important;
  border-radius: 6px !important;
  font-weight: 500 !important;
}

.u-header .nav-contact-btn:hover,
.u-header .u-nav-1 .nav-contact-btn:hover {
  background: #3a7ab8 !important;
  background-color: #3a7ab8 !important;
  color: white !important;
}

/* Mobile menu Contact Us button */
.u-nav-container-collapse .nav-contact-btn {
  background: #478ac9 !important;
  color: white !important;
  border-radius: 6px !important;
  margin: 10px 20px !important;
  display: inline-block !important;
}

/* Offset the page content to account for fixed header and beta banner */
.page-hero {
  margin-top: calc(var(--guide-header-height) + var(--guide-banner-height));
  padding-left: var(--guide-sidebar-width);
}

/* Adjust guides wrapper to account for fixed header and beta banner */
.guides-wrapper {
  margin-top: 140px;
  padding-top: 20px;
}

/* When page-hero is present, reduce the guides-wrapper margin */
.page-hero + .guides-wrapper {
  margin-top: 0;
  padding-top: 0;
}

.guides-sidebar-header {
  padding: 15px 20px;
  border-bottom: 1px solid var(--guide-border);
  background: linear-gradient(135deg, #478ac9 0%, #5a9bd4 100%);
  z-index: 10;
}

/* Expand/Collapse All Buttons */
.guides-expand-collapse {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  justify-content: center;
}

.expand-collapse-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.expand-collapse-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
}

.expand-collapse-btn svg {
  width: 16px;
  height: 16px;
  color: white;
}

.guides-sidebar-header h3 {
  display: none;
}

.guides-version {
  display: none;
}

/* Version footer at bottom of sidebar */
.guides-sidebar-footer {
  margin-top: auto;
  padding: 12px 20px;
  background: #f8fafc;
  border-top: 1px solid var(--guide-border);
  font-size: 0.7rem;
  color: var(--guide-text-muted);
  text-align: center;
  flex-shrink: 0;
}

/* Search Box */
.guides-search {
  position: relative;
}

.guides-search input {
  width: 100%;
  padding: 10px 12px 10px 36px;
  border: 1px solid var(--guide-border);
  border-radius: 8px;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.guides-search input:focus {
  border-color: var(--guide-primary);
  box-shadow: 0 0 0 3px rgba(71, 138, 201, 0.1);
}

.guides-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--guide-text-muted);
}

/* Search Results Dropdown */
.guides-search-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid var(--guide-border);
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
  margin-top: 4px;
  display: none;
}

.guides-search-results.active {
  display: block;
}

.search-result-item {
  display: block;
  padding: 12px 15px;
  border-bottom: 1px solid var(--guide-border);
  text-decoration: none;
  color: inherit;
  transition: background-color 0.15s ease;
}

.search-result-item:last-child {
  border-bottom: none;
}

.search-result-item:hover {
  background: #f8fafc;
}

.search-result-title {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--guide-primary);
  margin-bottom: 2px;
}

.search-result-category {
  font-size: 0.75rem;
  color: var(--guide-text-muted);
  margin-bottom: 4px;
}

.search-result-snippet {
  font-size: 0.8rem;
  color: var(--guide-text-light);
  line-height: 1.4;
}

.search-result-snippet mark {
  background: #fef08a;
  color: inherit;
  padding: 0 2px;
  border-radius: 2px;
}

.search-no-results {
  padding: 20px 15px;
  text-align: center;
  color: var(--guide-text-muted);
  font-size: 0.9rem;
}

/* Sidebar Navigation */
.guides-nav {
  padding: 15px 0;
  flex: 1;
  overflow-y: auto;
}

.guides-nav-section {
  margin-bottom: 10px;
}

.guides-nav-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: white;
  background: linear-gradient(135deg, #478ac9 0%, #5a9bd4 100%);
  cursor: pointer;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  white-space: nowrap;
  overflow: hidden;
}

.guides-nav-title:hover {
  background: linear-gradient(135deg, #3a7ab8 0%, #4a8bc4 100%);
}

.guides-nav-title svg {
  width: 18px;
  height: 18px;
  transition: transform 0.3s ease;
  color: white;
}

.guides-nav-section.collapsed .guides-nav-title {
  background: #f1f5f9;
  color: var(--guide-text);
}

.guides-nav-section.collapsed .guides-nav-title svg {
  transform: rotate(-90deg);
  color: var(--guide-text-muted);
}

.guides-nav-section.collapsed .guides-nav-title:hover {
  background: #e2e8f0;
}

.guides-nav-section.collapsed .guides-nav-list {
  display: none;
}

.guides-nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
  background: white;
  border-left: 3px solid var(--guide-primary);
}

/* Tier 2 Subsections */
.guides-nav-tier2 {
  margin: 0;
}

.guides-nav-tier2-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 8px 16px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--guide-primary-dark);
  background: #f1f5f9;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 1px solid var(--guide-border);
  white-space: nowrap;
  overflow: hidden;
}

.guides-nav-tier2-title:hover {
  background: #e2e8f0;
}

.guides-nav-tier2-title svg {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease;
  flex-shrink: 0;
  color: var(--guide-text-muted);
}

.guides-nav-tier2.collapsed .guides-nav-tier2-title svg {
  transform: rotate(-90deg);
}

.guides-nav-tier2.collapsed .guides-nav-tier3-list {
  display: none;
}

/* Tier 3 Items */
.guides-nav-tier3-list {
  list-style: none;
  padding: 0;
  margin: 0;
  background: white;
}

.guides-nav-tier3-item {
  border-bottom: 1px solid #f8fafc;
}

.guides-nav-tier3-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px 6px 28px;
  color: var(--guide-text);
  text-decoration: none;
  font-size: 0.68rem;
  transition: all 0.2s ease;
  border-left: 2px solid transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.guides-nav-tier3-link:hover {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.08) 0%, transparent 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.guides-nav-tier3-link.active {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.12) 0%, transparent 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
  font-weight: 600;
}

.guides-nav-tier3-link svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  opacity: 0.7;
}

.guides-nav-item {
  margin: 0;
  border-bottom: 1px solid #f1f5f9;
}

.guides-nav-item:last-child {
  border-bottom: none;
}

.guides-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px 10px 16px;
  color: var(--guide-text);
  text-decoration: none;
  font-size: 0.75rem;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
  margin-left: -3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.guides-nav-link span {
  overflow: hidden;
  text-overflow: ellipsis;
}

.guides-nav-link:hover {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.1) 0%, rgba(71, 138, 201, 0.02) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.guides-nav-link.active {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.15) 0%, rgba(71, 138, 201, 0.05) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
  font-weight: 600;
}

.guides-nav-link svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--guide-primary);
  opacity: 0.8;
}

/* Direct Link (standalone nav item without dropdown) */
.guides-nav-direct-link {
  display: block;
  padding: 12px 16px;
  color: var(--guide-text);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
  border-bottom: 1px solid var(--guide-border);
}

.guides-nav-direct-link:hover {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.1) 0%, rgba(71, 138, 201, 0.02) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.guides-nav-direct-link.active {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.15) 0%, rgba(71, 138, 201, 0.05) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

/* Standalone Top-Level Nav Links */
.guides-nav-standalone {
  border-bottom: 1px solid var(--guide-border);
}

.guides-nav-standalone-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  color: var(--guide-text);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.guides-nav-standalone-link:hover {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.1) 0%, rgba(71, 138, 201, 0.02) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.guides-nav-standalone-link.active {
  background: linear-gradient(90deg, rgba(71, 138, 201, 0.15) 0%, rgba(71, 138, 201, 0.05) 100%);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.guides-nav-standalone-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--guide-primary);
  opacity: 0.8;
}

/* Main Content Area */
.guides-content {
  flex: 1;
  padding: 20px 50px 60px;
  max-width: 1200px;
}

/* Guide Article Styles */
.guide-article {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.guide-header {
  padding: 30px 40px;
  border-bottom: 1px solid var(--guide-border);
}

.guide-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
  font-size: 0.85rem;
}

.guide-breadcrumb a {
  color: var(--guide-text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.guide-breadcrumb a:hover {
  color: var(--guide-primary);
}

.guide-breadcrumb span {
  color: var(--guide-text-muted);
}

.guide-title {
  font-size: 18pt;
  font-weight: 700;
  color: var(--guide-text);
  margin: 0 0 8px 0;
  line-height: 1.3;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.guide-subtitle {
  font-size: 0.9rem;
  color: var(--guide-text-muted);
  margin: 0;
  line-height: 1.5;
}

.guide-meta {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 15px;
  font-size: 0.85rem;
  color: var(--guide-text-muted);
}

.guide-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.guide-meta svg {
  width: 16px;
  height: 16px;
}

/* Guide Body Content */
.guide-body {
  padding: 40px;
}

.guide-body h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--guide-text);
  margin: 40px 0 20px;
  padding-top: 20px;
  border-top: 1px solid var(--guide-border);
}

.guide-body h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.guide-body h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--guide-text);
  margin: 30px 0 15px;
}

.guide-body h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--guide-text);
  margin: 25px 0 12px;
}

.guide-body p {
  font-size: 1rem;
  line-height: 1.8;
  color: #333;
  margin-bottom: 16px;
}

.guide-body ul,
.guide-body ol {
  margin: 0 0 20px 0;
  padding-left: 24px;
}

.guide-body li {
  font-size: 1rem;
  line-height: 1.8;
  color: #333;
  margin-bottom: 8px;
}

.guide-body ol > li {
  padding-left: 5px;
}

/* Nested lists */
.guide-body ol ol,
.guide-body ul ul,
.guide-body ol ul,
.guide-body ul ol {
  margin-top: 8px;
  margin-bottom: 8px;
}

.guide-body ol ol li,
.guide-body ul ul li {
  margin-bottom: 4px;
}

/* Image Styles */
.guide-image {
  margin: 25px 0;
  text-align: center;
}

.guide-image img {
  max-width: 100%;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--guide-border);
}

.guide-image figcaption {
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--guide-text-muted);
  font-style: italic;
}

/* Callout Boxes */
.guide-callout {
  padding: 16px 20px;
  border-radius: 8px;
  margin: 20px 0;
  display: flex;
  gap: 12px;
}

.guide-callout svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  margin-top: 2px;
}

.guide-callout-content {
  flex: 1;
}

.guide-callout-content p {
  margin: 0;
}

.guide-callout-content p + p {
  margin-top: 8px;
}

.guide-callout.info {
  background: #eff6ff;
  border-left: 4px solid #3b82f6;
}

.guide-callout.info svg {
  color: #3b82f6;
}

.guide-callout.warning {
  background: #fefce8;
  border-left: 4px solid #eab308;
}

.guide-callout.warning svg {
  color: #eab308;
}

.guide-callout.tip {
  background: #f0fdf4;
  border-left: 4px solid #22c55e;
}

.guide-callout.tip svg {
  color: #22c55e;
}

.guide-callout.important {
  background: #fef2f2;
  border-left: 4px solid #ef4444;
}

.guide-callout.important svg {
  color: #ef4444;
}

/* Number Badge for Steps */
.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: var(--guide-primary);
  color: white;
  font-size: 0.8rem;
  font-weight: 700;
  border-radius: 50%;
  margin-right: 8px;
}

/* Table of Contents (In-Page) */
.guide-toc {
  background: var(--guide-bg-light);
  border-radius: 8px;
  padding: 20px 25px;
  margin-bottom: 30px;
}

.guide-toc h4 {
  margin: 0 0 12px 0;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--guide-text);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.guide-toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.guide-toc li {
  margin: 0;
}

.guide-toc a {
  display: block;
  padding: 6px 0;
  color: var(--guide-primary);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.guide-toc a:hover {
  color: var(--guide-primary-dark);
  text-decoration: underline;
}

.guide-toc .toc-sub {
  padding-left: 16px;
}

/* Data Tables */
.guide-table-wrapper {
  overflow-x: auto;
  margin: 20px 0;
}

.guide-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.guide-table th,
.guide-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--guide-border);
}

.guide-table th {
  background: var(--guide-bg-light);
  font-weight: 600;
  color: var(--guide-text);
}

.guide-table tr:hover td {
  background: rgba(71, 138, 201, 0.04);
}

/* Active Badge */
.status-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.status-badge.active {
  background: #dcfce7;
  color: #166534;
}

.status-badge.inactive {
  background: #fee2e2;
  color: #991b1b;
}

/* Footer Navigation */
.guide-footer {
  display: flex;
  justify-content: space-between;
  padding: 30px 40px;
  border-top: 1px solid var(--guide-border);
  gap: 20px;
}

.guide-nav-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 20px;
  background: var(--guide-bg-light);
  border-radius: 8px;
  text-decoration: none;
  color: var(--guide-text);
  transition: all 0.3s ease;
  flex: 1;
  max-width: 45%;
}

.guide-nav-btn:hover {
  background: rgba(71, 138, 201, 0.1);
  color: var(--guide-primary);
}

.guide-nav-btn.next {
  flex-direction: row-reverse;
  text-align: right;
  margin-left: auto;
}

.guide-nav-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.guide-nav-btn .label {
  font-size: 0.75rem;
  color: var(--guide-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.guide-nav-btn .title {
  font-weight: 600;
  font-size: 0.95rem;
}

/* Mobile Sidebar Toggle */
.guides-sidebar-toggle {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 50px;
  height: 50px;
  background: var(--guide-primary);
  color: white;
  border: none;
  border-radius: 50%;
  box-shadow: 0 4px 15px rgba(71, 138, 201, 0.4);
  cursor: pointer;
  z-index: 60;
  align-items: center;
  justify-content: center;
}

.guides-sidebar-toggle svg {
  width: 24px;
  height: 24px;
}

/* Guides Landing Page */
.guides-landing {
  padding: 20px 40px 40px;
}

.guides-landing h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--guide-text);
  margin: 0 0 10px 0;
}

.guides-landing .subtitle {
  font-size: 1.1rem;
  color: var(--guide-text-muted);
  margin-bottom: 30px;
}

.guides-category {
  margin-bottom: 40px;
}

.guides-category h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--guide-text);
  margin: 0 0 20px 0;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--guide-primary);
  display: inline-block;
}

/* Tab Navigation */
.guides-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 30px;
  border-bottom: 2px solid var(--guide-border);
}

.guides-tab {
  padding: 12px 24px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--guide-text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.guides-tab:hover {
  color: var(--guide-primary);
  background: rgba(71, 138, 201, 0.05);
}

.guides-tab.active {
  color: var(--guide-primary);
  border-bottom-color: var(--guide-primary);
}

/* Tab Panels */
.guides-tab-panel {
  display: none;
}

.guides-tab-panel.active {
  display: block;
}

.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.guide-card {
  background: white;
  border: 1px solid var(--guide-border);
  border-radius: 12px;
  padding: 20px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.guide-card:hover {
  border-color: var(--guide-primary);
  box-shadow: 0 8px 25px rgba(71, 138, 201, 0.12);
  transform: translateY(-2px);
}

.guide-card-icon {
  width: 40px;
  height: 40px;
  background: rgba(71, 138, 201, 0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
}

.guide-card-icon svg {
  width: 22px;
  height: 22px;
  color: var(--guide-primary);
}

.guide-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--guide-text);
  margin: 0 0 8px 0;
}

.guide-card p {
  font-size: 0.9rem;
  color: var(--guide-text-muted);
  margin: 0;
  line-height: 1.5;
}

/* Responsive */
@media (max-width: 991px) {
  .guides-wrapper {
    margin-left: 0;
  }

  .page-hero {
    padding-left: 0;
  }

  .guides-sidebar {
    transform: translateX(-100%);
    top: 0;
    bottom: 0;
  }

  .guides-sidebar.open {
    transform: translateX(0);
  }

  .guides-content {
    padding: 20px;
  }

  .guides-sidebar-toggle {
    display: flex;
  }

  .guide-header,
  .guide-body,
  .guide-footer {
    padding: 25px;
  }

  .guide-title {
    font-size: 1.1rem;
  }
}

@media (max-width: 575px) {
  .guides-content {
    padding: 15px;
  }

  .guide-header,
  .guide-body {
    padding: 20px;
  }

  .guide-footer {
    flex-direction: column;
    padding: 20px;
  }

  .guide-nav-btn {
    max-width: 100%;
  }

  .guide-nav-btn.next {
    flex-direction: row;
    text-align: left;
  }

  .guide-title {
    font-size: 1rem;
  }

  .guides-grid {
    grid-template-columns: 1fr;
  }
}

/* Print Styles */
@media print {
  .guides-sidebar,
  .guides-sidebar-toggle,
  .guide-footer {
    display: none !important;
  }

  .guides-content {
    margin-left: 0;
    padding: 0;
  }

  .guide-article {
    box-shadow: none;
  }

  .guide-image img {
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* ============================================
   Legacy Sidebar Compatibility Styles
   For pages still using the old nav structure
   ============================================ */

/* Old sidebar header */
.sidebar-header {
  padding: 20px;
  padding-top: 25px;
  border-bottom: 1px solid var(--guide-border);
  background: linear-gradient(135deg, #478ac9 0%, #5a9bd4 100%);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.sidebar-header h3 {
  margin: 0 0 5px 0;
  font-size: 0.85rem;
  font-weight: 700;
  color: white;
}

.sidebar-close {
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  display: none;
}

@media (max-width: 991px) {
  .sidebar-close {
    display: block;
  }
}

/* Old sidebar search */
.sidebar-search {
  padding: 15px 20px;
  border-bottom: 1px solid var(--guide-border);
}

.sidebar-search input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--guide-border);
  border-radius: 8px;
  font-size: 0.9rem;
  outline: none;
}

.sidebar-search input:focus {
  border-color: var(--guide-primary);
  box-shadow: 0 0 0 3px rgba(71, 138, 201, 0.1);
}

/* Old sidebar navigation */
.sidebar-nav {
  padding: 15px 0;
}

.nav-section {
  margin-bottom: 20px;
}

.nav-section h4 {
  padding: 10px 20px;
  margin: 0;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--guide-text-muted);
}

.nav-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-section li {
  margin: 0;
}

.nav-section a {
  display: block;
  padding: 10px 20px 10px 30px;
  color: var(--guide-text);
  text-decoration: none;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.nav-section a:hover {
  background: var(--guide-bg-light);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
}

.nav-section a.active {
  background: rgba(71, 138, 201, 0.1);
  color: var(--guide-primary);
  border-left-color: var(--guide-primary);
  font-weight: 600;
}

/* Old sidebar toggle button */
.sidebar-toggle {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 50px;
  height: 50px;
  background: var(--guide-primary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.sidebar-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: white;
  border-radius: 2px;
}

@media (max-width: 991px) {
  .sidebar-toggle {
    display: flex;
  }

  .guides-sidebar.active {
    transform: translateX(0);
  }
}

/* ============================================
   UAT Testing Enhanced Styles
   Test cases with Expected/Actual results
   ============================================ */

/* Pre-Test Setup Section */
.uat-setup-section {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  border: 2px solid #478ac9;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 25px;
}

.uat-setup-section h3 {
  margin: 0 0 16px 0;
  color: #1e40af;
  font-size: 1.1rem;
}

.uat-setup-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.uat-setup-section li {
  padding: 8px 0;
  color: #334155;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.uat-setup-section li::before {
  content: "☐";
  font-size: 1.1rem;
}

/* Test Summary Dashboard */
.uat-summary-stats {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  margin-bottom: 25px;
}

.uat-summary-stats .stat {
  flex: 1;
  min-width: 100px;
  padding: 16px 20px;
  border-radius: 10px;
  text-align: center;
  background: white;
  border: 2px solid #e2e8f0;
}

.uat-summary-stats .stat .count {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 4px;
}

.uat-summary-stats .stat.pass {
  border-color: #10b981;
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
}
.uat-summary-stats .stat.pass .count { color: #059669; }

.uat-summary-stats .stat.fail {
  border-color: #ef4444;
  background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
}
.uat-summary-stats .stat.fail .count { color: #dc2626; }

.uat-summary-stats .stat.blocked {
  border-color: #f59e0b;
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
}
.uat-summary-stats .stat.blocked .count { color: #d97706; }

.uat-summary-stats .stat.skip {
  border-color: #6b7280;
  background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
}
.uat-summary-stats .stat.skip .count { color: #4b5563; }

.uat-summary-stats .stat.pending {
  border-color: #3b82f6;
  background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}
.uat-summary-stats .stat.pending .count { color: #2563eb; }

/* Test Case Card */
.uat-test-case {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  margin-bottom: 16px;
  overflow: hidden;
  transition: all 0.2s;
}

.uat-test-case:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.uat-test-case.status-pass {
  border-left: 4px solid #10b981;
}

.uat-test-case.status-fail {
  border-left: 4px solid #ef4444;
}

.uat-test-case.status-blocked {
  border-left: 4px solid #f59e0b;
}

.uat-test-case.status-skip {
  border-left: 4px solid #6b7280;
}

/* Test Case Header */
.test-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  flex-wrap: wrap;
}

.test-id {
  font-family: monospace;
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  background: white;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

.test-priority {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
}

.test-priority.priority-high {
  background: #fef2f2;
  color: #dc2626;
}

.test-priority.priority-medium {
  background: #fffbeb;
  color: #d97706;
}

.test-priority.priority-low {
  background: #f0fdf4;
  color: #16a34a;
}

.test-module {
  font-size: 0.75rem;
  color: #478ac9;
  background: #eff6ff;
  padding: 3px 8px;
  border-radius: 4px;
  margin-left: auto;
}

/* Test Case Content */
.test-content {
  padding: 16px;
}

.test-content h5 {
  margin: 0 0 12px 0;
  font-size: 1rem;
  font-weight: 600;
  color: #1e293b;
}

.test-steps {
  margin-bottom: 16px;
}

.test-steps strong {
  display: block;
  font-size: 0.85rem;
  color: #475569;
  margin-bottom: 8px;
}

.test-steps ol {
  margin: 0;
  padding-left: 20px;
}

.test-steps li {
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 4px;
}

.expected-result,
.actual-result {
  background: #f8fafc;
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 12px;
}

.expected-result strong,
.actual-result strong {
  display: block;
  font-size: 0.8rem;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.expected-result p {
  margin: 0;
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.5;
}

.expected-result {
  border-left: 3px solid #3b82f6;
}

.actual-result {
  border-left: 3px solid #8b5cf6;
}

.actual-result-input {
  width: 100%;
  min-height: 60px;
  padding: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.9rem;
  resize: vertical;
  font-family: inherit;
}

.actual-result-input:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

/* Test Case Actions */
.test-actions {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  background: #fafafa;
  border-top: 1px solid #e2e8f0;
  flex-wrap: wrap;
}

.test-status {
  padding: 8px 12px;
  border: 2px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  background: white;
  cursor: pointer;
  min-width: 140px;
}

.test-status:focus {
  outline: none;
  border-color: #478ac9;
}

.test-status option[value="pass"] { color: #059669; }
.test-status option[value="fail"] { color: #dc2626; }
.test-status option[value="blocked"] { color: #d97706; }
.test-status option[value="skip"] { color: #6b7280; }

.test-notes {
  flex: 1;
  min-width: 200px;
  min-height: 36px;
  padding: 8px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.85rem;
  resize: vertical;
  font-family: inherit;
}

.test-notes:focus {
  outline: none;
  border-color: #478ac9;
}

.test-guide-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #eff6ff;
  color: #478ac9;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s;
  flex-shrink: 0;
}

.test-guide-link:hover {
  background: #478ac9;
  color: white;
}

/* Test Data Reference */
.uat-test-data {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 25px;
}

.uat-test-data h4 {
  margin: 0 0 15px 0;
  font-size: 1rem;
  color: #1e293b;
}

.uat-test-data .guide-table {
  margin: 0;
}

/* Defect Summary Section */
.uat-defect-summary {
  background: #fef2f2;
  border: 2px solid #fca5a5;
  border-radius: 12px;
  padding: 20px;
  margin-top: 25px;
}

.uat-defect-summary h3 {
  margin: 0 0 15px 0;
  color: #991b1b;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.uat-defect-summary h3::before {
  content: "⚠";
  font-size: 1.2rem;
}

#defectList {
  margin-bottom: 15px;
}

.defect-item {
  background: white;
  border: 1px solid #fca5a5;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 10px;
}

.defect-item strong {
  color: #dc2626;
  font-size: 0.85rem;
}

.defect-item p {
  margin: 4px 0 0 0;
  font-size: 0.9rem;
  color: #334155;
}

.uat-add-defect-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: white;
  border: 1px solid #dc2626;
  border-radius: 6px;
  color: #dc2626;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.uat-add-defect-btn:hover {
  background: #dc2626;
  color: white;
}

/* Guide Preview Modal */
.guide-modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(2px);
}

.guide-modal-overlay.active {
  display: flex;
}

.guide-modal-container {
  background: white;
  border-radius: 12px;
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: modalSlideIn 0.2s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.guide-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
  border-radius: 12px 12px 0 0;
}

.guide-modal-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: #1e293b;
  font-weight: 600;
}

.guide-modal-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-modal-newtab {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  color: #64748b;
  text-decoration: none;
  transition: all 0.2s;
}

.guide-modal-newtab:hover {
  background: #e2e8f0;
  color: #478ac9;
}

.guide-modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  border-radius: 8px;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s;
}

.guide-modal-close:hover {
  background: #fee2e2;
  color: #dc2626;
}

.guide-modal-body {
  flex: 1;
  overflow: hidden;
  border-radius: 0 0 12px 12px;
}

.guide-modal-body iframe {
  width: 100%;
  height: 70vh;
  border: none;
  display: block;
}

/* Responsive UAT Styles */
@media (max-width: 768px) {
  .uat-summary-stats {
    flex-direction: column;
  }

  .uat-summary-stats .stat {
    min-width: auto;
  }

  .test-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .test-module {
    margin-left: 0;
  }

  .test-actions {
    flex-direction: column;
  }

  .test-status,
  .test-notes {
    width: 100%;
    min-width: auto;
  }

  .guide-modal-container {
    max-width: 100%;
    max-height: 95vh;
  }

  .guide-modal-body iframe {
    height: 60vh;
  }
}

/* ============================================
   Site Footer Styles for Guide Pages
   Footer fixed at bottom, sidebar ends above it
   ============================================ */

/* Fixed footer at bottom of screen - compact height */
.u-footer,
footer.u-footer {
  margin-left: 0 !important;
  width: 100% !important;
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 200;
  padding: 6px 0 !important;
  min-height: auto !important;
  height: auto !important;
}

.u-footer .u-sheet,
.u-footer .u-sheet-1 {
  padding: 0 15px !important;
  min-height: auto !important;
  height: auto !important;
}

/* Compact paragraph spacing - links line */
.u-footer p.u-text-1 {
  margin: 2px 0 !important;
  padding: 0 !important;
  font-size: 0.7rem !important;
  line-height: 1.3 !important;
  white-space: nowrap !important;
  text-align: center !important;
}

/* Center the footer sheet content */
.u-footer .u-sheet,
.u-footer .u-sheet-1 {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
}

/* All footer links inline and smaller */
.u-footer p.u-text-1 a {
  display: inline !important;
  padding: 0 4px !important;
  font-size: 0.7rem !important;
}

/* Add bottom padding to content to prevent footer overlap */
.guides-content {
  padding-bottom: 70px !important;
}

/* Adjust sidebar to end above fixed footer */
.guides-sidebar {
  bottom: 50px !important;
}

/* Responsive footer */
@media (max-width: 768px) {
  .u-footer p.u-text-1 {
    font-size: 0.65rem !important;
    white-space: normal !important;
  }
  .u-footer p.u-text-1 a {
    font-size: 0.65rem !important;
  }
}

/* ============================================
   Mobile Header Menu Styles
   (Functionality provided by guide-components.js)
   ============================================ */

/* Mobile sidenav open state */
.u-sidenav.u-open {
  transform: translateX(0) !important;
  visibility: visible !important;
}

.u-menu-overlay.u-open {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

/* Ensure sidenav starts closed */
.u-sidenav {
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.u-menu-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Menu close button styling */
.u-menu-close {
  cursor: pointer;
  padding: 15px;
  text-align: right;
}

.u-menu-close::before {
  content: '✕';
  font-size: 24px;
  color: white;
}

/* =====================================================
   MOBILE GUIDES SEARCH & NAV IN SIDENAV
   ===================================================== */

/* Mobile search bar in sidenav */
.mobile-guides-search {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 15px;
  background: #f5f8fc;
  border-bottom: 1px solid #e2e8f0;
}

.mobile-guides-search svg {
  width: 18px;
  height: 18px;
  stroke: #64748b;
  flex-shrink: 0;
}

.mobile-guides-search input {
  flex: 1;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
  background: white;
}

.mobile-guides-search input:focus {
  border-color: var(--guide-primary, #478ac9);
  box-shadow: 0 0 0 2px rgba(71, 138, 201, 0.15);
}

/* Mobile guides nav submenu inside sidenav */
.mobile-guides-nav-container {
  border-bottom: none !important;
}

.mobile-guides-nav {
  display: none;
  padding: 0 10px 10px;
  background: #f8fafc;
  border-top: 1px solid #e8edf2;
}

.mobile-guides-nav .guides-nav-section {
  margin-bottom: 0;
  border-bottom: 1px solid #e8edf2;
}

.mobile-guides-nav .guides-nav-title {
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--guide-primary, #478ac9);
}

.mobile-guides-nav .guides-nav-title svg {
  width: 14px;
  height: 14px;
}

.mobile-guides-nav .guides-nav-tier2-title {
  padding: 8px 12px 8px 20px;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
}

.mobile-guides-nav .guides-nav-tier2-title svg {
  width: 12px;
  height: 12px;
}

.mobile-guides-nav .guides-nav-tier3-link {
  padding: 6px 12px 6px 32px;
  font-size: 12px;
  color: #64748b;
  display: block;
  text-decoration: none;
}

.mobile-guides-nav .guides-nav-tier3-link:hover,
.mobile-guides-nav .guides-nav-tier3-link.active {
  color: var(--guide-primary, #478ac9);
}

.mobile-guides-nav .guides-nav-standalone {
  padding: 8px 12px;
  border-bottom: 1px solid #e8edf2;
}

.mobile-guides-nav .guides-nav-standalone-link {
  font-size: 12px;
  color: #475569;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
}

.mobile-guides-nav .guides-nav-standalone-link svg {
  width: 14px;
  height: 14px;
}

/* Show mobile-only elements on mobile */
@media (max-width: 991px) {
  .mobile-guides-search {
    display: flex;
  }

  .mobile-guides-nav {
    display: block;
  }
}
