

.portal-switcher {
  display: none !important;
}

/* Technician cannot manage Office inventory catalog */
#panel-inventory .df-tech-office-inventory-actions,
#panel-inventory button[onclick*="openInventoryEditor"],
#panel-inventory button[onclick*="openInventoryAudit"],
#panel-inventory button[onclick*="adjustInventory"],
#panel-inventory button[onclick*="deleteInventoryItem"],
#panel-inventory .df-qty-btn {
  display: none !important;
}

#inventory-editor-modal,
#inventory-audit-modal {
  display: none !important;
}

/* Technician permissions — Office-only management actions */
#panel-customers button[onclick*="openCustomerEditor"],
#panel-customers button[onclick*="deleteCustomer"],
#panel-assets button[onclick*="deleteAsset"],
#panel-work-orders button[onclick*="deleteWorkOrder"],
button[onclick*="deleteWorkOrder"] {
  display: none !important;
}










@media (max-width: 760px) {
  .content-body {
    padding: 7px !important;
  }

  .df-tech-command-card {
    display: none !important;
  }

  .df-tech-redesign-shell,
  .df-phone-stage,
  .phone-mockup-wrapper,
  .df-phone-premium,
  .phone-screen,
  .df-phone-screen-v4 {
    width: 100% !important;
    max-width: none !important;
  }

  .phone-mockup-wrapper,
  .df-phone-premium,
  .phone-screen,
  .df-phone-screen-v4 {
    min-height: calc(100vh - 14px) !important;
    height: auto !important;
    border-radius: 17px !important;
  }
}

/* Technician workflow: only the current status is green. */
.df-action-btn.current-status {
  background: #65c61c !important;
  color: #ffffff !important;
  border-color: #79df26 !important;
  box-shadow: 0 0 0 2px rgba(101,198,28,.18), 0 10px 24px rgba(101,198,28,.22) !important;
}
.df-action-btn:disabled {
  opacity: .52 !important;
  cursor: not-allowed !important;
}
#jarvis-fab, #jarvis-panel {
  display: none !important;
}
.df-hero-btn[onclick*="mobile"],
.df-hero-btn[onclick*="dispatch"] {
  display: none !important;
}

/* RC1 workflow + signature */
.df-action-btn.current-status {
  background:#65c61c !important;
  color:#fff !important;
  border-color:#79df26 !important;
  box-shadow:0 0 0 2px rgba(101,198,28,.2),0 10px 24px rgba(101,198,28,.22) !important;
}
.df-action-btn:disabled {
  opacity:.52 !important;
  cursor:not-allowed !important;
}
.df-signature-name-label,
.df-signature-approval {
  display:block;
  margin:10px 0;
  font-size:.8rem;
  font-weight:700;
}
.df-signature-approval {
  display:flex;
  gap:8px;
  align-items:center;
}
.df-signature-pad-container {
  width:100% !important;
  min-height:184px !important;
  overflow:hidden !important;
  background:#fff !important;
  border-radius:10px !important;
}
#mobile-sig-pad {
  display:block !important;
  width:100% !important;
  height:180px !important;
  background:#fff !important;
  border:2px dashed #64748b !important;
  border-radius:10px !important;
  touch-action:none !important;
  -ms-touch-action:none !important;
  pointer-events:auto !important;
  user-select:none !important;
  -webkit-user-select:none !important;
}

/* Guided one-button technician workflow */
.df-mobile-actions {
  display:none !important;
}
.df-guided-workflow-card {
  margin:14px 0;
  padding:16px;
  border:1px solid rgba(96,165,250,.35);
  border-radius:16px;
  background:linear-gradient(145deg,rgba(15,23,42,.98),rgba(30,41,59,.96));
  box-shadow:0 12px 30px rgba(0,0,0,.22);
}
.df-guided-label {
  font-size:.7rem;
  font-weight:900;
  letter-spacing:.1em;
  text-transform:uppercase;
  color:#93c5fd;
}
.df-guided-step-title {
  margin-top:6px;
  font-size:1.35rem;
  font-weight:900;
  color:#f8fafc;
}
.df-guided-step-help {
  margin:6px 0 14px;
  font-size:.82rem;
  line-height:1.45;
  color:#cbd5e1;
}
.df-guided-action-btn {
  width:100%;
  min-height:52px;
  border:0;
  border-radius:12px;
  background:#65c61c;
  color:#fff;
  font-weight:900;
  font-size:1rem;
  cursor:pointer;
  box-shadow:0 10px 24px rgba(101,198,28,.25);
  touch-action:manipulation;
}
.df-guided-action-btn.is-stop-work {
  background:#dc2626;
  box-shadow:0 10px 24px rgba(220,38,38,.25);
}
.df-guided-action-btn.is-complete-state,
.df-guided-action-btn:disabled {
  background:#475569;
  color:#cbd5e1;
  box-shadow:none;
  cursor:not-allowed;
}
.df-complete-hint {
  margin:12px 0 8px;
  padding:10px 12px;
  border-radius:10px;
  background:rgba(59,130,246,.12);
  border:1px solid rgba(59,130,246,.25);
  color:#bfdbfe;
  font-size:.78rem;
}


/* Final technician page-routing fix */
.tab-panel {
  display: none !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.tab-panel.active {
  display: block !important;
}

/* Do not permanently force Today's Jobs over the selected technician page. */
#panel-mobile:not(.active) {
  display: none !important;
}


/* Technician sidebar restored */
.sidebar {
  display: flex !important;
}

.df-header-logo {
  flex: 0 0 auto;
  width: 32px;
  height: auto;
  max-height: 28px;
  object-fit: contain;
  background: transparent;
  border: none;
  display: block;
  margin-right: 2px;
}

