/* ═══════════════════════════════════════════════════
   SOLERIS — Medieval Fantasy Design
   ═══════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@400;700;900&family=Cinzel:wght@400;600;700&family=Lora:ital,wght@0,400;0,600;1,400&family=IM+Fell+English:ital@0;1&display=swap');

/* ── Variables ─────────────────────────────────── */
:root {
  --bg-darkest:    #060402;
  --bg-dark:       #100c07;
  --bg-medium:     #1c1509;
  --bg-panel:      #231a0c;
  --bg-light:      #2e2210;

  --parchment:     #f5eac8;
  --parchment-mid: #ead9a2;
  --parchment-dark:#d4bb7e;

  --gold:          #c9a227;
  --gold-light:    #e8c84d;
  --gold-dark:     #7d6218;
  --gold-glow:     rgba(201,162,39,.25);
  --gold-subtle:   rgba(201,162,39,.12);

  --red-deep:      #5a1010;
  --red:           #7a1e1e;
  --red-light:     #a33030;

  --green-dark:    #0f2e12;
  --green:         #1a4d1f;

  --text-parchment:#1c0e05;
  --text-mid:      #3d2510;
  --text-light:    #f5eac8;
  --text-muted:    #a08050;
  --text-gold:     #c9a227;

  --border:        rgba(201,162,39,.35);
  --border-strong: rgba(201,162,39,.65);
  --border-subtle: rgba(201,162,39,.15);

  --shadow-dark:   rgba(0,0,0,.8);
  --shadow-gold:   rgba(201,162,39,.15);

  --radius:        3px;
  --radius-sm:     2px;

  --font-display:  'Cinzel Decorative', serif;
  --font-heading:  'Cinzel', serif;
  --font-body:     'Lora', Georgia, serif;
  --font-flavor:   'IM Fell English', Georgia, serif;
}

/* ── Reset & Base ──────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-darkest);
  color: var(--text-light);
  min-height: 100vh;
  line-height: 1.7;
  background-image:
    radial-gradient(ellipse at 20% 0%, rgba(60,30,5,.5) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 100%, rgba(40,20,5,.4) 0%, transparent 60%);
}

a { color: var(--gold); text-decoration: none; transition: color .2s; }
a:hover { color: var(--gold-light); }

ul { list-style: none; }

img { max-width: 100%; display: block; }

/* ── Site Header ───────────────────────────────── */
.site-header {
  background: linear-gradient(180deg, #000 0%, var(--bg-darkest) 60%, var(--bg-dark) 100%);
  border-bottom: 2px solid var(--gold-dark);
  padding: 2rem 1rem 1.5rem;
  position: relative;
  overflow: hidden;
}

.site-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 80px,
      rgba(201,162,39,.03) 80px,
      rgba(201,162,39,.03) 81px
    );
  pointer-events: none;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.brand-link {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: .4rem;
  text-decoration: none;
}

.brand-ornament {
  font-size: 1rem;
  color: var(--gold);
  opacity: .7;
  letter-spacing: .5rem;
}

.brand-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  color: var(--gold);
  letter-spacing: .15em;
  text-shadow:
    0 0 30px rgba(201,162,39,.4),
    0 2px 4px rgba(0,0,0,.8),
    0 0 60px rgba(201,162,39,.15);
  line-height: 1.1;
}

.brand-subtitle {
  font-family: var(--font-heading);
  font-size: clamp(.65rem, 1.5vw, .85rem);
  color: var(--parchment-dark);
  letter-spacing: .25em;
  text-transform: uppercase;
  opacity: .8;
}

/* ── Main Navigation ───────────────────────────── */
.main-nav {
  background: var(--bg-dark);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px var(--shadow-dark);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: .25rem;
  flex-wrap: wrap;
}

