/* ── RAVEN'S IMMORTAL ART STUDIOS — SHARED STYLES ── */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;900&family=Cormorant+Garamond:wght@400;500;600;700&family=Crimson+Pro:ital,wght@0,300;0,400;1,300;1,400&display=swap');

:root {
  --bg: #05080f;
  --bg-card: #090d1a;
  --border: #1a1e30;
  --border-hover: #a89a7e;
  --gold: #e3a94e;
  --gold-dim: #7a5518;
  --gold-bright: #f4c46a;
  --text: #e8dcc8;
  --text-dim: #b4aa96;
  --text-mid: #c2b79f;
  --glow: rgba(200, 137, 42, 0.28);
  --blue-deep: #05080f;
  --studios: #cdbb92;
  --studios-bright: #f0e2c0;
  --studios-line: rgba(205, 187, 146, 0.6);
  --btn-font: 'Cormorant Garamond', Georgia, serif;
}

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

body {
  font-family: 'Crimson Pro', Georgia, serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* ── NAV ── */
.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-bottom: 1px solid var(--border);
  background: rgba(4, 6, 14, 0.96);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.nav-brand {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.06em;
}

.nav-brand span { color: var(--gold); }

.nav-back {
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mid);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-back:hover { color: var(--gold); }

/* ── HERO (homepage only) ── */
.hero {
  position: relative;
  width: 100%;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px 50px;
  overflow: hidden;
  background-image: url('forge.png');
  background-size: cover;
  background-position: center;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(4, 6, 14, 0.75) 0%,
    rgba(4, 6, 14, 0.55) 50%,
    rgba(4, 6, 14, 0.92) 100%
  );
}

.hero-inner { position: relative; z-index: 2; }

.hero-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.8rem, 6vw, 3.2rem);
  font-weight: 900;
  letter-spacing: 0.06em;
  color: var(--text);
  text-shadow: 0 0 30px var(--glow), 0 0 60px rgba(200,137,42,0.1);
  margin-bottom: 0.5rem;
  animation: fadeUp 0.9s ease both;
}

.hero-sub {
  font-family: 'Cinzel', serif;
  font-size: clamp(0.8rem, 2.2vw, 1rem);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  animation: fadeUp 0.9s 0.12s ease both;
}

.hero-tagline {
  margin-top: 1rem;
  font-size: clamp(0.95rem, 2.2vw, 1.15rem);
  font-style: italic;
  color: var(--text-mid);
  font-weight: 300;
  animation: fadeUp 0.9s 0.24s ease both;
}

/* ── DIVIDER ── */
.divider {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 24px;
  margin: 28px auto 20px;
  max-width: 900px;
}

.divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border), transparent);
}

.divider-gem {
  width: 7px; height: 7px;
  background: var(--gold-dim);
  transform: rotate(45deg);
  box-shadow: 0 0 6px var(--glow);
}

/* ── SECTION LABEL ── */
.section-label {
  text-align: center;
  font-family: 'Cinzel', serif;
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 20px;
}

/* ── GRID ── */
.grid-wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

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

.card.wide { grid-column: 1 / -1; }

/* ── CARDS ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 18px 22px;
  cursor: pointer;
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.22s;
  text-decoration: none;
  display: block;
  position: relative;
  overflow: hidden;
}

.card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 0 24px rgba(200,137,42,0.18), inset 0 0 30px rgba(200,137,42,0.03);
  transform: translateY(-3px);
}

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

.card.highlight {
  background: linear-gradient(135deg, #0d1020 0%, #0a0e1c 100%);
  border-color: var(--gold-dim);
}

.card-icon { font-size: 1.5rem; margin-bottom: 8px; display: block; }

.card-title {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.35rem;
  letter-spacing: 0.04em;
}

.card-text {
  font-size: 0.98rem;
  color: var(--text-dim);
  line-height: 1.5;
  font-weight: 300;
}

.card-badge {
  display: inline-block;
  margin-top: 10px;
  font-family: 'Cinzel', serif;
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  border-radius: 3px;
  padding: 2px 8px;
}

.card-badge.gold { background: var(--gold-dim); color: var(--text); }

/* ── PAGE HEADER ── */
.page-header {
  padding: 44px 28px 32px;
  max-width: 900px;
  margin: 0 auto;
}

.page-header h1 {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.7rem, 5vw, 2.6rem);
  font-weight: 900;
  color: var(--text);
  letter-spacing: 0.05em;
  text-shadow: 0 0 28px var(--glow);
  margin-bottom: 0.4rem;
}

