/* ═══════════════════════════════════════════════════════════════════════════
   drinkuwu · convention sales  –  Light Mode  (drinkuwu.com style)
   Font: Nunito · Primary: #ff6b9d · Secondary: #4ecdc4 · BG: #f0f2f8
   ═══════════════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,400;0,600;0,700;0,800;0,900;1,700&display=swap');

/* ── Design Tokens ─────────────────────────────────────────────────────────── */
:root {
  /* Backgrounds */
  --bg:        #f0f2f8;
  --surface:   #ffffff;
  --surface-2: #f7f8ff;
  --border:    rgba(0, 0, 0, .08);
  --border-solid: #e5e7f2;

  /* Text */
  --text:      #1a1a2e;
  --text-dim:  #6b6b8a;
  --text-mute: #a8a8c0;

  /* Primary – pink */
  --pink:        #ff6b9d;
  --pink-dark:   #e84f84;
  --pink-light:  #ff94bb;
  --pink-bg:     #fff0f6;
  --pink-border: #ffd0e5;

  /* Secondary – mint */
  --mint:        #4ecdc4;
  --mint-dark:   #38b2aa;
  --mint-bg:     #edfaf9;

  /* Feedback */
  --danger:      #ff4757;
  --danger-bg:   #fff0f1;
  --warn:        #ffbe00;
  --warn-bg:     #fffbec;
  --ok:          #2ed573;
  --ok-bg:       #edfaf2;

  /* Shadows */
  --shadow-xs:   0 1px 4px rgba(0, 0, 0, .06);
  --shadow-sm:   0 4px 20px rgba(0, 0, 0, .08);
  --shadow:      0 8px 32px rgba(0, 0, 0, .10), 0 2px 8px rgba(255, 107, 157, .06);
  --shadow-lg:   0 16px 48px rgba(0, 0, 0, .12), 0 4px 16px rgba(255, 107, 157, .10);
  --shadow-pink: 0 6px 22px rgba(255, 107, 157, .40);
  --shadow-mint: 0 6px 22px rgba(78, 205, 196, .35);

  /* Radii */
  --r-sm:   10px;
  --r:      20px;
  --r-lg:   28px;
  --r-pill: 999px;

  /* Layout */
  --topbar-h: 60px;
  --nav-h:    68px;
}

/* ── Reset ─────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; display: block; }
button { cursor: pointer; }
a { color: inherit; }

/* ── Base Body ─────────────────────────────────────────────────────────────── */
body {
  font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  padding-bottom: calc(var(--nav-h) + 20px);
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
  position: relative;
}

/* ── Bubble / Blob Decoration ──────────────────────────────────────────────── */
.bubble-deco {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.bubble-deco::before,
.bubble-deco::after {
  content: '';
  position: absolute;
  border-radius: 50%;
}
.bubble-deco::before {
  width: 520px;
  height: 520px;
  background: radial-gradient(circle at 30% 30%, rgba(255, 107, 157, .22) 0%, transparent 68%);
  top: -180px;
  right: -140px;
}
.bubble-deco::after {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle at 60% 60%, rgba(78, 205, 196, .20) 0%, transparent 68%);
  bottom: 40px;
  left: -120px;
}

/* ── Topbar ────────────────────────────────────────────────────────────────── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--topbar-h);
  background: var(--surface);
  box-shadow: 0 1px 0 var(--border-solid), 0 2px 12px rgba(0, 0, 0, .05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  gap: 12px;
}

.brand {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--pink);
  text-decoration: none;
  letter-spacing: -.5px;
  flex-shrink: 0;
}
.brand span {
  color: var(--text-dim);
  font-weight: 600;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 0;
}

.con-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--pink-bg);
  color: var(--pink-dark);
  font-size: .75rem;
  font-weight: 800;
  padding: 5px 13px;
  border-radius: var(--r-pill);
  text-decoration: none;
  white-space: nowrap;
  transition: background .15s;
}
.con-pill:hover { background: var(--pink-border); }
.con-pill.warn  { background: var(--warn-bg); color: #a07000; }

.user-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--surface-2);
  color: var(--text-dim);
  font-size: .75rem;
  font-weight: 700;
  padding: 5px 13px;
  border-radius: var(--r-pill);
  white-space: nowrap;
}
.user-pill small { opacity: .7; }

/* ── Bottom Navigation ─────────────────────────────────────────────────────── */
.bottomnav {
  position: fixed;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  display: flex;
  align-items: stretch;
  background: var(--surface);
  border-radius: var(--r-pill);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .14), 0 2px 8px rgba(0, 0, 0, .06);
  padding: 5px;
  gap: 2px;
  max-width: calc(100vw - 24px);
  overflow-x: auto;
  scrollbar-width: none;
}
.bottomnav::-webkit-scrollbar { display: none; }

