/* Prism Mac Style Theme */
/* Based on macOS Terminal aesthetic */

code[class*="language-"],
pre[class*="language-"] {
  color: #abb2bf;
  background: none;
  font-family: "JetBrains Mono", "Fira Code", "Cascadia Code", "SF Mono", Consolas, monospace;
  font-size: 14px;
  text-align: left;
  white-space: pre;
  word-spacing: normal;
  word-break: normal;
  word-wrap: normal;
  line-height: 1.7;
  -moz-tab-size: 2;
  -o-tab-size: 2;
  tab-size: 2;
  -webkit-hyphens: none;
  -moz-hyphens: none;
  -ms-hyphens: none;
  hyphens: none;
}

pre[class*="language-"] {
  position: relative !important;
  margin: 32px 0 !important;
  padding: 24px !important;
  overflow: hidden !important;
  background: #1e1e1e !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  border: none !important;
}

code[class*="language-"] {
  position: relative !important;
  z-index: 1 !important;
  background: transparent !important;
}

pre[class*="language-"] code {
  display: block !important;
  padding: 0 !important;
  overflow-x: auto !important;
  background: transparent !important;
  color: #abb2bf !important;
  border: none !important;
  border-radius: 0 !important;
}

.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
  color: #5c6370;
}

.token.punctuation {
  color: #abb2bf;
}

.token.property,
.token.tag,
.token.boolean,
.token.number,
.token.constant,
.token.symbol,
.token.deleted {
  color: #e06c75;
}

.token.selector,
.token.attr-name,
.token.string,
.token.char,
.token.builtin,
.token.inserted {
  color: #98c379;
}

.token.operator,
.token.entity,
.token.url,
.language-css .token.string,
.style .token.string {
  color: #56b6f2;
}

.token.atrule,
.token.attr-value,
.token.keyword {
  color: #c678dd;
}

.token.function,
.token.class-name {
  color: #61afef;
}

.token.regex,
.token.important,
.token.variable {
  color: #e5c07b;
}

.token.important,
.token.bold {
  font-weight: bold;
}

.token.italic {
  font-style: italic;
}

.token.entity {
  cursor: help;
}

pre[class*="language-"].line-numbers {
  position: relative;
  padding-left: 3.8em;
  counter-reset: linenumber;
}

pre[class*="language-"].line-numbers > code {
  position: relative;
  white-space: inherit;
}

.line-numbers .line-numbers-rows {
  position: absolute;
  pointer-events: none;
  top: 24px;
  font-size: 100%;
  left: -3.8em;
  width: 3em;
  letter-spacing: -1px;
  border-right: 1px solid #2d2d30;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

.line-numbers-rows > span {
  pointer-events: none;
  display: block;
  counter-increment: linenumber;
  color: #5c6370;
  padding-right: 1em;
  text-align: right;
}

/* Copy button */
.copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #abb2bf;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  opacity: 0;
  transition: all 0.2s ease;
  z-index: 10;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

pre:hover .copy-btn {
  opacity: 1;
}

/* Dark mode adjustments */
[data-theme="dark"] pre[class*="language-"] {
  background: #1e1e1e;
}

[data-theme="dark"] pre[class*="language-"] code {
  background: #1e1e1e;
}
