:root {
  --radius-md: 8px;
  --font-code: 'Consolas', 'Monaco', 'Courier New', monospace;
  
  --border-strong: #B7BBC7;
  --text-primary-static: #000000;
}

/* Code Block Component */
.auto-code-wrapper {
  --cb-bg: #f8f9fa;
  --cb-header-bg: rgba(0, 0, 0, 0.04);
  --cb-border: rgba(0, 0, 0, 0.05);
  --cb-text-main: #333;
  --cb-text-header: #000;
  --cb-icon-fill: #000;
  
  --token-keyword: #3a57ff;
  --token-string: #d1441e;
  --token-function: #AB47BC;
  --token-comment: #AFB42B;

  margin: 20px 0;
  border-radius: var(--radius-md);
  max-width: 95vw;
  display: flex;
  flex-direction: column;
  
  background-color: var(--cb-bg);
  border: 1px solid var(--cb-border);
}

@media (prefers-color-scheme: dark) {
  .auto-code-wrapper {
    --cb-bg: #1e1e1e;
    --cb-header-bg: rgba(255, 255, 255, 0.05);
    --cb-border: #333;
    --cb-text-main: #d4d4d4;
    --cb-text-header: #fff;
    --cb-icon-fill: #fff;
  }
}

.code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-right: 16px;
  background: var(--cb-header-bg);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.code-lang {
  font-size: 18px;
  color: var(--cb-text-header);
  background-color: var(--cb-bg);
  padding: 16px 60px;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  border: none;
  outline: none;
}

.code-scroll-area {
  max-height: 540px;
  overflow: auto;
  padding: 24px 24px 0 24px;
}

.code-scroll-area code,
.plain-code-editor {
  font-family: var(--font-code) !important;
  font-size: 14px !important;
  line-height: 1.6 !important;
  white-space: pre !important;
  display: block;
  color: var(--cb-text-main);
}

.plain-code-editor {
  width: 100%;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
}

.copy-btn {
  background: transparent;
  border: none;
  color: var(--cb-text-header);
  font-weight: 500;
  cursor: pointer;
}

.copy-btn svg {
  height: 17px;
  width: 17px;
}
.copy-btn svg path {
  fill: var(--cb-icon-fill);
}

/* PrismJS Overrides */
.auto-code-wrapper :is(pre, code)[class*="language-"] {
  background: transparent !important;
  padding: 0 0 12px 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  text-shadow: none !important;
  border: none !important;
}

.token.keyword  { color: var(--token-keyword) !important; font-weight: bold; }
.token.string   { color: var(--token-string) !important; }
.token.function { color: var(--token-function) !important; }
.token.comment  { color: var(--token-comment) !important; font-style: italic; }


/* Custom Box  */
.custom-box {
  padding: 16px 32px;
  border-radius: var(--radius-md);
  margin: 20px 0;
  background-color: #f8f9fa;
}

