/* ============================================================
   Innovamed · Supervisión Almacén
   Estilos compartidos por todas las páginas del sistema.
   ============================================================ */

:root{
  --bg:#0d0f12;
  --surface:#13161b;
  --surface2:#1a1e25;
  --surface3:#21262f;
  --border:#2a2f3a;
  --border2:#363c4a;
  --accent:#2e7cf6;
  --accent-dim:#1a4a9e;
  --accent-glow:rgba(46,124,246,0.15);
  --green:#22c55e;
  --green-bg:rgba(34,197,94,0.1);
  --amber:#f59e0b;
  --amber-bg:rgba(245,158,11,0.1);
  --red:#ef4444;
  --red-bg:rgba(239,68,68,0.1);
  --text:#e8eaf0;
  --text2:#8b92a8;
  --text3:#555d70;
  --font:"DM Sans",sans-serif;
  --mono:"DM Mono",monospace;
  --r:10px;
  --r-lg:14px;
}

*{box-sizing:border-box;margin:0;padding:0}
html,body{
  height:100%;
  background:var(--bg);
  color:var(--text);
  font-family:var(--font);
  font-size:14px;
  line-height:1.6;
  overflow-x:hidden;
}
input,textarea,select,button{font-family:var(--font)}

::-webkit-scrollbar{width:4px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb{background:var(--border2);border-radius:4px}

/* ---------- Animaciones globales ---------- */
@keyframes fadeIn{
  from{opacity:0;transform:translateY(6px)}
  to{opacity:1;transform:translateY(0)}
}
.fade-in{animation:fadeIn 0.3s ease}

/* ============================================================
   LOGIN
   ============================================================ */
.login-page{
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  background:var(--bg);
  background-image:
    radial-gradient(ellipse 60% 40% at 70% 20%,rgba(46,124,246,0.07) 0%,transparent 60%),
    radial-gradient(ellipse 40% 50% at 10% 80%,rgba(46,124,246,0.04) 0%,transparent 60%);
  position:relative;
  overflow:hidden;
}
.login-page::before{
  content:"";
  position:absolute;
  inset:0;
  background-image:
    linear-gradient(var(--border) 1px,transparent 1px),
    linear-gradient(90deg,var(--border) 1px,transparent 1px);
  background-size:40px 40px;
  opacity:0.3;
  pointer-events:none;
}
.login-card{
  background:var(--surface);
  border:0.5px solid var(--border2);
  border-radius:var(--r-lg);
  padding:2.5rem;
  width:400px;
  position:relative;
  z-index:1;
  box-shadow:0 0 60px rgba(46,124,246,0.08),0 20px 40px rgba(0,0,0,0.4);
}
.login-logo-wrap{text-align:center;margin-bottom:1.75rem;padding:0.5rem 0}
.login-logo-wrap img{height:50px;width:auto;filter:brightness(0) invert(1);opacity:0.9}
.login-divider{height:0.5px;background:var(--border);margin-bottom:1.5rem}
.login-card h2{font-size:17px;font-weight:500;margin-bottom:0.2rem}
.login-card .sub{font-size:12px;color:var(--text3);margin-bottom:1.75rem}
.field-group{display:flex;flex-direction:column;gap:4px;margin-bottom:1rem}
.field-group label{font-size:10px;font-weight:500;color:var(--text3);text-transform:uppercase;letter-spacing:0.06em}
.field-group input{
  background:var(--surface2);
  border:0.5px solid var(--border2);
  border-radius:var(--r);
  padding:10px 12px;
  color:var(--text);
  font-size:14px;
  transition:border-color 0.15s;
}
.field-group input:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-glow)}
.btn-login{
  width:100%;
  background:var(--accent);
  border:none;
  border-radius:var(--r);
  padding:11px;
  color:#fff;
  font-size:14px;
  font-weight:500;
  cursor:pointer;
  transition:background 0.15s,transform 0.1s;
  margin-top:0.5rem;
}
.btn-login:hover{background:#3d8cf8}
.btn-login:active{transform:scale(0.98)}
.login-error{
  background:var(--red-bg);
  border:0.5px solid rgba(239,68,68,0.3);
  color:var(--red);
  border-radius:var(--r);
  padding:8px 12px;
  font-size:13px;
  margin-bottom:1rem;
  display:none;
}
.login-error.show{display:block}
.login-hint{font-size:11px;color:var(--text3);text-align:center;margin-top:1.25rem}

/* ============================================================
   TOPBAR (presente en todas las páginas internas)
   ============================================================ */
.app-shell{display:flex;flex-direction:column;min-height:100vh}
.topbar{
  background:var(--surface);
  border-bottom:0.5px solid var(--border);
  padding:0 1.5rem;
  height:56px;
  display:flex;
  align-items:center;
  gap:1rem;
  position:sticky;
  top:0;
  z-index:100;
}
.topbar-logo{
  height:26px;
  width:auto;
  filter:brightness(0) invert(1);
  opacity:0.88;
  margin-right:auto;
  cursor:pointer;
}
.nav-tabs{display:flex;gap:2px}
.nav-tab{
  padding:6px 14px;
  border-radius:6px;
  border:none;
  background:transparent;
  color:var(--text2);
  font-size:13px;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:6px;
  transition:all 0.15s;
  font-family:var(--font);
  text-decoration:none;
}
.nav-tab:hover{background:var(--surface2);color:var(--text)}
.nav-tab.active{background:var(--surface2);color:var(--accent)}
.nav-tab .dot{width:5px;height:5px;border-radius:50%;background:var(--accent);display:none}
.nav-tab.active .dot{display:block}
.topbar-user{
  display:flex;
  align-items:center;
  gap:8px;
  padding:4px 10px;
  border-radius:var(--r);
  border:0.5px solid var(--border);
  cursor:pointer;
}
.topbar-user:hover{background:var(--surface2)}
.user-avatar{
  width:26px;
  height:26px;
  border-radius:50%;
  background:var(--accent-dim);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:11px;
  font-weight:600;
  color:var(--accent);
}
.topbar-user span{font-size:12px;color:var(--text2)}

/* ============================================================
   CONTENEDOR PRINCIPAL
   ============================================================ */
.main-content{
  flex:1;
  padding:1.5rem;
  max-width:760px;
  margin:0 auto;
  width:100%;
}
.page-header{margin-bottom:1.5rem}
.page-header h2{font-size:20px;font-weight:500}
.page-header p{font-size:13px;color:var(--text2);margin-top:2px}

.edit-banner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  background:rgba(245,158,11,0.08);
  border:0.5px solid rgba(245,158,11,0.35);
  border-left:3px solid #f59e0b;
  border-radius:8px;
  padding:10px 14px;
  margin-bottom:1.25rem;
  font-size:12px;
  color:var(--text);
  flex-wrap:wrap;
}
.edit-banner strong{font-weight:600;color:#fbbf24}
.edit-banner.hidden{display:none}
.edit-banner-btn{font-size:11px;padding:5px 12px}

/* ============================================================
   DASHBOARD / SELECCIÓN
   ============================================================ */
.dash-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
  margin-top:1rem;
}
.dash-card{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  padding:2rem 1.5rem;
  cursor:pointer;
  text-decoration:none;
  color:inherit;
  display:flex;
  flex-direction:column;
  gap:0.75rem;
  transition:all 0.2s ease;
  position:relative;
  overflow:hidden;
}
.dash-card::before{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(135deg,rgba(46,124,246,0.06) 0%,transparent 50%);
  opacity:0;
  transition:opacity 0.2s;
  pointer-events:none;
}
.dash-card:hover{
  border-color:var(--border2);
  transform:translateY(-2px);
  box-shadow:0 8px 30px rgba(0,0,0,0.3),0 0 0 1px var(--accent-glow);
}
.dash-card:hover::before{opacity:1}
.dash-card-icon{
  width:48px;
  height:48px;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:22px;
  margin-bottom:0.5rem;
}
.dash-card.primary .dash-card-icon{background:rgba(46,124,246,0.12);color:var(--accent)}
.dash-card.secondary .dash-card-icon{background:rgba(34,197,94,0.12);color:var(--green)}
.dash-card h3{font-size:16px;font-weight:500}
.dash-card p{font-size:12px;color:var(--text2);line-height:1.5}
.dash-card .arrow{
  font-size:14px;
  color:var(--text3);
  margin-top:auto;
  display:flex;
  align-items:center;
  gap:4px;
  font-family:var(--mono);
}
.dash-welcome{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  padding:1.25rem 1.5rem;
  margin-bottom:1.5rem;
  display:flex;
  align-items:center;
  gap:1rem;
}
.dash-welcome-avatar{
  width:42px;
  height:42px;
  border-radius:50%;
  background:var(--accent-dim);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:15px;
  font-weight:600;
  color:var(--accent);
  flex-shrink:0;
}
.dash-welcome-text .greeting{font-size:14px;font-weight:500}
.dash-welcome-text .role{font-size:11px;color:var(--text3);margin-top:2px;font-family:var(--mono);text-transform:uppercase;letter-spacing:0.06em}

