/* ---- subscribe ---------------------------------------------------------
   Shared by the front page and the completion overlay on each puzzle page;
   subscribe.js builds the button and the dialog and does the remembering. */

/* The button: outlined ink on brand yellow, as the page's other buttons. */
.subscribe-open {
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 10px 20px;
  border: 2px solid var(--ink);
  border-radius: 6px;
  background: var(--brand);
  color: var(--ink);
  cursor: pointer;
}
.subscribe-open:hover { background: #ffd95e; }
.subscribe-open:active { transform: translateY(1px); }
.subscribe-open:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; }
.subscribe-open[hidden] { display: none; }

/* The dialog, in the same card as the puzzle page's first-visit invitation:
   white, with a band of brand yellow along the top. */
.subscribe-dialog {
  margin: auto;
  width: calc(100% - 40px);
  max-width: 440px;
  padding: 30px 26px 24px;
  border: none;
  border-top: 6px solid var(--brand);
  background: #fff;
  color: var(--ink);
  text-align: center;
}
.subscribe-dialog::backdrop { background: rgba(17, 17, 17, 0.55); }
/* every property set, since the front page styles its bare h2s as labels */
.subscribe-dialog-title {
  margin: 0 0 20px;
  padding: 0;
  background: none;
  font: 800 clamp(1.2rem, 5vw, 1.5rem)/1.15 var(--sans);
  letter-spacing: -0.015em;
  text-transform: none;
  color: var(--ink);
}
.subscribe-close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  background: none;
  font: 400 1.6rem/1 var(--sans);
  color: #63685c;
  cursor: pointer;
}
.subscribe-close:hover { color: var(--ink); }
.subscribe-close:focus-visible { outline: 3px solid var(--link); outline-offset: 0; }

/* One line: the address and a black button. On a phone the button drops under
   the field. */
.subscribe {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.subscribe input {
  flex: 1 1 200px;
  min-width: 0;
  font: inherit;
  font-size: 0.95rem;
  padding: 8px 12px;
  border: 2px solid var(--ink);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}
.subscribe button {
  flex: 0 0 auto;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 8px 18px;
  border: 2px solid var(--ink);
  border-radius: 6px;
  background: var(--ink);
  color: var(--brand);
  cursor: pointer;
}
.subscribe button:hover { background: #333; }
.subscribe input:focus-visible,
.subscribe button:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; }
.subscribe-note {
  margin-top: 14px;
  font-size: 0.85rem;
  color: #63685c;
}
/* what replaces the form once it has been sent */
.subscribe-thanks { font-weight: 600; }
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* On a puzzle's completion overlay it is a plain underlined line straight
   under Zatvori: an aside to the result, not a second button beside it. */
.lumbago-overlay .subscribe-open {
  /* the overlay spaces its lines 16px apart; this one belongs to the button */
  margin-top: -6px;
  padding: 2px 4px;
  border: none;
  border-radius: 0;
  background: none;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.lumbago-overlay .subscribe-open:hover {
  background: none;
  text-decoration-thickness: 2px;
}
