/* ────────────────────────────────────────────────────────────────
   Archive Community Layer — Notifications · Correspondence · Circle gateway
   Lane C (Product Presentation) · C2 · 2026-08-12
   Quiet luxury: cream / black / gold · editorial · no SaaS/Discord flavor
   Presentation only — backend pending (see docs/circle_archive_messaging_contract.md)
   ──────────────────────────────────────────────────────────────── */

/* ── Bell & entries ── */
.ac-bell {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px;
  border: 1px solid var(--card-border, #e3d7c2);
  border-radius: 50%;
  background: transparent;
  color: var(--gold, #a8842f);
  font-size: 15px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
  flex-shrink: 0;
}
.ac-bell:hover { border-color: var(--gold, #a8842f); }
.ac-bell:focus-visible { outline: 2px solid var(--gold, #a8842f); outline-offset: 2px; }
.ac-bell .ac-bell-glyph { line-height: 1; }
.ac-bell-badge {
  position: absolute; top: -4px; right: -4px;
  min-width: 15px; height: 15px; padding: 0 3px;
  border-radius: 999px;
  background: var(--gold, #a8842f); color: #fff;
  font-size: 9px; font-weight: 600; line-height: 15px; text-align: center;
  font-family: 'Inter', system-ui, sans-serif;
  display: none;
}
.ac-bell-badge[data-count]:not([data-count="0"]) { display: block; }

.ac-text-action {
  background: none; border: none; cursor: pointer;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-dim, #6f6252);
  padding: 6px 4px;
  white-space: nowrap;
}
.ac-text-action:hover { color: var(--gold, #a8842f); }
.ac-text-action:focus-visible { outline: 2px solid var(--gold, #a8842f); outline-offset: 2px; }

/* Mobile topbar entries */
.ac-mobile-bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border: none; background: transparent; color: var(--gold, #a8842f); font-size: 16px; cursor: pointer; }
.ac-mobile-bell .ac-bell-badge { top: 0; right: 0; }

/* ── Drawer shell (shared) ── */
.ac-overlay {
  position: fixed; inset: 0; z-index: 1400;
  background: rgba(20, 16, 10, 0.34);
  display: flex; justify-content: flex-end;
  opacity: 0; visibility: hidden; transition: opacity 0.22s ease, visibility 0.22s;
}
.ac-overlay.open { opacity: 1; visibility: visible; }
.ac-drawer {
  width: min(420px, 100vw);
  height: 100%;
  background: #fbf7ef;
  border-left: 1px solid #e4d9c6;
  box-shadow: -18px 0 46px rgba(42, 33, 23, 0.14);
  display: flex; flex-direction: column;
  transform: translateX(24px); transition: transform 0.22s ease;
}
.ac-overlay.open .ac-drawer { transform: translateX(0); }
.ac-drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px 14px;
  border-bottom: 1px solid #e4d9c6;
}
.ac-drawer-head h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 22px; font-weight: 600; color: #2a2117; letter-spacing: 0.02em;
}
.ac-drawer-close {
  border: none; background: none; cursor: pointer;
  font-size: 20px; color: #8a7a64; line-height: 1; padding: 4px 6px;
}
.ac-drawer-close:hover { color: #2a2117; }
.ac-drawer-close:focus-visible { outline: 2px solid #a8842f; outline-offset: 2px; }
.ac-drawer-body { flex: 1; overflow-y: auto; padding: 14px 22px 24px; }

/* States */
.ac-state { padding: 44px 18px; text-align: center; }
.ac-state-icon { font-size: 26px; color: #a8842f; margin-bottom: 12px; }
.ac-state-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 19px; font-weight: 600; color: #2a2117; }
.ac-state-body { font-size: 13px; color: #8a7a64; margin-top: 6px; line-height: 1.55; }
.ac-retry-btn {
  margin-top: 14px; padding: 8px 18px;
  border: 1px solid #a8842f; border-radius: 999px; background: transparent;
  color: #8a6b22; font-size: 11px; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; cursor: pointer;
}
.ac-retry-btn:hover { background: rgba(168, 132, 47, 0.08); }
.ac-retry-btn:focus-visible { outline: 2px solid #a8842f; outline-offset: 2px; }

/* Notifications list */
.ac-notif { display: flex; gap: 12px; padding: 13px 4px; border-bottom: 1px solid #eee5d4; }
.ac-notif:last-child { border-bottom: none; }
.ac-notif-dot { width: 7px; height: 7px; border-radius: 50%; background: #a8842f; margin-top: 7px; flex-shrink: 0; }
.ac-notif.unread .ac-notif-dot { background: #a8842f; }
.ac-notif.read .ac-notif-dot { background: transparent; }
.ac-notif-type { font-size: 9.5px; letter-spacing: 0.16em; text-transform: uppercase; color: #8a6b22; }
.ac-notif-title { font-size: 13.5px; color: #2a2117; margin-top: 2px; line-height: 1.45; }
.ac-notif-meta { font-size: 11px; color: #a2957f; margin-top: 4px; }
.ac-notif a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.ac-notif a:hover { color: #8a6b22; }
.ac-mark-read {
  border: none; background: none; cursor: pointer;
  font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase;
  color: #8a7a64; padding: 2px 0;
}
.ac-mark-read:hover { color: #a8842f; }

/* Messages — inbox */
.ac-conv { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-bottom: 1px solid rgba(120, 103, 70, 0.14); cursor: pointer; }
.ac-inbox-head { display: flex; align-items: baseline; justify-content: space-between; padding: 2px 4px 10px; }
.ac-inbox-title { font-family: var(--ac-serif); font-size: 14px; letter-spacing: 0.08em; color: var(--ac-ink); }
.ac-compose-link { background: none; border: none; padding: 4px 2px; color: var(--ac-gold-deep); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer; }
.ac-compose-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.ac-compose-link:focus-visible { outline: 2px solid var(--ac-gold); outline-offset: 2px; }
.ac-conv:last-child { border-bottom: none; }
.ac-conv:hover { background: rgba(168, 132, 47, 0.05); }
.ac-conv-mono {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  background: #efe7d6; color: #8a6b22;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Cormorant Garamond', serif; font-size: 15px; font-weight: 600;
}
.ac-conv-body { flex: 1; min-width: 0; }
.ac-conv-name { font-size: 13.5px; font-weight: 500; color: #2a2117; display: flex; justify-content: space-between; gap: 8px; }
.ac-conv-time { font-size: 10.5px; color: #a2957f; font-weight: 400; white-space: nowrap; }
.ac-conv-preview { font-size: 12px; color: #8a7a64; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac-conv.unread .ac-conv-name { color: #2a2117; }
.ac-conv.unread .ac-conv-preview { color: #57493a; }
.ac-conv-unread {
  display: inline-block; min-width: 17px; height: 17px; padding: 0 5px;
  border-radius: 999px; background: #a8842f; color: #fff;
  font-size: 9.5px; font-weight: 600; line-height: 17px; text-align: center; margin-top: 3px;
}

/* Conversation detail — letter style */
.ac-thread-head { padding: 6px 2px 14px; border-bottom: 1px solid #e4d9c6; margin-bottom: 16px; }
.ac-thread-name { font-family: 'Cormorant Garamond', serif; font-size: 20px; font-weight: 600; color: #2a2117; }
.ac-thread-sub { font-size: 11px; color: #a2957f; margin-top: 2px; }
.ac-msg { margin-bottom: 16px; max-width: 88%; }
.ac-msg.mine { margin-left: auto; }
.ac-msg-bubble {
  background: #fffdf8; border: 1px solid #e4d9c6; border-radius: 12px;
  padding: 12px 15px; font-size: 13.5px; color: #2a2117; line-height: 1.6;
}
.ac-msg.mine .ac-msg-bubble { background: #f3ead7; border-color: #dccdac; }
.ac-msg-meta { font-size: 10.5px; color: #a2957f; margin-top: 4px; padding: 0 4px; }
.ac-thread-reply { margin-top: 18px; }
.ac-thread-reply textarea {
  width: 100%; min-height: 88px; resize: vertical;
  background: #fffdf8; border: 1px solid #dccdac; border-radius: 10px;
  padding: 12px 14px; font-family: 'Inter', system-ui, sans-serif; font-size: 13px; color: #2a2117;
}
.ac-thread-reply textarea:focus-visible { outline: 2px solid #a8842f; outline-offset: 1px; }
.ac-send-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; }
.ac-send-btn {
  padding: 9px 20px; border: none; border-radius: 999px;
  background: #a8842f; color: #fff;
  font-size: 11px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer;
}
.ac-send-btn:disabled { background: #cbbf9f; cursor: not-allowed; }
.ac-send-note { font-size: 10.5px; color: #a2957f; }
.ac-back {
  border: none; background: none; cursor: pointer;
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: #8a6b22; padding: 0 0 10px;
}
.ac-back:hover { color: #a8842f; }

/* Circle gateway card (Archive) */
.arc-gateway {
  margin: 26px 2px 4px;
  background: #fffdf8;
  border: 1px solid #e4d9c6;
  border-radius: 14px;
  padding: 22px 24px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px;
}
.arc-gateway-kicker { font-size: 10px; letter-spacing: 0.22em; text-transform: uppercase; color: #8a6b22; }
.arc-gateway-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 21px; font-weight: 600; color: #2a2117; margin-top: 3px; }
.arc-gateway-body { font-size: 13px; color: #8a7a64; margin-top: 4px; max-width: 560px; line-height: 1.55; }
.arc-gateway-cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase;
  color: #8a6b22; text-decoration: none; border: 1px solid #a8842f; border-radius: 999px;
  padding: 10px 20px; white-space: nowrap;
}
.arc-gateway-cta:hover { background: rgba(168, 132, 47, 0.08); }
.arc-gateway-cta:focus-visible { outline: 2px solid #a8842f; outline-offset: 2px; }

/* Mobile menu entries (archive drawer) */
.ac-menu-item {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; cursor: pointer; font-size: 13px; color: #2a2117;
}
.ac-menu-item:hover { background: rgba(168, 132, 47, 0.06); }
.ac-menu-item .ac-menu-glyph { color: #a8842f; font-size: 14px; width: 16px; text-align: center; }

@media (max-width: 767px) {
  .ac-drawer { width: 100vw; }
}
