/* ==========================================================================
   SynMedCare Staff Workspace
   Warm, premium healthcare design language shared with the public website.
   ========================================================================== */
:root {
  --forest-950: #021d0b;
  --forest-900: #073902;
  --forest-800: #0b4b18;
  --forest-700: #166702;
  --green-600: #24a148;
  --green-500: #35b85b;
  --lime-200: #e2f0c6;
  --lime-100: #f1f7e6;
  --ivory: #fbfaf5;
  --paper: #ffffff;
  --ink: #071b10;
  --muted: #657369;
  --line: #e4e9e2;
  --soft: #f4f7f2;
  --coral: #e47a5f;
  --amber: #e8a740;
  --danger: #c84a4a;
  --radius-sm: 14px;
  --radius-md: 22px;
  --radius-lg: 34px;
  --shadow-soft: 0 18px 45px rgba(2, 29, 11, 0.1);
  --shadow-deep: 0 38px 90px rgba(0, 18, 6, 0.28);
  --ease: 260ms cubic-bezier(0.2, 0.8, 0.2, 1);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  min-width: 320px;
  background: var(--forest-950);
}

body {
  min-height: 100dvh;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 12%, rgba(53, 184, 91, 0.18), transparent 24rem),
    radial-gradient(circle at 92% 84%, rgba(226, 240, 198, 0.12), transparent 28rem),
    linear-gradient(145deg, #073902 0%, #03270e 58%, #021b0a 100%);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(226, 240, 198, 0.75);
  outline-offset: 3px;
}

.ambient {
  position: fixed;
  border-radius: 999px;
  filter: blur(3px);
  pointer-events: none;
  opacity: 0.45;
}

.ambient-one {
  width: 330px;
  height: 330px;
  top: -190px;
  right: 12%;
  border: 1px solid rgba(226, 240, 198, 0.25);
}

.ambient-two {
  width: 220px;
  height: 220px;
  left: -130px;
  bottom: 8%;
  background: rgba(36, 161, 72, 0.1);
}

.app-shell {
  width: min(100% - 2rem, 1220px);
  min-height: 100dvh;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  padding:
    max(1rem, env(safe-area-inset-top))
    0
    max(0.85rem, env(safe-area-inset-bottom));
  position: relative;
  z-index: 1;
}

/* Header */
.app-header {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: #fff;
  text-decoration: none;
}

.brand img {
  width: 174px;
  height: 52px;
  object-fit: contain;
  object-position: left center;
}

.brand-divider {
  width: 1px;
  height: 27px;
  background: rgba(255, 255, 255, 0.24);
}

.brand-sub {
  color: var(--lime-200);
  font-size: 0.68rem;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  max-width: 70px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.secure-badge,
.ghost-btn {
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding-inline: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  font-size: 0.73rem;
  font-weight: 700;
}

.secure-badge i {
  color: var(--lime-200);
}

.ghost-btn {
  cursor: pointer;
  transition: var(--ease);
}

.ghost-btn[hidden] {
  display: none;
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  transform: translateY(-1px);
}

/* Main shell and screen transitions */
.app-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 0 1.25rem;
}

.screen {
  display: none;
  width: 100%;
  min-width: 0;
}

.screen.active {
  display: block;
  animation: screen-in 0.5s var(--ease) both;
}

@keyframes screen-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.992);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.card {
  width: 100%;
  background: var(--paper);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-deep);
  overflow: hidden;
}

.screen-title {
  color: var(--ink);
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: -0.055em;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.screen-sub {
  max-width: 54ch;
  margin-top: 0.85rem;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.75;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--forest-700);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow.light {
  color: var(--lime-200);
}

.live-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--green-500);
  box-shadow: 0 0 0 0 rgba(53, 184, 91, 0.45);
  animation: live-pulse 2s infinite;
}

@keyframes live-pulse {
  70% { box-shadow: 0 0 0 9px rgba(53, 184, 91, 0); }
}

/* Login */
.login-card {
  min-height: min(680px, calc(100dvh - 150px));
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(420px, 1.06fr);
}

.login-visual {
  min-height: 610px;
  position: relative;
  overflow: hidden;
  background: var(--forest-900);
}

.login-visual > img {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  object-fit: cover;
  object-position: 50% 38%;
  filter: saturate(0.84) contrast(1.04);
  transition: transform 7s ease;
}