.bottomnav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  font-size: .65rem;
  font-weight: 800;
  color: var(--text-mute);
  text-decoration: none;
  white-space: nowrap;
  transition: background .15s, color .15s;
  min-width: 52px;
}
.bottomnav a span {
  font-size: 1.15rem;
  line-height: 1.2;
}
.bottomnav a.on {
  background: var(--pink-bg);
  color: var(--pink);
}
.bottomnav a:hover:not(.on) {
  background: var(--surface-2);
  color: var(--text-dim);
}

/* ── Main Container ────────────────────────────────────────────────────────── */
main.container {
  position: relative;
  z-index: 1;
  max-width: 920px;
  margin: 0 auto;
  padding: 16px 16px 0;
}

/* ── Typography ────────────────────────────────────────────────────────────── */
h1 {
  font-size: 1.55rem;
  font-weight: 900;
  color: var(--text);
  margin: 0 0 20px;
  letter-spacing: -.3px;
}
h2 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 16px;
  letter-spacing: -.2px;
}
p { margin: 0 0 12px; }

/* ── Cards ─────────────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  margin-bottom: 20px;
}

/* ── Flash Messages ────────────────────────────────────────────────────────── */
.flash {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: var(--r-sm);
  font-weight: 700;
  font-size: .9rem;
  margin-bottom: 16px;
}
.flash::before { font-size: 1.1rem; }
.flash.err  { background: var(--danger-bg); color: #c0002a; }
.flash.err::before { content: '⚠️'; }
.flash.ok   { background: var(--ok-bg); color: #007a38; }
.flash.ok::before  { content: '✅'; }

/* ── Form Layout ───────────────────────────────────────────────────────────── */
.stack { display: flex; flex-direction: column; gap: 14px; }
.row   { display: flex; gap: 14px; flex-wrap: wrap; }
.row > * { flex: 1; min-width: 120px; }

/* ── Labels ────────────────────────────────────────────────────────────────── */
label:not(.checkbox) {
  display: block;
  font-size: .75rem;
  font-weight: 800;
  color: var(--text-dim);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: .6px;
}

/* ── Text Inputs / Select / Textarea ───────────────────────────────────────── */
/*
   Cover ALL text-like inputs:
   · input:not([type])  → <input> with no type attr (defaults to text in HTML,
     but the [type=text] attribute selector won't match it in CSS)
   · explicit type selectors for all text-like variants
   · select + textarea
*/
input:not([type]),
input[type=text],
input[type=number],
input[type=password],
input[type=email],
input[type=search],
input[type=date],
input[type=tel],
input[type=url],
select,
textarea {
  display: block;
  width: 100%;
  padding: 12px 16px;
  background: var(--surface-2);
  border: 2px solid var(--border-solid);
  border-radius: var(--r-sm);
  font-family: inherit;
  font-size: .95rem;
  font-weight: 600;
  color: var(--text);          /* explicit: fixes invisible text on light bg */
  outline: none;
  transition: border-color .15s, box-shadow .15s, background .15s;
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
}
input:not([type]):focus,
input[type=text]:focus,
input[type=number]:focus,
input[type=password]:focus,
input[type=email]:focus,
input[type=search]:focus,
input[type=date]:focus,
input[type=tel]:focus,
input[type=url]:focus,
select:focus,
textarea:focus {
  border-color: var(--pink);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(255, 107, 157, .15);
}
input::placeholder,
textarea::placeholder {
  color: var(--text-mute);
  font-weight: 400;
}

/* ── Select Arrow ──────────────────────────────────────────────────────────── */
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b6b8a' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

/* ── File Input ────────────────────────────────────────────────────────────── */
input[type=file] {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border: 2px dashed var(--pink-border);
  border-radius: var(--r-sm);
  background: var(--pink-bg);
  color: var(--text);               /* ← Bug 3 Fix */
  cursor: pointer;
  font-family: inherit;
  font-size: .875rem;
  font-weight: 600;
  transition: border-color .15s, background .15s;
}
input[type=file]:hover {
  border-color: var(--pink-light);
  background: var(--surface);
}
input[type=file]::file-selector-button {
  background: var(--pink);
  color: #fff;
  border: none;
  border-radius: var(--r-pill);
  padding: 7px 18px;
  font-family: inherit;
  font-weight: 800;
  font-size: .8rem;
  cursor: pointer;
  margin-right: 14px;
  transition: background .15s;
}
input[type=file]::file-selector-button:hover { background: var(--pink-dark); }

/* ── Checkbox ──────────────────────────────────────────────────────────────── */
label.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .9rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  padding: 4px 0;
}
label.checkbox input[type=checkbox] {
  width: 20px;
  height: 20px;
  accent-color: var(--pink);
  cursor: pointer;
  flex-shrink: 0;
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 28px;
  background: var(--pink);
  color: #ffffff;
  border: 2px solid transparent;
  border-radius: var(--r-pill);
  font-family: inherit;
  font-size: .95rem;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background .15s, transform .1s, box-shadow .15s, border-color .15s;
  box-shadow: var(--shadow-pink);
  -webkit-tap-highlight-color: transparent;
  line-height: 1.2;
}
.btn:hover  { background: var(--pink-dark); box-shadow: 0 10px 28px rgba(255, 107, 157, .50); }
.btn:active { transform: scale(.97); box-shadow: var(--shadow-xs); }

.btn.block { width: 100%; }

.btn.secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-solid);
  box-shadow: var(--shadow-xs);
}
.btn.secondary:hover { background: var(--surface-2); box-shadow: var(--shadow-xs); }

