/* ============================================
   The Wound at the End of the World
   Main Stylesheet v1.0
   ============================================ */

/* ─── GOOGLE FONTS ─── */
@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@400;700;900&family=Cinzel:wght@400;600;700&family=EB+Garamond:ital,wght@0,400;0,500;1,400;1,500&display=swap');

/* ─── CSS VARIABLES ─── */
:root {
  --silver: #a8b8c8;
  --silver-light: #d4e0ea;
  --silver-dark: #6a7f92;
  --blue: #2a4a6b;
  --blue-light: #3d6b96;
  --blue-pale: #e8f0f7;
  --stone-dark: #2c3340;
  --stone-mid: #3d4a58;
  --stone-light: #f2f5f8;
  --stone-pale: #e8ecf0;
  --off-white: #f8fafc;
  --text-dark: #1a2330;
  --text-mid: #3a4a5a;
  --text-light: #6a7f92;
}

/* ─── RESET & BASE ─── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--off-white);
  color: var(--text-dark);
  font-family: 'EB Garamond', Georgia, serif;
  font-size: 18px;
  line-height: 1.7;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 999;
  opacity: 0.5;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ─── WORDPRESS CORE OVERRIDES ─── */
.wp-block-image { margin: 0; }
.alignnone, .aligncenter, .alignleft, .alignright { margin-bottom: 1.5rem; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }

/* ─── NAVIGATION ─── */
#masthead {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 100;
  padding: 18px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(to bottom, rgba(26,35,48,0.96) 0%, transparent 100%);
  transition: background 0.3s, box-shadow 0.3s;
}

#masthead.scrolled {
  background: rgba(26,35,48,0.98);
  box-shadow: 0 1px 0 rgba(168,184,200,0.15);
}

.site-branding .site-title {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  letter-spacing: 0.25em;
  color: var(--silver-light);
  text-transform: uppercase;
  font-weight: 400;
}

.site-branding .site-title a { color: var(--silver-light); }

#primary-navigation ul {
  display: flex;
  gap: 36px;
  list-style: none;
}

#primary-navigation a {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--silver);
  text-transform: uppercase;
  transition: color 0.2s;
}

#primary-navigation a:hover,
#primary-navigation .current-menu-item > a { color: var(--silver-light); }

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(168,184,200,0.4);
  color: var(--silver);
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.15em;
  padding: 8px 16px;
  cursor: pointer;
  text-transform: uppercase;
}

/* ─── HERO SECTION ─── */
#hero {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 70% at 50% 35%, rgba(42,74,107,0.35) 0%, transparent 65%),
    radial-gradient(ellipse 100% 50% at 50% 100%, rgba(61,107,150,0.15) 0%, transparent 60%),
    linear-gradient(180deg, #1a2330 0%, #243040 40%, #1a2330 100%);
}

.hero-motes {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.mote {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--silver-light);
  border-radius: 50%;
  opacity: 0;
  animation: float-up var(--dur) ease-in infinite;
  animation-delay: var(--delay);
  left: var(--x);
  bottom: 0;
  box-shadow: 0 0 4px 2px rgba(212,224,234,0.3);
}

@keyframes float-up {
  0%   { opacity: 0; transform: translateY(0) translateX(0); }
  10%  { opacity: 0.6; }
  70%  { opacity: 0.2; }
  100% { opacity: 0; transform: translateY(-80vh) translateX(calc(var(--drift) * 40px)); }
}

.hero-ornament {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(700px, 90vw);
  height: min(700px, 90vw);
  border: 1px solid rgba(168,184,200,0.08);
  border-radius: 50%;
  animation: pulse-ring 8s ease-in-out infinite;
  pointer-events: none;
}

.hero-ornament::before {
  content: '';
  position: absolute;
  inset: 30px;
  border: 1px solid rgba(168,184,200,0.05);
  border-radius: 50%;
}

@keyframes pulse-ring {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
  50%       { transform: translate(-50%, -50%) scale(1.02); opacity: 0.6; }
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 100px 24px 60px;
  max-width: 900px;
}

.hero-eyebrow {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  letter-spacing: 0.5em;
  color: var(--silver);
  text-transform: uppercase;
  margin-bottom: 32px;
  opacity: 0;
  animation: fade-in-up 1.2s 0.3s forwards;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.hero-eyebrow::before,
.hero-eyebrow::after {
  content: '';
  width: 40px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--silver-dark));
}

.hero-eyebrow::after {
  background: linear-gradient(to left, transparent, var(--silver-dark));
}

