:root,
.light,
.rust,
.navy,
.ayu,
.coal {
  color-scheme: dark;
  --bg: #0a0a0a;
  --fg: #cccccc;
  --sidebar-bg: #0a0a0a;
  --sidebar-fg: #888888;
  --sidebar-non-existant: #5f5f5f;
  --sidebar-active: #ffffff;
  --sidebar-header-border-color: #ffffff;
  --sidebar-spacer: #333333;
  --scrollbar: #5f5f5f;
  --icons: #aaaaaa;
  --icons-hover: #ffffff;
  --links: #e8e8e8;
  --inline-code-color: #dddddd;
  --theme-popup-bg: #1a1a1a;
  --theme-popup-border: #333333;
  --theme-hover: #333333;
  --quote-bg: #1a1a1a;
  --quote-border: #bdbdbd;
  --table-border-color: #333333;
  --table-header-bg: #1a1a1a;
  --table-alternate-bg: #101010;
  --searchbar-border-color: #333333;
  --searchbar-bg: #1a1a1a;
  --searchbar-fg: #cccccc;
  --searchbar-shadow-color: transparent;
  --searchresults-header-fg: #e8e8e8;
  --searchresults-border-color: #333333;
  --searchresults-li-bg: #1a1a1a;
  --search-mark-bg: #333333;
}

* {
  box-sizing: border-box;
  scrollbar-color: #5f5f5f #0a0a0a;
}

*::selection {
  background: #333333;
  color: #ffffff;
}

html {
  background: #0a0a0a;
  scroll-behavior: smooth;
}

body {
  background:
    linear-gradient(rgba(51, 51, 51, .13) 1px, transparent 1px),
    linear-gradient(90deg, rgba(51, 51, 51, .13) 1px, transparent 1px),
    #0a0a0a;
  background-attachment: fixed;
  background-size: 48px 48px;
  color: #cccccc;
  font-family: Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: -.012em;
  -webkit-font-smoothing: antialiased;
}

input,
textarea,
[contenteditable="true"] {
  caret-color: #e8e8e8;
}

a {
  color: #e8e8e8;
  text-decoration-color: #5f5f5f;
  text-underline-offset: .2em;
}

a:hover {
  color: #ffffff;
  text-decoration-color: #ffffff;
}

#sidebar {
  border-right: 1px solid #333333;
  background: rgba(10, 10, 10, .97);
}

.sidebar-scrollbox {
  padding: 28px 24px 40px;
}

.sidebar-scrollbox::before {
  content: "HACKTELIUM / ÍNDICE";
  display: block;
  margin: 0 0 30px;
  padding-bottom: 18px;
  border-bottom: 1px solid #333333;
  color: #e8e8e8;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .11em;
}

.chapter {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .79rem;
  letter-spacing: .02em;
}

.chapter li {
  margin-top: .3rem;
}

.chapter li a {
  padding: .35rem .5rem;
  border-left: 1px solid transparent;
}

.chapter li a:hover,
.chapter li a.active {
  border-left-color: #e8e8e8;
  background: #1a1a1a;
  color: #ffffff;
}

#menu-bar {
  min-height: 64px;
  border-bottom: 1px solid #333333;
  background: rgba(10, 10, 10, .92);
  backdrop-filter: blur(14px);
}

#menu-bar .icon-button {
  color: #aaaaaa;
}

#menu-bar .icon-button:hover {
  color: #ffffff;
  background: #1a1a1a;
}

#mdbook-theme-toggle,
.right-buttons a[href$="print.html"] {
  display: none;
}

.menu-title {
  color: #909090;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .72rem;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.content {
  max-width: 1060px;
  margin-inline: auto;
  padding: clamp(54px, 8vw, 110px) clamp(24px, 6vw, 72px) 120px;
}

main {
  color: #bdbdbd;
}

h1,
h2,
h3,
h4 {
  color: #e8e8e8;
  letter-spacing: -.035em;
}

main > h1 {
  margin-bottom: 3.5rem;
  color: #ffffff;
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 500;
  line-height: .92;
  letter-spacing: -.065em;
  text-transform: uppercase;
}

main > h1::before {
  content: "NOTA DE CAMPO / DOCUMENTO";
  display: block;
  margin-bottom: 1.2rem;
  color: #777777;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .72rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: .12em;
}

main h2 {
  margin-top: 4.5rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid #333333;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: -.025em;
  text-transform: uppercase;
}

main h2::before {
  content: "// ";
  color: #5f5f5f;
}

main h3 {
  margin-top: 3rem;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 1rem;
  text-transform: uppercase;
}

main h3::before {
  content: "> ";
  color: #5f5f5f;
}

.ht-hero {
  margin: calc(clamp(54px, 8vw, 110px) * -1) calc(clamp(24px, 6vw, 72px) * -1) clamp(64px, 8vw, 96px);
  padding: clamp(82px, 12vw, 150px) clamp(24px, 6vw, 72px) 0;
}

.ht-eyebrow {
  margin: 0 0 1.5rem;
  color: #888888;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .72rem;
  letter-spacing: .12em;
}

.ht-hero h1 {
  display: flex;
  flex-wrap: nowrap;
  align-items: baseline;
  width: max-content;
  max-width: 100%;
  margin: 0;
  color: #ffffff;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: clamp(3.8rem, 10vw, 8.5rem);
  font-weight: 500;
  line-height: .82;
  letter-spacing: 0;
}

.ht-type {
  flex: none;
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  vertical-align: bottom;
}