.btn.mint {
  background: var(--mint);
  box-shadow: var(--shadow-mint);
}
.btn.mint:hover { background: var(--mint-dark); }

.btn.danger {
  background: var(--danger);
  box-shadow: 0 6px 20px rgba(255, 71, 87, .35);
}
.btn.danger:hover { background: #e0283a; }

.btn.small { padding: 7px 18px; font-size: .8rem; }

.btn-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

/* ── Category Filter Bar ───────────────────────────────────────────────────── */
.cat-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 14px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.cat-bar::-webkit-scrollbar { display: none; }

.chip {
  flex-shrink: 0;
  padding: 9px 20px;
  border: 2px solid var(--border-solid);
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--text-dim);
  font-family: inherit;
  font-size: .82rem;
  font-weight: 800;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s, box-shadow .15s;
  white-space: nowrap;
}
.chip.on {
  background: var(--pink);
  border-color: var(--pink);
  color: #fff;
  box-shadow: var(--shadow-pink);
}
.chip:hover:not(.on) {
  border-color: var(--pink-light);
  color: var(--pink);
  background: var(--pink-bg);
}

/* ── Product Grid ──────────────────────────────────────────────────────────── */
#product-grid,
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 14px;
}

/* ── Product Tile ──────────────────────────────────────────────────────────── */
.tile {
  background: var(--surface);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .18s, box-shadow .18s;
  user-select: none;
  border: 1.5px solid rgba(0, 0, 0, .04);
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.tile .photo {
  position: relative;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.8rem;
  overflow: hidden;
  background: rgba(255, 255, 255, .5);
}
.tile .photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;   /* Fix 4: show full image, no cropping */
  display: block;
  padding: 4px;          /* small breathing room around the image */
}