/* ============================================================
   CARDS (bloques del formulario)
   ============================================================ */
.card{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  overflow:hidden;
  margin-bottom:1rem;
}
.card-header{
  display:flex;
  align-items:center;
  gap:10px;
  padding:0.875rem 1.25rem;
  background:var(--surface2);
  border-bottom:0.5px solid var(--border);
  cursor:pointer;
  user-select:none;
}
.card-header-icon{
  width:28px;
  height:28px;
  border-radius:6px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:14px;
  flex-shrink:0;
}
.card-header h3{font-size:13px;font-weight:500;flex:1}
.card-badge{
  font-size:10px;
  padding:2px 8px;
  border-radius:20px;
  background:var(--surface3);
  color:var(--text3);
  border:0.5px solid var(--border);
  font-family:var(--mono);
}
.card-badge.has-issues{background:rgba(239,68,68,0.1);color:var(--red);border-color:rgba(239,68,68,0.3)}
.card-badge.has-warns{background:rgba(245,158,11,0.1);color:var(--amber);border-color:rgba(245,158,11,0.3)}
.card-badge.all-ok{background:rgba(34,197,94,0.1);color:var(--green);border-color:rgba(34,197,94,0.3)}
.chevron{font-size:12px;color:var(--text3);transition:transform 0.2s;margin-left:4px}
.chevron.open{transform:rotate(180deg)}
.card-body{padding:0.25rem 0;display:none}
.card-body.open{display:block}