/* Variants */
.custom-box.color-blue   { background-color: #E1F5FE; border: 1px solid #03A9F4; }
.custom-box.color-red    { background-color: #FFEBEE; border: 1px solid #F44336; }
.custom-box.color-green  { background-color: #E8F5E9; border: 1px solid #4CAF50; }
.custom-box.color-yellow { background-color: #FFF8E1; border: 1px solid #FFC107; }
.custom-box.color-indigo { background-color: #E8EAF6; border: 1px solid #3F51B5; }

.box-header {
  display: flex;
  align-items: center;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-primary-static);
}

.box-header svg {
  width: 24px;
  height: 24px;
  margin-right: 10px;
  fill: var(--text-primary-static);
}

.box-content {
  margin-left: 34px;
}

.box-content :is(p, ul, ol, li) {
  margin: 0 !important;
  color: var(--text-primary-static) !important;
  font-size: 16px !important;
}


/* Audience Tag */

.audience-tag-box {
  padding: 24px;
  margin-bottom: 20px;
  border-radius: var(--radius-md);
  border: 1px solid #BDBDBD;
}

.tag-title {
  font-size: 22px;
  font-weight: 500;
  color: var(--text-primary-static);
}

.tag-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
}

.tag-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tag-row svg {
  height: 24px;
  width: 24px;
  flex-shrink: 0;
}

.tag-row span {
  color: #000000DE;
  line-height: 1.5;
}


/* Accordion */

.step-accordion {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  margin: 20px 0;
  overflow: hidden;
}

.accordion-header {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 20px;
  color: var(--text-primary-static);
  list-style: none;
  line-height: 1.3;
}

.accordion-header::-webkit-details-marker { display: none; }

.step-accordion .accordion-body {
  padding-inline: 24px;
  transition: height 0.3s ease-out;
  overflow: hidden;
}

.step-item {
  display: flex;
  gap: 16px;
}

.step-number {
  background: #2254E1;
  color: white;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-weight: bold;
  font-size: 14px;
}

.step-content {
  flex: 1;
}

.step-content p {
  margin-bottom: 10px !important;
  font-size: 18px !important;
  color: var(--text-primary-static) !important;
}

.step-accordion[open] .chevron {
  transform: rotate(180deg);
}

.chevron {
  transition: transform 0.3s ease;
  height: 24px;
  width: 24px;
}

/* Glossary / Highlight Component */

.glossary-definition {
    background-color: #E4EAFB; 
    color: #2254E1;
    cursor: help;
    position: relative;
    transition: all .3s ease;
}

.glossary-definition a {
    color: #2254E1 !important;
}

.glossary-definition:hover {
    padding: 2px 0;
}

@media screen and (min-width: 768px) {
  .glossary-definition::after {
      content: attr(data-tooltip);
      position: absolute;
      bottom: 34px; 
      left: 50%;
      transform: translateX(-50%);
      
      background: #fff;
      color: #000;
      padding: 12px 16px;
      border-radius: 6px;
      box-shadow: 0 4px 15px rgba(0,0,0,0.1);
      
      width: max-content;
      max-width: 250px;
      font-size: 12px;
      line-height: 1.5;
      pointer-events: none;
      
      opacity: 0;
      visibility: hidden;
      transition: all 0.2s ease;
      z-index: 100; 
  }

  .glossary-definition::before {
      content: '';
      position: absolute;
      bottom: 28px; 
      left: 50%;
      
      transform: translateX(-50%) rotate(45deg);
      
      width: 12px;
      height: 12px;
      background-color: #fff; 
      z-index: 101; 
      box-shadow: 2px 2px 4px rgba(0,0,0,0.1); 
      
      opacity: 0;
      visibility: hidden;
      transition: all 0.2s ease;
  }

  .glossary-definition:hover::after {
      opacity: 1;
      visibility: visible;
      bottom: 42px; 
  }

  .glossary-definition:hover::before {
      opacity: 1;
      visibility: visible;
      bottom: 36px; 
  }
}

/* Coming soon */

.coming-soon {
  width: fit-content;
  margin: 20px 0;
  padding: 4px 12px;
  border-radius: 8px;
  font-size: 14px;
  letter-spacing: 1%;
  display: inline-block;
}

.coming-soon.color-clockify   { background-color: #F0FAFF; color: #0287C5; }
.coming-soon.color-pumble    { background-color: #E2D1FF; color: #673AB7; }
.coming-soon.color-plaky  { background-color: #E9F0FF; color: #4E8AFF; }


/* Custom checklist */

.custom-checkbox-list ul {
    list-style: none;
    padding: 0 !important;
    margin: 20px 0 0 0 !important;
}

.custom-checkbox-list li {
    display: flex;
    align-items: center;
    padding-left: 0 !important;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.custom-checkbox-list label {
    display: flex;
    align-items: center;
    font-size: 18px;
}

.custom-checkbox-list li::before {
    display: none;
    margin-left: 0;
}

.custom-checkbox-list input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    
    width: 16px;
    height: 16px;
    border: 1px solid #8c8f94; 
    border-radius: 3px;
    background-color: #fff;
    cursor: pointer;
    display: inline-block;
    vertical-align: middle;
    position: relative;
    cursor: pointer;
    margin-right: 8px;
}

.custom-checkbox-list input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 10px;
    border: solid white; 
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.custom-checkbox-list.product-clockify input[type="checkbox"]:checked {
    background-color: #03A9F4; 
    border-color: #03A9F4;
}

.custom-checkbox-list.product-pumble input[type="checkbox"]:checked {
    background-color: #673AB7; 
    border-color: #673AB7;
}

.custom-checkbox-list.product-plaky input[type="checkbox"]:checked {
    background-color: #4D8AFF; 
    border-color: #4D8AFF;
}

.checklist-title {
    margin-bottom: 20px;
    font-weight: 500;
    font-size: 24px;
}

.custom-checkbox-list.product-clockify .checklist-title {
  color: #263238;
}

.custom-checkbox-list.product-pumble .checklist-title {
  color: #1d272c;
}

.custom-checkbox-list.product-plaky .checklist-title {
  color: #1a1c20;
}