/* Counter badge */
.tile .counter {
  position: absolute;
  top: 8px;
  right: 8px;
  background: var(--pink);
  color: #fff;
  font-size: .72rem;
  font-weight: 900;
  min-width: 28px;
  height: 28px;
  border-radius: var(--r-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 7px;
  box-shadow: 0 2px 8px rgba(255, 107, 157, .45);
  border: 2px solid #fff;
}

/* Bundle badge */
.tile.bundle .photo::after {
  content: '🎁 Bundle';
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: var(--mint);
  color: #fff;
  font-size: .65rem;
  font-weight: 900;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  box-shadow: 0 2px 6px rgba(78, 205, 196, .40);
}

.tile .body {
  padding: 10px 12px 8px;
  flex: 1;
}
.tile .name {
  font-size: .85rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--text);
}
.tile .price {
  font-size: .82rem;
  font-weight: 700;
  color: var(--pink);
  margin-top: 3px;
}

/* Action buttons (+/-) */
.tile .actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1.5px solid rgba(0, 0, 0, .06);
}
.tile .actions .btn {
  border-radius: 0;
  padding: 13px 6px;
  box-shadow: none;
  font-size: 1.3rem;
  font-weight: 700;
  background: transparent;
  color: var(--text-dim);
  border: none;
  transition: background .15s, color .15s;
}
.tile .actions .btn.minus:hover { background: var(--danger-bg); color: var(--danger); }
.tile .actions .btn:first-child { border-bottom-left-radius: calc(var(--r) - 1.5px); }
.tile .actions .btn:last-child  {
  border-bottom-right-radius: calc(var(--r) - 1.5px);
  border-left: 1.5px solid rgba(0, 0, 0, .06);
  background: var(--pink-bg);
  color: var(--pink);
  font-size: 1.5rem;
}
.tile .actions .btn:last-child:hover {
  background: var(--pink);
  color: #fff;
}

/* ── Tables ────────────────────────────────────────────────────────────────── */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  background: var(--surface);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
}
thead th {
  background: var(--surface-2);
  padding: 11px 16px;
  text-align: left;
  font-size: .7rem;
  font-weight: 900;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: .6px;
  border-bottom: 1.5px solid var(--border-solid);
  white-space: nowrap;
}
tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-solid);
  color: var(--text);
  vertical-align: middle;
}
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--surface-2); }

tfoot th {
  padding: 11px 16px;
  background: var(--surface-2);
  font-size: .8rem;
  font-weight: 800;
  color: var(--text);
  border-top: 2px solid var(--border-solid);
  white-space: nowrap;
}

.right  { text-align: right; }
.center { text-align: center; }
.muted  { color: var(--text-mute) !important; font-style: italic; }

/* ── Status Tags ───────────────────────────────────────────────────────────── */
.tag {
  display: inline-block;
  padding: 3px 11px;
  border-radius: var(--r-pill);
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .3px;
}
.tag.on     { background: var(--ok-bg);   color: #007a38; }
.tag.off    { background: var(--surface-2); color: var(--text-mute); }
.tag.bundle { background: var(--mint-bg);  color: var(--mint-dark); }

/* ── Image Thumbnail ───────────────────────────────────────────────────────── */
img.thumb {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: var(--r-sm);
  box-shadow: var(--shadow-xs);
}

/* ── Login Page ────────────────────────────────────────────────────────────── */
.login-shell {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.login-card {
  width: 100%;
  max-width: 390px;
  box-shadow: var(--shadow-lg);
  border-radius: var(--r-lg);
}
.login-card h1 {
  font-size: 1.9rem;
  font-weight: 900;
  text-align: center;
  color: var(--pink);
  margin-bottom: 24px;
  letter-spacing: -1px;
}
.login-card h1 span { color: var(--text-dim); font-weight: 700; }

/* ── Select Day / Con Page ─────────────────────────────────────────────────── */
.day-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.day-card {
  background: var(--surface);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  text-decoration: none;
  color: var(--text);
  transition: transform .15s, box-shadow .15s, background .15s, border-color .15s;
  border: 2px solid transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  width: 100%;
}
.day-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--pink-light); }
.day-card.on,
.day-card.active { border-color: var(--pink); background: var(--pink-bg); }
.day-card strong { font-size: .95rem; font-weight: 800; display: block; }
.day-card small   { font-size: .78rem; color: var(--text-dim); margin-top: 2px; display: block; }