.login-card:hover .login-visual > img {
  transform: scale(1.025);
}

.login-visual-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(1, 26, 9, 0.08), rgba(1, 24, 8, 0.36) 55%, rgba(1, 25, 9, 0.92)),
    linear-gradient(100deg, rgba(6, 54, 10, 0.24), transparent 65%);
}

.visual-copy {
  position: absolute;
  left: clamp(1.6rem, 4vw, 3.2rem);
  right: clamp(1.6rem, 4vw, 3.2rem);
  bottom: 7.2rem;
  color: #fff;
}

.visual-copy h2 {
  max-width: 11ch;
  margin-top: 1.1rem;
  font-size: clamp(2.2rem, 4vw, 3.7rem);
  line-height: 1.02;
  letter-spacing: -0.06em;
  font-weight: 800;
}

.visual-copy p {
  max-width: 38ch;
  margin-top: 1.1rem;
  color: rgba(255, 255, 255, 0.77);
  font-size: 0.94rem;
  line-height: 1.65;
}

.visual-note {
  position: absolute;
  right: 1.4rem;
  bottom: 1.4rem;
  left: 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(4, 38, 13, 0.48);
  backdrop-filter: blur(16px);
  font-size: 0.76rem;
  font-weight: 650;
}

.visual-note i {
  color: var(--lime-200);
}

.login-panel {
  min-width: 0;
  padding: clamp(2rem, 5.5vw, 5.3rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    radial-gradient(circle at 100% 0%, rgba(226, 240, 198, 0.46), transparent 17rem),
    var(--ivory);
}

.panel-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.2rem;
}

.portal-label {
  color: #899589;
  font-size: 0.68rem;
  font-weight: 700;
}

.login-panel .screen-title {
  max-width: 12ch;
}

.login-panel .screen-sub {
  margin-bottom: 1.8rem;
}

.form {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.05rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.48rem;
}

.field > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #263a2e;
  font-size: 0.76rem;
  font-weight: 800;
}

.field > span em {
  color: #8a958e;
  font-size: 0.66rem;
  font-style: normal;
  font-weight: 600;
}

.input-shell {
  width: 100%;
  min-width: 0;
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-inline: 1rem;
  border: 1.5px solid #dce4da;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.82);
  transition: var(--ease);
}

.input-shell:focus-within {
  border-color: var(--green-600);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(36, 161, 72, 0.1);
}

.input-shell > i {
  width: 18px;
  color: #8a978e;
  text-align: center;
}

.input-shell input {
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-size: 0.94rem;
  font-weight: 650;
  letter-spacing: 0.015em;
}

.input-shell input::placeholder,
.field > input::placeholder {
  color: #a1aba3;
  font-weight: 500;
}

.field > input,
.leave-select {
  width: 100%;
  min-height: 54px;
  padding: 0.85rem 1rem;
  border: 1.5px solid #dce4da;
  border-radius: var(--radius-sm);
  outline: none;
  color: var(--ink);
  background: #fff;
  font-size: 0.9rem;
  transition: var(--ease);
}

.field > input:focus,
.leave-select:focus {
  border-color: var(--green-600);
  box-shadow: 0 0 0 4px rgba(36, 161, 72, 0.1);
}

.btn-primary {
  min-height: 56px;
  margin-top: 0.35rem;
  padding: 0.95rem 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  border-radius: var(--radius-sm);
  color: #fff;
  background: linear-gradient(135deg, var(--green-600), var(--forest-700));
  box-shadow: 0 14px 28px -12px rgba(22, 103, 2, 0.68);
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 800;
  transition: var(--ease);
}

.btn-primary i {
  font-size: 0.78rem;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 18px 30px -12px rgba(22, 103, 2, 0.76);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0) scale(0.99);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-text {
  width: 100%;
  padding: 0.8rem;
  color: var(--muted);
  background: none;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 750;
}

.login-help {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: #77837a;
}

.login-help i {
  margin-top: 0.18rem;
  color: var(--green-600);
}

.login-help p {
  font-size: 0.7rem;
  line-height: 1.6;
}

/* Shared setup screens */
.setup-card,
.enroll-card {
  width: min(100%, 940px);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(300px, 0.84fr) minmax(390px, 1.16fr);
}

