.crown-page { --crown-gap: clamp(.85rem, 2vw, 1.35rem); }

.crown-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--ivory);
  background: radial-gradient(ellipse at 90% 10%, #2b5341, transparent 64%), var(--forest-deep);
}

.crown-hero::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  background: repeating-linear-gradient(128deg, transparent 0 54px, #f0ce8017 55px, transparent 56px 110px);
  mask-image: linear-gradient(90deg, transparent 30%, #000);
  content: "";
  pointer-events: none;
}

.crown-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.17fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding-block: clamp(3.1rem, 7vw, 6.4rem);
}

.crown-hero h1 {
  max-width: 14ch;
  font-size: clamp(3.15rem, 7vw, 6.2rem);
  line-height: .97;
  letter-spacing: -.06em;
  text-wrap: balance;
}

.crown-eyebrow, .crown-role, .crown-era {
  display: block;
  margin-bottom: .66rem;
  color: var(--gold-ink);
  font-size: .7rem;
  font-weight: 780;
  letter-spacing: .12em;
  line-height: 1.4;
  text-transform: uppercase;
}

.crown-hero .crown-eyebrow, .crown-hero .eyebrow { color: var(--gold-light); }
.crown-hero p:not(.crown-eyebrow, .eyebrow) { max-width: 35rem; margin-top: 1.15rem; color: #e0ebe0; }
.crown-hero figure { display: grid; gap: .65rem; min-width: 0; margin-inline: .3rem .65rem; }
.crown-hero figcaption { color: #f0ddb4; font-size: .75rem; line-height: 1.5; }
.crown-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.35rem; }

.crown-facts {
  padding-block: .8rem;
  border-bottom: 1px solid #d9d0ba;
  color: var(--forest-deep);
  background: #ede7d7;
  font-size: .85rem;
}

.crown-facts .wrap { display: flex; align-items: baseline; flex-wrap: wrap; gap: .3rem 1.3rem; }
.crown-section { padding-block: clamp(2.7rem, 5.8vw, 5.4rem); }
.crown-section + .crown-section { border-top: 1px solid var(--line); }
.crown-section .section-head { margin-bottom: clamp(1.25rem, 3vw, 2.1rem); }
.crown-section .section-head > p:not(.section-kicker, .crown-eyebrow) { max-width: 48rem; }

.crown-three, .crown-remaining, .crown-timeline, .crown-identity, .crown-branches, .crown-sources {
  display: grid;
  gap: var(--crown-gap);
}

:is(ol, ul):is(.crown-three, .crown-remaining, .crown-timeline, .crown-identity, .crown-branches) {
  margin: 0;
  padding: 0;
  list-style: none;
}

.crown-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.crown-remaining, .crown-identity, .crown-branches { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.crown-timeline { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.crown-section .crown-remaining { margin-top: var(--crown-gap); }

.crown-person, .crown-row, .crown-timeline > *, .crown-identity > *, .crown-branches > * {
  min-width: 0;
  padding: clamp(1.05rem, 2.5vw, 1.55rem);
  border: 1px solid var(--line);
  border-radius: .36rem;
  background: var(--paper);
}

.crown-person, .crown-row { display: grid; align-content: start; gap: .7rem; }
.crown-person h3, .crown-row h3 { font-size: clamp(1.5rem, 2.65vw, 2rem); }
.crown-person p, .crown-row p, .crown-timeline p, .crown-identity p, .crown-branches p { color: var(--muted); }
.crown-role { margin: 0; }
.crown-rank { color: var(--gold-ink); font: 500 clamp(2.4rem, 5.6vw, 4.4rem)/.95 var(--serif); letter-spacing: -.07em; }
.crown-row .crown-rank { font-size: clamp(1.7rem, 3.8vw, 2.55rem); }
.crown-person-lead { border-color: #355343; color: var(--ivory); background: linear-gradient(145deg, #214339, var(--forest-deep)); }
.crown-person-lead .crown-rank, .crown-person-lead .crown-role { color: var(--gold-light); }
.crown-person-lead p { color: #e0ebe0; }
.crown-person a, .crown-row a { justify-self: start; font-size: .83rem; font-weight: 680; }

.crown-source-note, .crown-callout {
  margin-top: var(--crown-gap);
  padding: 1rem clamp(.95rem, 2.4vw, 1.4rem);
  border-left: 3px solid var(--gold);
  color: var(--muted);
  background: #eee8d8;
  font-size: .9rem;
}

.crown-callout h3 { margin-bottom: .35rem; color: var(--forest); }
.crown-source-note a, .crown-callout a, .crown-sources a { color: var(--forest); font-weight: 680; }
.crown-timeline > article {
  display: grid;
  grid-template-rows: subgrid;
  grid-row: span 2;
  gap: 0;
  padding: 0;
  overflow: hidden;
  border-top: 3px solid #c6a45f;
}

.crown-timeline-figure {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  background: #eee8d8;
}

.crown-timeline-image {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  background: #d1c4a7;
}

.crown-timeline-image.periodo-regencial { object-position: center 13%; }
.crown-timeline-image.princesa-isabel { object-position: center 8%; }

.crown-timeline-figure figcaption {
  display: grid;
  align-content: start;
  gap: .15rem;
  padding: .65rem clamp(.8rem, 1.6vw, 1.15rem);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.42;
}

.crown-timeline-figure a { color: var(--forest); font-weight: 700; }
.crown-timeline-copy { padding: clamp(1rem, 2vw, 1.35rem); }
.crown-timeline-copy .crown-era { margin-top: 0; }
.crown-timeline p, .crown-identity p, .crown-branches p { margin-top: .55rem; font-size: .93rem; }
.crown-identity > :first-child { border-color: #b6c7b8; background: #e8eee2; }
.crown-sources { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-left: 1.25rem; }
.crown-sources > * { overflow-wrap: anywhere; }
.crown-hero :focus-visible, .crown-person-lead :focus-visible { outline-color: var(--gold-light); }

@media (max-width: 58rem) {
  .crown-timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 46rem) {
  .crown-hero-grid, .crown-three, .crown-remaining, .crown-timeline, .crown-identity, .crown-branches, .crown-sources { grid-template-columns: minmax(0, 1fr); }
  .crown-hero figure { max-width: 31rem; }
}

.crown-person {
  grid-template-rows: auto 1fr;
  align-content: stretch;
  gap: 0;
  overflow: hidden;
  padding: 0;
}

.crown-person-copy {
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  gap: .65rem;
  padding: clamp(1.05rem, 2.5vw, 1.55rem);
}

.crown-portrait {
  overflow: hidden;
  background: #e3e0d8;
}

.crown-portrait img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 25%;
}

.crown-portrait figcaption {
  padding: .38rem .75rem;
  color: var(--muted);
  background: #eee8d8;
  font-size: .69rem;
  line-height: 1.4;
}

.crown-person-lead .crown-portrait figcaption {
  color: #f0e2b9;
  background: #214339;
}

.crown-row {
  grid-template-columns: minmax(6.75rem, 27%) minmax(0, 1fr);
  align-items: center;
  gap: clamp(.8rem, 2.4vw, 1.35rem);
}

.crown-row .crown-portrait { border-radius: .25rem; }
.crown-row .crown-portrait img { aspect-ratio: 4 / 5; }
.crown-row-copy { display: grid; align-content: start; gap: .42rem; }

@media (max-width: 26rem) {
  .crown-row .crown-portrait figcaption { padding-inline: .4rem; }
  .crown-row h3 { overflow-wrap: anywhere; }
}