.nav-link {
  font-family: var(--font-heading);
  font-size: .8rem;
  font-weight: 600;
  color: var(--parchment-dark);
  text-decoration: none;
  letter-spacing: .08em;
  padding: .9rem .85rem;
  display: flex;
  align-items: center;
  gap: .4rem;
  border-bottom: 2px solid transparent;
  transition: all .2s;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--gold-light);
  border-bottom-color: var(--gold);
  background: var(--gold-subtle);
}

.nav-link.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

.nav-icon {
  font-size: .9rem;
  opacity: .8;
}

/* Search */
.nav-search { display: flex; align-items: center; }

.search-form {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-medium);
}

.search-input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-light);
  font-family: var(--font-body);
  font-size: .85rem;
  padding: .5rem .75rem;
  width: 180px;
}

.search-input::placeholder { color: var(--text-muted); opacity: .7; }

.search-btn {
  background: var(--gold-dark);
  border: none;
  color: var(--parchment);
  padding: .5rem .75rem;
  cursor: pointer;
  font-size: 1rem;
  transition: background .2s;
}

.search-btn:hover { background: var(--gold); }

/* ── Main Content Area ─────────────────────────── */
.site-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
  min-height: 60vh;
}

/* ── Ornament Divider ──────────────────────────── */
.ornament {
  text-align: center;
  margin: 2rem 0;
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.ornament::before,
.ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
}

.ornament span {
  color: var(--gold);
  font-size: 1rem;
  opacity: .8;
  flex-shrink: 0;
}

/* ── Page Title ────────────────────────────────── */
.page-title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 700;
  color: var(--gold);
  letter-spacing: .08em;
  margin-bottom: 1rem;
  text-shadow: 0 0 20px var(--gold-glow);
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 15px var(--gold-glow);
}

/* ── Breadcrumb ────────────────────────────────── */
.breadcrumb {
  margin-bottom: 1.5rem;
}

.breadcrumb ul {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-wrap: wrap;
  font-family: var(--font-heading);
  font-size: .75rem;
  letter-spacing: .06em;
  color: var(--text-muted);
}

.breadcrumb li + li::before {
  content: '›';
  margin-right: .5rem;
  color: var(--gold-dark);
}

.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb .current { color: var(--gold-light); }

/* ── Badges ────────────────────────────────────── */
.badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: .2em .6em;
  border-radius: var(--radius-sm);
  line-height: 1.4;
  border: 1px solid transparent;
}

.badge-race    { background: rgba(60,30,5,.6);  color: var(--parchment-mid); border-color: var(--gold-dark); }
.badge-type    { background: rgba(40,20,60,.5);  color: #c8b0e0; border-color: rgba(150,80,200,.4); }
.badge-genre   { background: rgba(20,40,60,.5);  color: #a0c8e0; border-color: rgba(60,120,180,.4); }
.badge-default { background: var(--bg-panel);   color: var(--text-muted); border-color: var(--border-subtle); }
.badge-vivant  { background: rgba(15,46,18,.7);  color: #7acc7a; border-color: rgba(80,180,80,.4); }
.badge-mort    { background: rgba(60,10,10,.7);  color: #cc7070; border-color: rgba(180,60,60,.4); }
.badge-langue  { background: rgba(30,25,10,.7);  color: var(--parchment-mid); border-color: var(--border); }

/* ── HOME PAGE ─────────────────────────────────── */

/* Hero */
.hero {
  text-align: center;
  padding: 3rem 1rem 2rem;
  position: relative;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  color: var(--gold);
  font-weight: 700;
  letter-spacing: .1em;
  text-shadow: 0 0 40px rgba(201,162,39,.4), 0 2px 6px rgba(0,0,0,.9);
  margin-bottom: .75rem;
}

.hero-subtitle {
  font-family: var(--font-flavor);
  font-style: italic;
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  color: var(--parchment-dark);
  margin-bottom: 1.25rem;
}

.hero-divider {
  color: var(--gold);
  font-size: 1.2rem;
  letter-spacing: .8rem;
  margin-bottom: 1.25rem;
  opacity: .8;
}

.hero-text {
  max-width: 620px;
  margin: 0 auto;
  color: var(--text-muted);
  font-size: .95rem;
  line-height: 1.8;
}

/* Category Cards */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  margin: 1rem 0;
}

.cat-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .6rem;
  padding: 1.75rem 1.5rem;
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: all .25s;
}

.cat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--gold-subtle) 0%, transparent 60%);
  opacity: 0;
  transition: opacity .25s;
}