.page-header p {
  font-size: 1.1rem;
  color: var(--text-mid);
  font-style: italic;
  font-weight: 300;
}

/* ── CONTENT ── */
.content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 22px 64px;
}

/* ── ITEM CARDS ── */
.item-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 22px 20px 24px;
  margin-bottom: 14px;
  transition: border-color 0.25s, box-shadow 0.22s;
  position: relative;
  overflow: hidden;
}

.item-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.item-card:hover { border-color: var(--gold-dim); box-shadow: 0 0 18px rgba(200,137,42,0.12); }
.item-card:hover::after { opacity: 1; }

.item-title {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.35rem;
  letter-spacing: 0.03em;
}

.item-meta {
  font-size: 0.75rem;
  font-family: 'Cinzel', serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.55rem;
}

.item-desc {
  font-size: 1rem;
  color: var(--text-mid);
  line-height: 1.55;
  font-weight: 300;
  margin-bottom: 14px;
}

/* ── BUTTONS ── */
.btn {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 8px 18px;
  border-radius: 4px;
  border: 1px solid var(--gold-dim);
  color: var(--gold);
  background: transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
  margin-right: 8px;
  margin-top: 4px;
}

.btn:hover { background: var(--gold); color: #04060e; box-shadow: 0 0 14px var(--glow); }

.btn-primary {
  background: var(--gold-dim);
  color: var(--text);
  border-color: var(--gold);
}

.btn-primary:hover { background: var(--gold); color: #04060e; }

.btn-locked {
  border-color: #2a2a3a;
  color: #8a8598;
  cursor: not-allowed;
}

.btn-locked:hover { background: transparent; color: #8a8598; box-shadow: none; }

/* ── BADGE ── */
.badge {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  border-radius: 3px;
  padding: 2px 8px;
  margin-left: 8px;
  vertical-align: middle;
}

/* ── LOCK ICON ── */
.lock { color: var(--text-dim); font-size: 0.8rem; margin-right: 4px; }

/* ── COMING SOON BANNER ── */
.coming-soon {
  text-align: center;
  padding: 60px 24px;
  border: 1px dashed var(--border);
  border-radius: 12px;
  margin-bottom: 20px;
}

.coming-soon h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.2rem;
  color: var(--text-mid);
  margin-bottom: 0.5rem;
}

.coming-soon p { font-size: 1rem; color: var(--text-dim); font-style: italic; }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 22px;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-dim);
  letter-spacing: 0.06em;
}

footer span { color: var(--gold-dim); }

/* ── 5 MAIN BUTTONS (homepage) ── */
.hub-row {
  display: flex;
  gap: 8px;
  max-width: 900px;
  margin: 24px auto 0;
  padding: 0 12px;
}

.hub-btn {
  flex: 1 1 0;
  min-width: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 4px 12px;
  text-align: center;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.2s;
}

.hub-btn:hover, .hub-btn:active {
  border-color: var(--gold);
  box-shadow: 0 0 18px rgba(200,137,42,0.22);
  transform: translateY(-2px);
}

.hub-icon { display: block; font-size: 1.5rem; margin-bottom: 6px; }

.hub-label {
  display: block;
  font-family: 'Cinzel', serif;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.25;
}

@media (min-width: 600px) {
  .hub-btn { padding: 22px 8px 18px; }
  .hub-icon { font-size: 2rem; }
  .hub-label { font-size: 0.85rem; }
}

/* ── DRAWING PAGE ── */
.draw-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.draw-tools input[type=color] {
  width: 40px; height: 34px;
  border: 1px solid var(--gold-dim);
  border-radius: 4px;
  background: transparent;
  padding: 0;
}

.draw-tools input[type=range] { width: 110px; accent-color: var(--gold); }

.draw-tools .btn { margin: 0; }
.draw-tools .btn.active { background: var(--gold); color: #04060e; }

#canvas {
  width: 100%;
  height: 60vh;
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid var(--border);
  touch-action: none;
  display: block;
}

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ══ BRAND OVERRIDES — "STUDIOS" look for every button ══ */
.btn, .hub-label, .card-title, .nav-back, .nav-brand, .card-badge, .badge {
  font-family: var(--btn-font);
  text-transform: uppercase;
}
.btn {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: var(--studios);
  border-color: var(--studios-line);
}
.btn:hover { background: var(--studios); color: var(--bg); box-shadow: 0 0 14px rgba(168,154,126,0.25); }
.btn-primary { background: rgba(168,154,126,0.1); border-color: var(--studios); color: var(--studios-bright); }
.btn-primary:hover { background: var(--studios); color: var(--bg); }
.draw-tools .btn.active { background: var(--studios); color: var(--bg); }