.ht-cursor {
  flex: none;
  color: #ffffff;
  animation: ht-blink .76s steps(1, end) infinite;
}

.ht-typing .ht-cursor {
  animation: none;
}

@keyframes ht-blink {
  50% { opacity: 0; }
}

.ht-lead {
  position: relative;
  max-width: 760px;
  margin: 2.5rem 0 0;
  color: #aaaaaa;
  font-size: clamp(1.15rem, 2.1vw, 1.65rem);
  line-height: 1.38;
  letter-spacing: -.03em;
}

.ht-lead::before {
  content: attr(data-text);
  display: block;
  visibility: hidden;
}

.ht-lead-type {
  position: absolute;
  inset: 0;
  display: block;
}

.ht-latest-card {
  display: flex;
  min-height: 210px;
  margin: 2rem 0 1px;
  padding: clamp(26px, 4vw, 42px);
  border: 1px solid #333333;
  flex-direction: column;
  background: #0a0a0a;
  color: inherit;
  text-decoration: none;
  transition: background-color .18s ease;
}

a.ht-latest-card:hover {
  background: #1a1a1a;
}

.ht-latest-label {
  color: #777777;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .68rem;
  letter-spacing: .1em;
}

.ht-latest-card strong {
  margin-top: auto;
  color: #ffffff;
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -.035em;
}

.ht-latest-card > span:not(.ht-latest-label) {
  max-width: 720px;
  margin-top: .8rem;
  color: #999999;
}

.ht-latest-card em {
  margin-top: 1.25rem;
  color: #cccccc;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .68rem;
  font-style: normal;
  letter-spacing: .08em;
}

.ht-latest-empty {
  min-height: 180px;
}

.ht-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 2rem 0 4rem;
  padding: 1px;
  background: #333333;
}

#ht-latest-article + .ht-card-grid {
  margin-top: 1px;
}

.ht-card {
  display: flex;
  min-height: 290px;
  padding: 28px;
  flex-direction: column;
  background: #0a0a0a;
  text-decoration: none;
  transition: background-color .18s ease;
}

.ht-card:hover {
  background: #1a1a1a;
}

.ht-card-index {
  color: #5f5f5f;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .68rem;
  letter-spacing: .08em;
}

.ht-card-art {
  display: none;
  width: 100%;
  height: 132px;
  min-width: 0;
  margin: 6px 0 12px;
  flex: 0 0 132px;
  pointer-events: none;
}

.ht-motion-ready .ht-card-art {
  display: block;
}

.ht-card strong {
  margin-top: auto;
  color: #e8e8e8;
  font-size: 1.35rem;
  font-weight: 500;
  line-height: 1.1;
}

.ht-card > span:not(.ht-card-index) {
  margin-top: .75rem;
  color: #888888;
  font-size: .9rem;
  line-height: 1.5;
}

.ht-card em {
  margin-top: 1.4rem;
  color: #cccccc;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .68rem;
  font-style: normal;
  letter-spacing: .08em;
}

.ht-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .75rem 2rem;
  margin: -1.7rem 0 3rem;
  padding: 12px 0;
  border-top: 1px solid #333333;
  border-bottom: 1px solid #333333;
  color: #777777;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .7rem;
  letter-spacing: .08em;
}

code,
kbd,
samp,
pre {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

:not(pre) > code,
kbd {
  padding: .15em .42em;
  border: 1px solid #333333;
  border-radius: 0;
  background: #1a1a1a;
  color: #dddddd;
}

pre {
  position: relative;
  margin: 2rem 0;
  padding: 3.6rem 1.4rem 1.5rem;
  border: 1px solid #333333;
  border-radius: 0;
  background: #0f0f0f;
  color: #dddddd;
  font-size: .88rem;
  line-height: 1.7;
}

pre::before {
  content: "TERMINAL / SALIDA";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  padding: .72rem 1rem;
  border-bottom: 1px solid #333333;
  color: #5f5f5f;
  font-size: .64rem;
  line-height: 1;
  letter-spacing: .1em;
}

.code-header {
  margin: 0;
  border: 0;
  background: transparent;
}

.code-header + pre {
  margin-top: 0;
}

blockquote {
  margin: 2.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid #333333;
  border-left: 3px solid #bdbdbd;
  background: #1a1a1a;
  color: #c8c8c8;
}

table {
  display: table;
  width: 100%;
  margin: 2rem 0;
  border-collapse: collapse;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .82rem;
}

th {
  color: #e8e8e8;
  font-weight: 600;
  letter-spacing: .05em;
  text-align: left;
  text-transform: uppercase;
}

th,
td {
  padding: .85rem 1rem;
  border: 1px solid #333333;
}

.nav-chapters {
  color: #909090;
}

.nav-chapters:hover {
  color: #ffffff;
  background: #1a1a1a;
}

#searchbar {
  border-radius: 0;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: .8rem;
}

@media (max-width: 900px) {
  .ht-card-grid {
    grid-template-columns: 1fr;
  }

  .ht-card {
    min-height: 230px;
  }
}

@media (max-width: 700px) {
  .content {
    padding-inline: 22px;
  }

  .ht-hero {
    margin-inline: -22px;
    padding-inline: 22px;
  }

  .ht-hero h1 {
    font-size: clamp(2.55rem, 13vw, 5rem);
  }

}

@media (prefers-reduced-motion: reduce) {
  .ht-type {
    width: 10ch;
    animation: none !important;
  }

  .ht-cursor {
    animation: none !important;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
