/* Editorial taxonomy archives backed by Drupal Views. */
.gf-taxonomy-editorial {
  --gf-taxonomy-navy: #0b1f3b;
  --gf-taxonomy-blue: #1e3464;
  --gf-taxonomy-gold: #d4af37;
  --gf-taxonomy-action: #ffc96a;
  --gf-taxonomy-paper: #f3efe6;
  --gf-taxonomy-paper-deep: #e9e2d5;
  --gf-taxonomy-muted: #5c6877;
  --gf-taxonomy-line: rgba(11, 31, 59, .18);
  padding-bottom: clamp(3.5rem, 7vw, 6.5rem);
  background: linear-gradient(180deg, #fff 0, #fff 24rem, #f7f4ed 24rem, #f7f4ed 100%);
  color: var(--gf-taxonomy-navy);
}

.gf-taxonomy-editorial,
.gf-taxonomy-editorial * { box-sizing: border-box; }
.path-taxonomy .gf-page-top { display: none; }

.gf-taxonomy-editorial__header {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--gf-taxonomy-line);
  background:
    linear-gradient(90deg, var(--gf-taxonomy-navy) 0 33.333%, #fff 33.333% 66.666%, #ce1126 66.666%) bottom / 100% 3px no-repeat,
    linear-gradient(135deg, #f8f6f1, #fff 58%);
}

.gf-taxonomy-editorial__header::after {
  position: absolute;
  right: clamp(-5rem, -4vw, -2rem);
  bottom: -7rem;
  width: 18rem;
  height: 18rem;
  border: 1px solid rgba(212, 175, 55, .23);
  border-radius: 50%;
  box-shadow: 0 0 0 2.5rem rgba(212, 175, 55, .055), 0 0 0 5rem rgba(11, 31, 59, .025);
  content: '';
  pointer-events: none;
}

.gf-taxonomy-editorial__header-inner,
.gf-taxonomy-editorial__content,
.gf-taxonomy-editorial__empty,
.gf-taxonomy-editorial > .pager,
.gf-taxonomy-editorial__feeds,
.gf-taxonomy-editorial__exposed {
  width: min(1180px, calc(100% - clamp(2rem, 6vw, 6rem)));
  margin-inline: auto;
}

.gf-taxonomy-editorial__header-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .55rem 2rem;
  align-items: end;
  padding-block: clamp(2.4rem, 5vw, 4.75rem) clamp(2rem, 4vw, 3.8rem);
}

.gf-taxonomy-editorial__eyebrow {
  grid-column: 1 / -1;
  margin: 0;
  color: #85601f;
  font-size: .75rem;
  font-weight: 850;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.gf-taxonomy-editorial__header h1 {
  max-width: 22ch;
  margin: 0;
  color: var(--gf-taxonomy-navy);
  font-family: var(--gf-font-heading, "Montserrat", sans-serif);
  font-size: clamp(2rem, 4.6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: .98;
  overflow-wrap: break-word;
}

.gf-taxonomy-editorial__description {
  grid-column: 1;
  max-width: 64ch;
  margin-top: .55rem;
  color: var(--gf-taxonomy-muted);
  font-size: clamp(.98rem, 1.4vw, 1.12rem);
  line-height: 1.65;
}

.gf-taxonomy-editorial__description > * { margin-block: 0 .5rem; }

.gf-taxonomy-editorial__count {
  grid-column: 2;
  grid-row: 2 / span 2;
  align-self: center;
  min-width: 8rem;
  margin: 0;
  border-left: 2px solid var(--gf-taxonomy-gold);
  color: var(--gf-taxonomy-muted);
  padding-left: 1rem;
  font-size: .78rem;
  font-weight: 750;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.gf-taxonomy-editorial__count strong {
  display: block;
  color: var(--gf-taxonomy-navy);
  font-size: 1.85rem;
  letter-spacing: -.03em;
  line-height: 1;
}

.gf-taxonomy-editorial__content { padding-top: clamp(2rem, 4vw, 3.75rem); }

.gf-taxonomy-editorial__grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.6rem);
}

.gf-taxonomy-editorial__grid > .views-row {
  display: flex;
  min-width: 0;
  grid-column: span 4;
  margin: 0;
}

.gf-taxonomy-editorial__grid .gf-teaser-card {
  position: relative;
  display: flex;
  width: 100%;
  max-width: none;
  min-width: 0;
  height: 100%;
  flex-direction: column;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--gf-taxonomy-line);
  border-top: 3px solid var(--gf-taxonomy-gold);
  border-radius: .25rem;
  background: linear-gradient(160deg, #f6f2e9, var(--gf-taxonomy-paper));
  box-shadow: 0 .45rem 1.25rem rgba(11, 31, 59, .07);
  transition: border-color .19s ease, background-color .19s ease, box-shadow .19s ease;
}

.gf-taxonomy-editorial__grid .gf-teaser-card:hover,
.gf-taxonomy-editorial__grid .gf-teaser-card:focus-within {
  border-color: rgba(30, 52, 100, .55);
  border-top-color: var(--gf-taxonomy-action);
  background: var(--gf-taxonomy-paper-deep);
  box-shadow: 0 .6rem 1.6rem rgba(11, 31, 59, .1);
}

.gf-taxonomy-editorial__grid .gf-teaser-media {
  position: relative;
  width: 100%;
  max-width: none;
  min-width: 0;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 0;
  background: var(--gf-taxonomy-blue);
}

.gf-taxonomy-editorial__grid .gf-teaser-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .2s ease;
}

.gf-taxonomy-editorial__grid .gf-teaser-card:hover .gf-teaser-media img,
.gf-taxonomy-editorial__grid .gf-teaser-card:focus-within .gf-teaser-media img { transform: scale(1.028); }

.gf-taxonomy-editorial__grid .gf-teaser-media--placeholder img {
  opacity: .22;
  filter: grayscale(1) contrast(1.08);
}

.gf-taxonomy-editorial__grid .gf-teaser-media--placeholder::after {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, .86);
  content: 'FMG';
  font-family: var(--gf-font-heading, "Montserrat", sans-serif);
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 300;
  letter-spacing: .2em;
}

