/* =========================================================
   Extras — additions on top of styles.css for v2 features:
   notification bell, follow-up modal, OTP auth screens,
   profile-setup page.
   ========================================================= */

/* ---------- Notification bell ---------- */
.notif-wrap { position: relative; }
.notif-badge {
  position: absolute; top: 4px; right: 4px;
  min-width: 16px; height: 16px;
  padding: 0 4px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center;
  line-height: 1;
}
.notif-pop {
  position: absolute;
  right: 0; top: calc(100% + 8px);
  width: 340px; max-width: 90vw;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  z-index: 50;
  overflow: hidden;
}
.notif-pop[hidden] { display: none !important; }   /* hidden attr must win */
.notif-pop-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-2);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.notif-pop-clear {
  background: transparent; border: 0;
  font-family: inherit; font-size: 11px; letter-spacing: inherit;
  color: var(--accent);
  cursor: pointer; padding: 0;
}
.notif-pop-clear:hover { text-decoration: underline; }

.notif-list {
  list-style: none; margin: 0; padding: 0;
  max-height: 380px; overflow-y: auto;
}
.notif-list li {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-2);
  cursor: pointer;
  display: flex; flex-direction: column; gap: 4px;
  transition: background .12s ease;
}
.notif-list li:hover    { background: var(--surface-2); }
.notif-list li:last-child { border-bottom: 0; }
.notif-list li.unread { background: var(--accent-soft); }
.notif-list li.unread:hover {
  background: color-mix(in srgb, var(--accent-soft) 70%, var(--surface) 30%);
}

.notif-title {
  font-weight: 600; font-size: 14px; color: var(--ink);
  display: flex; align-items: center; gap: 6px;
}
.notif-body { font-size: 13.5px; color: var(--ink-2); line-height: 1.45; }
.notif-time {
  font-family: var(--font-mono); font-size: 10.5px;
  color: var(--ink-3); letter-spacing: .08em;
}

.notif-empty {
  padding: 28px 16px; text-align: center;
  font-size: 14px; color: var(--ink-3);
}

/* ---------- Auth: OTP screens + setup ---------- */
/* Default: hidden. Only .is-active reveals. JS toggles the class. */
.auth-stage { display: none; flex-direction: column; gap: 14px; margin-top: 8px; }
.auth-stage.is-active { display: flex; }
.auth-stage[hidden] { display: none !important; }   /* belt-and-suspenders */

.auth-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 8px 0 -4px;
}

.auth-input {
  width: 100%;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.auth-input:focus {
  outline: 0;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.auth-otp {
  font-family: var(--font-mono);
  font-size: 22px;
  letter-spacing: .25em;
  text-align: center;
}

.auth-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--ink); color: var(--bg);
  border: 1px solid var(--ink);
  padding: 13px 20px;
  border-radius: 11px;
  font-family: var(--font-body);
  font-weight: 600; font-size: 15px;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .15s ease, opacity .15s ease;
}
.auth-primary:hover    { transform: translateY(-1px); }
.auth-primary:disabled { opacity: .55; cursor: progress; transform: none; }

.auth-back, .auth-link {
  background: transparent; border: 0;
  font-family: var(--font-body);
  font-size: 13.5px;
  color: var(--ink-3);
  cursor: pointer; padding: 4px 0;
  text-align: center;
}
.auth-back:hover, .auth-link:hover { color: var(--ink); }
.auth-link:disabled { opacity: .4; cursor: default; }

.auth-meta {
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  margin-top: 4px;
}

.auth-divider {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 4px 0;
}
.auth-divider::before, .auth-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--line-2);
}

.email-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%;
  padding: 13px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 11px;
  font-family: var(--font-body);
  font-size: 15px; font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  transition: background .12s ease, border-color .12s ease;
}
.email-btn:hover {
  background: var(--surface-2);
  border-color: color-mix(in srgb, var(--ink) 22%, var(--line));
}

.login-ok {
  margin-top: 14px;
  background: var(--ok-soft);
  color: var(--ok);
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13.5px;
}

/* ---------- Profile setup avatar ---------- */
.setup-avatar-row {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  margin: 4px 0 16px;
}
.setup-avatar {
  position: relative;
  width: 96px; height: 96px;
  flex: 0 0 96px;     /* firm size — don't grow/shrink even inside flex parents */
  min-width: 96px;
  max-width: 96px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px dashed var(--line);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  cursor: pointer;
}
.setup-avatar img {
  width: 96px; height: 96px;     /* hard-pin instead of % so a giant src can't push the parent */
  max-width: 96px; max-height: 96px;
  object-fit: cover;
  display: block;
}
.setup-avatar-fallback {
  font-family: var(--font-display);
  font-size: 36px; font-weight: 500;
  color: var(--ink-3);
  text-transform: uppercase;
}
.setup-avatar-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase;
  padding: 5px 0; text-align: center;
  opacity: 0; transition: opacity .15s ease;
}
.setup-avatar:hover .setup-avatar-overlay { opacity: 1; }
.setup-avatar-hint {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0;
}

/* ---------- Follow-up button on tasks ---------- */
.task-followup {
  background: transparent; border: 0;
  color: var(--ink-3);
  cursor: pointer;
  display: inline-flex; align-items: center;
  padding: 4px;
  border-radius: 6px;
  transition: color .12s ease, background .12s ease;
  flex-shrink: 0;
}
.task-followup:hover { color: var(--accent); background: var(--surface-2); }
.task-followup.has-fu { color: var(--accent); }

.task-fu-pill {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
}

