/* Turn cross-document view-transitions on */
/* Note that this at-rule is all that is needed to create the default cross-fade animation  */

@view-transition {
    navigation: auto;
}

/* Customize the default animation behavior */

::view-transition-group(root) {
    animation-duration: 0.5s;
}

/* Create a custom animation */

/* Example slide up and out transition
@keyframes move-out {
    from {
        transform: translateY(0%);
    }

    to {
        transform: translateY(-100%);
    }
}

@keyframes move-in {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0%);
    }
}

*/

/* Apply the custom animation to the old and new page states */

/*
::view-transition-old(root) {
    animation: 0.4s ease-in both move-out;

}

::view-transition-new(root) {
    animation: 0.4s ease-in both move-in;
}
/*
 */

:root {
  --fir: #2f4f45;
  --deep-sea: #365c67;
  --ink: #243033;
  --ember: #a7653f;
  --bg: #f7f8f6;
  --heading: #1f2937;
  --text: #334155;
  --muted: #475569;
  --link-hover: #0f172a;
}

:root[data-theme="dark"] {
  --fir: #9dc9ba;
  --deep-sea: #8fc0ce;
  --ink: #e2e8f0;
  --ember: #f6b38b;
  --bg: #0f172a;
  --heading: #f8fafc;
  --text: #cbd5e1;
  --muted: #94a3b8;
  --link-hover: #ffffff;
}

body {
  font-family: "Nunito", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.75;
  font-size: 1.0625rem;
}

h1, h2, h3 {
  font-family: "Fraunces", serif;
}

header {
  background: var(--bg);
}

main h1, main h2, main h3 {
  color: var(--heading);
}

main p, main li, nav a {
  color: var(--text);
}

/* Prose spacing — scoped to <article> so it doesn't conflict with
   the space-y-* Tailwind utilities used on other pages */
article p {
  margin-bottom: 1.5em;
}

article h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 2.5em;
  margin-bottom: 0.75em;
}

article h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-top: 2em;
  margin-bottom: 0.5em;
}

article a {
  color: var(--ember);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* These elements are rare enough that scoping to main is fine */
main blockquote {
  border-left: 3px solid var(--ember);
  padding: 0.25em 0 0.25em 1.25rem;
  margin: 2em 0;
  color: var(--muted);
  font-style: italic;
}

main blockquote p {
  margin-bottom: 0;
}

main code {
  font-family: monospace;
  background: rgba(0, 0, 0, 0.06);
  padding: 0.15em 0.4em;
  border-radius: 3px;
  font-size: 0.9em;
}

:root[data-theme="dark"] main code {
  background: rgba(255, 255, 255, 0.08);
}

main pre {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 6px;
  padding: 1.25rem 1.5rem;
  overflow-x: auto;
  margin-bottom: 1.5em;
  font-size: 0.875rem;
  line-height: 1.65;
}

:root[data-theme="dark"] main pre {
  background: rgba(255, 255, 255, 0.06);
}

main pre code {
  background: none;
  padding: 0;
  border-radius: 0;
  font-size: inherit;
}

main figure {
  margin: 2em 0;
}

main figure img {
  width: 100%;
  border-radius: 8px;
  display: block;
}

main figcaption {
  margin-top: 0.6em;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
  font-style: italic;
}

.theme-toggle {
  border: 1px solid var(--muted);
  color: var(--text);
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
}

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

.theme-toggle svg {
  width: 1.1rem;
  height: 1.1rem;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-sun {
  display: none;
}

:root[data-theme="dark"] .icon-moon {
  display: none;
}

:root[data-theme="dark"] .icon-sun {
  display: inline;
}

.hero-image-dark {
  display: none;
}

:root[data-theme="dark"] .hero-image-light {
  display: none;
}

:root[data-theme="dark"] .hero-image-dark {
  display: block;
}

a:hover {
  color: var(--link-hover);
}