.gf-taxonomy-editorial__grid .gf-teaser-content {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  justify-content: flex-start;
  padding: clamp(1.05rem, 2vw, 1.45rem);
}

.gf-taxonomy-editorial__grid .gf-teaser-header-row {
  align-items: center;
  gap: .55rem 1rem;
}

.gf-taxonomy-editorial__grid .gf-teaser-category,
.gf-taxonomy-editorial__grid .gf-teaser-date {
  color: #765716;
  font-size: .69rem;
  font-weight: 850;
  letter-spacing: .08em;
  line-height: 1.35;
  text-transform: uppercase;
}

.gf-taxonomy-editorial__grid .gf-teaser-date {
  margin-left: auto;
  color: var(--gf-taxonomy-muted);
  letter-spacing: .035em;
}

.gf-taxonomy-editorial__grid .gf-teaser-title {
  margin: .7rem 0 0;
  color: var(--gf-taxonomy-navy);
  font-family: var(--gf-font-heading, "Montserrat", sans-serif);
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
  line-height: 1.22;
  overflow-wrap: anywhere;
  transition: color .19s ease;
}

.gf-taxonomy-editorial__grid .gf-teaser-summary {
  display: -webkit-box;
  overflow: hidden;
  margin: .65rem 0 0;
  color: var(--gf-taxonomy-muted);
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.gf-taxonomy-editorial__grid .gf-teaser-footer {
  margin-top: auto;
  padding-top: .9rem;
}

.gf-taxonomy-editorial__grid .gf-teaser-cta {
  min-height: 44px;
  color: var(--gf-taxonomy-navy);
  font-size: .82rem;
}

.gf-taxonomy-editorial__grid .gf-teaser-cta svg { transition: transform .19s ease; }
.gf-taxonomy-editorial__grid .gf-teaser-card:hover .gf-teaser-cta svg,
.gf-taxonomy-editorial__grid .gf-teaser-card:focus-within .gf-teaser-cta svg { transform: translateX(5px); }

/* Lead treatment is data-gated in preprocess; small archives remain uniform. */
.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child { grid-column: span 8; }

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-card {
  display: grid;
  grid-template-columns: minmax(0, 58%) minmax(0, 42%);
  border-top-color: var(--gf-taxonomy-action);
  background: var(--gf-taxonomy-navy);
}

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-media {
  height: 100%;
  min-height: 27rem;
  aspect-ratio: auto;
}

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-content {
  justify-content: center;
  padding: clamp(1.4rem, 3vw, 2.4rem);
}

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-title {
  color: #fff;
  font-size: clamp(1.45rem, 2.35vw, 2.25rem);
  line-height: 1.08;
}

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-category,
.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-cta { color: var(--gf-taxonomy-action); }

.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-date,
.gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-summary { color: rgba(255, 255, 255, .74); }

.gf-taxonomy-editorial__empty {
  display: grid;
  justify-items: center;
  gap: .65rem;
  margin-top: clamp(2rem, 5vw, 4.5rem);
  border: 1px solid var(--gf-taxonomy-line);
  border-top: 3px solid var(--gf-taxonomy-gold);
  background: var(--gf-taxonomy-paper);
  padding: clamp(2.25rem, 6vw, 5.5rem) 1.5rem;
  text-align: center;
}

.gf-taxonomy-editorial__empty-mark {
  display: grid;
  width: 4.5rem;
  height: 4.5rem;
  place-items: center;
  border: 1px solid var(--gf-taxonomy-gold);
  border-radius: 50%;
  color: var(--gf-taxonomy-navy);
  font-weight: 850;
  letter-spacing: .08em;
}

.gf-taxonomy-editorial__empty h2,
.gf-taxonomy-editorial__empty p { max-width: 42rem; margin: 0; }

.gf-taxonomy-editorial__empty a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: .5rem;
  margin-top: .6rem;
  border-bottom: 2px solid var(--gf-taxonomy-gold);
  color: var(--gf-taxonomy-navy);
  font-weight: 800;
  text-decoration: none;
}