/* ---------- Modal ---------- */
/* Default state: hidden. Only .is-open shows it. This is specificity-proof —
   no [hidden] attribute games that can be overridden by other class rules. */
.modal {
  position: fixed; inset: 0;
  background: rgba(15, 16, 18, .55);
  z-index: 200;
  display: none;       /* DEFAULT — invisible until JS adds .is-open */
  align-items: center; justify-content: center;
  padding: 20px;
}
.modal.is-open {
  display: flex;
  animation: modal-fade .15s ease;
}
.modal[hidden] { display: none !important; }    /* belt-and-suspenders */
@keyframes modal-fade { from { opacity: 0; } to { opacity: 1; } }
.modal-card {
  position: relative;
  width: 100%; max-width: 440px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 28px 22px;
  box-shadow: var(--shadow-md);
  display: flex; flex-direction: column; gap: 12px;
}
.modal-close {
  position: absolute; top: 12px; right: 14px;
  background: transparent; border: 0; font-size: 24px;
  color: var(--ink-3); cursor: pointer; line-height: 1;
}
.modal-close:hover { color: var(--ink); }

.modal-title {
  font-family: var(--font-display);
  font-weight: 500; font-size: 22px;
  letter-spacing: -.015em;
  margin: 0;
  color: var(--ink);
}
.modal-sub {
  margin: 0 0 6px;
  font-size: 14px; color: var(--ink-2);
  font-style: italic;
}
.modal-actions {
  display: flex; justify-content: flex-end; align-items: center;
  gap: 10px; margin-top: 10px;
}

/* ---------- Landing-page secondary CTA ---------- */
.cta-secondary {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: var(--font-body);
  font-weight: 600; font-size: 15px;
  text-decoration: none;
  transition: background .12s ease, border-color .12s ease, transform .12s ease;
}
.cta-secondary:hover {
  background: var(--surface-2);
  border-color: color-mix(in srgb, var(--ink) 22%, var(--line));
  transform: translateY(-1px);
}

/* The hero-cta-row already exists in landing.css; we just need the wrap. */
.hero-cta-row { flex-wrap: wrap; }

/* New row for the mid-page CTA so two buttons can sit together. */
.midcta-row {
  display: inline-flex; flex-wrap: wrap; gap: 12px;
  justify-content: center;
}

/* ---------- Reminders page ---------- */
.rem-page { max-width: 760px; padding-top: 28px; }
.rem-head { margin-bottom: 22px; }
.rem-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 8px;
}
.rem-title {
  font-family: var(--font-display);
  font-weight: 500; font-size: 38px;
  letter-spacing: -.02em;
  margin: 0 0 8px;
  color: var(--ink);
}
.rem-sub {
  font-size: 15px; color: var(--ink-2);
  margin: 0;
}

.rem-tabs {
  display: flex; gap: 4px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 4px;
  margin: 22px 0 18px;
  width: fit-content;
}
.rem-tab {
  background: transparent; border: 0;
  font-family: var(--font-body);
  font-size: 13.5px; font-weight: 500;
  color: var(--ink-2);
  padding: 8px 14px;
  border-radius: 9px;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  transition: background .12s ease, color .12s ease;
}
.rem-tab:hover { color: var(--ink); }
.rem-tab.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.rem-count {
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 1px 6px;
  border-radius: 4px;
}

.rem-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.rem-item {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  transition: border-color .12s ease;
}
.rem-item:hover { border-color: color-mix(in srgb, var(--ink) 16%, var(--line)); }
.rem-item--done { opacity: .55; }
.rem-item--done .rem-task { text-decoration: line-through; }

.rem-item-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.rem-task {
  margin: 0;
  font-size: 15.5px; color: var(--ink);
  font-weight: 500;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.rem-note {
  margin: 0;
  font-size: 13.5px; color: var(--ink-2);
  font-style: italic;
}
.rem-meta {
  margin: 4px 0 0;
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
}
.rem-when { color: var(--ink); font-weight: 600; letter-spacing: .04em; }
.rem-date { letter-spacing: .04em; }

.rem-pill {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: var(--surface-2);
  color: var(--ink-2);
  padding: 2px 6px;
  border-radius: 4px;
}
.rem-pill--ok   { background: var(--ok-soft);     color: var(--ok); }
.rem-pill--warn { background: var(--accent-soft); color: var(--accent); }

.rem-item-actions { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }

.rem-empty {
  text-align: center;
  padding: 60px 20px;
  background: var(--surface);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--ink-2);
  font-size: 14.5px;
}
.rem-empty a { color: var(--accent); text-decoration: underline; }

/* ---------- Has-reminder dot on tasks (DAT board) ---------- */
.task-fu-pill {
  display: inline-flex; align-items: center; gap: 4px;
}
.task-fu-pill::before {
  content: ""; width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: rem-pulse 2.4s infinite;
}
@keyframes rem-pulse {
  0%, 60%, 100% { opacity: 1; }
  80%           { opacity: .35; }
}

/* Mobile niceties */
@media (max-width: 640px) {
  .rem-item { flex-direction: column; }
  .rem-item-actions { flex-direction: row; }
  .rem-title { font-size: 30px; }
}

/* Reminders link in navbar — share the bell's badge styling. */
.rem-link { position: relative; text-decoration: none; }
.rem-link:hover { color: var(--accent); }

/* ---------- Follow-up modal: when + tz row ---------- */
.fu-when-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
@media (max-width: 480px) {
  .fu-when-row { grid-template-columns: 1fr; }
}
.fu-tz {
  font-family: var(--font-mono);
  font-size: 13px;
}
.fu-tz-hint {
  margin: 6px 0 0;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: .04em;
  line-height: 1.4;
}