
#iv-app { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; max-width: 1000px; margin: 0 auto; }
.iv-section { background: #f9f9f9; border: 1px solid #ddd; border-radius: 8px; padding: 20px 24px; margin-bottom: 24px; }
.iv-section h3 { margin: 0 0 14px; font-size: 16px; }
.iv-cat-list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.iv-cat-pill { display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px; border-radius: 20px; background: #e5e5e5; font-size: 13px; cursor: pointer; border: 2px solid transparent; transition: all .15s; }
.iv-cat-pill:hover { background: #d5d5d5; }
.iv-cat-pill.iv-cat-active { background: #2271b1; color: #fff; border-color: #2271b1; }
.iv-cat-del { background: none; border: none; color: inherit; cursor: pointer; font-size: 16px; padding: 0; line-height: 1; opacity: .7; }
.iv-cat-del:hover { opacity: 1; }
.iv-cat-add-row { display: flex; gap: 8px; }
.iv-cat-add-row input { flex: 1; padding: 7px 10px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; }
.iv-form-row { margin-bottom: 10px; }
.iv-form-row input[type="text"], .iv-form-row textarea, .iv-form-row select { width: 100%; padding: 8px 10px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; box-sizing: border-box; }
.iv-form-row--inline { display: flex; gap: 10px; align-items: center; }
.iv-form-row--inline select { flex: 0 0 180px; width: auto; }
.iv-form-row--inline input[type="file"] { flex: 1; }
.iv-btn { display: inline-block; padding: 8px 16px; border-radius: 4px; border: 1px solid #ccc; background: #fff; cursor: pointer; font-size: 13px; transition: background .15s; }
.iv-btn:hover { background: #f0f0f0; }
.iv-btn-primary { background: #2271b1; color: #fff; border-color: #2271b1; }
.iv-btn-primary:hover { background: #135e96; }
.iv-btn-danger { background: #d63638; color: #fff; border-color: #d63638; font-size: 12px; padding: 5px 10px; }
.iv-btn-danger:hover { background: #b02226; }
.iv-toolbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; flex-wrap: wrap; gap: 10px; }
.iv-toolbar label { font-size: 14px; display: flex; align-items: center; gap: 6px; }
.iv-toolbar-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.iv-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; }
.iv-item { border: 1px solid #ddd; border-radius: 8px; overflow: hidden; position: relative; background: #fff; transition: box-shadow .2s; }
.iv-item:hover { box-shadow: 0 4px 16px rgba(0,0,0,.13); }
.iv-item img { width: 100%; height: 160px; object-fit: cover; display: block; }
.iv-zoomable { cursor: zoom-in; }
.iv-item-caption { padding: 10px; }
.iv-item-caption strong { display: block; font-size: 13px; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.iv-item-caption p { font-size: 12px; color: #555; margin: 0 0 8px; }
.iv-item-cat-row select { width: 100%; font-size: 12px; padding: 4px 6px; border: 1px solid #ccc; border-radius: 4px; }
.iv-check { position: absolute; top: 8px; left: 8px; background: rgba(255,255,255,.9); border-radius: 3px; padding: 2px 5px; }
.iv-delete-btn { display: block; width: calc(100% - 20px); margin: 0 10px 10px; }
.iv-item--hidden { display: none !important; }
.iv-msg { margin-top: 10px; font-size: 13px; }
.iv-msg.success { color: #0a6b27; }
.iv-msg.error { color: #d63638; }
.iv-notice { padding: 14px 18px; background: #fff3cd; border: 1px solid #ffc107; border-radius: 6px; }
.iv-empty { color: #888; font-style: italic; }
.iv-zoom-modal { position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 99999; display: flex; align-items: center; justify-content: center; }
.iv-zoom-modal img { max-width: 90vw; max-height: 90vh; border-radius: 6px; box-shadow: 0 8px 40px rgba(0,0,0,.6); }
#iv-zoom-close { position: absolute; top: 18px; right: 24px; background: none; border: none; color: #fff; font-size: 36px; cursor: pointer; line-height: 1; }

/* ── Registration ── */
.iv-reg-box { background:#f9f9f9; border:1px solid #ddd; border-radius:8px; padding:28px 32px; max-width:480px; margin:0 auto; }
.iv-reg-box h3 { margin:0 0 20px; font-size:18px; }
.iv-reg-box .iv-form-row { margin-bottom:14px; }
.iv-reg-box label { display:block; font-size:13px; font-weight:600; margin-bottom:4px; color:#333; }
.iv-reg-box input { width:100%; padding:9px 11px; border:1px solid #ccc; border-radius:4px; font-size:14px; box-sizing:border-box; }
.iv-reg-box input:focus { border-color:#2271b1; outline:none; box-shadow:0 0 0 2px rgba(34,113,177,.15); }
.iv-btn-full { width:100%; padding:11px; font-size:15px; margin-top:6px; }
.iv-pw-strength { font-size:12px; font-weight:600; margin-top:4px; min-height:16px; }
.iv-reg-login-link { text-align:center; font-size:13px; color:#666; margin-top:16px; }
.iv-reg-notice { padding:14px 18px; border-radius:6px; margin-bottom:20px; font-size:14px; }
.iv-reg-notice.success { background:#d4edda; border:1px solid #a3d9a5; color:#155724; }
.iv-reg-notice.error   { background:#f8d7da; border:1px solid #f5c2c7; color:#842029; }
.iv-reg-success-icon { font-size:52px; color:#0a6b27; text-align:center; margin-bottom:12px; }
#iv-reg-success-wrap { text-align:center; }
#iv-reg-success-wrap p { color:#444; line-height:1.6; }
.iv-reg-resend { font-size:13px; color:#666; }
.iv-btn-link { background:none; border:none; color:#2271b1; cursor:pointer; font-size:inherit; text-decoration:underline; padding:0; }
.iv-btn-link:hover { color:#135e96; }
.iv-status-pill { display:inline-block; padding:2px 10px; border-radius:12px; font-size:12px; font-weight:600; }
.iv-status-pill.active    { background:#d4edda; color:#155724; }
.iv-status-pill.pending   { background:#fff3cd; color:#856404; }
.iv-status-pill.suspended { background:#f8d7da; color:#842029; }

/* ── File picker ── */
.iv-file-row { margin-bottom: 10px; }
.iv-file-btns { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.iv-btn-file { flex: 1; min-width: 140px; padding: 10px; font-size: 14px; text-align: center; background: #f0f6fc; border-color: #2271b1; color: #2271b1; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; user-select: none; }
.iv-btn-file:hover { background: #dbeafe; }
.iv-file-name { font-size: 12px; color: #666; font-style: italic; padding: 2px 0; }
@media (max-width: 480px) {
  .iv-file-btns { flex-direction: column; }
  .iv-btn-file { width: 100%; }
}

.iv-file-row { margin-bottom: 10px; }
/* Hide input but keep it accessible - display:none breaks label clicks on some mobile browsers */
.iv-file-hidden {
  position: absolute;
  width: 1px; height: 1px;
  opacity: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  pointer-events: none;
}
.iv-file-btns { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.iv-btn-file { flex: 1; min-width: 140px; padding: 10px; font-size: 14px; text-align: center; background: #f0f6fc; border-color: #2271b1; color: #2271b1; cursor: pointer; display: inline-block; }
.iv-btn-file:hover { background: #dbeafe; }
.iv-file-name { font-size: 12px; color: #666; font-style: italic; padding: 2px 0; min-height: 18px; }
@media (max-width: 480px) {
  .iv-file-btns { flex-direction: column; }
  .iv-btn-file { width: 100%; text-align: center; }
}