.setup-intro {
  min-height: 560px;
  padding: clamp(2rem, 5vw, 4.5rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
  background:
    radial-gradient(circle at 20% 8%, rgba(226, 240, 198, 0.18), transparent 16rem),
    var(--forest-900);
}

.step-badge {
  align-self: flex-start;
  padding: 0.48rem 0.8rem;
  border: 1px solid rgba(226, 240, 198, 0.25);
  border-radius: 999px;
  color: var(--lime-200);
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.setup-icon,
.page-icon {
  width: 62px;
  height: 62px;
  margin: 2rem 0 1.25rem;
  display: grid;
  place-items: center;
  border-radius: 19px;
  color: var(--forest-900);
  background: var(--lime-200);
  font-size: 1.35rem;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.14);
}

.setup-intro h2 {
  max-width: 9ch;
  font-size: clamp(2.2rem, 4vw, 3.35rem);
  line-height: 1.04;
  letter-spacing: -0.055em;
}

.setup-intro > p {
  margin-top: 1rem;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.88rem;
  line-height: 1.7;
}

.privacy-note {
  margin-top: 2.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.67);
  font-size: 0.7rem;
  line-height: 1.55;
}

.privacy-note i {
  margin-right: 0.45rem;
  color: var(--lime-200);
}

.setup-content {
  padding: clamp(2rem, 5vw, 4.8rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--ivory);
}

.setup-content .screen-title {
  max-width: 11ch;
  margin-top: 0.8rem;
}

.setup-content .screen-sub {
  margin-bottom: 1.6rem;
}

/* Face enrollment */
.enroll-card {
  grid-template-columns: minmax(300px, 0.92fr) minmax(390px, 1.08fr);
  background: var(--ivory);
}

.enroll-copy {
  padding: clamp(2rem, 5vw, 4.4rem);
  background:
    radial-gradient(circle at 0 100%, rgba(226, 240, 198, 0.55), transparent 19rem),
    var(--ivory);
}

.enroll-copy .eyebrow {
  display: flex;
  margin-top: 2rem;
}

.enroll-copy .screen-title {
  margin-top: 0.75rem;
}

.tip-list {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  list-style: none;
}

.tip-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #4e5e53;
  font-size: 0.78rem;
  font-weight: 700;
}

.tip-list i {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--forest-700);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.camera-panel {
  padding: clamp(2rem, 5vw, 4rem);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  color: #fff;
  background:
    radial-gradient(circle at 70% 20%, rgba(53, 184, 91, 0.24), transparent 16rem),
    var(--forest-950);
}

.camera-label {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.camera-wrap {
  width: 230px;
  height: 230px;
  margin: 0 auto 1.35rem;
  position: relative;
}

.camera-wrap.small {
  width: 168px;
  height: 168px;
  margin: 1.4rem auto 1rem;
}

.camera-wrap video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 35%, #174a28, #06190c 72%);
  transform: scaleX(-1);
}

.camera-ring {
  position: absolute;
  inset: -8px;
  border: 2px solid var(--green-500);
  border-radius: 50%;
  box-shadow:
    0 0 0 7px rgba(53, 184, 91, 0.08),
    0 0 34px rgba(53, 184, 91, 0.22);
  transition: var(--ease);
}

.camera-ring::before,
.camera-ring::after {
  content: "";
  position: absolute;
  inset: 12%;
  border-top: 2px solid rgba(226, 240, 198, 0.66);
  border-bottom: 2px solid rgba(226, 240, 198, 0.66);
  border-radius: 50%;
  opacity: 0.52;
}

.camera-ring.searching {
  border-color: var(--amber);
  box-shadow: 0 0 0 7px rgba(232, 167, 64, 0.1), 0 0 34px rgba(232, 167, 64, 0.24);
  animation: camera-pulse 1.4s infinite;
}

.camera-ring.ok {
  border-color: var(--green-500);
}

.scan-line {
  width: 72%;
  height: 1px;
  position: absolute;
  top: 24%;
  left: 14%;
  z-index: 2;
  background: linear-gradient(90deg, transparent, rgba(226, 240, 198, 0.8), transparent);
  box-shadow: 0 0 8px rgba(226, 240, 198, 0.5);
  animation: scan 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes camera-pulse {
  50% { transform: scale(1.018); }
}

@keyframes scan {
  0%, 100% { top: 25%; opacity: 0.25; }
  50% { top: 72%; opacity: 0.9; }
}

.consent {
  max-width: 45ch;
  margin: 0 auto 1.1rem;
  color: rgba(255, 255, 255, 0.57);
  font-size: 0.66rem;
  line-height: 1.65;
  text-align: center;
}

/* Clock workspace */
.clock-card {
  width: min(100%, 1060px);
  margin-inline: auto;
  padding: clamp(1.45rem, 3.2vw, 2.7rem);
  background:
    radial-gradient(circle at 96% 3%, rgba(226, 240, 198, 0.55), transparent 18rem),
    var(--ivory);
}

.clock-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  padding-bottom: 1.6rem;
  border-bottom: 1px solid var(--line);
}