.gf-taxonomy-editorial__feeds { margin-top: 1rem; text-align: right; }

/* The taxonomy View uses Drupal's mini pager; behavior/query state is intact. */
.gf-taxonomy-editorial > .gf-taxonomy-pager { margin-top: clamp(1.75rem, 4vw, 3rem); }

.gf-taxonomy-pager .pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .45rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.gf-taxonomy-pager .page-link {
  display: inline-flex;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  border: 1px solid rgba(11, 31, 59, .25);
  border-radius: .22rem;
  background: #f6f2e9;
  color: var(--gf-taxonomy-navy);
  padding: .5rem .8rem;
  font-family: var(--gf-font-heading, "Montserrat", sans-serif);
  font-size: .78rem;
  font-weight: 800;
  text-decoration: none;
  transition: border-color .18s ease, background-color .18s ease, color .18s ease, transform .18s ease;
}

.gf-taxonomy-pager a.page-link:hover,
.gf-taxonomy-pager a.page-link:focus-visible {
  border-color: var(--gf-taxonomy-gold);
  background: #fff7df;
  color: var(--gf-taxonomy-navy);
  transform: translateY(-1px);
}

.gf-taxonomy-pager .is-active .page-link {
  border-color: var(--gf-taxonomy-navy);
  background: var(--gf-taxonomy-navy);
  color: #fff;
}

.gf-taxonomy-editorial :focus-visible {
  outline: 3px solid var(--gf-taxonomy-action);
  outline-offset: 3px;
}

@media (max-width: 1100px) {
  .gf-taxonomy-editorial__grid > .views-row { grid-column: span 6; }
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .gf-taxonomy-editorial { background: #f7f4ed; }
  .gf-taxonomy-editorial__header-inner { grid-template-columns: 1fr; }
  .gf-taxonomy-editorial__count { grid-column: 1; grid-row: auto; margin-top: .65rem; }
  .gf-taxonomy-editorial__grid > .views-row,
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child { grid-column: 1 / -1; }
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-card { display: flex; }
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-media { min-height: 0; aspect-ratio: 16 / 10; }
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-title { font-size: clamp(1.25rem, 6.3vw, 1.65rem); }
  .gf-taxonomy-editorial__grid .gf-teaser-summary { -webkit-line-clamp: 2; }
}

@media (max-width: 430px) {
  .gf-taxonomy-editorial__header-inner,
  .gf-taxonomy-editorial__content,
  .gf-taxonomy-editorial__empty,
  .gf-taxonomy-editorial > .pager,
  .gf-taxonomy-editorial__feeds,
  .gf-taxonomy-editorial__exposed { width: calc(100% - 1.5rem); }
  .gf-taxonomy-editorial__header-inner { padding-block: 2rem 1.65rem; }
  .gf-taxonomy-editorial__content { padding-top: 1.25rem; }
  .gf-taxonomy-editorial__grid { gap: .9rem; }
  .gf-taxonomy-editorial__grid .gf-teaser-content,
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-content { padding: 1rem; }
  .gf-taxonomy-editorial__grid .gf-teaser-media,
  .gf-taxonomy-editorial--featured .gf-taxonomy-editorial__grid > .views-row:first-child .gf-teaser-media { min-height: 11rem; aspect-ratio: 16 / 10; }
  .gf-taxonomy-editorial__grid .gf-teaser-title { font-size: 1.08rem; }
  .gf-taxonomy-editorial__grid .gf-teaser-summary { font-size: .88rem; }
  .gf-taxonomy-pager__direction { display: none; }
  .gf-taxonomy-pager .page-link { padding-inline: .65rem; }
}

@media (prefers-reduced-motion: reduce) {
  .gf-taxonomy-editorial__grid .gf-teaser-card,
  .gf-taxonomy-editorial__grid .gf-teaser-media img,
  .gf-taxonomy-editorial__grid .gf-teaser-title,
  .gf-taxonomy-editorial__grid .gf-teaser-cta svg,
  .gf-taxonomy-pager .page-link { transition: none; }
}
