/* Blog subscription - form, end-of-post box, /subscribe page, one-time invitation.
   Redesigned 2026-10-29 (owner: better look, a name field, better words). Brand: navy
   #132d44, orange #ffaa0a (fill only - orange text on white fails contrast), white. */

.sub-form { display: grid; gap: 12px; }
.sub-fields { display: grid; gap: 12px; }
.sub-field { display: grid; gap: 5px; min-width: 0; }
.sub-field label { font-size: 13px; font-weight: 700; letter-spacing: .02em; color: #132d44; text-transform: uppercase; }
.sub-field input {
  font: inherit; font-size: 16px; /* 16px stops iOS zooming into the field */
  width: 100%; min-width: 0; box-sizing: border-box;
  padding: 13px 14px; border: 1.5px solid #c3cad6; border-radius: 8px; background: #fff; color: #111;
  transition: border-color .15s, box-shadow .15s;
}
.sub-field input::placeholder { color: #8a93a3; }
.sub-field input:focus { outline: none; border-color: #132d44; box-shadow: 0 0 0 3px rgba(255, 170, 10, .45); }
.sub-field input[aria-invalid="true"] { border-color: #b3261e; }
.sub-btn { width: 100%; justify-content: center; font-size: 16px; padding: 14px 20px; border-radius: 8px; cursor: pointer; }
.sub-btn:disabled { opacity: .6; cursor: wait; }
.sub-fine { font-size: 12.5px; line-height: 1.5; color: #5a6475; margin: 0; }
.sub-fine a { color: inherit; text-decoration: underline; }
.sub-msg { background: #eaf6ee; border-left: 4px solid #1a7f37; color: #1d3d26; padding: 14px 16px; border-radius: 8px; line-height: 1.5; }
.sub-err, .sub-fail { color: #b3261e; font-weight: 600; margin: 0; font-size: 14px; }
.sub-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sub-form [hidden] { display: none !important; }   /* .btn sets display, which beats the hidden attribute */
.sub-form.is-done .sub-fields, .sub-form.is-done .sub-btn, .sub-form.is-done .sub-fine { display: none; }

.sub-icon { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: #ffaa0a; color: #132d44; }

/* end of post + /subscribe page */
.sub-box {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center;
  background: #132d44; color: #fff; border-radius: 16px; padding: 40px; margin: 48px 0;
  position: relative; overflow: hidden;
}
.sub-box::after { /* a quiet orange corner, the site's accent */
  content: ""; position: absolute; right: -60px; top: -60px; width: 180px; height: 180px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,170,10,.28), rgba(255,170,10,0) 70%); pointer-events: none;
}
.sub-kicker { margin: 14px 0 4px; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #ffc65c; }
.sub-box h2 { margin: 0 0 12px; font-size: clamp(24px, 3.2vw, 34px); line-height: 1.15; color: #fff; }
.sub-lead { margin: 0 0 16px; color: #d6dde8; line-height: 1.6; }
.sub-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.sub-points li { padding-left: 28px; position: relative; color: #eef2f7; }
.sub-points li::before { content: ""; position: absolute; left: 0; top: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: #ffaa0a url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23132d44' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round' d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center/12px no-repeat; }
.sub-box-form { background: #fff; color: #111; border-radius: 12px; padding: 26px; box-shadow: 0 12px 32px rgba(0,0,0,.25); position: relative; z-index: 1; }
.sub-page { padding-top: 120px; padding-bottom: 40px; }
@media (max-width: 860px) {
  .sub-box { grid-template-columns: 1fr; gap: 24px; padding: 26px 20px; }
  .sub-box-form { padding: 20px; }
}

/* the one-time invitation */
.sub-pop { position: fixed; z-index: 70; background: #fff; color: #111; box-shadow: 0 16px 48px rgba(0,0,0,.32); }
.sub-pop[hidden] { display: none; }
.sub-pop h2 { color: #132d44; margin: 12px 0 6px; line-height: 1.2; }
.sub-pop-lead { margin: 0 0 16px; color: #3d4757; line-height: 1.5; }
.sub-pop-x { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: #f1f3f6; font-size: 24px; line-height: 1; cursor: pointer; color: #333; }
.sub-pop-x:hover { background: #e3e7ed; }
.sub-pop-no { display: block; margin: 10px auto 0; border: 0; background: none; color: #4a5465; text-decoration: underline; cursor: pointer; font: inherit; font-size: 14px; padding: 6px; }
@media (min-width: 768px) {
  .sub-pop { top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(460px, 92vw); max-height: 92vh; overflow: auto;
             border-radius: 16px; padding: 30px 30px 18px; text-align: left; }
  .sub-pop h2 { font-size: 26px; }
  html.sub-pop-open body::after { content: ""; position: fixed; inset: 0; background: rgba(19,45,68,.55); z-index: 65; }
}
/* phones: a bar at the bottom, about a third of the screen; the article stays readable above it
   (Google demotes pop-ups that cover the content on phones) */
@media (max-width: 767px) {
  .sub-pop { left: 0; right: 0; bottom: 0; max-height: 40vh; overflow: auto; border-radius: 18px 18px 0 0; padding: 14px 16px 10px;
             border-top: 4px solid #ffaa0a; }
  .sub-pop .sub-icon, .sub-pop-lead, .sub-pop .sub-field label { display: none; }
  .sub-pop h2 { font-size: 18px; margin: 2px 44px 10px 0; }
  .sub-pop .sub-fields { grid-template-columns: 1fr 1fr; gap: 8px; }
  .sub-pop .sub-field input { padding: 11px 10px; font-size: 16px; }
  .sub-pop .sub-form { gap: 8px; }
  .sub-pop .sub-btn { padding: 12px; }
  .sub-pop .sub-fine { font-size: 11px; }
  .sub-pop .sub-form, .sub-pop .sub-fields { min-width: 0; max-width: 100%; }
  .sub-pop-no { margin-top: 4px; }
  .sub-pop-x { top: 8px; right: 8px; width: 36px; height: 36px; }
}
html.sub-pop-open .pnote { display: none; }   /* the privacy notice waits until the invitation is closed */
