/* ═══ Orion — Relógio de Ponto (dashboard exclusivo) ═══ */

body.orion-apenas-ponto {
  --pd-bg: #f0f4f8;
  --pd-surface: #ffffff;
  --pd-surface2: #f8fafc;
  --pd-border: #e2e8f0;
  --pd-text: #0f172a;
  --pd-muted: #64748b;
  --pd-teal: #0d9488;
  --pd-teal-d: #0f766e;
  --pd-teal-l: #ccfbf1;
  --pd-green: #059669;
  --pd-green-bg: #ecfdf5;
  --pd-red: #dc2626;
  --pd-red-bg: #fef2f2;
  --pd-amber: #d97706;
  --pd-amber-bg: #fffbeb;
  --pd-shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 4px 16px rgba(15, 23, 42, 0.04);
  --pd-shadow-lg: 0 8px 32px rgba(13, 148, 136, 0.12);
  background: var(--pd-bg) !important;
}

body.orion-apenas-ponto .sb-nav .sb-it:not([data-p="ponto"]),
body.orion-apenas-ponto .sb-nav .sb-grp,
body.orion-apenas-ponto .sb-it[data-p="config"],
body.orion-apenas-ponto #acabDock,
body.orion-apenas-ponto #dirDock,
body.orion-apenas-ponto #notifWrap,
body.orion-apenas-ponto .sb-switch,
body.orion-apenas-ponto .pfbanner {
  display: none !important;
}

body.orion-apenas-ponto .sb {
  width: 0;
  min-width: 0;
  overflow: hidden;
  border: none;
  pointer-events: none;
}

body.orion-apenas-ponto .main-wrap {
  margin-left: 0;
}

body.orion-apenas-ponto .tb-menu {
  display: none;
}

body.orion-apenas-ponto .topbar {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--pd-border);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
}

body.orion-apenas-ponto .tb-title {
  font-weight: 800;
  letter-spacing: -0.3px;
  color: var(--pd-text);
}

body.orion-apenas-ponto .ca {
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  padding: 20px 24px 40px;
}

/* ── Hero ── */
.ponto-dash-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
  padding: 28px 32px;
  margin-bottom: 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, #0f766e 0%, #0d9488 40%, #14b8a6 100%);
  color: #fff;
  box-shadow: var(--pd-shadow-lg);
  position: relative;
  overflow: hidden;
}

.ponto-dash-hero::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -10%;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.ponto-dash-hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: 20%;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.ponto-dash-hero > * {
  position: relative;
  z-index: 1;
}

.ponto-dash-hero h1 {
  font-size: 26px;
  font-weight: 800;
  margin: 0 0 6px;
  letter-spacing: -0.5px;
}

.ponto-dash-hero .ponto-dash-sub {
  margin: 0;
  font-size: 14px;
  opacity: 0.88;
  font-weight: 500;
}

.ponto-dash-clock {
  text-align: right;
}

.ponto-dash-clock .hora {
  font-family: var(--mono);
  font-size: 44px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -2px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.ponto-dash-clock .data {
  font-size: 13px;
  opacity: 0.85;
  margin-top: 8px;
  text-transform: capitalize;
  font-weight: 500;
}

.ponto-dash-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.ponto-dash-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
  transition: background 0.15s, transform 0.15s;
}

.ponto-dash-link:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-1px);
}

/* ── Abas ── */
#pontoAbas {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  padding: 5px;
  background: var(--pd-surface);
  border-radius: 14px;
  border: 1px solid var(--pd-border);
  box-shadow: var(--pd-shadow);
}

.ponto-tab {
  padding: 10px 18px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 13px;
  font-family: var(--font);
  background: transparent;
  color: var(--pd-muted);
  transition: all 0.15s;
}

.ponto-tab:hover {
  color: var(--pd-text);
  background: var(--pd-surface2);
}

.ponto-tab.on {
  background: linear-gradient(135deg, var(--pd-teal), var(--pd-teal-d));
  color: #fff;
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.35);
}

/* ── KPI grid ── */
.ponto-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.ponto-kpi {
  background: var(--pd-surface);
  border: 1px solid var(--pd-border);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--pd-shadow);
  position: relative;
  overflow: hidden;
}

.ponto-kpi::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--kpi-accent, var(--pd-teal));
}

.ponto-kpi-lbl {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--pd-muted);
  margin-bottom: 8px;
}

.ponto-kpi-val {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--kpi-color, var(--pd-text));
  font-family: var(--mono);
  line-height: 1.1;
}

.ponto-kpi-sub {
  font-size: 11px;
  color: var(--pd-muted);
  margin-top: 6px;
  font-weight: 500;
}

.ponto-kpi--green { --kpi-accent: var(--pd-green); --kpi-color: var(--pd-green); }
.ponto-kpi--red { --kpi-accent: var(--pd-red); --kpi-color: var(--pd-red); }
.ponto-kpi--amber { --kpi-accent: var(--pd-amber); --kpi-color: var(--pd-amber); }
.ponto-kpi--teal { --kpi-accent: var(--pd-teal); --kpi-color: var(--pd-teal); }

/* ── Charts ── */
.ponto-charts-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.ponto-charts-row--3 {
  grid-template-columns: 1fr 1fr 0.85fr;
}

