/* Archive Vault — inline "pen icon" editing overlay for signed-in staff.
   Loaded on the three content pages (Home, Our Mission, Consign With Us)
   alongside inline-edit.js. Reuses this site's own design tokens
   (--burgundy, --ink, --surface, --line, --font-body from css/style.css)
   plus the .field / .btn / .ck-image-* classes already defined there, so
   the toggle, pencils and editor modal read as part of the site rather
   than a bolted-on tool. */

body.ie-editing [data-ck],
body.ie-editing [data-ck-img],
body.ie-editing [data-ck-bg] {
  outline: 1px dashed var(--brass, #a9835a);
  outline-offset: 3px;
}

.ie-toggle {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 9999;
  padding: 13px 22px;
  font-family: var(--font-body, "Inter", sans-serif);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: var(--burgundy, #6d1f2e);
  border: none;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
  cursor: pointer;
}
.ie-toggle:hover { background: var(--burgundy-deep, #4a141f); }
body.ie-editing .ie-toggle { background: var(--ink, #2a2523); }
body.ie-editing .ie-toggle:hover { background: var(--burgundy, #6d1f2e); }

.ie-pencil {
  position: fixed;
  z-index: 9998;
  width: 28px;
  height: 28px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--burgundy, #6d1f2e);
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}
.ie-pencil:hover { background: var(--ink, #2a2523); }
.ie-pencil svg { width: 14px; height: 14px; display: block; }

.ie-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(20, 14, 15, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.ie-modal-backdrop[hidden] { display: none; }

.ie-modal-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  max-height: 86vh;
  overflow-y: auto;
  background: var(--surface, #fff);
  border: 1px solid var(--line, #e6ddd3);
  padding: 40px 32px 32px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.3);
}
.ie-modal-card h3 { font-size: 20px; margin: 0 0 18px; }
.ie-modal-card form .field { margin-bottom: 4px; }
.ie-modal-card textarea { min-height: 130px; }

.ie-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: var(--fog, #f3ede6);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink, #2a2523);
  font-size: 18px;
  line-height: 1;
}

.ie-error {
  color: var(--danger, #a13a3a);
  font-size: 12.5px;
  margin: 10px 0 0;
}

@media (max-width: 640px) {
  .ie-toggle { right: 14px; bottom: 14px; padding: 11px 18px; font-size: 11px; }
  .ie-modal-card { padding: 32px 22px 26px; }
}
