:root {
  --character-panel-bg: rgba(19, 15, 10, 0.62);
  --character-panel-border: rgba(255, 255, 255, 0.12);
  --character-card-bg: rgba(255, 255, 255, 0.06);
  --character-card-hover: rgba(255, 255, 255, 0.1);
  --character-rule: rgba(255, 255, 255, 0.1);
}

.character-page {
  background: radial-gradient(circle at 15% 15%, rgba(255, 255, 255, 0.08), transparent 45%), linear-gradient(180deg, rgba(8, 7, 6, 0.9), rgba(16, 12, 8, 0.96));
  color: var(--light-brown);
}
.character-page .character-page__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 1rem;
  border-bottom: 1px solid var(--character-rule);
  background: rgba(6, 5, 4, 0.92);
}
.character-page .character-page__home {
  flex-shrink: 0;
  color: var(--lighter-green);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 0.4rem 0.95rem;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.character-page .character-page__home:hover {
  color: var(--dark-brown);
  background: var(--light-green);
  border-color: var(--light-green);
}
.character-page .character-page__top .banner-nav {
  position: relative;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.character-page .character-hero {
  position: relative;
  isolation: isolate;
  min-height: clamp(200px, 28vw, 320px);
  overflow: hidden;
  border-bottom: 1px solid var(--character-rule);
}
.character-page .character-hero__bg {
  position: absolute;
  inset: -12px;
  background-image: var(--character-hero-image);
  background-size: cover;
  background-position: center 25%;
  filter: saturate(1.05) brightness(0.55);
  transform: scale(1.06);
}
.character-page .character-hero__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(8, 6, 4, 0.94) 0%, rgba(8, 6, 4, 0.78) 38%, rgba(8, 6, 4, 0.4) 100%);
}
.character-page .character-hero__inner {
  position: relative;
  z-index: 1;
  width: min(1200px, 100% - 2rem);
  margin: 0 auto;
  padding: 1.75rem 0 2rem;
  max-width: 42rem;
}
.character-page .character-hero__eyebrow {
  margin: 0 0 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: var(--light-green);
  opacity: 0.95;
}
.character-page .character-hero__title {
  margin: 0;
  font-size: clamp(1.75rem, 4vw, 2.65rem);
  line-height: 1.08;
  color: var(--theme-color);
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.55);
}
.character-page .character-hero__species {
  margin: 0.35rem 0 0.75rem;
  font-size: 0.98rem;
  color: #f2ebd8;
  opacity: 0.92;
}
.character-page .character-hero__blurb {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.55;
  color: #ede4d3;
  opacity: 0.95;
}
.character-page .character-hero__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  width: fit-content;
}
.character-page .character-hero__links a {
  color: var(--lighter-green);
  text-decoration: none;
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
  text-transform: lowercase;
  border-right: 1px solid rgba(255, 255, 255, 0.22);
  transition: background-color 0.2s ease, color 0.2s ease;
}
.character-page .character-hero__links a:last-child {
  border-right: 0;
}
.character-page .character-hero__links a:hover {
  color: var(--dark-brown);
  background: var(--light-green);
}
.character-page .character-profile {
  width: min(1200px, 100% - 2rem);
  margin: 2rem auto 3rem;
}
.character-page .profile-shell {
  border: 1px solid var(--character-panel-border);
  background: var(--character-panel-bg);
  backdrop-filter: blur(2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}
.character-page .profile-layout {
  display: grid;
  grid-template-columns: minmax(200px, 260px) minmax(0, 1fr);
  gap: 0;
  align-items: stretch;
  min-height: 0;
}
.character-page .profile-aside {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--character-rule);
  background: rgba(0, 0, 0, 0.18);
}
.character-page .profile-image-container {
  position: relative;
  flex: 0 0 auto;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  border: 0;
  border-bottom: 1px solid var(--character-rule);
  background: rgba(0, 0, 0, 0.35);
}
.character-page .profile-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.25s ease;
}
.character-page .profile-image-container:hover .profile-image {
  opacity: 0.92;
}
.character-page .profile-stats {
  margin: 0;
  padding: 0;
  flex: 1 1 auto;
}
.character-page .profile-stats__row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 0.5rem 0.75rem;
  padding: 0.65rem 1rem;
  border-bottom: 1px solid var(--character-rule);
  align-items: baseline;
}
.character-page .profile-stats__row:last-child {
  border-bottom: 0;
}
.character-page .profile-stats__label {
  display: block;
  margin: 0;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--light-green);
}
.character-page .profile-stats__value {
  display: block;
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff9eb;
  line-height: 1.35;
}
.character-page .profile-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.character-page .motto {
  padding: 1.25rem 1.35rem;
  border-bottom: 1px solid var(--character-rule);
  background: rgba(0, 0, 0, 0.12);
}
.character-page .motto blockquote {
  margin: 0;
  padding: 0 0 0 1rem;
  border-left: 3px solid color-mix(in srgb, var(--theme-color) 70%, transparent);
  color: #f9f5e7;
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.5;
  opacity: 0.96;
}
.character-page .profile-content {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  flex: 1 1 auto;
}
.character-page .section {
  margin: 0;
  padding: 1.1rem 1.2rem 1.15rem;
  background: var(--character-card-bg);
  border-right: 1px solid var(--character-rule);
  border-bottom: 1px solid var(--character-rule);
  transition: background-color 0.2s ease;
}
.character-page .section:nth-child(2n) {
  border-right: 0;
}
.character-page .section:last-child:nth-child(odd) {
  grid-column: 1/-1;
  border-right: 0;
}
.character-page .section:hover {
  background: var(--character-card-hover);
}
.character-page .section h2 {
  margin: 0 0 0.65rem;
  padding-bottom: 0.45rem;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--theme-color);
  border-bottom: 1px solid var(--character-rule);
}
.character-page .section ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.character-page .section li {
  padding: 0.45rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: #f2ebd8;
  line-height: 1.45;
  font-size: 0.92rem;
}
.character-page .section li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.character-page .section li strong {
  color: var(--lighter-green);
}
.character-page .footer {
  margin-top: 0;
}

@media (max-width: 900px) {
  .character-page .profile-layout {
    grid-template-columns: 1fr;
  }
  .character-page .profile-aside {
    border-right: 0;
    border-bottom: 1px solid var(--character-rule);
  }
  .character-page .profile-image-container {
    max-width: 280px;
    margin: 0 auto;
    border-bottom: 1px solid var(--character-rule);
  }
  .character-page .profile-content {
    grid-template-columns: 1fr;
  }
  .character-page .section {
    border-right: 0;
  }
  .character-page .section:last-child:nth-child(odd) {
    grid-column: auto;
  }
}
@media (max-width: 640px) {
  .character-page .character-profile {
    width: calc(100% - 1rem);
    margin: 1rem auto 2rem;
  }
  .character-page .character-hero__inner {
    padding: 1.25rem 0 1.5rem;
  }
  .character-page .motto {
    padding: 1rem 1rem;
  }
}
