/* login */
.login { padding-top: 8px; }
.brand-hero { display: flex; flex-direction: column; gap: 8px; padding: 8px 0 4px; }
.mark { width: 64px; height: 64px; border-radius: 16px; background: var(--ink); color: var(--accent-2); display: grid; place-items: center; }
.roles { display: grid; gap: 10px; }
.role-btn {
  display: flex; align-items: center; gap: 14px; text-align: left; min-height: 76px; padding: 14px; border: 2px solid var(--ink); border-radius: var(--r);
  background: var(--card); transition: transform .12s ease, box-shadow .15s ease;
}
.role-btn > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.role-btn b { font-size: 17px; text-transform: uppercase; letter-spacing: .05em; }
.role-btn:active { transform: scale(.98); }
.role-ic { flex: none; width: 48px; height: 48px; border-radius: 12px; background: var(--accent); color: #fff; display: grid; place-items: center; }
@media (hover: hover) { .role-btn:hover { box-shadow: 4px 4px 0 var(--ink); } }
.install .how summary { min-height: var(--tap); display: flex; align-items: center; cursor: pointer; font-weight: 700; color: var(--accent); }
.install .how p { padding-bottom: 6px; }

/* fichaje */
.clock-wrap { display: grid; place-items: center; padding: 10px 0; }
.clock-btn {
  position: relative; width: 184px; height: 184px; border-radius: 50%; border: 0; color: #fff; font-weight: 800; font-size: 20px;
  text-transform: uppercase; letter-spacing: .05em; line-height: 1.15; padding: 20px; background: var(--accent);
  box-shadow: 0 0 0 8px var(--paper), 0 0 0 11px var(--accent), 0 10px 0 11px rgba(23,34,46,.18);
  transition: transform .12s ease;
}
.clock-btn.out { background: var(--ink); box-shadow: 0 0 0 8px var(--paper), 0 0 0 11px var(--ink), 0 10px 0 11px rgba(23,34,46,.18); }
.clock-btn:active:not([disabled]) { transform: scale(.96); }
.clock-btn.busy::after { content: ""; position: absolute; inset: -14px; border-radius: 50%; border: 3px solid var(--accent-2); animation: ring 1.2s ease-out infinite; }
@keyframes ring { from { transform: scale(.9); opacity: .9; } to { transform: scale(1.18); opacity: 0; } }
.row .pill { flex: none; }

/* parte */
.file-btn { align-self: flex-start; cursor: pointer; }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.thumb { position: relative; width: 96px; height: 96px; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: var(--paper-2); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumbs.sm .thumb { width: 56px; height: 56px; }
.thumb-x { position: absolute; top: 2px; right: 2px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(23,34,46,.82); color: #fff; display: grid; place-items: center; }
.thumb-x svg { width: 16px; height: 16px; }

/* tareas */
.task { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 14px; background: var(--card); border: 1px solid var(--line); border-left: 5px solid var(--line); border-radius: 12px; }
.task.st-doing { border-left-color: var(--accent-2); }
.task.st-done { border-left-color: #2F7D4B; }
.task.st-done .task-title { text-decoration: line-through; color: var(--ink-2); }
.task-main { min-width: 0; overflow-wrap: anywhere; }
.task-title { font-weight: 700; }
.task-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }
@media (max-width: 400px) { .task { flex-direction: column; align-items: stretch; } .task-side { flex-direction: row; justify-content: space-between; align-items: center; } }

/* obras / personas */
.person { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px dashed var(--line); }
.person:first-child { border-top: 0; }
.avatar { flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.pname { font-weight: 700; }
.just summary { cursor: pointer; font-size: 13px; font-weight: 700; color: var(--warn); min-height: 28px; display: flex; align-items: center; }
.just p { background: var(--warn-bg); color: var(--warn); border-radius: 8px; padding: 8px 10px; }
.news { display: flex; gap: 12px; padding: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; }
.news-ic { flex: none; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--paper-2); }
.news-ic.k-in { background: var(--ok-bg); color: var(--ok); }
.news-ic.k-manual { background: var(--warn-bg); color: var(--warn); }
.news-ic.k-parte { background: var(--info-bg); color: var(--info); }
.quote { font-style: italic; color: var(--ink-2); }

/* mapa */
.map { height: min(62dvh, 520px); min-height: 320px; border-radius: var(--r); border: 2px solid var(--ink); overflow: hidden; isolation: isolate; background: var(--paper-2); }
.pin { display: grid; place-items: center; width: 36px; height: 36px; background: var(--accent); color: #fff; border: 3px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.35); }
.pin { font-weight: 800; font-size: 14px; }
.pinwrap .pin { font-variant-numeric: tabular-nums; }
.leaflet-container { font: inherit; }
.leaflet-control-zoom a { width: 44px !important; height: 44px !important; line-height: 44px !important; }
.schematic { width: 100%; height: 100%; background: var(--card); display: block; }
.sch-g path { stroke: rgba(23,34,46,.1); stroke-width: 1; }
.sch-r { fill: rgba(249,115,22,.15); stroke: var(--accent); stroke-width: 1.5; }
.sch-p { fill: var(--accent); stroke: #fff; stroke-width: 2; }
.sch-n { fill: #fff; font: 800 13px var(--font); }
.sch-l { fill: var(--ink); font: 700 10.5px var(--font); }
.map-off { position: absolute; }
.map:has(.schematic) { display: flex; flex-direction: column; }
.map:has(.schematic) .map-off { position: static; padding: 8px 12px; font-size: 13px; background: var(--warn-bg); color: var(--warn); font-weight: 600; }

/* conecta */
.bullets { display: flex; flex-direction: column; gap: 8px; margin: 10px 0; }
.bullets li { padding-left: 20px; position: relative; overflow-wrap: anywhere; }
.bullets li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 8px; height: 8px; background: var(--accent); transform: rotate(45deg); }
.steps { counter-reset: s; display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }
.steps li { counter-increment: s; padding-left: 40px; position: relative; min-height: 30px; overflow-wrap: anywhere; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: -1px; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: #fff; font-weight: 800; display: grid; place-items: center; font-size: 14px; }
.diagram { margin-top: 14px; display: flex; flex-direction: column; gap: 12px; }
.drow { display: flex; flex-direction: column; align-items: stretch; gap: 4px; }
.dside { display: grid; gap: 8px; grid-template-columns: 1fr; }
.dnode { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 2px solid var(--ink); border-radius: 12px; background: #fff; min-width: 0; overflow-wrap: anywhere; }
.dnode b { text-transform: uppercase; letter-spacing: .06em; font-size: 14px; }
.dnode span { font-size: 13px; color: var(--ink-2); }
.n-app { background: #FDEBDD; border-color: var(--accent); }
.n-api { background: var(--ink); color: #fff; }
.n-api span { color: #cbd3dc; }
.dside .dnode { border-style: dashed; background: var(--card); }
.darrow { display: grid; place-items: center; color: var(--accent); }
@media (min-width: 640px) {
  .drow { flex-direction: row; align-items: stretch; }
  .drow .dnode { flex: 1; }
  .darrow { flex: none; transform: rotate(-90deg); }
  .dside { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 768px) { .conecta-wide { max-width: 760px; } }