/* ---------- Items de checklist ---------- */
.chk-item{
  display:grid;
  grid-template-columns:1fr auto;
  align-items:start;
  gap:12px;
  padding:0.6rem 1.25rem;
  border-bottom:0.5px solid var(--border);
}
.chk-item:last-child{border-bottom:none}
.chk-label{font-size:13px;color:var(--text);line-height:1.45;padding-top:2px}
.btn-group{display:flex;gap:3px;flex-shrink:0}
.btn-chk{
  width:30px;
  height:30px;
  border-radius:6px;
  border:0.5px solid var(--border2);
  background:var(--surface2);
  cursor:pointer;
  font-size:13px;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:all 0.12s;
}
.btn-chk:hover{background:var(--surface3)}
.btn-chk.ok.active{background:var(--green-bg);border-color:rgba(34,197,94,0.4)}
.btn-chk.warn.active{background:var(--amber-bg);border-color:rgba(245,158,11,0.4)}
.btn-chk.bad.active{background:var(--red-bg);border-color:rgba(239,68,68,0.4)}
.obs-field{grid-column:1/-1;display:none;padding-bottom:8px}
.obs-field.show{display:block}
.obs-field textarea{
  width:100%;
  background:var(--surface3);
  border:0.5px solid var(--border2);
  border-radius:8px;
  padding:8px 10px;
  color:var(--text);
  font-size:12px;
  resize:vertical;
  min-height:50px;
  line-height:1.5;
}
.obs-field textarea:focus{outline:none;border-color:var(--accent)}
.obs-field textarea::placeholder{color:var(--text3)}

