/* admin.css
   Admin surfaces: passcode gate, use-case list, field editor.
   ------------------------------------------------------------------------- */

.adm-tag {
  display: inline-flex; align-items: center; gap: 7px; flex-shrink: 0;
  font-size: 11.5px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase;
}

.adm-tag svg { width: 14px; height: 14px; }

.adm-hint { font-size: 12.5px; opacity: .82; min-width: 0; flex: 1; }

.adm-acts { display: flex; gap: 7px; align-items: center; flex-wrap: wrap; margin-left: auto; }

.gate { max-width: 520px; margin: 0 auto; padding: 90px 0 120px; text-align: center; }

.gate-ic {
  width: 52px; height: 52px; margin: 0 auto 22px; border-radius: 50%;
  display: grid; place-items: center; color: var(--accent);
  background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
}

.gate-ic svg { width: 24px; height: 24px; }

.gate h1 { font-size: 27px; margin-bottom: 12px; }

.gate p { font-size: 13.5px; color: var(--ink-3); line-height: 1.6; margin-bottom: 26px; }

.gate-f { display: flex; gap: 9px; }

.gate-f .field { flex: 1; }

.gate-err { color: var(--c-red); font-weight: 650; font-size: 13.5px; margin-top: 16px; }

.adm-hd { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }

.adm-hd .btn { margin-left: auto; }

.adm-list { border: 1px solid var(--line); border-radius: var(--r-l); overflow: hidden; }

.adm-row {
  display: grid; grid-template-columns: 46px minmax(0, 1fr) 40px auto;
  gap: 14px; align-items: center; padding: 12px 16px;
  background: var(--surface); border-top: 1px solid var(--line);
  border-left: 3px solid var(--m-c, transparent);
}

.adm-row:first-child { border-top: 0; }

.adm-no { font-size: 12px; font-weight: 800; color: var(--ink-3); }

.adm-nm { min-width: 0; }

.adm-nm b { display: block; font-size: 14.5px; font-weight: 650; letter-spacing: -.012em; }

.adm-nm span {
  display: block; font-size: 11.5px; color: var(--ink-3); margin-top: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.adm-ph {
  font-family: var(--mono); font-size: 11px; font-weight: 800; color: var(--ink-3);
  background: var(--bg-3); border-radius: 4px; padding: 3px 6px; text-align: center;
}

.adm-act { display: flex; gap: 5px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }

.editor { padding: 28px 0 0; }

.ed-hd {
  display: flex; align-items: flex-start; gap: 20px; flex-wrap: wrap;
  padding-bottom: 20px; margin-bottom: 24px; border-bottom: 1px solid var(--line);
}

.ed-hd h1 { font-size: clamp(22px, 3vw, 30px); letter-spacing: -.028em; }

.ed-hd p { font-size: 11.5px; color: var(--ink-3); margin: 6px 0 0; }

.ed-acts { display: flex; gap: 9px; margin-left: auto; flex-wrap: wrap; }

.ed-ft {
  display: flex; gap: 9px; padding-top: 22px; margin-top: 26px;
  border-top: 1px solid var(--line); flex-wrap: wrap;
}

.frow { margin-bottom: 22px; }

.frow > h4 {
  font-size: 11.5px; font-weight: 750; letter-spacing: .07em; text-transform: uppercase;
  color: var(--ink-3); margin-bottom: 9px;
}

.f2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.f2 label, .frow > label { display: block; }

.f2 label > span {
  display: block; font-size: 11px; font-weight: 650; color: var(--ink-3);
  margin-bottom: 5px; letter-spacing: .02em;
}

.f-hint { font-size: 11.5px; color: var(--ink-3); margin: 6px 0 0; }

.frow textarea.field, .frow input.field, .frow select.field { width: 100%; }

.cbs { display: grid; gap: 8px; }

.cb { display: flex; align-items: center; gap: 9px; cursor: pointer; font-size: 14px; }

.cb input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; flex-shrink: 0; }

.imgf {
  display: grid; grid-template-columns: 190px 1fr; gap: 16px; align-items: start;
  border: 1px solid var(--line); border-radius: var(--r-m); padding: 13px; background: var(--bg-2);
}

.imgf img { width: 100%; border-radius: var(--r-s); border: 1px solid var(--line); }

.imgf-none {
  aspect-ratio: 16/9; display: grid; place-items: center; border-radius: var(--r-s);
  border: 1px dashed var(--line-2); color: var(--ink-3); font-size: 12.5px;
}

.imgf-a { display: flex; gap: 8px; flex-wrap: wrap; }

@media (max-width: 860px) {
  .f2 { grid-template-columns: minmax(0, 1fr); }
  .imgf { grid-template-columns: minmax(0, 1fr); }
  .adm-row { grid-template-columns: 42px minmax(0, 1fr) 36px; row-gap: 10px; }
  .adm-act { grid-column: 1 / -1; justify-content: flex-start; }
}

@media (max-width: 660px) {
  .adm-hint { display: none; }
  .adm-acts { margin-left: 0; width: 100%; }
  .gate { padding: 56px 0 80px; }
  .gate-f { flex-direction: column; }
  .gate-f .btn { width: 100%; justify-content: center; }
  .ed-acts { width: 100%; }
  .ed-acts .btn, .ed-ft .btn { flex: 1; justify-content: center; }
}
