/* ─── Top Navigation Layout ───────────────────── */
.topnav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ─── Navigation Links ────────────────────────── */
.topnav a,
.dropbtn {
  text-decoration: none;
  color: #d0d0d0;
  font-weight: 400;
  font-size: 1rem;
  padding: 8px 12px;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.topnav a:hover,
.dropbtn:hover {
  color: #ffffff;
  background-color: #2c3e50;
}

/* ─── Topbar Right Container ──────────────────── */
.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: nowrap;
}

/* ─── Topbar Share Dropdown ───────────────────────────── */
#share-dropdown {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 12px;
  margin-right: 20px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  max-width: 100%;
}

#share-dropdown a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  background: transparent;
  color: inherit;
  text-decoration: none;
}

#share-dropdown a:hover {
  background-color: #eaeaea;
  color: #2c3e50;
}

#share-dropdown img,
#share-dropdown svg,
#share-dropdown i {
  width: 16px;
  height: 16px;
  display: block;
  margin: 0;
}

#share-dropdown a span {
  line-height: 1;
  vertical-align: middle;
  display: inline-block;
}


/* ─── glossary ──────────────── */
:target {
  scroll-margin-top: 70px; /* or whatever height your top bar is */
}


/* ─── Dropdown Fade-In Animation ──────────────── */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#share-dropdown a {
  all: unset;
  display: block;
  padding: 10px 16px;
  color: c;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 400;
  cursor: pointer;
  transition: background-color 0.2s ease;
  text-decoration: none !important;

}

/* Topbar */
  
.topbar {
  display: flex;
  align-items: center;
  color: white;
  background-color: #2c3e50;
  padding: 0.5rem 1rem;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;
  z-index: 1000;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 3rem; /* space between toggle and logo */
}

.topbar a:link,
.topbar a:visited,
.topbar a:hover,
.topbar a:active {
  color: #ffffff; /* or any color you prefer */
  text-decoration: none; /* optional: removes underline */
}



/* Tooltip for text with image */
.text-tooltip {
  position: relative;
  cursor: pointer;
}

.text-tooltip-img {
  display: none;
  position: absolute;
  left: 50%;
  bottom: 100%;
  transform: translateX(-50%);
  width: auto;
  max-width: 300px;
  z-index: 10;
  border: 1px solid #ccc;
  background: #fff;
  padding: 4px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.text-tooltip:hover .text-tooltip-img {
  display: block;
}

.text-tooltip-img img {
  display: block;
  width: 100%;
  height: auto;
}


/* Base Reset and Typography */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 14px;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, sans-serif;
  line-height: 1.6;
  background-color: #ffffff;
  color: #333;
  font-size: 1rem;
}


h1, h2, h3, h4 {
  font-weight: 700;
}

p {
  margin-top: 0.5em;
  margin-bottom: 0.5em;
}

h1 {
  color: #452c50;
}

h2 {
  margin: 2rem 0 0.25rem 0;
  font-size: 1.3rem;
  color: #333;
}

h3 {
  margin: 1rem 0 0.25rem 0;
  font-size: 1.05rem;
  color: #333;
}

h4 {
  margin: 1rem 0 0.25rem 0;
  font-size: 1rem;
  color: #333;
  font-style: italic;
}

p, li, a {
  font-weight: 400;
  text-decoration: none !important;
}

a:visited {
  color: #0000EE
}


ul {
  padding-left: 1.2rem;
}

li {
  margin: 0.5rem 0;
}

ol {
  padding-left: 1.5rem;
}

ol li {
  margin-bottom: 0.5rem;
}

ol li::marker {
  font-weight: bold;
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
  margin-top: 0.5rem;
  margin-bottom: 1.2rem;
}

