@font-face {
  font-family: "header";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/Oswald-Regular.ttf") format("truetype");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 420;
  font-display: swap;
  src: url("../fonts/Inter-Regular.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: italic;
  font-weight: 420;
  font-display: swap;
  src: url("../fonts/Inter-Italic.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/Inter-Bold.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/Inter-BoldItalic.woff2") format("woff2");
}

@font-face {
  font-family: "mono";
  font-weight: 420;
  font-display: swap;
  src: url("../fonts/intelone-mono-font-family-regular.otf") format("opentype");
}

:root {
  --color-bg: #2e2e2e;
  --color-surface-1: #323232;
  --color-surface-2: #3a3a3a;
  --color-bg-darkest: #222222;

  --color-text-primary: #A0A0A2;
  --color-text-secondary: #79808A;
  --color-text-muted: #79808A;

  --color-accent: #957A65;
  --color-accent-hover: #a88973;

  --color-border: #4B4B4B;

  --font-body: "Inter", "Arial", sans-serif;
  --font-heading: "header", system-ui, sans-serif;
  --font-mono: "mono", monospace;

  --text-xs: 0.85rem;
  --text-sm: 1rem;
  --text-md: 1.21rem;
  --text-lg: 1.3rem;
  --text-xl: 1.6rem;
  --text-2xl: 1.9rem;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;

  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 15px;
}

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

[hidden] { display: none !important; }

html,
body {
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-md);
  line-height: 1.75;
  background: var(--color-bg);
  color: var(--color-text-primary);
}

main {
  min-height: 100vh;
  padding: 0 15px;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-text-secondary);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  color: var(--color-accent);
}

code {
  background-color: var(--color-surface-2);
  color: var(--color-accent);
  font-family: var(--font-mono);
}

h1 {
  display: none;
}

.container {
  max-width: 800px;
  width: 100%;
  margin: 0 auto;
  padding: 0 var(--space-4);
}

/* ── banner header ────────────────────────────────── */

header {
  margin-bottom: 30px;
}

header img.banner {
  display: block;
  width: 100%;
  height: 250px;
  object-fit: cover;
}

nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  padding: var(--space-2) var(--space-4);
  text-transform: lowercase;
  background: var(--color-surface-1);
  flex-wrap: wrap;
}

nav a {
  font-size: var(--text-md);
  color: var(--color-text-secondary);
  border: none;
}

nav a:hover {
  color: var(--color-accent);
}

.nav-icon-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-secondary);
  display: flex;
  align-items: center;
  padding: 0;
  line-height: 1;
}

.nav-icon-btn:hover {
  color: var(--color-accent);
}

.nav-rss-wrap,
.nav-search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-dropdown {
  position: absolute;
  top: calc(100% + var(--space-2));
  right: 0;
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: var(--space-2) 0;
  min-width: 240px;
  z-index: 100;
}

.nav-dropdown-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
}

.nav-dropdown-label {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  width: 50px;
  flex-shrink: 0;
}

.nav-dropdown-url {
  flex: 1;
  font-size: 0.85rem;
  color: var(--color-text-secondary);
}

.nav-dropdown-copy {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 3px;
  padding: 2px 8px;
  font-size: 0.8rem;
  cursor: pointer;
  color: var(--color-text-muted);
  flex-shrink: 0;
}

.nav-dropdown-copy:hover {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

#search {
  width: 120px;
  font-size: var(--text-md);
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: var(--color-surface-1);
  color: var(--color-text-primary);
  transition: width 0.2s ease;
}

#search:focus {
  width: 200px;
  outline: none;
}

#search::-webkit-search-cancel-button {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  cursor: pointer;
  background-color: var(--color-accent);
  clip-path: polygon(20% 0%,0% 20%,30% 50%,0% 80%,20% 100%,50% 70%,80% 100%,100% 80%,70% 50%,100% 20%,80% 0%,50% 30%);
}

/* ── typography ────────────────────────────────────── */

h1,
h2,
h3,
h4,
h5,
h6,
.post-title,
.archive {
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
  color: var(--color-text-secondary);
}

h2 {
  font-size: 325%;
  text-align: center;
  margin-bottom: var(--space-3);
}

h3, .names, .archive {
  font-size: 180%;
  margin-bottom: 15px;
  margin-top: 60px;
}

h4 {
  font-size: 140%;
  margin-top: var(--space-5);
}

h5 {
  font-size: 115%;
}

/* feed reader: match feedi font sizes */
.feed-post {
  padding-bottom: 0;
  font-size: 1.1rem;
  --text-sm: 1rem;
}

.feed-body .post-title {
  font-size: var(--text-2xl);
  text-align: left;
  margin: 0;
}

.feed-modal-body hr {
  margin: var(--space-3) 0;
}

blockquote {
  margin: var(--space-4) 0;
  padding-left: var(--space-4);
  border-left: 5px solid var(--color-text-secondary);
  display: block;
  margin-inline-start: 5px;
}

b, strong {
  font-weight: 700;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: var(--space-6);
  font-size: var(--text-sm);
}

th,
td {
  border: 1px solid var(--color-border);
  padding: var(--space-1) var(--space-2);
}

th {
  background: var(--color-surface-1);
}

ul {
  margin-bottom: var(--space-6);
  margin-left: 15px;
  padding-left: 0;
}

ul li {
  list-style-type: '\2726';
  padding-left: 10px;
}

ol {
  margin-bottom: var(--space-6);
  padding-left: 25px;
}

/* ── posts ───────────────────────────────────────────── */

.post {
  padding-bottom: var(--space-7);
}

.post-break {
  margin-top: var(--space-3);
  text-align: right;
}