.who-name {
  margin-top: 0.42rem;
  color: var(--ink);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -0.05em;
  font-weight: 800;
}

.who-status {
  display: flex;
  align-items: center;
  gap: 0.48rem;
  margin-top: 0.6rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
}

.who-status .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #9ca8a0;
}

.who-status.in .dot {
  background: var(--green-600);
  box-shadow: 0 0 0 5px rgba(36, 161, 72, 0.12);
}

.today-chip {
  min-height: 45px;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid #dfe6dd;
  border-radius: 13px;
  color: #536258;
  background: rgba(255, 255, 255, 0.75);
  font-size: 0.72rem;
  font-weight: 800;
}

.today-chip i {
  color: var(--green-600);
}

.clock-workspace {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(320px, 1.1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.identity-card,
.clock-action {
  min-height: 336px;
  border-radius: var(--radius-md);
}

.identity-card {
  padding: 1.3rem;
  color: #fff;
  background:
    radial-gradient(circle at 80% 10%, rgba(53, 184, 91, 0.22), transparent 13rem),
    var(--forest-950);
}

.identity-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.75rem;
  font-weight: 800;
}

.mini-secure {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.6rem;
  font-weight: 700;
}

.mini-secure i {
  margin-right: 0.25rem;
  color: var(--lime-200);
}

.identity-card > p {
  max-width: 35ch;
  margin-inline: auto;
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.68rem;
  line-height: 1.5;
  text-align: center;
}

.meta-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.9rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.42rem 0.68rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.57);
  background: rgba(255, 255, 255, 0.07);
  font-size: 0.59rem;
  font-weight: 750;
}

.chip.ok {
  color: var(--lime-200);
  border-color: rgba(53, 184, 91, 0.25);
  background: rgba(36, 161, 72, 0.12);
}

.chip.bad {
  color: #ffd0c3;
  border-color: rgba(228, 122, 95, 0.25);
  background: rgba(228, 122, 95, 0.12);
}

.clock-action {
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 50% 50%, rgba(226, 240, 198, 0.48), transparent 12rem),
    #edf5df;
}