.hero-title {
  font-family: 'Cinzel Decorative', serif;
  font-size: clamp(2.8rem, 7vw, 6rem);
  font-weight: 900;
  line-height: 1.1;
  color: #f0f4f8;
  text-shadow: 0 0 80px rgba(61,107,150,0.25), 0 2px 4px rgba(0,0,0,0.6);
  margin-bottom: 8px;
  opacity: 0;
  animation: fade-in-up 1.4s 0.5s forwards;
}

.hero-title .word-wound {
  color: var(--silver-light);
  display: block;
  font-size: clamp(3.2rem, 8vw, 7rem);
  text-shadow: 0 0 40px rgba(168,184,200,0.4), 0 0 80px rgba(42,74,107,0.3);
}

.hero-title .word-at {
  font-size: clamp(1.2rem, 3vw, 2.2rem);
  font-weight: 400;
  letter-spacing: 0.4em;
  color: var(--silver);
  display: block;
  margin: 6px 0;
}

.hero-title .word-end {
  font-size: clamp(1.6rem, 4vw, 3rem);
  font-weight: 400;
  color: var(--silver);
  display: block;
}

.hero-title .word-world {
  color: #7aadcf;
  display: block;
  font-size: clamp(2.4rem, 6vw, 5rem);
  text-shadow: 0 0 40px rgba(61,107,150,0.6);
}

.hero-divider {
  margin: 28px auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  opacity: 0;
  animation: fade-in 1.4s 0.9s forwards;
}

.hero-divider .line {
  display: block;
  height: 1px;
  width: 80px;
  background: linear-gradient(to right, transparent, var(--silver-dark));
}

.hero-divider .line-right {
  background: linear-gradient(to left, transparent, var(--silver-dark));
}

.hero-divider .diamond {
  width: 8px;
  height: 8px;
  background: var(--silver-dark);
  transform: rotate(45deg);
  display: block;
}

.hero-tagline {
  font-style: italic;
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: var(--silver);
  margin-bottom: 48px;
  opacity: 0;
  animation: fade-in-up 1.4s 1s forwards;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  opacity: 0;
  animation: fade-in-up 1.4s 1.2s forwards;
  margin-bottom: 80px;
}

.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0;
  animation: fade-in 2s 2s forwards;
}

.scroll-indicator span {
  font-family: 'Cinzel', serif;
  font-size: 9px;
  letter-spacing: 0.3em;
  color: rgba(168,184,200,0.5);
  text-transform: uppercase;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, rgba(168,184,200,0.5), transparent);
  animation: scroll-pulse 2s ease-in-out infinite;
  display: block;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 1; transform: scaleY(1); }
  50%       { opacity: 0.3; transform: scaleY(0.7); }
}

/* ─── BUTTONS ─── */
.btn-primary,
.wp-block-button__link {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 12px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 16px 40px;
  background: var(--blue-light);
  color: #f0f4f8;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.08);
  transform: translateX(-100%);
  transition: transform 0.3s;
}

.btn-primary:hover::before { transform: translateX(0); }
.btn-primary:hover { box-shadow: 0 0 30px rgba(61,107,150,0.5); color: #fff; }

.btn-secondary {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 12px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 15px 40px;
  background: transparent;
  color: var(--silver-light);
  border: 1px solid rgba(168,184,200,0.4);
  cursor: pointer;
  transition: all 0.3s;
}

.btn-secondary:hover {
  border-color: var(--silver-light);
  color: #fff;
  background: rgba(168,184,200,0.08);
}

/* ─── SECTION SHARED ─── */
.section-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 48px;
}

.section-label {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.5em;
  color: var(--blue-light);
  text-transform: uppercase;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, var(--blue-light), transparent);
  max-width: 60px;
  opacity: 0.5;
}

.section-label.light { color: var(--silver); }
.section-label.light::after { background: linear-gradient(to right, var(--silver), transparent); }

.section-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 24px;
  line-height: 1.2;
}

.section-title.light { color: var(--silver-light); }

/* ─── BOOK / EXCERPT SECTION ─── */
#book {
  padding: 100px 0;
  background: linear-gradient(180deg, var(--off-white) 0%, var(--stone-light) 50%, var(--off-white) 100%);
}

.book-layout {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 80px;
  align-items: start;
}

.book-cover-wrap {
  position: sticky;
  top: 120px;
}