img.border {
  max-width: 100%;
  height: auto;
  display: block;
  border: 1px solid #ccc;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}


/* Hero Section */
.hero {
  background-color: #ffffff;
  padding: 4rem 2rem;
  text-align: center;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #452c50;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.2rem;
  font-weight: 400;
  color: #333;
  max-width: 700px;
  margin: 0 auto;
}

/* Section Light */
.section-light {
  width: 100%;
  background-color: #ffffff;
  padding: 1rem;
}

.section-light table {
  width: 100%;
  table-layout: auto;
  border-collapse: collapse;
}

table th,
table td {
  padding: 5px;
  border: 1px solid #ccc;
  text-align: left;
  vertical-align: middle;
  font-size: 1rem;
}

.section-light th:first-child,
.section-light td:first-child {
  width: 1%;
  white-space: nowrap;
}

.section-light th {
  background-color: #f5f5f5;
}

.section-light table.shortcut-tables-cursor-icons td:nth-child(3) {
  text-align: center !important;
}

.section-light table.tooltip-wrapper {
  position: relative;
  display: inline-block;
}

.section-light table.tooltip-gif {
  display: none;
  position: absolute;
  top: 100%; /* below the icon */
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  background: #fff;
  padding: 5px;
  border: 1px solid #ccc;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.tooltip-wrapper:hover .tooltip-gif {
  display: block;
}


.section-light table.tooltip-row:hover .tooltip-gif {
  display: block;
}

#gif-tooltip {
  position: absolute;
  display: none;
  z-index: 9999;
  pointer-events: none;
  background: #fff;
  border: 1px solid #ccc;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  padding: 5px;
  max-width: 400px;
  transition: opacity 0.2s ease;
}

#gif-tooltip img {
  max-width: 100%;
  height: auto;
  display: block;
}



/* Table row hover highlight style */
.hover-table tbody tr:hover {
  background-color: #f0f0f0;
  cursor: default;
}

/* Table style with no visible borders */
.no-border {
  width: 100%;
  border-collapse: collapse;
}

.no-border th,
.no-border td {
  border: none;
  padding: 8px;
  text-align: left;
  vertical-align: middle;
  font-size: 1rem;
}


