@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&display=swap');

:root {
  --ink: #201f1d;
  --paper: #f8f6f1;
  --muted: #716d66;
  --line: #dedbd3;
  --accent: #596d60;
}

:root.dark {
  --ink: #f2eee6;
  --paper: #201f1d;
  --muted: #bbb5aa;
  --line: #4b4842;
  --accent: #aec2b2;
  --link: #b7d4ec;
}

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Lora", Iowan Old Style, Baskerville, "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.75;
}

/* Switcher version of toggle */
.theme-toggle {
  appearance: none;
  background: transparent;
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer;
  height: 1.4rem;
  width: 2.5rem;
  position: fixed;
  right: 1.5rem;
  top: 1rem;
  z-index: 1100;
  display: flex;
  align-items: center;
  padding: 0.15rem;
  box-sizing: border-box;
  transition: background-color 200ms ease, border-color 200ms ease;
}

.theme-toggle span {
  display: block;
  width: 1rem;
  height: 1rem;
  background: var(--ink);
  border-radius: 50%;
  transform: translate(0, -5.5px);
  transition: transform 200ms ease, background-color 200ms ease;
}

:root.dark .theme-toggle {
  background: var(--ink);
  border-color: var(--ink);
}

:root.dark .theme-toggle span {
  background: var(--paper);
  transform: translate(1.1rem, -5.5px);
}

.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }

/* Hide title ("Javier Fajardo") from sidebar*/
.sidebar-title {
  display: none;
}
#quarto-content { background: var(--paper); }
#quarto-document-content { max-width: 690px; margin: 0 auto; padding: 4rem 2rem 5rem; }

#quarto-sidebar {
  background: var(--paper);
  /* border-right: 1px solid var(--line); */
  border-right: none !important;
  padding: 3.7rem 1.4rem;
}

#quarto-sidebar .sidebar-item-text,
#quarto-sidebar .sidebar-link { color: var(--muted); font-size: .92rem; }

#quarto-sidebar .sidebar-link:hover,
#quarto-sidebar .sidebar-link.active { color: var(--ink); }

#quarto-sidebar .sidebar-item-container { margin: .25rem 0; }

h1, h2, h3, .title {
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.2;
}

h1, .title { font-size: clamp(2rem, 4vw, 3.35rem); margin: 1.5rem 0 1.15rem; }
h2 { font-size: 1.45rem; margin-top: 2.7rem; }
h3 { font-size: 1.1rem; margin-bottom: .15rem; }

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent); }
.accent { color: var(--accent); }

.button-link {
  display: inline-block;
  margin-top: .4rem;
  border-bottom: 1px solid currentColor;
  color: var(--ink);
  font-size: .92rem;
  font-weight: 600;
  text-decoration: none;
}

.recent-list { border-top: 1px solid var(--line); padding: 1.15rem 0 .15rem; }
.recent-list h3 { margin-top: 0; }
.recent-list p { color: var(--muted); font-size: .92rem; margin-top: .15rem; }
.about-entity { margin-top: 2rem; }
.about-image { max-width: 160px !important; border: 1px solid var(--line); }
.about-links .about-link { font-size: .9rem; }
.quarto-title-meta, .description { color: var(--muted); }
.listing-item { border-bottom: 1px solid var(--line); padding: 1.3rem 0 !important; }
.listing-title { font-weight: 600; }
.page-footer { color: var(--muted); border-top: 1px solid var(--line); font-size: .78rem; }

.profile-links {
  margin: 0.5rem 0 1.75rem;
  display: flex;
  flex-wrap: wrap;
}

.profile-links a {
  color: var(--accent);
  text-decoration: none;
  margin-right: 1.5rem;
}

.profile-links a:hover {
  text-decoration: underline;
}

.profile-links i {
  margin-right: 0.3rem;
}

.nav-footer {
  background: var(--paper) !important;
  color: var(--muted);
}

.nav-footer a {
  color: var(--muted);
}