/* ── Reports ───────────────────────────────────────────────────────────────── */
.report-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.stat-card {
  background: var(--surface);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  text-align: center;
}
.stat-card .stat-val {
  font-size: 1.7rem;
  font-weight: 900;
  color: var(--pink);
  line-height: 1.1;
}
.stat-card .stat-label {
  font-size: .75rem;
  font-weight: 700;
  color: var(--text-dim);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

/* ── Empty State ───────────────────────────────────────────────────────────── */
.empty {
  text-align: center;
  padding: 56px 24px;
  color: var(--text-dim);
}
.empty .big {
  font-size: 4.5rem;
  margin-bottom: 16px;
  line-height: 1;
}
.empty p {
  font-size: .95rem;
  font-weight: 600;
  color: var(--text-dim);
  margin-bottom: 24px;
}

/* ── Spacer ────────────────────────────────────────────────────────────────── */
.spacer { height: 20px; }

/* ── Scrollbar ─────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-solid); border-radius: 999px; }

/* ── Print / Reports PDF ───────────────────────────────────────────────────── */
@media print {
  .topbar, .bottomnav, .btn, .cat-bar, .bubble-deco { display: none !important; }
  body { padding: 0; background: #fff; color: #000; }
  .table-wrap { box-shadow: none; border: 1px solid #ddd; }
  main.container { max-width: 100%; padding: 0; }
  thead th { background: #f0f0f0 !important; }
}

/* ── Responsive Adjustments ─────────────────────────────────────────────────── */
@media (min-width: 480px) {
  #product-grid, .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  }
}

@media (min-width: 640px) {
  .topbar { padding: 0 24px; }
  main.container { padding: 20px 24px 0; }
  .tile .photo { height: 160px; }
}

@media (min-width: 900px) {
  body { padding-bottom: calc(var(--nav-h) + 28px); }
  .card { padding: 28px 32px; }
}

/* ── Hidden (JS helper) ────────────────────────────────────────────────────── */
.hidden { display: none !important; }

/* ── Select fix: ensure text isn't clipped ─────────────────────────────────── */
select {
  min-width: 110px;
}
/* Compact role-select in tables */
.select-role { min-width: 110px; width: auto; }

/* ── Inline flex button groups ─────────────────────────────────────────────── */
.btn-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  justify-content: flex-end;
}
/* Allow form elements in a btn-group to participate in the flex layout */
.btn-group form { display: contents; }

/* ── Password-reset row (inline input + button) ────────────────────────────── */
.pw-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.pw-row input {
  width: 140px !important;   /* compact in table cells */
  min-width: 0;
  padding: 8px 12px;
  font-size: .82rem;
}
.pw-row .btn { flex-shrink: 0; }

/* ── Inactive user rows ────────────────────────────────────────────────────── */
.row-inactive td { opacity: .45; }
.row-inactive:hover td { opacity: .65; }

/* ── Self-tag (du) ─────────────────────────────────────────────────────────── */
.tag-self {
  display: inline-block;
  background: var(--mint-bg);
  color: var(--mint-dark);
  font-size: .65rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--r-pill);
  vertical-align: middle;
}

/* ── Crop Modal ────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fadeIn .18s ease;
}
.modal-overlay[hidden] { display: none !important; }

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  padding: 24px;
  width: 100%;
  max-width: 540px;
  max-height: 90dvh;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
  animation: slideUp .2s ease;
}
.modal-box h2 { margin: 0; font-size: 1.15rem; }

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.crop-wrap {
  flex: 1;
  min-height: 0;
  max-height: 55dvh;
  overflow: hidden;
  border-radius: var(--r-sm);
  background: #111;
}
.crop-wrap img { display: block; max-width: 100%; }

/* Cropper.js brand-colour overrides */
.cropper-line   { background-color: var(--pink) !important; }
.cropper-point  { background-color: var(--pink) !important; }
.cropper-view-box { outline-color: var(--pink) !important; }
.cropper-face   { background-color: rgba(255, 107, 157, .07) !important; }
