/*
 * The public pages this service serves, in the EOQ house style.
 *
 * The chrome — the page ground, the masthead, the card, the footer — is shared
 * by every page, so it lives here and in `layout.ejs` rather than inside any
 * one view. The `.eoq-page` wrapper was written as `.eoq-unsubscribe`; it is
 * the ground the preference centre stands on too, and is named for that.
 *
 * Below the EOQ block are the classes the older views still use — the
 * newsletter archive, one newsletter, the sign-up form — kept working.
 */

  :root {
    --eoq-navy: #0c2f57;
    --eoq-blue: #174f8a;
    --eoq-green: #15a66a;
    --eoq-green-dark: #0a8c5a;
    --eoq-mint: #dff5eb;
    --eoq-sky: #f4f9fd;
    --eoq-border: #dce7ef;
    --eoq-text: #243b5a;
    --eoq-muted: #6d8099;
    --eoq-white: #ffffff;
  }

  .eoq-page {
    min-height: 100vh;
    margin: 0;
    background:
      radial-gradient(circle at 87% 15%, rgba(52, 160, 219, .12), transparent 26%),
      linear-gradient(180deg, #fbfdff 0%, #f2f8fc 72%, #eaf4fa 100%);
    color: var(--eoq-text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    overflow: hidden;
  }

  .eoq-page * { box-sizing: border-box; }

  .eoq-shell {
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
  }

  .eoq-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 28px 0 12px;
  }

  .eoq-logo {
    display: block;
    width: 294px;
    max-width: 52vw;
    height: auto;
  }

  .eoq-tagline {
    color: #164ea0;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.7;
    letter-spacing: .22em;
    text-align: right;
    text-transform: uppercase;
  }

  .eoq-tagline::after {
    content: "";
    display: block;
    width: 48px;
    height: 3px;
    margin-top: 8px;
    background: var(--eoq-green);
  }

  .eoq-hero {
    position: relative;
    padding: 58px 0 28px;
  }

  .eoq-hero::after {
    content: "";
    position: absolute;
    right: -24px;
    top: 10px;
    width: 320px;
    height: 250px;
    opacity: .42;
    pointer-events: none;
    background:
      radial-gradient(circle at 72% 20%, rgba(76, 154, 207, .22) 0 12%, transparent 13%),
      radial-gradient(circle at 64% 40%, rgba(76, 154, 207, .14) 0 18%, transparent 19%),
      radial-gradient(circle at 82% 58%, rgba(76, 154, 207, .12) 0 15%, transparent 16%);
  }

  .eoq-kicker {
    margin: 0 0 10px;
    color: #126a7c;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .24em;
    text-transform: uppercase;
  }

  .eoq-title {
    margin: 0;
    color: var(--eoq-navy);
    font-size: clamp(42px, 5vw, 68px);
    line-height: 1;
    letter-spacing: -.035em;
  }

  .eoq-lede {
    max-width: 760px;
    margin: 14px 0 0;
    color: #56708e;
    font-size: 20px;
    line-height: 1.55;
  }

  .eoq-card {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 0;
    margin: 12px 0 74px;
    border: 1px solid rgba(201, 218, 230, .92);
    border-radius: 16px;
    background: rgba(255,255,255,.97);
    box-shadow: 0 18px 50px rgba(25, 78, 116, .09);
    overflow: hidden;
  }

  .eoq-main {
    padding: 42px 46px 38px;
  }

  .eoq-heading {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 34px;
  }

  .eoq-bubble {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    color: var(--eoq-navy);
    background: var(--eoq-mint);
  }

  .eoq-bubble svg { width: 31px; height: 31px; }

  .eoq-heading h2,
  .eoq-aside h2 {
    margin: 0;
    color: var(--eoq-navy);
    letter-spacing: -.02em;
  }

  .eoq-heading h2 { font-size: clamp(28px, 3vw, 40px); }

  .eoq-sub {
    margin: 8px 0 0;
    color: #526b8a;
    font-size: 18px;
    line-height: 1.55;
  }

  .eoq-sub strong { color: var(--eoq-navy); }

  .eoq-label {
    display: block;
    margin-bottom: 10px;
    color: var(--eoq-navy);
    font-weight: 800;
    font-size: 16px;
  }

  .eoq-textarea {
    display: block;
    width: 100%;
    min-height: 142px;
    resize: vertical;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    padding: 16px;
    outline: none;
    color: var(--eoq-text);
    background: #fff;
    font: inherit;
    line-height: 1.5;
    transition: border-color .18s ease, box-shadow .18s ease;
  }

  .eoq-textarea:focus {
    border-color: var(--eoq-green);
    box-shadow: 0 0 0 4px rgba(21,166,106,.11);
  }

  .eoq-counter {
    margin: 7px 2px 0;
    color: #7a8ca2;
    font-size: 13px;
    text-align: right;
  }

  .eoq-actions {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-top: 24px;
  }

  .eoq-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 210px;
    min-height: 52px;
    border: 0;
    border-radius: 8px;
    padding: 0 24px;
    color: #fff;
    background: linear-gradient(135deg, var(--eoq-green), var(--eoq-green-dark));
    box-shadow: 0 10px 22px rgba(21,166,106,.19);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease;
  }

  .eoq-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 26px rgba(21,166,106,.24);
  }

  .eoq-button svg { width: 22px; height: 22px; }

  .eoq-link {
    color: #0b9360;
    font-weight: 700;
    text-underline-offset: 3px;
  }

  .eoq-assurance {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 18px 0 0;
    color: #617691;
    font-size: 14px;
  }

  .eoq-assurance svg {
    width: 20px;
    height: 20px;
    color: var(--eoq-green);
  }

  .eoq-aside {
    padding: 42px 36px;
    border-left: 1px solid var(--eoq-border);
    background: linear-gradient(180deg, #fbfefd 0%, #f4fbf8 100%);
  }

  .eoq-aside h2 {
    margin-top: 22px;
    font-size: 26px;
    line-height: 1.2;
  }

  .eoq-aside p {
    margin: 12px 0 0;
    color: #5b708b;
    font-size: 17px;
    line-height: 1.55;
  }

  .eoq-aside hr {
    border: 0;
    border-top: 1px solid #d7e5e1;
    margin: 28px 0;
  }

  .eoq-aside blockquote {
    margin: 0;
    color: #6e7f95;
    font-size: 17px;
    font-style: italic;
    line-height: 1.55;
  }

  .eoq-aside blockquote::before {
    content: "“";
    display: block;
    margin-bottom: -8px;
    color: #b7dcd0;
    font-family: Georgia, serif;
    font-size: 52px;
    line-height: .8;
  }

  /* --- the preference centre's controls, in the same hand as the textarea --- */

  .eoq-field { margin-bottom: 26px; }

  .eoq-label {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .eoq-field-icon {
    width: 21px;
    height: 21px;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .eoq-input {
    display: block;
    width: 100%;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    padding: 15px 46px 15px 16px;
    outline: none;
    color: var(--eoq-text);
    background: #fff;
    font: inherit;
    appearance: none;
    transition: border-color .18s ease, box-shadow .18s ease;
  }

  .eoq-input:focus {
    border-color: var(--eoq-green);
    box-shadow: 0 0 0 4px rgba(21,166,106,.11);
  }

  .eoq-select { position: relative; }

  .eoq-select > svg {
    position: absolute;
    top: 50%;
    right: 16px;
    width: 19px;
    height: 19px;
    color: var(--eoq-navy);
    pointer-events: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    transform: translateY(-50%);
  }

  .eoq-hint {
    margin: 8px 2px 0;
    color: #7a8ca2;
    font-size: 14px;
  }

  .eoq-fieldset {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
  }

  .eoq-fieldset legend { margin-bottom: 12px; padding: 0; }

  .eoq-choice {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-top: 12px;
    border: 1px solid #cfdce8;
    border-radius: 9px;
    padding: 17px;
    cursor: pointer;
    transition: border-color .18s ease, box-shadow .18s ease;
  }

  .eoq-choice:hover {
    border-color: #b6cde0;
    box-shadow: 0 6px 16px rgba(25, 78, 116, .06);
  }

  .eoq-choice input[type='checkbox'] {
    flex: 0 0 auto;
    width: 23px;
    height: 23px;
    margin: 1px 0 0;
    accent-color: var(--eoq-green);
  }

  .eoq-choice-name {
    display: block;
    color: var(--eoq-navy);
    font-weight: 800;
  }

  .eoq-choice-hint {
    display: block;
    margin-top: 3px;
    color: #7a8ca2;
    font-size: 14px;
  }

  .eoq-saved {
    margin: 0 0 24px;
    border: 1px solid #b7e2cd;
    border-radius: 9px;
    padding: 14px 16px;
    color: #0a7a51;
    background: #effaf4;
    font-weight: 700;
  }

  .eoq-error {
    margin: 12px 0 74px;
    border: 1px solid #f1c0c0;
    border-radius: 12px;
    padding: 24px;
    color: #842029;
    background: #fff5f5;
  }

  .eoq-footer {
    position: relative;
    padding: 58px 0 34px;
    color: rgba(255,255,255,.92);
    background: var(--eoq-navy);
  }

  .eoq-footer::before {
    content: "";
    position: absolute;
    left: -3%;
    right: -3%;
    top: -31px;
    height: 48px;
    border-top: 5px solid var(--eoq-green);
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
    background: var(--eoq-navy);
  }

  .eoq-footer-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: end;
    gap: 32px;
  }

  .eoq-footer-logo {
    width: 190px;
    max-width: 42vw;
    filter: brightness(0) invert(1);
    opacity: .96;
  }

  .eoq-footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px 22px;
  }

  .eoq-footer a { color: #fff; text-underline-offset: 3px; }

  .eoq-footer-bottom {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 28px;
    color: rgba(255,255,255,.7);
    font-size: 13px;
  }

  @media (max-width: 900px) {
    .eoq-card { grid-template-columns: 1fr; }
    .eoq-aside { border-left: 0; border-top: 1px solid var(--eoq-border); }
    .eoq-tagline { display: none; }
  }

  @media (max-width: 620px) {
    .eoq-shell { width: min(100% - 28px, 1220px); }
    .eoq-header { padding-top: 20px; }
    .eoq-logo { width: 240px; max-width: 78vw; }
    .eoq-hero { padding-top: 40px; }
    .eoq-main, .eoq-aside { padding: 28px 22px; }
    .eoq-heading { gap: 14px; }
    .eoq-bubble { width: 52px; height: 52px; }
    .eoq-actions { align-items: stretch; flex-direction: column; gap: 14px; }
    .eoq-button { width: 100%; }
    .eoq-footer-grid, .eoq-footer-bottom { display: flex; flex-direction: column; align-items: flex-start; }
    .eoq-footer-links { justify-content: flex-start; }
  }

/* ---------- newsletter archive ---------- */

.card-list {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  padding: 0;
  list-style: none;
}

.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 18px 50px rgba(25, 78, 116, .09);
}

.card__media img {
  display: block;
  width: 100%;
  height: auto;
}

.card__body {
  display: grid;
  gap: 8px;
  padding: 20px;
}

.card__title {
  margin: 0;
  font-size: 19px;
}

.card__title a {
  color: var(--eoq-navy);
  text-decoration: none;
}

.card__date {
  color: var(--eoq-muted);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.card__summary {
  margin: 0;
  color: var(--eoq-muted);
}

.pagination {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 30px;
}

.pagination__status {
  color: var(--eoq-muted);
  font-size: 14px;
}

.pagination__link {
  color: var(--eoq-green);
  font-weight: 600;
}

/* ---------- one newsletter ---------- */

.article {
  max-width: 760px;
  margin: 0 auto;
  padding: 34px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 18px 50px rgba(25, 78, 116, .09);
}

.article__hero img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 9px;
}

.article__date {
  color: var(--eoq-muted);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.article__title {
  margin: 8px 0 12px;
  font-size: clamp(26px, 4vw, 36px);
}

.article__summary {
  margin: 0 0 22px;
  color: var(--eoq-muted);
  font-size: 17px;
}

.article__content img {
  max-width: 100%;
  height: auto;
}

.article__webversion {
  margin-top: 26px;
  color: var(--eoq-muted);
  font-size: 14px;
}