.cat-card:hover { border-color: var(--gold); box-shadow: 0 0 30px var(--gold-glow), inset 0 0 30px var(--gold-subtle); transform: translateY(-2px); }
.cat-card:hover::before { opacity: 1; }

.cat-card-icon {
  font-size: 2rem;
  line-height: 1;
  color: var(--gold);
  text-shadow: 0 0 15px var(--gold-glow);
  position: relative;
}

.cat-card-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: .08em;
  position: relative;
}

.cat-card-desc {
  font-size: .85rem;
  color: var(--text-muted);
  line-height: 1.6;
  position: relative;
  flex: 1;
}

.cat-card-arrow {
  font-size: .9rem;
  color: var(--gold);
  opacity: 0;
  transition: all .2s;
  margin-top: auto;
  position: relative;
}

.cat-card:hover .cat-card-arrow { opacity: 1; transform: translateX(4px); }

/* Featured grid */
.home-featured { margin-top: 1rem; }

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: .75rem;
}

.featured-card {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  padding: .9rem 1.1rem;
  background: var(--bg-medium);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--gold-dark);
  border-radius: var(--radius);
  text-decoration: none;
  transition: all .2s;
}

.featured-card:hover {
  border-left-color: var(--gold);
  background: var(--bg-panel);
  box-shadow: 0 0 15px var(--gold-glow);
}

.featured-label {
  font-family: var(--font-heading);
  font-size: .85rem;
  font-weight: 600;
  color: var(--gold-light);
  letter-spacing: .05em;
}

.featured-sub {
  font-size: .75rem;
  color: var(--text-muted);
}

/* ── CATEGORY PAGE ─────────────────────────────── */
.perso-group { margin-bottom: 2rem; }

.group-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  color: var(--parchment-dark);
  letter-spacing: .15em;
  text-transform: uppercase;
  padding: .5rem 0;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 1.25rem;
}

.entries-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.entry-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.1rem 1.2rem;
  background: var(--bg-panel);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  text-decoration: none;
  transition: all .22s;
  position: relative;
}

.entry-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold), var(--gold-dark));
  opacity: 0;
  transition: opacity .2s;
  border-radius: 0 0 var(--radius) var(--radius);
}

.entry-card:hover {
  border-color: var(--border-strong);
  background: var(--bg-light);
  box-shadow: 0 4px 20px var(--shadow-dark), 0 0 20px var(--gold-glow);
  transform: translateY(-1px);
}

.entry-card:hover::after { opacity: 1; }

.entry-icon {
  font-size: 1.5rem;
  color: var(--gold);
  opacity: .8;
  flex-shrink: 0;
  line-height: 1;
  margin-top: .1rem;
}

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

.entry-name {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: .05em;
  margin-bottom: .4rem;
}

.entry-meta { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .5rem; }

.entry-excerpt {
  font-size: .8rem;
  color: var(--text-muted);
  line-height: 1.5;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.entry-arrow {
  color: var(--gold-dark);
  font-size: .9rem;
  opacity: 0;
  transition: all .2s;
  flex-shrink: 0;
  margin-top: .15rem;
}

.entry-card:hover .entry-arrow { opacity: 1; transform: translateX(3px); }

/* ── WIKI ARTICLE ──────────────────────────────── */
.wiki-article {
  max-width: 1100px;
}

.article-header {
  margin-bottom: 1rem;
}

.article-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  color: var(--gold);
  letter-spacing: .08em;
  line-height: 1.2;
  margin-bottom: .6rem;
  text-shadow: 0 0 30px var(--gold-glow);
}

