/* SPDX-FileCopyrightText: 2026 Troy McConaghy <troy@troymcconaghy.com>
 * SPDX-License-Identifier: GPL-2.0-or-later
 *
 * This file is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published
 * by the Free Software Foundation, either version 2 of the License,
 * or (at your option) any later version.
 *
 * This file is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this file. If not, see <https://www.gnu.org/licenses/>.
 */

@font-face {
  font-family: 'Albert Sans';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/albert-sans/AlbertSans-VariableFont_wght.47994b2c4fdf9e52682b29eee89a81fd1ad5f630b3100ef81e0f476a8e6daf30.woff2') format('woff2');
}

@font-face {
  font-family: 'Albert Sans';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/albert-sans/AlbertSans-Italic-VariableFont_wght.bd31199c61cba2e3f8a4e97c555d2a10852d01dbe90ef74b82682c8bd5c8eade.woff2') format('woff2');
}

@font-face {
  font-family: 'STIX Two Text';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/stix-two-text/STIXTwoText-VariableFont_wght.e02d0db7547b41a3e6d30582f9b461967eba6112ad5f5b9bfae6091af25f42d7.woff2') format('woff2');
}

@font-face {
  font-family: 'STIX Two Text';
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/stix-two-text/STIXTwoText-Italic-VariableFont_wght.43df2f304141948ad4c6bfb37c9f165271d5d9994e879053959e612201b6af29.woff2') format('woff2');
}

:root {
  --color-foreground: #1D201F;  /* applies to most text */
  --color-foreground-muted: #707170;
  --color-background: #F7F5F3;

  --font-sans: 'Albert Sans', ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  --font-serif: 'STIX Two Text', ui-serif, Georgia, serif;

  --font-size-tiny: clamp(14px, 2vw, 16px);
  --font-size-small: clamp(16px, 2vw, 18px);
  --font-size-medium: clamp(19px, 2.5vw, 22px);
  --font-size-heading-6: clamp(21px, 2.5vw, 22px);
  --font-size-large: clamp(21px, 2.5vw, 24px);
  --font-size-heading-5: clamp(24px, 2.5vw, 26px);
  --font-size-extra-large: clamp(24px, 3vw, 32px);
  --font-size-heading-4: clamp(27px, 3vw, 32px);
  --font-size-heading-3: clamp(30px, 3.5vw, 40px);
  --font-size-heading-2: clamp(33px, 4vw, 48px);
  --font-size-heading-1: clamp(36px, 4.5vw, 54px);
  --font-size-huge: clamp(36px, 5vw, 64px);

  --line-height-body: 1.45;
  --line-height-headings: 1.25;

  --letter-spacing-body: -0.01em;
  --letter-spacing-heading: -0.02em;

  --spacing-baseline: 16px;
  --spacing-1: 8px;
  --spacing-2: 12px;
  --spacing-3: 16px;
  --spacing-4: 24px;
  --spacing-5: 32px;
  --spacing-6: clamp(32px, 7.5vw, 40px);
  --spacing-7: clamp(48px, 9vw, 64px);

  --content-width: 632px;
  --wide-width: 960px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--color-background);
  color: var(--color-foreground);
  font-family: var(--font-sans);
  font-size: var(--font-size-medium);
  font-weight: 500;
  line-height: var(--line-height-body);
  letter-spacing: var(--letter-spacing-body);
  margin: 0;
  padding: var(--spacing-7) var(--spacing-5);
}

a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

a:hover {
  text-decoration: none;
}

header a {
  text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: var(--letter-spacing-heading);
  line-height: var(--line-height-headings);
  margin-top: 1.25em;
  margin-bottom: 0.75em;
}

h1 { font-size: var(--font-size-heading-1); }
h2 { font-size: var(--font-size-heading-2); }
h3 { font-size: var(--font-size-heading-3); }
h4 { font-size: var(--font-size-heading-4); }
h5 { font-size: var(--font-size-heading-5); }
h6 { font-size: var(--font-size-heading-6); }

h1:first-child, h2:first-child, h3:first-child,
h4:first-child, h5:first-child, h6:first-child {
  margin-top: 0;
}

h2.center {
  display: block;
  text-align: center;
}

p.muted {
  color: var(--color-foreground-muted);
}

article {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: 0;
}

@media (min-width: 900px) {
  article h1 {
    margin-left: -15%;
    margin-right: -15%;
  }
}

article p {
  margin-top: 0;
  margin-bottom: 1.5em;
}

article p:last-child {
  margin-bottom: 0;
}

article h1 {
  text-align: center;
  /* margin-bottom: 0.4em; */
}

header {
  text-align: center;
  margin-bottom: var(--spacing-7);
}

main {
  max-width: var(--content-width);
  margin: 0 auto;
}

footer {
  text-align: center;
  margin-top: var(--spacing-7);
  color: var(--color-foreground-muted);
  font-size: var(--font-size-small);
}

ul, ol {
  padding-left: 1.5em;
  margin: 0 0 1.5em 0;
}

li {
  margin-bottom: 0.5em;
}

.posts-list,
.posts-list li {
  margin-bottom: 0;
  padding-left: 0;
}

.posts-list {
  list-style: none;
  border-bottom: 1px solid var(--color-background);
}

.posts-list li {
  padding: var(--spacing-4) 0;
  border-top: 1px solid var(--color-background);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.posts-list li a {
  display: inline;
  flex: 0 1 75%;
  line-height: var(--line-height-body);
}

.posts-list li time {
  display: block;
  font-weight: 500;
  color: var(--color-foreground-muted);
  display: inline;
  flex-shrink: 0;
  white-space: nowrap;
  line-height: var(--line-height-body);
  margin-bottom: 0;
}

.more-link {
  display: block;
  font-size: var(--font-size-small);
  color: var(--color-foreground-muted);
  margin-top: var(--spacing-4);
  text-align: center;
}

hr {
  border: none;
  height: 1px;
  background-color: var(--color-background);
  margin: var(--spacing-5) 0;
}

hr.diamond {
  width: 201px;
  margin-left: auto;
  margin-right: auto;
  background: linear-gradient(
    90deg,
    var(--color-foreground) 0%,
    var(--color-foreground) calc(50% - 20px),
    transparent calc(50% - 20px),
    transparent calc(50% + 20px),
    var(--color-foreground) calc(50% + 20px),
    var(--color-foreground) 100%
  );
  position: relative;
  overflow: visible;
}

hr.diamond::before {
  content: '';
  display: block;
  width: 7px;
  height: 7px;
  background-color: var(--color-foreground);
  position: absolute;
  left: calc(50% - 3.5px);
  top: calc(50% - 3.5px);
  transform: rotate(45deg);
}

.dropcap::first-letter {
  float: left;
  font-size: 5.3em;
  font-weight: inherit;
  line-height: 1;
  margin-right: 0.1em;
  padding-top: 0.08em;
}

/* Zero out the blockquote's margin when it's inside a figure */
figure > blockquote {
  margin: 0;
}
/* This affects figcaptions inside blockquote figures: */
figure:has(> blockquote) > figcaption {
  text-align: right;
  margin-top: 0.5em;
  color: var(--color-foreground-muted);
}

.button {
  display: inline-block;
  background-color: var(--color-foreground);
  color: var(--color-background);
  font-family: var(--font-sans);
  font-size: var(--font-size-small);
  font-weight: 600;
  line-height: var(--line-height-headings);
  text-decoration: none;
  padding: 0.5em 1em;
  border-radius: 999px;
}

.button:hover {
  text-decoration: none;
  opacity: 0.9;
}