/* ---------- Adjuntar foto por ítem ---------- */
.obs-attach{
  margin-top:10px;
  display:flex;
  flex-direction:column;
  gap:10px;
  padding-top:10px;
  border-top:0.5px dashed var(--border);
}
.btn-attach{
  align-self:flex-start;
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:12px;
  font-weight:500;
  padding:8px 14px;
  border-radius:8px;
  background:var(--accent-glow);
  color:var(--accent);
  border:0.5px solid rgba(46,124,246,0.4);
  cursor:pointer;
  user-select:none;
  font-family:var(--font);
  transition:all 0.15s;
}
.btn-attach:hover{
  background:var(--accent);
  color:#fff;
  border-color:var(--accent);
  transform:translateY(-1px);
}
.btn-attach:active{transform:translateY(0)}
.img-preview:empty{display:none}
.img-preview-wrap{
  position:relative;
  display:inline-block;
  border-radius:8px;
  overflow:hidden;
  border:0.5px solid var(--border2);
  max-width:200px;
}
.img-preview-wrap img{
  display:block;
  width:100%;
  height:auto;
  max-height:140px;
  object-fit:cover;
}
.btn-remove-photo{
  position:absolute;
  top:4px;
  right:4px;
  width:24px;
  height:24px;
  border-radius:50%;
  border:none;
  background:rgba(0,0,0,0.75);
  color:#fff;
  font-size:12px;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
}
.btn-remove-photo:hover{background:var(--red)}

/* ---------- Foto adjunta en el detalle del histórico ---------- */
.issue-photo{
  margin-top:8px;
  border-radius:8px;
  border:0.5px solid var(--border2);
  max-width:220px;
  max-height:160px;
  cursor:pointer;
  display:block;
}
.issue-photo:hover{border-color:var(--accent)}

/* ---------- Grids de información ---------- */
.meta-grid{
  display:grid;
  grid-template-columns:1fr 1fr 1fr;
  gap:10px;
  padding:1.25rem;
}
.meta-grid-2{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  padding:0 1.25rem 1.25rem;
}
.f{display:flex;flex-direction:column;gap:4px}
.f label{font-size:10px;font-weight:500;text-transform:uppercase;letter-spacing:0.06em;color:var(--text3)}
.f input,.f select,.f textarea{
  background:var(--surface2);
  border:0.5px solid var(--border2);
  border-radius:8px;
  padding:8px 10px;
  color:var(--text);
  font-size:13px;
}
.f input:focus,.f textarea:focus{outline:none;border-color:var(--accent)}
.f textarea{resize:vertical;min-height:60px}
.f input::placeholder,.f textarea::placeholder{color:var(--text3)}

/* ---------- Estado general (4 botones) ---------- */
.status-sel{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:8px;
  padding:0 1.25rem 1.25rem;
}
.s-btn{
  border:0.5px solid var(--border);
  background:var(--surface2);
  border-radius:8px;
  padding:8px 6px;
  text-align:center;
  cursor:pointer;
  font-size:11px;
  color:var(--text2);
  line-height:1.4;
  transition:all 0.15s;
}
.s-btn:hover{border-color:var(--border2);background:var(--surface3)}
.s-btn.active.optimo{background:var(--green-bg);border-color:rgba(34,197,94,0.4);color:var(--green)}
.s-btn.active.aceptable{background:rgba(46,124,246,0.1);border-color:rgba(46,124,246,0.4);color:var(--accent)}
.s-btn.active.atencion{background:var(--amber-bg);border-color:rgba(245,158,11,0.4);color:var(--amber)}
.s-btn.active.critico{background:var(--red-bg);border-color:rgba(239,68,68,0.4);color:var(--red)}

/* ---------- Summary strip ---------- */
.summary-strip{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:8px;
  margin-bottom:1rem;
}
.sstat{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r);
  padding:0.75rem;
  text-align:center;
}
.sstat .n{font-size:22px;font-weight:500;font-family:var(--mono)}
.sstat .l{font-size:10px;text-transform:uppercase;letter-spacing:0.06em;color:var(--text3);margin-top:2px}
.sstat.s-total .n{color:var(--text)}
.sstat.s-ok .n{color:var(--green)}
.sstat.s-warn .n{color:var(--amber)}
.sstat.s-bad .n{color:var(--red)}