.cover-art {
  width: 100%;
  aspect-ratio: 2/3;
  background:
    radial-gradient(ellipse 80% 60% at 50% 30%, rgba(61,107,150,0.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 30% 70%, rgba(42,74,107,0.12) 0%, transparent 60%),
    linear-gradient(160deg, #2c3a4a 0%, #1e2c3a 40%, #243040 80%, #1a2330 100%);
  border: 1px solid rgba(168,184,200,0.25);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 28px;
  box-shadow:
    0 0 0 1px rgba(168,184,200,0.08),
    0 20px 60px rgba(0,0,0,0.25),
    inset 0 0 80px rgba(0,0,0,0.3);
}

.cover-art::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(168,184,200,0.15);
  pointer-events: none;
}

.cover-art::after {
  content: '';
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(168,184,200,0.07);
  pointer-events: none;
}

.cover-symbol {
  width: 140px;
  height: 140px;
  margin-bottom: 32px;
  filter: drop-shadow(0 0 20px rgba(168,184,200,0.35));
}

.cover-title-block {
  text-align: center;
  position: relative;
  z-index: 1;
}

.cover-t {
  font-family: 'Cinzel Decorative', serif;
  font-size: 11px;
  letter-spacing: 0.3em;
  color: var(--silver-dark);
  text-transform: uppercase;
  display: block;
  margin-bottom: 8px;
}

.cover-main {
  font-family: 'Cinzel Decorative', serif;
  font-weight: 900;
  font-size: 1.5rem;
  color: var(--silver-light);
  line-height: 1.2;
  text-shadow: 0 0 30px rgba(168,184,200,0.3);
  display: block;
}

.cover-sub {
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  color: var(--silver);
  letter-spacing: 0.15em;
  margin-top: 8px;
  display: block;
}

.cover-band {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 16px 28px;
  background: rgba(0,0,0,0.35);
  border-top: 1px solid rgba(168,184,200,0.12);
  text-align: center;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  color: var(--silver-dark);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* If a real cover image is set as featured image */
.cover-art.has-image .cover-symbol,
.cover-art.has-image .cover-title-block,
.cover-art.has-image .cover-band { display: none; }

.cover-art.has-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-info { padding-top: 20px; }

.book-lead {
  color: var(--text-mid);
  margin-bottom: 24px;
  font-size: 1.05rem;
}

.excerpt-block {
  background: rgba(42,74,107,0.05);
  border-left: 2px solid var(--blue-light);
  padding: 32px 36px;
  margin: 32px 0;
  position: relative;
}

.excerpt-block::before {
  content: '\201C';
  position: absolute;
  top: -20px;
  left: 24px;
  font-family: 'Cinzel Decorative', serif;
  font-size: 80px;
  color: rgba(42,74,107,0.08);
  line-height: 1;
}

.excerpt-block p {
  font-style: italic;
  font-size: 1.1rem;
  color: var(--text-mid);
  line-height: 1.85;
}

.meta-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
}

.meta-tag {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--blue-light);
  border: 1px solid rgba(42,74,107,0.25);
  padding: 6px 16px;
  text-transform: uppercase;
  background: rgba(42,74,107,0.04);
}

/* ─── SYNOPSIS SECTION ─── */
#synopsis {
  padding: 100px 0;
  background: var(--stone-dark);
  position: relative;
  overflow: hidden;
}

#synopsis::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--silver-dark), transparent);
}

#synopsis::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--silver-dark), transparent);
}

.synopsis-text {
  max-width: 760px;
  font-size: 1.15rem;
  line-height: 1.9;
  color: var(--silver-light);
}

.synopsis-text p + p { margin-top: 20px; }

/* ─── WORLD SECTION ─── */
#world {
  padding: 100px 0;
  background: var(--off-white);
}

.world-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  margin-top: 60px;
}

.world-card {
  background: var(--stone-pale);
  padding: 44px 36px;
  position: relative;
  overflow: hidden;
  transition: background 0.3s;
}
.world-card-image {
  width: 100%;
  aspect-ratio: 1/1;
  overflow: hidden;
  margin-bottom: 20px;
}

.world-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.world-card:hover .world-card-image img {
  transform: scale(1.03);
}
.world-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--blue-light);
  transform: scaleX(0);
  transition: transform 0.4s;
}

.world-card:hover::before { transform: scaleX(1); }
.world-card:hover { background: var(--blue-pale); }

.world-card-icon {
  font-size: 2rem;
  margin-bottom: 20px;
  display: block;
}

.world-card-title {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  letter-spacing: 0.15em;
  color: var(--blue);
  text-transform: uppercase;
  margin-bottom: 14px;
}

.world-card-desc {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.7;
}