.read-more {
  color: var(--color-accent);
}

.small,
.date {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-align: center;
  font-style: italic;
}

.tags {
  margin-top: 15px;
  font-style: italic;
}

.rss-subscribe {
  font-size: var(--text-sm);
  color: var(--color-accent);
  font-style: normal;
  border: none;
  margin-left: var(--space-3);
  opacity: 0.7;
}

.rss-subscribe:hover {
  opacity: 1;
  color: var(--color-accent-hover);
}

audio {
  color-scheme: dark;
  margin-top: 15px;
  margin-bottom: 15px;
  width: 100%;
}

#load-more {
  display: none;
  margin: 30px auto;
  font-size: 110%;
  color: var(--color-accent);
  background-color: var(--color-bg);
  padding: 15px;
  border: 1px solid var(--color-border);
  border-radius: 15px;
  cursor: pointer;
}

#load-more.show {
  display: block;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

/* ── image alts ──────────────────────────────────────── */

img[alt="thumb"] {
  float: right;
  margin: 15px;
  width: 200px;
  border: 1px solid var(--color-border);
  background-color: var(--color-surface-1);
  padding: 5px;
  border-radius: var(--radius-lg);
  filter: brightness(85%);
}

img[alt="full"],
img[alt="center"] {
  display: block;
  margin: var(--space-4) auto;
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
}

img[alt="round"] {
  border-radius: 50%;
}

/* ── feeds ───────────────────────────────────────────── */

.feed-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-bottom: 4px;
  text-decoration: none;
}

a.feed-meta:hover {
  color: var(--color-accent);
}

.feed-meta .date {
  margin-left: auto;
  white-space: nowrap;
  flex-shrink: 0;
}

.feed-avatar {
  width: 14px;
  height: 14px;
}

.feed-content {
  margin-top: var(--space-2);
  line-height: 1.6;
}

.feed-source-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.feed-body {
  display: flex;
  gap: var(--space-3);
  padding: var(--space-3) 0;
}

.feed-body:hover .post-title {
  color: var(--color-accent);
}

.feed-body-text .post-title {
  margin-top: 0;
  line-height: 1;
}

.feed-thumb {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: var(--radius-md);
  flex-shrink: 0;
}

.feed-body-text {
  flex: 1;
  min-width: 0;
}

.feed-blurb {
  margin: var(--space-1) 0 0;
  line-height: 1.5;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* ── feed modal ──────────────────────────────────────── */

.feed-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
}

.feed-modal-overlay.hidden {
  display: none;
}

.feed-modal {
  background: var(--color-surface-1);
  border-radius: 6px;
  max-width: 680px;
  width: 100%;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}

.feed-modal-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--color-border);
}

.feed-modal-title {
  flex: 1;
  font-weight: 600;
  font-size: var(--text-md);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.feed-modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-muted);
  font-size: 1.2rem;
  line-height: 1;
  padding: 4px;
}

.feed-modal-close:hover {
  color: var(--color-text-primary);
}

.feed-modal-body {
  padding: var(--space-4);
  overflow-y: auto;
  flex: 1;
  line-height: 1.7;
  font-size: var(--text-md);
}

.feed-modal-body img {
  max-width: 100%;
  height: auto;
}

.feed-modal-footer {
  padding: var(--space-3) var(--space-4);
  border-top: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.feed-modal-original {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  border: none;
}

.feed-modal-original:hover {
  color: var(--color-accent);
}

.feed-modal-subscribe {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  border: none;
}

.feed-modal-subscribe:hover {
  color: var(--color-accent);
}

/* ── archive ──────────────────────────────────────────── */

.archive-filters {
  display: flex;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
}

.archive-filter {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 3px;
  color: var(--color-text-muted);
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  letter-spacing: 0.06em;
  padding: 2px 10px;
  text-transform: uppercase;
}

.archive-filter:hover {
  color: var(--color-text-primary);
  border-color: var(--color-text-muted);
}

.archive-filter.active {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* ── brine-specific ────────────────────────────────── */

.social img {
  opacity: .33;
  width: 50px;
  padding: 10px 10px 0 0;
  display: inline-block;
  border: 0;
}

.kofi img {
  width: 30px;
  height: auto;
}

.dim {
  filter: brightness(75%);
}

.song {
  text-align: center;
  margin: auto;
  width: 80%;
}

.song > div {
  white-space: pre-wrap;
  font-size: 115%;
  display: inline-block;
}

.image img {
  border-radius: 50%;
  float: right;
  clear: right;
  padding: 5px;
  width: 250px;
  height: 250px;
  overflow: auto;
  background-color: #cdcbc9;
  filter: brightness(89%);
}

.rune img {
  border-radius: 15%;
  float: right;
  padding: 5px;
  max-width: 150px;
  overflow: auto;
  filter: brightness(89%);
}

.border {
  border: medium solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 25px;
  margin-bottom: 50px;
  overflow: auto;
}

.center {
  text-align: center;
}

hr {
  margin: 50px 0;
  border: none;
  border-top: 1px solid var(--color-border);
  opacity: 0.5;
}

/* ── footer ──────────────────────────────────────────── */

footer {
  margin-top: var(--space-7);
  padding: var(--space-4);
  background: var(--color-surface-1);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
}

footer img {
  width: 30px;
  height: auto;
  display: block;
}

/* ── responsive ──────────────────────────────────────── */

@media (max-width: 600px) {
  nav {
    gap: var(--space-2);
    flex-wrap: wrap;
  }

  img[alt="thumb"] {
    float: none;
    display: block;
    margin: var(--space-4) auto;
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
