/* ── Reset & base ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --brand:    #4f46e5;
  --brand-dk: #3730a3;
  --brand-lt: #eef2ff;
  --success:  #16a34a;
  --danger:   #dc2626;
  --warn:     #d97706;
  --bg:       #f5f6fa;
  --surface:  #ffffff;
  --border:   #e2e5ef;
  --text:     #1e2130;
  --muted:    #6b7280;
  --radius:   12px;
  --shadow:   0 2px 12px rgba(0,0,0,.08);
}

html { font-size: 15px; -webkit-text-size-adjust: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Nav ──────────────────────────────────────────────────── */
.nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  height: 54px;
  display: flex;
  align-items: center;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  user-select: none;
  text-decoration: none;
}
.brand span {
  background: linear-gradient(120deg, #4f46e5 0%, #7c3aed 45%, #ec4899 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.brand svg { flex-shrink: 0; color: #7c3aed; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.nav-link {
  font-size: .8rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  padding: .25rem .5rem;
  border-radius: 5px;
  transition: color .15s, background .15s;
  white-space: nowrap;
}
.nav-link:hover { color: var(--brand); background: var(--brand-lt); }

.nav-admin-btn {
  margin-left: 6px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .8rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  padding: .3rem .7rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: color .15s, border-color .15s;
  white-space: nowrap;
}
.nav-admin-btn:hover { color: var(--brand); border-color: var(--brand); }

/* ── Page wrap ────────────────────────────────────────────── */
.page-wrap {
  width: 100%;
  max-width: 680px;
  margin: 0 auto;
  padding: 20px 16px 40px;
  box-sizing: border-box;
}

/* ── Tabs ─────────────────────────────────────────────────── */
.tabs {
  display: flex;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px;
  gap: 4px;
  margin-bottom: 16px;
}

.tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 12px;
  border: none;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font-size: .875rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, color .15s;
  white-space: nowrap;
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}
.tab:hover { background: var(--bg); color: var(--text); }
.tab-active {
  background: var(--brand) !important;
  color: #fff !important;
  box-shadow: 0 1px 4px rgba(79,70,229,.3);
}
.tab-active:hover { background: var(--brand-dk) !important; }

/* ── Page intro ───────────────────────────────────────────── */
.page-intro {
  padding: 4px 2px 14px;
}
.page-intro-title {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.2;
  margin-bottom: 5px;
}
.page-intro-gradient {
  background: linear-gradient(120deg, #4f46e5 0%, #7c3aed 45%, #ec4899 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.page-intro-desc {
  font-size: .825rem;
  color: var(--muted);
  line-height: 1.55;
}
.page-intro-desc strong {
  color: var(--text);
  font-weight: 700;
}

.tab-content { /* no extra wrapper styles needed */ }

/* ── Card ─────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

/* ── Field groups ─────────────────────────────────────────── */
.field-group {
  padding: 14px 16px 0;
}
.field-group:last-of-type { padding-bottom: 0; }

.field-label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 6px;
}
.label-hint {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: #9ca3af;
}

.field-inp {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: .9375rem;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.field-inp:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  background: #fff;
}
.field-inp-sub {
  margin-top: 6px;
  font-size: .8125rem;
  height: 36px;
  background: #fafafa;
  color: var(--muted);
}
.field-inp-sub:focus { color: var(--text); background: #fff; }

.field-ta {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: .9375rem;
  font-family: inherit;
  color: var(--text);
  background: var(--bg);
  resize: vertical;
  min-height: 100px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.field-ta:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  background: #fff;
}

/* ── From / To row ────────────────────────────────────────── */
.from-to-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  padding: 14px 16px 0;
}

/* strip all padding from field-groups inside the row — the row handles spacing */
.from-to-row .field-group {
  padding: 0;
}

/* ── Create card ──────────────────────────────────────────── */
.create-card { }

.create-error {
  padding: 0 16px;
  margin-top: 10px;
}

/* ── Create footer ────────────────────────────────────────── */
.create-footer {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  margin-top: 14px;
}