.hub-label { font-size: 0.68rem; font-weight: 600; letter-spacing: 0.14em; color: var(--studios); }
@media (min-width: 600px) { .hub-label { font-size: 0.95rem; letter-spacing: 0.2em; } }
.hub-btn:hover, .hub-btn:active { border-color: var(--studios); box-shadow: 0 0 18px rgba(168,154,126,0.2); }

.card-title { font-size: 1.15rem; font-weight: 600; letter-spacing: 0.16em; color: var(--studios-bright); }
.card::after, .item-card::after { background: linear-gradient(to right, transparent, var(--studios), transparent); }
.card:hover { box-shadow: 0 0 22px rgba(168,154,126,0.15); }
.card.highlight { border-color: var(--studios-line); }

.card-badge, .badge { font-size: 0.7rem; font-weight: 600; letter-spacing: 0.18em; color: var(--studios); border-color: var(--studios-line); }
.card-badge.gold { background: rgba(168,154,126,0.18); color: var(--studios-bright); }

.nav-back { font-size: 0.85rem; font-weight: 600; letter-spacing: 0.16em; color: var(--studios); }
.nav-back:hover { color: var(--studios-bright); }
.nav-brand { font-size: 0.9rem; font-weight: 600; letter-spacing: 0.14em; color: #d5d7d8; }
.nav-brand span { color: var(--studios); }
.site-nav { background: rgba(5, 8, 15, 0.96); }

/* ── LOGO HERO (homepage) ── */
.logo-hero { text-align: center; padding: 20px 12px 0; }
.logo-hero img {
  width: 100%;
  max-width: 620px;
  height: auto;
  display: block;
  margin: 0 auto;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, #000 60%, transparent 100%);
          mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, #000 60%, transparent 100%);
  animation: fadeUp 0.9s ease both;
}
.logo-tagline {
  font-family: var(--btn-font);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--studios);
  margin-top: 4px;
}

/* ══ Easier to read: brighter gold, heavier letters (Oct 2026) ══ */
.btn, .hub-label, .card-title, .nav-back, .nav-brand, .card-badge, .badge, .item-meta { font-weight: 700; }
.btn { font-size: 0.92rem; }
.hub-label { font-size: 0.72rem; color: var(--studios-bright); }
@media (min-width: 600px) { .hub-label { font-size: 1rem; } }
.card-title { font-size: 1.22rem; }
.card-text, .item-desc { color: #c9bfae; }
.item-meta { font-size: 0.82rem; letter-spacing: 0.1em; }
.nav-back { font-size: 0.92rem; color: var(--studios-bright); }
.nav-brand span { color: var(--studios); }
.card-badge, .badge { font-size: 0.76rem; color: var(--studios-bright); }

/* ════════════════════════════════════════════════════════════
   DESKTOP-FIRST LAYOUT (Oct 2026)
   The whole site is designed for a computer screen first.
   ════════════════════════════════════════════════════════════ */
:root { --page-w: 1200px; --read-w: 760px; }
html { scroll-behavior: smooth; }
body { font-size: 17px; }

/* Top menu (built by nav.js) */
.site-nav { height: 68px; padding: 0 28px; gap: 20px; justify-content: flex-start; }
.nav-brand { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }
.nav-brand img { height: 52px; width: auto; display: block; -webkit-mask-image: radial-gradient(ellipse 50% 50% at 50% 50%, #000 55%, transparent 100%); mask-image: radial-gradient(ellipse 50% 50% at 50% 50%, #000 55%, transparent 100%); }
.nav-brand .nb-txt { font-size: 0.92rem; letter-spacing: 0.1em; white-space: nowrap; }
.nav-menu { flex: 1; display: flex; justify-content: center; gap: 4px; }
.nav-menu a { display: inline-flex; align-items: center; gap: 7px; padding: 9px 13px; border-radius: 8px; text-decoration: none;
  font: 700 0.95rem var(--btn-font); letter-spacing: 0.09em; text-transform: uppercase; color: var(--text-mid); transition: color 0.2s, background 0.2s; white-space: nowrap; }
.nav-menu a:hover { color: var(--studios-bright); background: rgba(205,187,146,0.08); }
.nav-menu a.on { color: var(--studios-bright); background: rgba(205,187,146,0.14); box-shadow: inset 0 -2px 0 var(--studios); }
.nav-menu .nm-i { font-size: 1.05rem; }
.nav-menu { justify-content: flex-end; }
/* the menu always fits: it tightens step by step as the window gets narrower */
@media (max-width: 1520px) { .nav-menu .nm-i { display: none; } }
@media (max-width: 1340px) { .nav-brand .nb-txt { display: none; } .site-nav { gap: 12px; padding: 0 20px; } }
@media (max-width: 1120px) { .nav-menu a { padding: 8px 9px; font-size: 0.86rem; letter-spacing: 0.05em; } .nav-acct { padding: 8px 12px; font-size: 0.86rem; letter-spacing: 0.05em; } }
.nav-tog { display: none; }
@media (max-width: 900px) {
  .nav-tog { display: inline-flex; margin-left: auto; padding: 8px 14px; border-radius: 8px; border: 1px solid var(--studios-line); background: transparent; color: var(--studios-bright);
    font: 700 0.9rem var(--btn-font); letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer; }
  .nav-menu { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 2px; padding: 10px 16px 14px;
    background: rgba(5, 8, 15, 0.98); border-bottom: 1px solid var(--border); z-index: 60; }
  .site-nav.open .nav-menu { display: flex; }
  .nav-menu a { padding: 12px 14px; font-size: 1rem; }
  .nav-menu .nm-i { display: inline; }
  .site-nav { position: relative; }
}
.crumb { margin: 0 0 14px; }
.crumb .crumb-link { font: 700 0.9rem var(--btn-font); letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-mid); text-decoration: none; }
.crumb .crumb-link:hover { color: var(--studios-bright); }
.reading .crumb { text-align: center; }

/* Page widths */
.page-header, .grid-wrap, .content, .divider, .hub-row { max-width: var(--page-w); }
.page-header { padding: 56px 36px 30px; }
.page-header h1 { font-size: 3rem; }
.page-header p { font-size: 1.25rem; max-width: 760px; }
.grid-wrap, .content { padding-left: 36px; padding-right: 36px; padding-bottom: 80px; }
.divider { padding: 0 36px; }

/* Card grids: three across, wide cards span the row */
.grid { grid-template-columns: repeat(3, 1fr); gap: 22px; }
.card { padding: 28px 26px 30px; border-radius: 14px; }
.card-icon { font-size: 2.1rem; margin-bottom: 14px; }
.card-text { font-size: 1.05rem; }
.cards2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; align-items: start; }
.cards2 > .item-card { margin-bottom: 0; }
.cards3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: start; }
.cards3 > .item-card { margin-bottom: 0; }
.item-card { padding: 28px 28px 30px; border-radius: 14px; }