/* ---------- Fotos ---------- */
.photo-section{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  padding:1.25rem;
  margin-bottom:1rem;
}
.photo-section h4{
  font-size:12px;
  font-weight:500;
  color:var(--text2);
  text-transform:uppercase;
  letter-spacing:0.06em;
  margin-bottom:0.75rem;
}
.photo-note{
  font-size:11px;
  color:var(--text3);
  background:var(--surface2);
  border-radius:8px;
  padding:8px 10px;
  border:0.5px solid var(--border);
  font-family:var(--mono);
  line-height:1.6;
  margin-top:0.5rem;
}
.photo-count{display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap}

/* ---------- Botones inferiores ---------- */
.form-footer{display:flex;gap:10px;margin-top:1.5rem}
.btn{
  display:flex;
  align-items:center;
  gap:7px;
  padding:10px 18px;
  border-radius:var(--r);
  border:0.5px solid var(--border);
  background:var(--surface2);
  color:var(--text2);
  font-size:13px;
  cursor:pointer;
  transition:all 0.15s;
  font-family:var(--font);
  font-weight:500;
  text-decoration:none;
}
.btn:hover{background:var(--surface3);color:var(--text);border-color:var(--border2)}
.btn-primary{flex:1;justify-content:center;background:var(--accent);border-color:transparent;color:#fff;font-weight:500}
.btn-primary:hover{background:#3d8cf8;color:#fff}
.btn-ghost{background:transparent}

/* ============================================================
   HISTÓRICO
   ============================================================ */
.hist-toolbar{display:flex;align-items:center;gap:10px;margin-bottom:1.25rem}
.hist-toolbar input{
  flex:1;
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r);
  padding:8px 12px;
  color:var(--text);
  font-size:13px;
}
.hist-toolbar input:focus{outline:none;border-color:var(--accent)}
.hist-toolbar input::placeholder{color:var(--text3)}
.hist-empty{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  padding:3rem 2rem;
  text-align:center;
}
.hist-empty p{color:var(--text3);font-size:13px}
.hist-list{display:flex;flex-direction:column;gap:8px}
.hist-card{
  background:var(--surface);
  border:0.5px solid var(--border);
  border-radius:var(--r-lg);
  overflow:hidden;
  cursor:pointer;
  transition:border-color 0.15s;
}
.hist-card:hover{border-color:var(--border2)}
.hist-card-header{display:flex;align-items:center;gap:12px;padding:1rem 1.25rem}
.hist-date{
  background:var(--surface2);
  border-radius:6px;
  padding:6px 10px;
  text-align:center;
  flex-shrink:0;
  min-width:56px;
}
.hist-date .d{font-size:18px;font-weight:600;line-height:1;font-family:var(--mono)}
.hist-date .m{font-size:10px;text-transform:uppercase;color:var(--text3);letter-spacing:0.06em}
.hist-info{flex:1}
.hist-info .inspector{font-size:13px;font-weight:500}
.hist-info .meta{font-size:11px;color:var(--text3);margin-top:2px;font-family:var(--mono)}
.hist-badges{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
.badge{font-size:10px;padding:3px 8px;border-radius:20px;font-family:var(--mono)}
.badge-ok{background:var(--green-bg);color:var(--green);border:0.5px solid rgba(34,197,94,0.3)}
.badge-warn{background:var(--amber-bg);color:var(--amber);border:0.5px solid rgba(245,158,11,0.3)}
.badge-bad{background:var(--red-bg);color:var(--red);border:0.5px solid rgba(239,68,68,0.3)}
.badge-status{font-size:11px;padding:4px 10px;border-radius:20px}
.badge-status.optimo{background:var(--green-bg);color:var(--green)}
.badge-status.aceptable{background:rgba(46,124,246,0.1);color:var(--accent)}
.badge-status.atencion{background:var(--amber-bg);color:var(--amber)}
.badge-status.critico{background:var(--red-bg);color:var(--red)}
.btn-card-pdf{
  font-size:10px;
  font-family:var(--font);
  padding:4px 9px;
  border-radius:6px;
  background:var(--accent-glow);
  color:var(--accent);
  border:0.5px solid rgba(46,124,246,0.3);
  cursor:pointer;
  transition:all 0.15s;
  margin-left:4px;
}
.btn-card-pdf:hover{
  background:var(--accent);
  color:#fff;
  border-color:var(--accent);
}

/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.7);
  z-index:200;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:1rem;
  backdrop-filter:blur(4px);
  animation:fadeIn 0.2s ease;
}
.modal-overlay.hidden{display:none}
.modal{
  background:var(--surface);
  border:0.5px solid var(--border2);
  border-radius:var(--r-lg);
  width:100%;
  max-width:680px;
  max-height:85vh;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  box-shadow:0 20px 60px rgba(0,0,0,0.5);
}
.modal-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:1.25rem 1.5rem;
  border-bottom:0.5px solid var(--border);
  flex-shrink:0;
}
.modal-head h3{font-size:15px;font-weight:500}
.modal-head .close-btn{
  width:28px;
  height:28px;
  border-radius:6px;
  border:0.5px solid var(--border);
  background:var(--surface2);
  cursor:pointer;
  font-size:16px;
  color:var(--text2);
  display:flex;
  align-items:center;
  justify-content:center;
}
.modal-head .close-btn:hover{background:var(--surface3);color:var(--text)}
.modal-body{overflow-y:auto;padding:1.5rem;flex:1}
.detail-meta{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:8px;
  margin-bottom:1.25rem;
}
.detail-meta-item{
  background:var(--surface2);
  border-radius:8px;
  padding:10px 12px;
  border:0.5px solid var(--border);
}
.detail-meta-item .key{font-size:10px;text-transform:uppercase;letter-spacing:0.06em;color:var(--text3)}
.detail-meta-item .val{font-size:13px;font-weight:500;margin-top:2px;font-family:var(--mono)}
.detail-section{margin-bottom:1.25rem}
.detail-section h4{
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:0.06em;
  color:var(--text3);
  margin-bottom:0.5rem;
}
.detail-issue{
  display:flex;
  align-items:flex-start;
  gap:8px;
  padding:8px 0;
  border-bottom:0.5px solid var(--border);
}
.detail-issue:last-child{border-bottom:none}
.issue-icon{font-size:14px;flex-shrink:0;padding-top:1px}
.issue-text{font-size:12px;color:var(--text2);line-height:1.5}
.issue-note{font-size:11px;color:var(--text3);margin-top:3px;font-style:italic}
.photo-grid{display:flex;flex-wrap:wrap;gap:8px}
.photo-chip{
  background:var(--surface2);
  border:0.5px solid var(--border);
  border-radius:6px;
  padding:5px 10px;
  font-size:11px;
  color:var(--text2);
  font-family:var(--mono);
}
.no-issues{
  font-size:12px;
  color:var(--text3);
  padding:8px 0;
  display:flex;
  align-items:center;
  gap:6px;
}
.obs-block{
  background:var(--surface2);
  border-radius:8px;
  padding:10px 12px;
  border:0.5px solid var(--border);
  font-size:12px;
  color:var(--text2);
  line-height:1.6;
}