.action-kicker {
  color: var(--forest-700);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.clock-button {
  width: 198px;
  height: 198px;
  margin: 0.85rem auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.34rem;
  border: 8px solid rgba(255, 255, 255, 0.56);
  border-radius: 50%;
  color: #fff;
  background:
    radial-gradient(circle at 35% 25%, #3cc463, var(--green-600) 44%, var(--forest-700) 100%);
  box-shadow:
    0 22px 40px -16px rgba(22, 103, 2, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    inset 0 -9px 16px rgba(0, 0, 0, 0.12);
  cursor: pointer;
  transition: var(--ease);
}

.clock-button:hover:not(:disabled) {
  transform: translateY(-3px) scale(1.015);
}

.clock-button:active:not(:disabled) {
  transform: scale(0.975);
}

.clock-button:disabled {
  filter: grayscale(0.35);
  opacity: 0.6;
  cursor: not-allowed;
}

.clock-button.is-in {
  background:
    radial-gradient(circle at 35% 25%, #f1b859, var(--amber) 45%, #c1791e 100%);
  box-shadow:
    0 22px 40px -16px rgba(193, 121, 30, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.36),
    inset 0 -9px 16px rgba(0, 0, 0, 0.12);
}

.clock-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  font-size: 1.1rem;
}

.cb-label {
  font-size: 1.18rem;
  font-weight: 800;
}

.cb-timer {
  min-height: 1em;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.7rem;
  font-weight: 700;
}

.action-note {
  max-width: 37ch;
  color: #697969;
  font-size: 0.63rem;
  line-height: 1.5;
  text-align: center;
}

.day-details {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.recent-wrap,
.quick-links {
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.74);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.section-heading h3 {
  margin-top: 0.28rem;
  color: var(--ink);
  font-size: 0.98rem;
  letter-spacing: -0.02em;
}

.section-heading > i {
  color: #a6b0a8;
}

.recent {
  margin-top: 0.75rem;
}

.recent-item {
  min-height: 39px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid #edf0eb;
  color: #526057;
  font-size: 0.72rem;
}

.recent-item:first-child {
  border-top: 0;
}

.recent-item .t-in,
.recent-item .t-out {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  font-weight: 800;
}

.recent-item .t-in::before,
.recent-item .t-out::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.recent-item .t-in {
  color: var(--forest-700);
}

.recent-item .t-in::before {
  background: var(--green-600);
}

.recent-item .t-out {
  color: #ac6a19;
}

.recent-item .t-out::before {
  background: var(--amber);
}

.recent-item time {
  color: #89958c;
}

.clock-nav {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.75rem;
}

.nav-pill {
  width: 100%;
  min-height: 59px;
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 0.7rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid #e5eae2;
  border-radius: 15px;
  color: var(--ink);
  background: #fff;
  cursor: pointer;
  text-align: left;
  transition: var(--ease);
}

.nav-pill:hover {
  border-color: rgba(36, 161, 72, 0.35);
  transform: translateX(3px);
  box-shadow: 0 9px 20px rgba(7, 57, 2, 0.07);
}

.nav-pill > i {
  color: #a4aea6;
  font-size: 0.65rem;
}

.nav-pill > span:nth-child(2) {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.nav-pill strong {
  font-size: 0.75rem;
}

.nav-pill small {
  color: #8a958d;
  font-size: 0.6rem;
}

.nav-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: var(--forest-700);
  background: var(--lime-100);
}

.nav-icon.coral {
  color: #a84f38;
  background: #fcedea;
}

/* Inner schedule page */
.inner-page-card {
  width: min(100%, 800px);
  margin-inline: auto;
  padding: clamp(1.5rem, 4vw, 3.2rem);
  background:
    radial-gradient(circle at 100% 0%, rgba(226, 240, 198, 0.5), transparent 18rem),
    var(--ivory);
}

.inner-page-header {
  position: relative;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}

.inner-page-header .page-icon {
  margin: 2.3rem 0 1.2rem;
}

.inner-page-header .screen-title {
  margin-top: 0.6rem;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0;
  color: #6f7c73;
  background: none;
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 800;
}

.back-link:hover {
  color: var(--forest-700);
}

.list-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 1.2rem;
}

.list-item {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.8);
  transition: var(--ease);
}

.list-item:hover {
  border-color: rgba(36, 161, 72, 0.25);
  box-shadow: 0 10px 24px rgba(7, 57, 2, 0.06);
  transform: translateY(-1px);
}

.li-main {
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
}

.li-sub {
  margin-top: 0.25rem;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.5;
}

.li-badge {
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  font-size: 0.61rem;
  font-weight: 800;
  text-transform: capitalize;
}

.li-badge.pending { color: #8f5a15; background: #fff2d9; }
.li-badge.approved { color: #0c6b30; background: #e3f6e9; }
.li-badge.rejected { color: #9b3636; background: #fce7e7; }

.empty-note {
  padding: 2rem 1rem;
  border: 1px dashed #d8dfd6;
  border-radius: 16px;
  color: #89958c;
  background: rgba(255, 255, 255, 0.48);
  font-size: 0.76rem;
  text-align: center;
}

/* Leave */
.leave-card {
  width: min(100%, 970px);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(285px, 0.8fr) minmax(430px, 1.2fr);
}

.leave-sidebar {
  padding: clamp(1.7rem, 4vw, 3.4rem);
  color: #fff;
  background:
    radial-gradient(circle at 10% 80%, rgba(226, 240, 198, 0.17), transparent 15rem),
    var(--forest-900);
}

.light-back {
  color: rgba(255, 255, 255, 0.62);
}

.light-back:hover {
  color: #fff;
}

.page-icon.light-icon {
  color: var(--forest-900);
  background: var(--lime-200);
}

.leave-sidebar h1 {
  margin-top: 0.65rem;
  color: #fff;
  font-size: clamp(2.1rem, 4vw, 3.3rem);
  line-height: 1.04;
  letter-spacing: -0.055em;
}

.leave-sidebar > p {
  margin-top: 1rem;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.82rem;
  line-height: 1.7;
}

.balance-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-top: 2rem;
}

.balance-chip {
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.bc-num {
  color: var(--lime-200);
  font-size: 1.6rem;
  line-height: 1;
  font-weight: 800;
}

.bc-label {
  margin-top: 0.4rem;
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.57rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.leave-main {
  max-height: min(740px, calc(100dvh - 135px));
  overflow-y: auto;
  padding: clamp(1.7rem, 4.5vw, 3.5rem);
  background: var(--ivory);
}

.form-heading {
  margin-bottom: 1.3rem;
}

.form-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.8rem;
}

.sub-head {
  margin: 2rem 0 0.7rem;
  color: var(--ink);
  font-size: 0.88rem;
}

/* Feedback */
.toast {
  max-width: min(90vw, 460px);
  position: fixed;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  z-index: 80;
  padding: 0.9rem 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  color: #fff;
  background: rgba(3, 26, 10, 0.95);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(16px);
  transform: translateX(-50%) translateY(150%);
  transition: transform var(--ease);
  font-size: 0.78rem;
  font-weight: 700;
  text-align: center;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

.toast.ok { background: rgba(9, 93, 35, 0.96); }
.toast.err { background: rgba(155, 45, 45, 0.96); }

.busy {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  background: rgba(1, 20, 7, 0.78);
  backdrop-filter: blur(10px);
}

.busy[hidden] {
  display: none;
}

.busy span {
  color: #fff;
  font-size: 0.78rem;
  font-weight: 750;
}

.spinner {
  width: 48px;
  height: 48px;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--lime-200);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.app-footer {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: rgba(255, 255, 255, 0.46);
  font-size: 0.61rem;
  font-weight: 650;
}

.app-footer span:last-child {
  color: rgba(226, 240, 198, 0.6);
}

.app-footer i {
  margin-right: 0.3rem;
}

/* Tablet */
@media (max-width: 900px) {
  .app-shell {
    width: min(100% - 1.4rem, 760px);
  }

  .login-card {
    grid-template-columns: minmax(260px, 0.8fr) minmax(390px, 1.2fr);
  }

  .login-visual {
    min-height: 570px;
  }

  .visual-copy {
    bottom: 6.4rem;
  }

  .visual-copy h2 {
    font-size: 2.45rem;
  }

  .visual-copy p {
    display: none;
  }

  .setup-card,
  .enroll-card,
  .leave-card {
    grid-template-columns: minmax(250px, 0.8fr) minmax(370px, 1.2fr);
  }

  .clock-workspace {
    grid-template-columns: 0.88fr 1.12fr;
  }
}

/* Mobile */
@media (max-width: 680px) {
  body {
    background:
      radial-gradient(circle at 90% 0%, rgba(53, 184, 91, 0.2), transparent 20rem),
      var(--forest-900);
  }

  .app-shell {
    width: min(100% - 1rem, 520px);
  }

  .app-header {
    min-height: 62px;
  }

  .brand img {
    width: 137px;
    height: 44px;
  }

  .brand-divider,
  .brand-sub,
  .secure-badge {
    display: none;
  }

  .ghost-btn {
    width: 40px;
    padding: 0;
    border-radius: 12px;
  }

  .ghost-btn span {
    display: none;
  }

  .app-main {
    align-items: flex-start;
    padding: 0.5rem 0 1rem;
  }

  .card {
    border-radius: 25px;
  }

  .login-card,
  .setup-card,
  .enroll-card,
  .leave-card {
    display: block;
  }

  .login-card {
    min-height: 0;
  }

  .login-visual {
    min-height: 215px;
  }

  .login-visual > img {
    object-position: 50% 38%;
  }

  .login-visual-overlay {
    background: linear-gradient(180deg, rgba(1, 24, 8, 0.05), rgba(1, 24, 8, 0.86));
  }

  .visual-copy {
    right: 1.3rem;
    bottom: 1.35rem;
    left: 1.3rem;
  }

  .visual-copy h2 {
    max-width: 15ch;
    margin-top: 0.6rem;
    font-size: 1.65rem;
    line-height: 1.08;
  }

  .visual-note,
  .visual-copy p {
    display: none;
  }

  .login-panel {
    padding: 1.65rem 1.3rem 1.5rem;
  }

  .panel-topline {
    margin-bottom: 0.85rem;
  }

  .portal-label {
    display: none;
  }

  .screen-title {
    font-size: 2rem;
  }

  .login-panel .screen-title {
    max-width: 14ch;
  }

  .login-panel .screen-sub {
    margin: 0.65rem 0 1.25rem;
    font-size: 0.82rem;
    line-height: 1.6;
  }

  .input-shell,
  .field > input,
  .leave-select {
    min-height: 52px;
  }

  .btn-primary {
    min-height: 53px;
  }

  .login-help {
    margin-top: 1.15rem;
    padding-top: 1rem;
  }

  .setup-intro {
    min-height: 255px;
    padding: 1.5rem;
    justify-content: flex-end;
  }

  .setup-icon {
    width: 48px;
    height: 48px;
    margin: 1rem 0 0.8rem;
    border-radius: 14px;
    font-size: 1rem;
  }

  .setup-intro h2 {
    max-width: 12ch;
    font-size: 2rem;
  }

  .setup-intro > p,
  .privacy-note {
    display: none;
  }

  .setup-content,
  .enroll-copy,
  .camera-panel,
  .leave-sidebar,
  .leave-main {
    padding: 1.5rem 1.3rem;
  }

  .setup-content .screen-sub {
    margin-bottom: 1.2rem;
  }

  .enroll-copy .eyebrow {
    margin-top: 1.2rem;
  }

  .tip-list {
    display: none;
  }

  .camera-panel {
    padding-top: 1.8rem;
  }

  .camera-wrap {
    width: 205px;
    height: 205px;
  }

  .clock-card {
    padding: 1.2rem;
  }

  .clock-header {
    padding-bottom: 1.2rem;
  }

  .today-chip {
    display: none;
  }

  .clock-workspace,
  .day-details {
    grid-template-columns: 1fr;
  }

  .identity-card,
  .clock-action {
    min-height: 0;
  }

  .identity-card {
    padding: 1rem;
  }

  .camera-wrap.small {
    width: 130px;
    height: 130px;
    margin: 1rem auto 0.75rem;
  }

  .identity-card > p {
    display: none;
  }

  .clock-action {
    padding: 1.2rem;
  }

  .clock-button {
    width: 176px;
    height: 176px;
  }

  .recent-wrap,
  .quick-links {
    padding: 1rem;
  }

  .inner-page-card {
    padding: 1.35rem;
  }

  .inner-page-header .page-icon {
    width: 52px;
    height: 52px;
    margin: 1.8rem 0 1rem;
  }

  .leave-sidebar {
    padding-bottom: 1.7rem;
  }

  .leave-sidebar .page-icon {
    width: 50px;
    height: 50px;
    margin: 1.7rem 0 1rem;
  }

  .leave-sidebar h1 {
    font-size: 2.2rem;
  }

  .leave-sidebar > p {
    font-size: 0.76rem;
  }

  .balance-row {
    margin-top: 1.25rem;
  }

  .leave-main {
    max-height: none;
    overflow: visible;
  }

  .form-2col {
    grid-template-columns: 1fr;
  }

  .app-footer {
    padding-inline: 0.4rem;
  }

  .app-footer span:first-child {
    display: none;
  }

  .app-footer {
    justify-content: flex-end;
  }
}

@media (max-width: 390px) {
  .login-visual {
    min-height: 190px;
  }

  .visual-copy h2 {
    font-size: 1.48rem;
  }

  .login-panel {
    padding-inline: 1.05rem;
  }

  .clock-card,
  .inner-page-card {
    padding-inline: 0.95rem;
  }

  .camera-wrap {
    width: 185px;
    height: 185px;
  }

  .clock-button {
    width: 164px;
    height: 164px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── "Turn on camera" overlay button (shown when the camera is off) ── */
.cam-toggle {
  position: absolute; inset: 0; z-index: 5;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.4rem;
  border: none; border-radius: 50%; cursor: pointer;
  background: rgba(7, 36, 16, 0.82);
  color: #fff; font-family: inherit; font-weight: 700; font-size: 0.82rem;
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
  transition: background 0.2s;
}
.cam-toggle[hidden] { display: none; }
.cam-toggle:hover { background: rgba(7, 36, 16, 0.9); }
.cam-toggle i { font-size: 1.6rem; color: var(--brand, #24A148); }
.cam-toggle span { opacity: 0.95; }