/* Reading pages keep a comfortable book-width column, centered */
.reading .page-header, .reading .content, .reading .divider { max-width: var(--read-w); }
.reading .page-header { text-align: center; }
.reading .page-header p { margin: 0 auto; }
.reading .story { max-width: none; }
.reading .story p { font-size: 1.25rem; line-height: 1.7; }
.reading .story-end { max-width: none; }

/* Footer */
footer { padding: 34px 36px 40px; font-size: 0.9rem; color: var(--text-mid); }
footer span { color: var(--studios); }
.foot-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 22px; margin-top: 14px; }
.foot-links a { color: var(--text-mid); text-decoration: none; font-size: 0.95rem; }
.foot-links a:hover { color: var(--studios-bright); }
.foot-links .fl-sep { width: 1px; background: var(--border); }

/* Buttons a little larger for mouse use */
.btn { padding: 10px 22px; }
/* Cards fill the row evenly: 3 or 4 across depending on how many there are */
.grid { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.card.wide { grid-column: auto; }
/* Footer sits at the bottom of the window on short pages */
body.site { display: flex; flex-direction: column; min-height: 100vh; }
body.site > footer { margin-top: auto; }
body.site > * { width: 100%; }
.nav-acct { flex: 0 0 auto; padding: 9px 18px; border-radius: 8px; border: 1px solid var(--studios); background: var(--studios); color: #10121a;
  font: 700 0.95rem var(--btn-font); letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none; white-space: nowrap; margin-left: 6px; }
.nav-acct:hover { background: var(--studios-bright); }
.nav-acct.in { background: transparent; color: var(--studios-bright); text-transform: none; letter-spacing: 0.02em; max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
.nav-acct.in::before { content: '\25CF  '; color: #7cc3a2; font-size: 0.7rem; vertical-align: middle; }
.acct .btn, .auth .btn { margin-right: 0; }

/* "Coming soon" in place of buttons that don't work yet */
.btn-soon { opacity: 0.75; cursor: default; border-style: dashed; background: transparent !important; color: var(--text-mid) !important; }
.btn-soon:hover { box-shadow: none; transform: none; }
