/*
  Eclipse top-of-page override module.
  Link after site-pages.css to replace the dashboard-like opener with a
  slim guild nav, cinematic banner hero, and compact first content row.
*/

body.eclipse-page {
  --eclipse-banner-ink: #fff4d4;
  --eclipse-banner-muted: #d3c19b;
  --eclipse-banner-dim: #8f8062;
  --eclipse-banner-gold: #d8a93d;
  --eclipse-banner-green: #38d06f;
  --eclipse-banner-red: #8f2f24;
  --eclipse-banner-line: rgba(244, 213, 130, 0.16);
  --eclipse-banner-line-hot: rgba(244, 213, 130, 0.38);
  --eclipse-banner-black: #050505;
  background:
    radial-gradient(circle at 50% -18%, rgba(74, 100, 104, 0.22), transparent 36%),
    linear-gradient(180deg, #050505 0, #080807 42%, #050505 100%);
}

body.eclipse-page .eclipse-modern {
  width: min(1520px, calc(100% - 32px));
  padding: 10px 0 64px;
}

body.eclipse-page .guild-topbar {
  position: sticky;
  top: 8px;
  z-index: 30;
  min-height: 44px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  border: 1px solid rgba(255, 226, 154, 0.14);
  border-radius: 0;
  padding: 5px 8px;
  background:
    linear-gradient(180deg, rgba(21, 22, 22, 0.94), rgba(4, 5, 5, 0.96)),
    rgba(5, 5, 5, 0.94);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.52);
  backdrop-filter: blur(18px);
}

body.eclipse-page .guild-logo {
  min-width: 164px;
  gap: 8px;
}

body.eclipse-page .guild-logo img {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(216, 169, 61, 0.45);
  border-radius: 2px;
  box-shadow: 0 0 18px rgba(216, 169, 61, 0.16);
}

body.eclipse-page .guild-logo strong {
  color: var(--eclipse-banner-ink);
  font-family: "LifeCraft", Georgia, "Times New Roman", serif;
  font-size: 1.55rem;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1;
  text-transform: uppercase;
}

body.eclipse-page .guild-logo em {
  color: var(--eclipse-banner-dim);
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  line-height: 1.05;
}

body.eclipse-page .guild-topbar nav {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: 1px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

body.eclipse-page .guild-topbar nav::-webkit-scrollbar {
  display: none;
}

body.eclipse-page .guild-topbar nav a {
  flex: 0 0 auto;
  min-height: 32px;
  border: 1px solid transparent;
  border-radius: 0;
  padding: 0 10px;
  color: rgba(226, 213, 178, 0.78);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

body.eclipse-page .guild-topbar nav a:hover,
body.eclipse-page .guild-topbar nav a:focus-visible {
  color: var(--eclipse-banner-ink);
  border-color: rgba(216, 169, 61, 0.34);
  background: rgba(216, 169, 61, 0.13);
  outline: none;
}

body.eclipse-page .guild-hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: 1fr;
  align-items: end;
  min-height: clamp(410px, 39vw, 560px);
  margin-top: 10px;
  border: 1px solid var(--eclipse-banner-line);
  border-radius: 0;
  padding: 0;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(4, 5, 5, 0.88) 0%, rgba(4, 5, 5, 0.22) 34%, rgba(4, 5, 5, 0.24) 68%, rgba(4, 5, 5, 0.9) 100%),
    linear-gradient(180deg, rgba(4, 5, 5, 0.08) 0%, rgba(4, 5, 5, 0.05) 42%, rgba(4, 5, 5, 0.96) 100%),
    url("/assets/eclipse/eclipse-cinematic-banner.png") center 48% / cover no-repeat,
    #070707;
  box-shadow: 0 28px 92px rgba(0, 0, 0, 0.62);
}

body.eclipse-page .guild-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 48% 28%, rgba(255, 223, 144, 0.12), transparent 24%),
    radial-gradient(circle at 50% 120%, rgba(216, 169, 61, 0.18), transparent 34%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.78), transparent 18%, transparent 82%, rgba(0, 0, 0, 0.82));
  pointer-events: none;
}

body.eclipse-page .guild-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 34%;
  z-index: 1;
  background:
    linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72) 56%, rgba(0, 0, 0, 0.95)),
    linear-gradient(90deg, transparent, rgba(216, 169, 61, 0.16), transparent);
  pointer-events: none;
}

body.eclipse-page .hero-character-strip {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: none;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0;
  opacity: 0.28;
  mix-blend-mode: screen;
  pointer-events: none;
}

body.eclipse-page .hero-character-strip i {
  min-height: 100%;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, transparent 0 46%, rgba(216, 169, 61, 0.1) 100%),
    url("/assets/eclipse/eclipse-roster-forge.png") center bottom / cover no-repeat;
  filter: saturate(1.16) contrast(1.08);
  transform: skewX(-4deg) scaleX(1.08);
}

body.eclipse-page .hero-character-strip i:nth-child(1) { background-position: 0% bottom; }
body.eclipse-page .hero-character-strip i:nth-child(2) { background-position: 20% bottom; }
body.eclipse-page .hero-character-strip i:nth-child(3) { background-position: 40% bottom; }
body.eclipse-page .hero-character-strip i:nth-child(4) { background-position: 60% bottom; }
body.eclipse-page .hero-character-strip i:nth-child(5) { background-position: 80% bottom; }
body.eclipse-page .hero-character-strip i:nth-child(6) { background-position: 100% bottom; }

body.eclipse-page .guild-hero-copy {
  position: relative;
  z-index: 2;
  justify-self: stretch;
  align-self: end;
  width: 100%;
  max-width: none;
  display: grid;
  justify-items: center;
  gap: 0;
  padding: clamp(58px, 7vw, 96px) clamp(18px, 4vw, 64px) clamp(30px, 4vw, 54px);
  text-align: center;
}