/* ─── CHARACTERS SECTION ─── */
#characters {
  padding: 100px 0;
  background: linear-gradient(180deg, var(--stone-light) 0%, var(--off-white) 100%);
}

.characters-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  margin-top: 60px;
}

.character-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 28px;
  align-items: start;
}

.char-portrait {
  width: 120px;
  height: 160px;
  background:
    radial-gradient(ellipse at 50% 30%, rgba(61,107,150,0.15) 0%, transparent 60%),
    var(--stone-pale);
  border: 1px solid rgba(42,74,107,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.char-portrait::after {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(42,74,107,0.08);
}

.char-portrait img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.char-initial {
  font-family: 'Cinzel Decorative', serif;
  font-size: 3rem;
  color: var(--blue-light);
  opacity: 0.5;
  position: relative;
  z-index: 1;
}

.char-name {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 4px;
}

.char-role {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.25em;
  color: var(--silver-dark);
  text-transform: uppercase;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(42,74,107,0.15);
}

.char-desc {
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.65;
}

/* ─── CHAPTERS SECTION ─── */
#chapters {
  padding: 100px 0;
  background: var(--stone-dark);
}

.acts-container { margin-top: 60px; }

.act-block { margin-bottom: 48px; }

.act-header {
  font-family: 'Cinzel', serif;
  font-size: 0.8rem;
  letter-spacing: 0.4em;
  color: var(--silver);
  text-transform: uppercase;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.act-header::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, rgba(168,184,200,0.3), transparent);
}

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

.chapter-item {
  padding: 16px 20px;
  background: var(--stone-mid);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: background 0.2s;
}

.chapter-item:hover { background: rgba(61,107,150,0.15); }

.chapter-num {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--silver-dark);
  min-width: 28px;
}

.chapter-name {
  font-size: 0.88rem;
  color: var(--silver-light);
  line-height: 1.4;
}

/* ─── NEWSLETTER SECTION ─── */
#newsletter {
  padding: 100px 0;
  background: var(--stone-light);
  position: relative;
  overflow: hidden;
  text-align: center;
}

#newsletter::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 80% at 50% 50%, rgba(42,74,107,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(61,107,150,0.04) 0%, transparent 60%);
}

.newsletter-inner {
  position: relative;
  z-index: 1;
  max-width: 600px;
  margin: 0 auto;
}

.newsletter-ornament {
  width: 60px;
  height: 1px;
  background: var(--blue-light);
  margin: 0 auto 32px;
  opacity: 0.5;
  display: block;
}

.newsletter-title {
  font-family: 'Cinzel', serif;
  font-size: 2rem;
  color: var(--text-dark);
  margin-bottom: 16px;
}

.newsletter-sub {
  font-style: italic;
  color: var(--text-light);
  margin-bottom: 40px;
}

.newsletter-form {
  display: flex;
  gap: 0;
  max-width: 480px;
  margin: 0 auto;
}

.newsletter-form input[type="email"] {
  flex: 1;
  background: #fff;
  border: 1px solid rgba(42,74,107,0.2);
  border-right: none;
  padding: 14px 20px;
  color: var(--text-dark);
  font-family: 'EB Garamond', serif;
  font-size: 1rem;
  outline: none;
}

.newsletter-form input[type="email"]::placeholder {
  color: rgba(58,74,90,0.4);
  font-style: italic;
}

.newsletter-form input[type="email"]:focus {
  border-color: rgba(42,74,107,0.5);
  background: var(--blue-pale);
}

.newsletter-form button[type="submit"] {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 14px 28px;
  background: var(--blue);
  color: var(--silver-light);
  border: 1px solid var(--blue);
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.newsletter-form button[type="submit"]:hover { background: var(--blue-light); }

.newsletter-success {
  display: none;
  font-style: italic;
  color: var(--blue-light);
  margin-top: 20px;
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
}

/* WordPress Contact Form 7 / Gravity Forms compat */
.wpcf7-form input[type="email"],
.gform_wrapper input[type="email"] {
  flex: 1;
  background: #fff;
  border: 1px solid rgba(42,74,107,0.2);
  padding: 14px 20px;
  font-family: 'EB Garamond', serif;
  font-size: 1rem;
  width: 100%;
  box-sizing: border-box;
}

/* ─── STANDARD PAGES / POSTS ─── */
.page-content-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 120px 48px 80px;
}

.entry-title {
  font-family: 'Cinzel Decorative', serif;
  font-size: clamp(1.8rem, 4vw, 3rem);
  color: var(--text-dark);
  margin-bottom: 32px;
  line-height: 1.2;
}