.article-badges { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .6rem; }

.article-aliases {
  font-family: var(--font-flavor);
  font-style: italic;
  font-size: .9rem;
  color: var(--text-muted);
}

/* Article layout: content + sidebar */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2rem;
  align-items: start;
}

@media (max-width: 768px) {
  .article-layout { grid-template-columns: 1fr; }
  .article-infobox { order: -1; }
}

/* Infobox */
.article-infobox {
  background: linear-gradient(180deg, var(--bg-panel) 0%, var(--bg-medium) 100%);
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  overflow: hidden;
  position: sticky;
  top: 60px;
}

.infobox-title {
  font-family: var(--font-heading);
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--parchment);
  background: linear-gradient(90deg, var(--gold-dark), rgba(125,98,24,.6));
  padding: .65rem 1rem;
}

.infobox-list {
  padding: .75rem 1rem;
  display: grid;
  gap: 0;
}

.infobox-list dt {
  font-family: var(--font-heading);
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-top: .75rem;
  padding-bottom: .15rem;
  border-bottom: 1px solid var(--border-subtle);
}

.infobox-list dt:first-child { margin-top: 0; }

.infobox-list dd {
  font-size: .85rem;
  color: var(--parchment-dark);
  margin-top: .2rem;
  padding-bottom: .1rem;
}

.infobox-section {
  padding: .75rem 1rem;
  border-top: 1px solid var(--border-subtle);
}

.infobox-section h4 {
  font-family: var(--font-heading);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: .5rem;
}

/* Article content sections */
.article-content { min-width: 0; }

.article-section {
  background: linear-gradient(180deg, var(--bg-panel) 0%, rgba(28,21,9,.95) 100%);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.25rem;
  position: relative;
}

.article-section::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--gold-dark), transparent);
  border-radius: var(--radius) 0 0 var(--radius);
}