/* Quarto's top-bar layout */
@media (max-width: 991px) {

  .theme-toggle {
    top: 0.5rem;
    right: 1rem;
  }

  .theme-toggle span {
    transform: translate(0, 1px);
  }

  :root.dark .theme-toggle span {
    transform: translate(1.1rem, 1px);
  }

  /* Top-bar colours */
  .quarto-secondary-nav {
    background: var(--paper) !important;
    color: var(--ink);
    border-bottom: 1px solid var(--line);
  }

  .quarto-secondary-nav .quarto-page-breadcrumbs a {
    color: var(--ink) !important;
  }

  .quarto-secondary-nav .quarto-btn-toggle {
    color: var(--ink);
  }

  /* Hide the Home breadcrumb on the homepage */
  body:has(.quarto-page-breadcrumbs .breadcrumb-item:only-child)
    .quarto-page-breadcrumbs {
    display: none;
  }

  /* Hamburger / X navigation button */
  .quarto-secondary-nav .quarto-btn-toggle {
    color: var(--ink);
    background: transparent;
    border: 0;
    box-shadow: none;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    position: relative;
  }

  .quarto-secondary-nav .quarto-btn-toggle i {
    display: none;
  }

  .quarto-secondary-nav .quarto-btn-toggle::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 1.15rem;
    height: 2px;
    background: currentColor;
    transform: translate(-50%, -50%);
    box-shadow: 0 -5px 0 currentColor, 0 5px 0 currentColor;
    transition: transform 180ms ease, box-shadow 180ms ease;
  }

  .quarto-secondary-nav .quarto-btn-toggle::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 1.15rem;
    height: 2px;
    background: currentColor;
    transform: translate(-50%, -50%) rotate(45deg);
    opacity: 0;
    transition: transform 180ms ease, opacity 180ms ease;
  }

  .quarto-secondary-nav .quarto-btn-toggle[aria-expanded="true"]::before {
    transform: translate(-50%, -50%) rotate(45deg);
    box-shadow: none;
  }

  .quarto-secondary-nav .quarto-btn-toggle[aria-expanded="true"]::after {
    transform: translate(-50%, -50%) rotate(-45deg);
    opacity: 1;
  }

}


/* Narrow phone layout */
@media (max-width: 600px) {

  #quarto-document-content {
    padding: 2.2rem 1.25rem 4rem;
  }

  /* .theme-toggle {   already governed by 991px media
    right: 1rem;
    top: 1rem;
  } */

  body {
    font-size: 16px;
  }

  .navbar-nav .nav-link {
    margin-left: 0;
  }

}


/* Digital business card */

.card-page {
  text-align: center;
}

.card-subtitle {
  color: var(--ink);
  font-size: 1.05rem;
  margin: -0.7rem 0 0.2rem;
}

.card-affiliation {
  color: var(--muted);
  margin: 0 0 2rem;
}

.card-actions {
  margin-top: 1.75rem;
  text-align: center;
}

.card-primary-action {
  display: inline-block;
  background: var(--ink);
  color: var(--paper);
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  margin-top: 1.5rem;
}

.card-primary-action:hover {
  background: var(--accent);
  color: var(--paper);
  text-decoration: none;
}

.card-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0;
}

.card-links a {
  display: block;
  color: var(--accent);
  text-decoration: none;
}

.card-links a:hover {
  text-decoration: underline;
}

.card-links i {
  display: inline-block;
  width: 1.25rem;
  margin-right: 0.45rem;
  text-align: center;
  color: inherit;
}


/* Printable / visual business card */

.card-print-page {
  max-width: 32rem;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  text-align: center;
}

.card-print-page h1 {
  margin-bottom: 0;
}

.card-print-contact {
  margin-top: 2rem;
}

.card-print-contact p {
  margin: 0.75rem 0;
  color: var(--accent);
}

.card-print-contact i {
  display: inline-block;
  width: 1.25rem;
  margin-right: 0.45rem;
  text-align: center;
}

.card-print-qr {
  margin-top: 2rem;
}

.card-print-qr img {
  display: block;
  width: 150px;
  height: 150px;
  margin: 0 auto;
}

.card-print-qr p {
  margin-top: 0.9rem;
  color: var(--muted);
  font-size: 0.95rem;
}