/* ============================================================
   TOAST
   ============================================================ */
.toast{
  position:fixed;
  bottom:1.5rem;
  right:1.5rem;
  z-index:300;
  background:var(--surface2);
  border:0.5px solid var(--border2);
  border-radius:var(--r);
  padding:10px 16px;
  font-size:13px;
  display:flex;
  align-items:center;
  gap:8px;
  box-shadow:0 4px 20px rgba(0,0,0,0.4);
  transform:translateY(20px);
  opacity:0;
  transition:all 0.25s;
  pointer-events:none;
}
.toast.show{transform:translateY(0);opacity:1}
.toast.success{border-color:rgba(34,197,94,0.4);color:var(--green)}
.toast.error{border-color:rgba(239,68,68,0.4);color:var(--red)}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media(max-width:600px){
  .meta-grid,.meta-grid-2{grid-template-columns:1fr 1fr}
  .summary-strip{grid-template-columns:1fr 1fr}
  .detail-meta{grid-template-columns:1fr 1fr}
  .status-sel{grid-template-columns:1fr 1fr}
  .hist-badges{display:none}
  .login-card{width:92vw;padding:2rem 1.5rem}
  .dash-grid{grid-template-columns:1fr}
  .topbar{padding:0 1rem;gap:0.5rem}
  .nav-tab{padding:6px 10px;font-size:12px}
  .topbar-user span{display:none}
}