@media (min-width: 768px) {
  .df-header-logo {
    width: 36px;
    max-height: 32px;
  }
}

.app-container {
  display: flex !important;
  min-height: 100vh !important;
}

.main-content {
  min-width: 0 !important;
}

.sidebar-footer {
  display: block !important;
}

.sidebar-footer button[onclick*="signOutFirebase"] {
  display: flex !important;
  width: 100% !important;
}

@media (max-width: 900px) {
  .sidebar {
    position: fixed !important;
    left: -290px;
    top: 0;
    bottom: 0;
    width: 280px !important;
    z-index: 1200 !important;
    transition: left .22s ease;
    box-shadow: 12px 0 30px rgba(0,0,0,.35);
  }

  .sidebar.mobile-open {
    left: 0 !important;
  }

  .main-content {
    width: 100% !important;
    margin-left: 0 !important;
  }

  .top-navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
  }

  .content-body {
    padding: 10px !important;
  }
}

/* =========================================================
   Technician login / registration — scrollable tabbed overlay
   ========================================================= */
html.df-tech-login-open,
html.df-tech-login-open body {
  height: auto !important;
  min-height: 100dvh !important;
  overflow: auto !important;
  overflow-x: hidden !important;
  position: static !important;
  max-height: none !important;
  touch-action: auto !important;
}

html.df-tech-login-open .app-container,
html.df-tech-login-open #main-app,
html.df-tech-login-open .mobile-bottom-nav,
html.df-tech-login-open .bottom-nav,
html.df-tech-login-open .phone-nav,
html.df-tech-login-open .df-mobile-bottom-nav {
  display: none !important;
}

.df-tech-login-overlay {
  position: fixed !important;
  inset: 0 !important;
  z-index: 99999 !important;
  display: none;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: flex-start !important;
  box-sizing: border-box !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100dvh !important;
  min-height: 100dvh !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain !important;
  -webkit-overflow-scrolling: touch !important;
  touch-action: pan-y !important;
  padding: 16px 14px 40px !important;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 60%, #0f2a1a 100%) !important;
  font-family: 'Inter', 'Segoe UI', sans-serif !important;
}

/* Visible while login session class is present (default before auth). */
html.df-tech-login-open .df-tech-login-overlay,
body.df-tech-login-open .df-tech-login-overlay,
.df-tech-login-overlay.is-visible {
  display: flex !important;
}

.df-tech-login-overlay[hidden],
.df-tech-login-overlay.is-hidden {
  display: none !important;
}

.df-tech-login-card {
  width: 100% !important;
  max-width: 420px !important;
  margin: 12px auto 32px !important;
  box-sizing: border-box !important;
  background: rgba(30, 41, 59, 0.96) !important;
  border: 1px solid rgba(118, 184, 42, 0.3) !important;
  border-radius: 18px !important;
  padding: 22px 18px 28px !important;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55) !important;
}

.df-tech-login-brand {
  text-align: center;
  margin-bottom: 14px;
}

.df-tech-login-logo {
  width: min(120px, 36vw);
  max-width: 140px;
  height: auto;
  margin: 0 auto 8px;
  display: block;
  background: transparent;
  border: none;
  object-fit: contain;
}

.df-tech-login-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #f1f5f9;
  letter-spacing: -0.02em;
}

.df-tech-login-subtitle {
  font-size: 0.8rem;
  color: #93c5fd;
  margin-top: 2px;
  font-weight: 500;
}

.df-tech-login-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 0 0 14px;
  padding: 4px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid #334155;
}

.df-tech-login-tab {
  min-height: 48px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: #94a3b8;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
}

.df-tech-login-tab.active {
  background: linear-gradient(135deg, #76b82a, #5a9020);
  color: #fff;
}

.df-tech-login-error {
  display: none;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid #ef4444;
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 12px;
  font-size: 0.82rem;
  color: #fca5a5;
  font-weight: 500;
}

.df-tech-login-panel {
  text-align: left;
}

.df-tech-login-field {
  margin-bottom: 10px;
}

.df-tech-login-field label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.df-tech-login-field input,
.df-tech-login-panel input {
  width: 100%;
  box-sizing: border-box;
  min-height: 44px;
  padding: 10px 12px;
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 8px;
  color: #f1f5f9;
  font-size: 16px; /* prevents iOS zoom */
  outline: none;
}

.df-tech-login-field input:focus {
  border-color: #76b82a;
}

.df-tech-reg-code {
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.df-tech-login-primary,
.df-tech-login-secondary {
  width: 100%;
  min-height: 48px;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
}

.df-tech-login-primary {
  border: none;
  color: #fff;
  background: linear-gradient(135deg, #76b82a, #5a9020);
  box-shadow: 0 4px 16px rgba(118, 184, 42, 0.3);
}

.df-tech-login-secondary {
  background: #fff;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

.df-tech-login-link {
  width: 100%;
  min-height: 44px;
  margin-top: 6px;
  padding: 8px;
  background: transparent;
  border: none;
  color: #93c5fd;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.df-tech-login-footer {
  text-align: center;
  margin-top: 16px;
  padding-bottom: 8px;
  font-size: 0.72rem;
  color: #475569;
}

.df-tech-login-footer span {
  color: #f59e0b;
  font-weight: 600;
}

@media (max-width: 430px) {
  .df-tech-login-overlay {
    padding: 10px 10px 48px !important;
  }

  .df-tech-login-card {
    margin: 8px auto 40px !important;
    padding: 16px 14px 32px !important;
    border-radius: 14px !important;
  }

  .df-tech-login-logo {
    width: 72px;
  }

  .df-tech-login-title {
    font-size: 1.2rem;
  }

  .df-tech-login-field {
    margin-bottom: 8px;
  }

  .df-tech-login-brand {
    margin-bottom: 10px;
  }
}