/* Centered Intro Block */
.center-text {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.intro-block {
  background-color: #8d8e8f;
  padding: 2rem;
  border-radius: 8px;
}


.logo a {
  color: #d0d0d0;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.2rem;
  padding: 8px 12px;
}

.logo a:hover {
  color: #ffffff;
  background-color: #2c3e50;
}

/* Side Bar Navigation */
.nav-level-1 {
  width: 250px; /* Adjust as needed */
  flex-shrink: 0;
  margin-right: 20px;
}

.nav-level-1 a {
  font-weight: 400;
}

.nav-level-1 > li {
  list-style: none;
  padding-left: 0;
  font-weight: 400;
}

.nav-level-2 {
  display: none;
}

.nav-level-2.show {
  display: block;
}


.nav-level-2 li {
  margin: 0.25rem 0;
}

.nav-level-2 a {
  display: block;
  padding: 2px 0;
  text-decoration: none;
  color: #333;
  font-size: 1rem;
  font-weight: 400;
}

.nav-level-2 a:hover {
  color: #452c50;
  text-decoration: none;
}

.nav-level-2 a.active {
  color: #452c50;
  font-weight: 600;
}

.nav-toggle {
  background: none;
  border: none;
  font-weight: 400;
  font-size: 1rem;
  cursor: pointer;
  padding: 0.5rem 0;
  width: 100%;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-toggle:hover {
  color: #452c50;
  text-decoration: none;
}

.nav-toggle.expanded .arrow {
  transform: rotate(135deg);
}

/* ─── Toggle Button with Arrow ───────────── */
.nav-toggle {
  background: none;
  border: none;
  font-size: 1rem;
  font-weight: 400;
  cursor: pointer;
  width: 100%;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  color: #333;
}

.nav-toggle:hover {
  color: #452c50;
}

/* ─── Arrow Icon ─────────────────────────── */
.arrow {
  display: inline-block;
  border: solid #333;
  border-width: 0 2px 2px 0;
  padding: 4px;
  transform: rotate(45deg);
  transition: transform 0.3s ease;
  margin-left: 8px;
}

/* ─── Rotated Arrow When Expanded ────────── */
.nav-toggle.expanded .arrow {
  transform: rotate(135deg);
}


/* Main layout content */
.content {
  margin-left: 30px; /* 30px space between navbar and content */
  flex: 1;
  padding: 2rem;
  transition: margin-left 0.3s ease;
}

/* Main content */
.main-content {
  flex-grow: 1;
}

/* Footer */
.site-footer {
  background-color: #2c3e50;
  color: #d0d0d0;
  text-align: center;
  padding: 10px 20px;
  font-size: 0.9rem;
  position: relative;
  z-index: 1001;
}

.site-footer a {
  text-decoration: none;
  color: #d0d0d0;
  font-weight: 600;
  font-size: inherit;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.site-footer a:hover {
  color: #ffffff;
  background-color: #2c3e50;
}

.noscript-warning {
  background: #f44336;
  color: white;
  padding: 10px;
  text-align: center;
}

.gif-tooltip img {
  max-width: none;
  height: auto;
}


/* ─── Layout Structure ───────────────────────────── */
.layout-wrapper {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  min-height: calc(100vh - 60px); /* Adjust for topbar height */
}

.content-wrapper {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  margin-left: 280px; /* match sidebar width */
  transition: margin-left 0.3s ease;
}

.sidebar-wrapper {
  position: fixed;
  top: 60px;
  left: 0;
  width: 280px;
  height: calc(100vh - 60px);
  background-color: #f9f9f9;
  border-right: 1px solid #ddd;
  overflow-y: auto;
  transition: width 0.3s ease;
  z-index: 999;
}


/* ─── Sidebar Collapse Behavior ──────────────────── */
.sidebar-wrapper.collapsed {
  width: 0;
}

.sidebar-wrapper.collapsed .navbar-collapse {
  display: none;
}

/* Use layout-wrapper context to reset margin */
.layout-wrapper .sidebar-wrapper.collapsed ~ .content-wrapper {
  margin-left: 0;
}

/* ─── Sidebar Toggle Button ──────────────────────── */
.sidebar-toggle,
#navbar-toggle {
  position: fixed;
  top: 0.6rem;
  left: 0.5rem;
  z-index: 1001;
  font-size: 1.5rem;
  background: #333;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 0.5rem 1rem;
  cursor: pointer;
}

/* ─── Adsbar ────────────────────────── */
.adsbar-wrapper {
  width: 180px;
  background-color: #f5f5f5;
  border-left: 1px solid #ddd;
  padding: 15px;
  overflow-y: auto;
}


.adsbar-content {
  font-size: 14px;
  color: #333;
}

/* Optional: hide on small screens */
@media (max-width: 768px) {
  .adsbar-wrapper {
    display: none;
  }
}


/* ─── Utility & Accessibility ────────────────────── */
.noscript-warning {
  background: #f44336;
  color: #fff;
  padding: 10px;
  text-align: center;
}

.gif-tooltip img {
  max-width: none;
  height: auto;
}

.copy-tooltip {
  position: absolute;
  top: -25px;
  left: 0;
  background: #333;
  color: #fff;
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.copy-tooltip.visible {
  opacity: 1;
}

/* ─── Modal Image Preview ────────────────────────── */
.thumbnail {
  max-width: 100%;
  height: auto;
  cursor: pointer;
  margin: 10px 0;
  pointer-events: auto;
}

.modal {
  display: none;
  position: fixed;
  z-index: 999;
  left: 0;
  top: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.8);
  overflow: auto;
}

.modal-content {
  display: block;
  margin: 80px auto 5% auto;
  max-width: 90vw;
  max-height: 80vh;
  width: auto;
  height: auto;
  object-fit: contain;
}

.close {
  position: absolute;
  top: 80px;
  right: 35px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 1000;
}

/* ─── Portrait Mode Warning ────────────────────── */
#portrait-warning {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(17, 17, 17, 0.92); /* darker semi-transparent black */
  color: #fff;
  font-size: 1.5em;
  text-align: center;
  padding: 2em;
  box-sizing: border-box;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

@media screen and (orientation: portrait) {
  #portrait-warning {
    display: flex;
  }
}



/* ─── Contact Form ─────────────────────────── */
#contactForm {
  max-width: 600px;
  margin: 2rem auto;
  padding: 2rem;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  font-family: "Inter", sans-serif;
}

#contactForm label {
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: block;
  color: #333;
}

#contactForm input,
#contactForm select,
#contactForm textarea {
  width: 100%;
  padding: 0.75rem;
  margin-bottom: 1.25rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
}

#contactForm button {
  background-color: #2c3e50;
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  border-radius: 6px;
  cursor: pointer;
}

#contactForm button:hover {
  background-color: #374f66;
}

#formSuccess {
  display: none;
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #2c3e50;
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 8px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  z-index: 1000;
  animation: fadeInUp 0.4s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translate(0px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0px);
  }
}


/* ─── 404 Error Page ────────────────────────── */

.error-page {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  background-color: #111;
  color: #fff;
  font-family: sans-serif;
  text-align: center;
}

.error-container {
  padding: 2em;
}

.error-container h1 {
  font-size: 5em;
  margin: 0;
}

.error-container p {
  font-size: 1.2em;
  margin: 1em 0;
}