.footer-options {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.pass-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0 10px;
  background: var(--bg);
  height: 42px;
  transition: border-color .15s;
}
.pass-wrap:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  background: #fff;
}
.pass-ico { flex-shrink: 0; color: var(--muted); }
.pass-inp {
  flex: 1;
  border: none;
  background: transparent;
  font-size: .875rem;
  color: var(--text);
  outline: none;
  min-width: 0;
}

.exp-sel {
  height: 42px;
  padding: 0 10px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: .875rem;
  color: var(--text);
  background: var(--bg);
  outline: none;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
}
.exp-sel:focus { border-color: var(--brand); }

/* ── Buttons ──────────────────────────────────────────────── */
.btn-share {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  height: 44px;
  padding: 0 20px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, transform .1s;
}
.btn-share:hover  { background: var(--brand-dk); }
.btn-share:active { transform: scale(.97); }
.btn-share:disabled { opacity: .6; cursor: not-allowed; }

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 18px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s;
  flex-shrink: 0;
}
.btn-primary:hover { background: var(--brand-dk); }
.btn-primary.full-width { width: 100%; margin-top: 10px; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 16px;
  background: var(--brand-lt);
  color: var(--brand);
  border: 1.5px solid #c7d2fe;
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s;
}
.btn-secondary:hover { background: #e0e7ff; }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 16px;
  background: transparent;
  color: var(--muted);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.btn-outline:hover { border-color: var(--brand); color: var(--brand); }

/* ── Dropzone ─────────────────────────────────────────────── */
.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 20px 16px;
  border: 2px dashed var(--border);
  border-radius: 8px;
  background: var(--bg);
  cursor: pointer;
  text-align: center;
  transition: border-color .15s, background .15s;
  color: var(--muted);
}
.dropzone:hover, .dropzone.drag-over {
  border-color: var(--brand);
  background: var(--brand-lt);
  color: var(--brand);
}
.drop-text { font-size: .875rem; }
.drop-text strong { color: var(--text); }
.drop-link { color: var(--brand); text-decoration: underline; }
.drop-hint { font-size: .75rem; color: #9ca3af; }

/* ── Chips ────────────────────────────────────────────────── */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px 4px 10px;
  background: var(--brand-lt);
  border: 1px solid #c7d2fe;
  border-radius: 20px;
  font-size: .8rem;
  max-width: 220px;
  position: relative;
  overflow: hidden;
}
.chip-err { background: #fef2f2; border-color: #fca5a5; flex-wrap: wrap; }
.chip-err-msg {
  flex-basis: 100%;
  font-size: .72rem;
  color: var(--danger);
  margin-top: 3px;
  line-height: 1.35;
  word-break: break-word;
}
.chip-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.chip-size { color: var(--muted); white-space: nowrap; flex-shrink: 0; }
.chip-rm {
  background: none; border: none; cursor: pointer;
  color: var(--muted); font-size: 1rem; line-height: 1;
  padding: 0 2px; flex-shrink: 0;
}
.chip-rm:hover { color: var(--danger); }
.chip-bar {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 2px; background: #c7d2fe;
}
.chip-fill { height: 100%; background: var(--brand); transition: width .2s; }

/* ── Progress ─────────────────────────────────────────────── */
.prog-wrap { margin-top: 8px; }
.prog-row  { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.prog-lbl  { font-size: .8rem; color: var(--muted); }
.prog-pct  { font-size: .8rem; color: var(--muted); }
.prog-ok   { color: var(--success); }
.prog-err  { color: var(--danger); }
.prog-track { height: 4px; background: var(--border); border-radius: 2px; overflow: hidden; }
.prog-fill  { height: 100%; background: var(--brand); border-radius: 2px; transition: width .3s; }
.prog-fill-ok { background: var(--success); }

/* ── Success card ─────────────────────────────────────────── */
.success-card {
  text-align: center;
  padding: 32px 24px;
}
.success-icon {
  width: 60px; height: 60px;
  background: #dcfce7;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
  color: var(--success);
}
.success-title { font-size: 1.25rem; font-weight: 700; margin-bottom: 4px; }
.success-sub   { color: var(--muted); font-size: .9rem; margin-bottom: 20px; }

.success-code-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 14px 20px;
  margin-bottom: 10px;
}
.success-code {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: .15em;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}
.btn-copy {
  height: 36px;
  padding: 0 14px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 7px;
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s;
  flex-shrink: 0;
}
.btn-copy:hover { background: var(--brand-dk); }

.success-exp {
  font-size: .8rem;
  color: var(--muted);
  margin-bottom: 20px;
}
.success-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Open panel ───────────────────────────────────────────── */
.open-panel { display: flex; flex-direction: column; gap: 16px; }

.code-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.code-section .field-label { margin-bottom: 10px; }

.code-row {
  display: flex;
  gap: 8px;
  width: 100%;
  overflow: hidden;
}
.code-inp-lg {
  flex: 1;
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.code-inp-lg:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  background: #fff;
}
.code-inp-lg::placeholder { font-weight: 400; letter-spacing: .04em; color: #9ca3af; font-size: 1rem; }

/* ── View card ────────────────────────────────────────────── */
.view-card { }

.view-hdr {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.view-from-to {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .9375rem;
  font-weight: 600;
  margin-bottom: 6px;
}
.view-from { color: var(--text); }
.view-arrow { color: var(--muted); }
.view-to   { color: var(--brand); }

.view-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.view-code-badge {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  padding: 2px 8px;
  border-radius: 4px;
}
.view-exp { font-size: .8rem; color: var(--muted); }

.view-body { padding: 16px; }

.view-text-wrap {
  position: relative;
  margin-bottom: 14px;
}

.view-text {
  white-space: pre-wrap;
  word-break: break-word;
  font-size: .9375rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  padding-right: 40px;
}

.btn-copy-text {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--muted);
  cursor: pointer;
  transition: color .15s, border-color .15s, background .15s;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.btn-copy-text:hover { color: var(--brand); border-color: var(--brand); background: var(--brand-lt); }
.btn-copy-text-ok { color: var(--success) !important; border-color: var(--success) !important; background: #dcfce7 !important; }

.files-label {
  font-size: .8rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 8px;
}

.view-files { display: flex; flex-direction: column; gap: 8px; }

.view-file {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.vf-info { flex: 1; min-width: 0; }
.vf-name { font-size: .875rem; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vf-size { font-size: .75rem; color: var(--muted); margin-top: 1px; }

.btn-dl {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: .8rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background .15s;
}
.btn-dl:hover { background: var(--brand-dk); }

.btn-dl-all {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 38px;
  margin-top: 10px;
  background: var(--brand-lt);
  color: var(--brand);
  border: 1.5px solid #c7d2fe;
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s;
}
.btn-dl-all:hover { background: #e0e7ff; }

/* ── Password card ────────────────────────────────────────── */
.pass-card {
  text-align: center;
  padding: 28px 20px;
}
.pass-icon {
  width: 52px; height: 52px;
  background: #fef3c7;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px;
  color: var(--warn);
}
.pass-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 4px; }
.pass-sub   { color: var(--muted); font-size: .875rem; margin-bottom: 16px; }
.pass-unlock-row {
  display: flex;
  gap: 8px;
  max-width: 360px;
  margin: 0 auto;
}
.pass-unlock-row .field-inp { flex: 1; }

/* ── Auth card ────────────────────────────────────────────── */
.auth-card {
  text-align: center;
  padding: 36px 24px;
  margin-top: 20px;
}
.auth-icon {
  width: 64px; height: 64px;
  background: var(--brand-lt);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
  color: var(--brand);
}
.auth-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 6px; }
.auth-sub   { color: var(--muted); font-size: .9rem; margin-bottom: 20px; }
.auth-card .field-inp { margin-bottom: 10px; }

/* ── Loading ──────────────────────────────────────────────── */
.loading-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  color: var(--muted);
  font-size: .9rem;
}
.spinner {
  width: 20px; height: 20px;
  border: 2.5px solid var(--border);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Notices ──────────────────────────────────────────────── */
.notice {
  padding: 10px 14px;
  border-radius: 8px;
  font-size: .875rem;
  line-height: 1.4;
}
.notice-error {
  background: #fef2f2;
  color: var(--danger);
  border: 1px solid #fca5a5;
}
.notice-info {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

/* ── Implicit consent notice ──────────────────────────────── */
.tnc-implicit {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: .72rem;
  color: var(--muted);
  line-height: 1.5;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 7px 10px;
}
.tnc-shield-ico {
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--brand);
  opacity: .65;
}
.tnc-implicit strong { color: var(--text); font-weight: 600; }
.tnc-link {
  color: var(--brand);
  text-decoration: underline;
  font-weight: 500;
}
.tnc-link:hover { color: var(--brand-dk); }

/* ── Textarea wrap + clear button ────────────────────────── */
.ta-wrap {
  position: relative;
}
.ta-wrap .field-ta {
  padding-right: 30px;
}
.btn-clear-ta {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--border);
  border: none;
  border-radius: 50%;
  color: var(--muted);
  font-size: .85rem;
  line-height: 1;
  cursor: pointer;
  transition: background .15s, color .15s;
  padding: 0;
}
.btn-clear-ta:hover { background: #d1d5db; color: var(--text); }

/* ── Revoke ───────────────────────────────────────────────── */
.revoke-idle-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.revoke-idle-hint {
  font-size: .8rem;
  color: var(--muted);
}
/* ── Report content button ───────────────────────────────── */
.report-wrap {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.btn-report-toggle {
  background: none;
  border: 1px solid #fca5a5;
  color: #b91c1c;
  font-size: .78rem;
  font-weight: 600;
  padding: .3rem .75rem;
  border-radius: 6px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.btn-report-toggle:hover { background: #fef2f2; }
.report-form {
  margin-top: 12px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 14px 16px;
}
.report-title {
  font-size: .85rem;
  font-weight: 700;
  color: #b91c1c;
  margin-bottom: 6px;
}
.report-desc {
  font-size: .78rem;
  color: #7f1d1d;
  margin-bottom: 10px;
  line-height: 1.5;
}
.report-textarea {
  width: 100%;
  padding: .5rem .75rem;
  border: 1.5px solid #fca5a5;
  border-radius: 7px;
  font-size: .875rem;
  font-family: inherit;
  resize: vertical;
  outline: none;
  background: #fff;
  color: var(--text);
  transition: border-color .15s;
}
.report-textarea:focus { border-color: #ef4444; }
.report-actions {
  display: flex;
  gap: .5rem;
  margin-top: 10px;
  flex-wrap: wrap;
}
.btn-report-submit {
  background: #ef4444;
  color: #fff;
  border: none;
  padding: .4rem .9rem;
  border-radius: 7px;
  font-size: .82rem;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .15s;
}
.btn-report-submit:hover { opacity: .85; }
.btn-report-submit:disabled { opacity: .5; cursor: not-allowed; }
.btn-report-cancel {
  background: none;
  border: 1px solid #fca5a5;
  color: #b91c1c;
  padding: .4rem .9rem;
  border-radius: 7px;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
}
.btn-report-cancel:hover { background: #fff; }
.report-msg-ok {
  margin-top: 8px;
  padding: .5rem .75rem;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  font-size: .82rem;
  color: #15803d;
  font-weight: 600;
}
.report-msg-error {
  margin-top: 8px;
  padding: .5rem .75rem;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  font-size: .82rem;
  color: #b91c1c;
}

.btn-revoke {
  background: none;
  border: none;
  padding: 0;
  font-size: .8rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: underline;
  cursor: pointer;
  transition: color .15s;
}
.btn-revoke:hover { color: var(--danger); }

.revoke-confirm {
  margin-top: 14px;
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 8px;
  padding: 12px 14px;
  text-align: left;
}
.revoke-confirm-text {
  display: block;
  font-size: .85rem;
  color: #991b1b;
  margin-bottom: 10px;
  line-height: 1.5;
}
.revoke-confirm-btns {
  display: flex;
  gap: 8px;
}
.btn-revoke-yes {
  height: 34px;
  padding: 0 14px;
  background: var(--danger);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s;
}
.btn-revoke-yes:hover { background: #b91c1c; }
.btn-revoke-yes:disabled { opacity: .6; cursor: not-allowed; }
.btn-revoke-cancel {
  height: 34px;
  padding: 0 14px;
  background: transparent;
  color: var(--muted);
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-size: .8rem;
  font-weight: 500;
  cursor: pointer;
  transition: color .15s, border-color .15s;
}
.btn-revoke-cancel:hover { color: var(--text); border-color: var(--text); }

/* ── Hamburger ────────────────────────────────────────────── */
.nav-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-left: auto;
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: 7px;
  color: var(--muted);
  cursor: pointer;
  flex-shrink: 0;
  transition: color .15s, border-color .15s;
  -webkit-tap-highlight-color: transparent;
}
.nav-hamburger:hover { color: var(--brand); border-color: var(--brand); }

/* ── Cookie banner (floating strip) ──────────────────────── */
#cookie-banner {
  position: fixed;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 32px);
  max-width: 624px;
  background: rgba(30,33,48,.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  box-shadow: 0 4px 24px rgba(0,0,0,.22);
  padding: 8px 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  z-index: 9999;
  animation: cookie-in .3s ease;
}
@keyframes cookie-in {
  from { opacity: 0; transform: translateX(-50%) translateY(12px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
#cookie-banner.cookie-hide {
  animation: cookie-out .3s ease forwards;
}
@keyframes cookie-out {
  to { opacity: 0; transform: translateX(-50%) translateY(12px); }
}
.cookie-text {
  font-size: .72rem;
  color: rgba(255,255,255,.75);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cookie-link {
  color: #a5b4fc;
  text-decoration: underline;
}
.cookie-btn {
  flex-shrink: 0;
  height: 26px;
  padding: 0 10px;
  background: rgba(255,255,255,.15);
  color: #fff;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 20px;
  font-size: .7rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s;
}
.cookie-btn:hover { background: rgba(255,255,255,.25); }
@media (max-width: 540px) {
  #cookie-banner { width: calc(100% - 24px); padding: 8px 12px; gap: 8px; }
  .cookie-text { white-space: normal; font-size: .7rem; }
}

/* ── Mobile nav (hamburger) ───────────────────────────────── */
@media (max-width: 640px) {
  .nav-hamburger { display: inline-flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: 54px;
    left: 0;
    right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 6px 20px rgba(0,0,0,.08);
    flex-direction: column;
    align-items: stretch;
    padding: 8px 12px 12px;
    gap: 2px;
    z-index: 99;
    margin-left: 0;
  }
  .nav-links.nav-open { display: flex; }
  .nav-link {
    font-size: .9rem;
    padding: .55rem .75rem;
    border-radius: 8px;
    color: var(--muted);
  }
  .nav-link:hover { background: var(--bg); color: var(--brand); }
  .nav-admin-btn {
    margin-left: 0;
    margin-top: 4px;
    width: 100%;
    justify-content: flex-start;
    padding: .55rem .75rem;
    border-radius: 8px;
    font-size: .9rem;
  }
}

/* ── Responsive ───────────────────────────────────────────── */
@media (min-width: 480px) {
  .from-to-row {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .from-to-row .field-group {
    padding: 0;
  }
  .footer-options {
    flex: 1;
    min-width: 0;
  }
  .btn-share {
    width: auto;
    flex-shrink: 0;
  }
}

@media (min-width: 600px) {
  .page-wrap { padding: 28px 24px 60px; }
}

@media (min-width: 720px) {
  .page-wrap { padding: 32px 28px 60px; }
}

/* ── Prevent iOS/Android zoom on input focus ──────────────── */
@media (max-width: 767px) {
  input, textarea, select {
    font-size: 16px !important;
  }
}