.ponto-chart-card {
  background: var(--pd-surface);
  border: 1px solid var(--pd-border);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--pd-shadow);
}

.ponto-chart-hd {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 12px;
}

.ponto-chart-title {
  font-size: 14px;
  font-weight: 800;
  color: var(--pd-text);
  letter-spacing: -0.2px;
}

.ponto-chart-sub {
  font-size: 11px;
  color: var(--pd-muted);
  margin-top: 3px;
  font-weight: 500;
}

.ponto-chart-wrap {
  position: relative;
  height: 220px;
}

.ponto-chart-wrap--sm {
  height: 200px;
}

.ponto-month-pick {
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--pd-border);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font);
  color: var(--pd-text);
  background: var(--pd-surface2);
}

/* ── Cards / tabelas ── */
.ponto-panel {
  background: var(--pd-surface);
  border: 1px solid var(--pd-border);
  border-radius: 16px;
  box-shadow: var(--pd-shadow);
  overflow: hidden;
  margin-bottom: 16px;
}

.ponto-panel-hd {
  padding: 16px 20px;
  border-bottom: 1px solid var(--pd-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  background: var(--pd-surface2);
}

.ponto-panel-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--pd-text);
  letter-spacing: -0.2px;
}

.ponto-panel-note {
  font-size: 12px;
  color: var(--pd-muted);
  padding: 10px 20px;
  border-bottom: 1px solid var(--pd-border);
  background: #fafbfc;
}

.ponto-tbl-wrap {
  overflow-x: auto;
}

.ponto-tbl-planilha {
  width: 100%;
  border-collapse: collapse;
}

.ponto-tbl-planilha thead th {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--pd-muted);
  padding: 10px 14px;
  text-align: left;
  background: #f1f5f9;
  border-bottom: 1px solid var(--pd-border);
  white-space: nowrap;
}

.ponto-tbl-planilha tbody td {
  padding: 12px 14px;
  font-size: 13px;
  color: var(--pd-text);
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}

.ponto-tbl-planilha tbody tr:hover td {
  background: #f8fafc;
}

.ponto-th-bat, .ponto-td-bat { background: rgba(13, 148, 136, 0.06); }
.ponto-th-ext, .ponto-td-ext { background: var(--pd-green-bg); color: var(--pd-green); font-weight: 700; }
.ponto-th-neg, .ponto-td-neg { background: var(--pd-red-bg); color: var(--pd-red); font-weight: 700; }
.ponto-th-tot, .ponto-td-tot { background: #f1f5f9; font-weight: 700; }

/* Status chips */
.ponto-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
}

.ponto-chip--ok { background: var(--pd-green-bg); color: var(--pd-green); border: 1px solid #a7f3d0; }
.ponto-chip--wait { background: var(--pd-amber-bg); color: var(--pd-amber); border: 1px solid #fde68a; }
.ponto-chip--done { background: #f1f5f9; color: var(--pd-muted); border: 1px solid var(--pd-border); }

.ponto-btn-sm {
  padding: 5px 10px;
  border-radius: 8px;
  border: 1px solid var(--pd-border);
  background: var(--pd-surface);
  font-size: 11px;
  font-weight: 700;
  color: var(--pd-text);
  cursor: pointer;
  font-family: var(--font);
  transition: all 0.12s;
}

.ponto-btn-sm:hover {
  border-color: var(--pd-teal);
  color: var(--pd-teal);
  background: var(--pd-teal-l);
}

.ponto-btn-sm--p {
  background: var(--pd-teal);
  color: #fff;
  border-color: var(--pd-teal);
}

.ponto-btn-sm--p:hover {
  background: var(--pd-teal-d);
  color: #fff;
}

/* Ranking extras */
.ponto-rank-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ponto-rank-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--pd-surface2);
  border: 1px solid var(--pd-border);
}

.ponto-rank-pos {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--pd-teal-l);
  color: var(--pd-teal-d);
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ponto-rank-name {
  flex: 1;
  font-size: 13px;
  font-weight: 700;
  color: var(--pd-text);
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ponto-rank-bar-wrap {
  flex: 1.2;
  height: 6px;
  background: #e2e8f0;
  border-radius: 3px;
  overflow: hidden;
  min-width: 60px;
}

.ponto-rank-bar {
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--pd-teal), #34d399);
}

.ponto-rank-val {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 800;
  color: var(--pd-green);
  flex-shrink: 0;
  min-width: 48px;
  text-align: right;
}

@media (max-width: 1024px) {
  .ponto-kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .ponto-charts-row,
  .ponto-charts-row--3 { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  body.orion-apenas-ponto .ca { padding: 14px 12px 32px; }
  .ponto-dash-hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 22px 20px;
  }
  .ponto-dash-clock { text-align: center; }
  .ponto-dash-clock .hora { font-size: 36px; }
  .ponto-dash-actions { justify-content: center; }
  .ponto-kpi-grid { grid-template-columns: 1fr; }
  .ponto-kpi-val { font-size: 24px; }
  #pontoAbas { gap: 4px; }
  .ponto-tab { padding: 8px 12px; font-size: 12px; }
}