body.eclipse-page .guild-hero h1 {
  max-width: min(860px, 94vw);
  margin: 0;
  color: var(--eclipse-banner-ink);
  font-family: "LifeCraft", Georgia, "Times New Roman", serif !important;
  font-size: clamp(2.7rem, 4.45vw, 4.7rem);
  font-weight: 400;
  line-height: 0.86;
  letter-spacing: 0;
  text-transform: uppercase;
  text-wrap: balance;
  text-shadow:
    0 3px 0 rgba(0, 0, 0, 0.66),
    0 18px 44px rgba(0, 0, 0, 0.92);
}

body.eclipse-page .guild-hero-copy p {
  max-width: 720px;
  margin: 16px auto 0;
  color: rgba(230, 217, 181, 0.9);
  font-size: clamp(0.98rem, 1.35vw, 1.2rem);
  font-weight: 650;
  line-height: 1.45;
  text-shadow: 0 3px 16px rgba(0, 0, 0, 0.92);
}

body.eclipse-page .guild-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
}

body.eclipse-page .guild-actions a {
  min-width: 138px;
  min-height: 42px;
  border: 1px solid rgba(255, 229, 154, 0.28);
  border-radius: 0;
  padding: 0 18px;
  color: var(--eclipse-banner-ink);
  background:
    linear-gradient(180deg, rgba(35, 36, 35, 0.92), rgba(9, 10, 10, 0.95));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 15px 34px rgba(0, 0, 0, 0.42);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

body.eclipse-page .guild-actions a:first-child {
  color: #090704;
  border-color: rgba(255, 222, 132, 0.7);
  background:
    linear-gradient(180deg, #f0ca61 0%, #d19a2b 48%, #935f16 100%);
  text-shadow: 0 1px 0 rgba(255, 240, 182, 0.34);
}

body.eclipse-page .guild-actions a:hover,
body.eclipse-page .guild-actions a:focus-visible {
  transform: translateY(-1px);
  border-color: var(--eclipse-banner-line-hot);
  filter: brightness(1.08);
  outline: none;
}

body.eclipse-page .hero-ledger {
  display: none;
}

body.eclipse-page .guild-dashboard {
  display: grid;
  grid-template-columns: minmax(360px, 1.1fr) minmax(260px, 0.78fr) minmax(270px, 0.82fr);
  align-items: start;
  gap: 10px;
  margin-top: 10px;
}

body.eclipse-page .guild-dashboard .guild-card {
  min-height: 0;
  border: 1px solid var(--eclipse-banner-line);
  border-radius: 0;
  padding: 14px;
  background:
    linear-gradient(180deg, rgba(23, 24, 23, 0.86), rgba(8, 9, 9, 0.94));
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.34);
}

body.eclipse-page .guild-dashboard .card-head {
  margin-bottom: 8px;
}

body.eclipse-page .guild-dashboard .card-head span {
  color: var(--eclipse-banner-green);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
}

body.eclipse-page .guild-dashboard .card-head strong {
  color: var(--eclipse-banner-ink);
  font-family: Inter, "Segoe UI", sans-serif;
  font-size: 1rem;
  font-weight: 950;
}

body.eclipse-page .guild-dashboard .member-list,
body.eclipse-page .guild-dashboard #eclipse-honor-roll {
  gap: 6px;
}

body.eclipse-page .guild-dashboard .member-row,
body.eclipse-page .guild-dashboard .death-row {
  min-height: 50px;
  border-radius: 0;
  padding: 8px 9px;
  background: rgba(255, 255, 255, 0.035);
}

body.eclipse-page .guild-dashboard .progression-card p {
  margin-top: 8px;
  font-size: 0.86rem;
  line-height: 1.38;
}

body.eclipse-page .realm-intel-section,
body.eclipse-page .news-card {
  margin-top: 10px;
}

@media (max-width: 1180px) {
  body.eclipse-page .guild-topbar {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  body.eclipse-page .guild-topbar nav {
    justify-content: flex-start;
  }

  body.eclipse-page .guild-dashboard {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.eclipse-page .guild-dashboard .death-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  body.eclipse-page .eclipse-modern {
    width: min(100% - 14px, 1520px);
    padding-top: 7px;
  }

  body.eclipse-page .guild-topbar {
    position: relative;
    top: 0;
  }

  body.eclipse-page .guild-logo {
    min-width: 0;
  }

  body.eclipse-page .guild-topbar nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible;
  }

  body.eclipse-page .guild-topbar nav a {
    justify-content: center;
    min-height: 34px;
    border-color: rgba(244, 213, 130, 0.12);
    background: rgba(255, 255, 255, 0.035);
    font-size: 0.68rem;
  }

  body.eclipse-page .guild-hero {
    min-height: 420px;
    background-position: center top;
  }

  body.eclipse-page .hero-character-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    opacity: 0.2;
  }

  body.eclipse-page .hero-character-strip i:nth-child(n+4) {
    display: none;
  }

  body.eclipse-page .guild-hero-copy {
    padding: 76px 16px 34px;
  }

  body.eclipse-page .guild-hero h1 {
    font-size: clamp(2.55rem, 11vw, 3.55rem);
  }

  body.eclipse-page .guild-hero-copy p {
    font-size: 0.96rem;
  }

  body.eclipse-page .guild-actions {
    width: 100%;
  }

  body.eclipse-page .guild-actions a {
    flex: 1 1 150px;
  }

  body.eclipse-page .guild-dashboard {
    grid-template-columns: 1fr;
  }
}