.entry-content h1, .entry-content h2, .entry-content h3,
.entry-content h4, .entry-content h5, .entry-content h6 {
  font-family: 'Cinzel', serif;
  color: var(--text-dark);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.entry-content p { margin-bottom: 1.25rem; }

.entry-content a {
  color: var(--blue-light);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.entry-content blockquote {
  border-left: 2px solid var(--blue-light);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: rgba(42,74,107,0.04);
  font-style: italic;
}

/* ─── FOOTER ─── */
#colophon {
  padding: 60px 48px 40px;
  background: var(--stone-dark);
  border-top: 1px solid rgba(168,184,200,0.12);
  text-align: center;
}

.footer-title {
  font-family: 'Cinzel Decorative', serif;
  font-size: 1.1rem;
  color: var(--silver);
  margin-bottom: 24px;
}

.footer-nav {
  display: flex;
  gap: 32px;
  justify-content: center;
  list-style: none;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.footer-nav a {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(168,184,200,0.4);
  text-transform: uppercase;
  transition: color 0.2s;
}

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

.site-info {
  font-size: 0.8rem;
  color: rgba(168,184,200,0.25);
  font-style: italic;
}

/* ─── SCROLL REVEAL ─── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── ANIMATIONS ─── */
@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .world-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .book-layout { grid-template-columns: 1fr; }
  .book-cover-wrap { position: static; max-width: 300px; margin: 0 auto 40px; }
  .characters-grid { grid-template-columns: 1fr; }
  #masthead { padding: 16px 24px; }
  #primary-navigation ul { gap: 20px; }
  .section-inner { padding: 0 24px; }
  .world-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  #primary-navigation { display: none; }
  #primary-navigation.toggled { display: block; }
  #primary-navigation.toggled ul {
    flex-direction: column;
    background: rgba(26,35,48,0.98);
    padding: 20px 24px;
    gap: 16px;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
  }
  .menu-toggle { display: block; }
}

@media (max-width: 600px) {
  .newsletter-form { flex-direction: column; }
  .newsletter-form input[type="email"] { border-right: 1px solid rgba(42,74,107,0.2); border-bottom: none; }
  .character-card { grid-template-columns: 80px 1fr; }
  .char-portrait { width: 80px; height: 110px; }
  .page-content-wrap { padding: 100px 24px 60px; }
  #colophon { padding: 40px 24px 30px; }
}

/* ─── ADMIN BAR OFFSET ─── */
.admin-bar #masthead { top: 32px; }
@media screen and (max-width: 782px) {
  .admin-bar #masthead { top: 46px; }
}

/* ─── HOUSES SECTION ─── */
#houses {
  padding: 100px 0;
  background: var(--off-white);
}

.houses-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  margin-top: 60px;
}

.house-card {
  background: var(--stone-pale);
  border: 1px solid rgba(42,74,107,0.12);
  overflow: hidden;
  transition: box-shadow 0.3s;
  position: relative;
}

.house-card:hover {
  box-shadow: 0 8px 40px rgba(42,74,107,0.12);
}

.house-card-header {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 0;
  align-items: stretch;
}

.house-card-mon {
  width: 120px;
  min-height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  background: var(--stone-mid);
}

.house-card-mon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

.house-card-mon .mon-fallback {
  font-family: 'Cinzel Decorative', serif;
  font-size: 2.5rem;
  color: rgba(168,184,200,0.4);
  position: relative;
  z-index: 1;
}

.house-card-identity {
  padding: 24px 24px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.house-card-colour-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 10px;
  background: var(--house-colour, var(--blue-light));
}

.house-card-name {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 4px;
  margin-top: 8px;
}

.house-card-standing {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  letter-spacing: 0.25em;
  color: var(--silver-dark);
  text-transform: uppercase;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(42,74,107,0.1);
}

.house-card-body {
  padding: 0 24px 24px;
}

.house-card-desc {
  font-size: 0.92rem;
  color: var(--text-mid);
  line-height: 1.7;
  margin-bottom: 16px;
}

.house-card-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.house-meta-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 8px;
  font-size: 0.85rem;
  line-height: 1.5;
}

.house-meta-label {
  font-family: 'Cinzel', serif;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--blue-light);
  text-transform: uppercase;
  padding-top: 2px;
}

.house-meta-value {
  color: var(--text-mid);
}

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

@media (max-width: 600px) {
  .house-card-header { grid-template-columns: 90px 1fr; }
  .house-card-mon { width: 90px; min-height: 120px; }
}