.article-section--double {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.article-section--double::before { display: none; }

@media (max-width: 600px) {
  .article-section--double { grid-template-columns: 1fr; }
}

.article-section--magic {
  border-color: rgba(150,80,200,.25);
  background: linear-gradient(180deg, rgba(40,15,60,.6) 0%, rgba(28,21,9,.95) 100%);
}

.article-section--magic::before {
  background: linear-gradient(180deg, rgba(150,80,200,.6), transparent);
}

.article-section-title {
  font-family: var(--font-heading);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .9rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.article-section p {
  color: var(--parchment-dark);
  font-size: .95rem;
  line-height: 1.8;
}

/* Trait blocks */
.trait-block { min-width: 0; }

.trait-title {
  font-family: var(--font-heading);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .6rem;
}

.trait-title--forces   { color: #7acc7a; }
.trait-title--faiblesses { color: #cc7070; }

/* Relations */
.relations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

@media (max-width: 500px) { .relations-grid { grid-template-columns: 1fr; } }

.relation-block { min-width: 0; }

.relation-title {
  font-family: var(--font-heading);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .6rem;
}

.relation-block--ally .relation-title  { color: #7acc7a; }
.relation-block--enemy .relation-title { color: #cc7070; }

/* Info list */
.info-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}

.info-list li {
  font-size: .875rem;
  color: var(--parchment-dark);
  padding-left: 1rem;
  position: relative;
  line-height: 1.5;
}

.info-list li::before {
  content: '◆';
  position: absolute;
  left: 0;
  color: var(--gold-dark);
  font-size: .5rem;
  top: .45em;
}

.info-list a { color: var(--gold); }
.info-list a:hover { color: var(--gold-light); text-decoration: underline; }

/* Quartier blocks */
.quartier-block {
  padding: .9rem 1.1rem;
  background: var(--bg-medium);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--gold-dark);
  border-radius: var(--radius);
  margin-bottom: .75rem;
}

.quartier-title {
  font-family: var(--font-heading);
  font-size: .9rem;
  font-weight: 600;
  color: var(--gold-light);
  letter-spacing: .06em;
  margin-bottom: .4rem;
}

/* Magic & language sections */
.magic-condition {
  margin-top: .75rem;
  padding: .6rem .9rem;
  background: rgba(150,80,200,.1);
  border: 1px solid rgba(150,80,200,.2);
  border-radius: var(--radius);
  font-size: .85rem;
  color: var(--parchment-dark);
}

.language-example {
  margin-top: 1rem;
  padding: .75rem 1.1rem;
  background: var(--bg-medium);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-flavor);
  font-style: italic;
  font-size: .95rem;
  color: var(--parchment);
  text-align: center;
}

/* Lexique table */
.lexique-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
}

.lexique-table th {
  font-family: var(--font-heading);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gold);
  background: var(--bg-medium);
  padding: .6rem .9rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.lexique-table td {
  padding: .5rem .9rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--parchment-dark);
}

.lexique-table tr:hover td { background: var(--bg-medium); }

.lex-word {
  font-family: var(--font-flavor);
  font-style: italic;
  color: var(--gold-light);
}

/* ── SEARCH PAGE ───────────────────────────────── */
.results-count {
  font-family: var(--font-heading);
  font-size: .8rem;
  color: var(--text-muted);
  letter-spacing: .08em;
  margin-bottom: 1.5rem;
}

.no-results {
  text-align: center;
  padding: 3rem;
  color: var(--text-muted);
}

.no-results p { margin-bottom: .75rem; }

/* ── NOT FOUND ─────────────────────────────────── */
.page-notfound {
  text-align: center;
  padding: 3rem 1rem;
}

.btn-back {
  display: inline-block;
  margin-top: 1.5rem;
  padding: .7rem 1.5rem;
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: .85rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: .1em;
  transition: all .2s;
}

.btn-back:hover {
  background: var(--bg-light);
  border-color: var(--gold);
  box-shadow: 0 0 15px var(--gold-glow);
}

.btn-random {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .55rem 1.1rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: .8rem;
  letter-spacing: .1em;
  color: var(--text-muted);
  text-decoration: none;
  white-space: nowrap;
  transition: all .2s;
  flex-shrink: 0;
}

.btn-random:hover {
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 12px var(--gold-glow);
}

/* ── FOOTER ────────────────────────────────────── */
.site-footer {
  margin-top: 4rem;
  background: var(--bg-darkest);
  border-top: 1px solid var(--border-subtle);
  padding: 2.5rem 1.5rem;
  text-align: center;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
}

.footer-ornament {
  font-size: 1rem;
  color: var(--gold-dark);
  letter-spacing: .5rem;
  margin-bottom: .25rem;
}

.footer-title {
  font-family: var(--font-heading);
  font-size: .9rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: .15em;
}

.footer-text {
  font-size: .75rem;
  color: var(--text-muted);
  font-family: var(--font-heading);
  letter-spacing: .08em;
}

/* ── Utilities ─────────────────────────────────── */
.text-muted { color: var(--text-muted); font-style: italic; }

/* ── Scrollbar ─────────────────────────────────── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-darkest); }
::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold); }

/* ── Responsive ────────────────────────────────── */
@media (max-width: 900px) {
  .nav-inner { flex-direction: column; padding: 0; gap: 0; }
  .nav-links { width: 100%; justify-content: center; }
  .nav-link { padding: .75rem .65rem; font-size: .75rem; }
  .nav-search { padding: .5rem 1rem; width: 100%; }
  .search-input { width: 100%; flex: 1; }
}

@media (max-width: 600px) {
  .site-main { padding: 1.5rem 1rem 3rem; }
  .categories-grid { grid-template-columns: 1fr 1fr; }
  .entries-grid { grid-template-columns: 1fr; }
  .featured-grid { grid-template-columns: 1fr 1fr; }
  .article-section { padding: 1.1rem 1.2rem; }
}

@media (max-width: 400px) {
  .categories-grid { grid-template-columns: 1fr; }
  .featured-grid { grid-template-columns: 1fr; }
}