/* TOMATO OS - Admin Console Styling (Optimized for 800x1280 Kiosk Display) */
:root {
  --admin-bg: #070e12;
  --admin-panel: #0d181f;
  --admin-card: #13232c;
  --admin-card2: #182d38;
  --admin-border: #1e3947;
  --admin-border-focus: #2ef387;
  --admin-accent: #2ef387;
  --admin-cyan: #22d3ee;
  --admin-amber: #f59e0b;
  --admin-danger: #ef233c;
  --admin-body: #d1e2eb;
  --admin-muted: #9ab3c0;
}

* {
  box-sizing: border-box;
}

body {
  background: var(--admin-bg);
  background: radial-gradient(circle at 50% 12%, #10242e 0%, #070e12 65%, #030709 100%);
  color: #f1f7f9;
  font-family: 'Prompt', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  letter-spacing: 0.005em;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* Dedicated 800x1280 Kiosk Canvas Container */
.admin-kiosk-canvas {
  width: 100%;
  max-width: 800px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 16px 14px 120px 14px;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  position: relative;
}

@media (min-width: 640px) {
  .admin-kiosk-canvas {
    padding: 18px 18px 120px 18px;
  }
}

/* Dedicated Physical 800x1280 Kiosk Display Profile */
@media screen and (min-width: 799px) and (max-width: 801px) and (min-height: 1279px) and (max-height: 1281px) {
  body {
    overflow: hidden;
    height: 1280px;
  }
  .admin-kiosk-canvas {
    width: 800px !important;
    max-width: 800px !important;
    height: 1280px !important;
    max-height: 1280px !important;
    padding: 16px 16px 110px 16px !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
  }
}

/* Glass & Card Styles */
.admin-glass {
  background: rgba(13, 24, 31, 0.92);
  backdrop-filter: blur(12px);
  border: 1px solid var(--admin-border);
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

@media (min-width: 640px) {
  .admin-glass {
    padding: 20px;
  }
}

.admin-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-border);
  border-radius: 14px;
  padding: 16px;
  transition: all 0.2s ease;
}

.admin-card:focus-within {
  border-color: rgba(46, 243, 135, 0.6);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

/* Form Inputs, Selects, and Textareas (Dark Theme & 48px Touch Ergonomics) */
input,
select,
textarea,
.admin-input,
input[type='text'],
input[type='password'],
input[type='number'],
input[type='email'],
input[type='search'],
input:where(:not([type])) {
  display: block;
  width: 100%;
  background-color: #081217 !important;
  background: #081217 !important;
  color: #ffffff !important;
  border: 1px solid var(--admin-border) !important;
  border-radius: 10px !important;
  padding: 10px 14px !important;
  font-family: 'Prompt', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-size: 15px !important;
  line-height: 1.5 !important;
  min-height: 48px !important;
  box-shadow: none !important;
  outline: none !important;
  box-sizing: border-box !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
}

input:focus,
select:focus,
textarea:focus,
.admin-input:focus,
input[type='text']:focus,
input[type='password']:focus,
input[type='number']:focus {
  outline: none !important;
  border-color: var(--admin-accent) !important;
  background-color: #0d1e26 !important;
  background: #0d1e26 !important;
  box-shadow: 0 0 0 2px rgba(46, 243, 135, 0.25) !important;
}

input::placeholder,
textarea::placeholder {
  color: #647d8c !important;
  opacity: 1 !important;
}

.admin-input-mono {
  font-family: 'Space Mono', monospace !important;
  font-weight: 700 !important;
  letter-spacing: 0.02em !important;
}

input.text-emerald-400,
.text-emerald-400 {
  color: #2ef387 !important;
}

input.text-cyan-400,
.text-cyan-400 {
  color: #22d3ee !important;
}

input.text-amber-400,
.text-amber-400 {
  color: #f59e0b !important;
}

input.text-red-400,
.text-red-400 {
  color: #ff6b7d !important;
}

textarea.admin-input,
textarea {
  min-height: 68px !important;
  resize: vertical;
}

select.admin-input,
select {
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239ab3c0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 16px !important;
  padding-right: 40px !important;
  cursor: pointer;
}

select option {
  background-color: #0d1a21;
  color: #ffffff;
  padding: 8px;
}

.admin-label {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: #d1e2eb;
  margin-bottom: 6px;
  letter-spacing: 0.005em;
}

/* Buttons */
.admin-btn-primary {
  background: #2ef387;
  color: #061e13;
  font-family: 'Prompt', sans-serif;
  font-weight: 800;
  font-size: 14.5px;
  padding: 10px 18px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s ease;
  min-height: 48px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.admin-btn-primary:active {
  transform: scale(0.97);
  background: #28dc78;
}

.admin-btn-primary:hover {
  background: #39ffa0;
  box-shadow: 0 6px 18px rgba(46, 243, 135, 0.35);
}

.admin-btn-secondary {
  background: #152731;
  color: #ffffff;
  font-family: 'Prompt', sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid var(--admin-border);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
  min-height: 48px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.admin-btn-secondary:active {
  transform: scale(0.97);
  background: #101e26;
}

.admin-btn-secondary:hover {
  background: #1c3543;
  border-color: var(--admin-cyan);
  color: #ffffff;
}

.admin-btn-danger {
  background: rgba(239, 35, 60, 0.15);
  color: #ff6b7d;
  font-family: 'Prompt', sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(239, 35, 60, 0.35);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
  min-height: 48px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.admin-btn-danger:active {
  transform: scale(0.97);
}

.admin-btn-danger:hover {
  background: rgba(239, 35, 60, 0.25);
  border-color: #ef233c;
  color: #ffffff;
}

/* Quick Navigation Header Buttons */
.admin-nav-btn {
  background: #112028;
  color: #e2eff5;
  font-family: 'Prompt', sans-serif;
  font-weight: 700;
  font-size: 13.5px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid #1f3947;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
  min-height: 46px;
  text-decoration: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  white-space: nowrap;
}

.admin-nav-btn:active {
  transform: scale(0.96);
  background: #0b151b;
}

.admin-nav-btn:hover {
  background: #172c38;
  border-color: var(--admin-cyan);
  color: #ffffff;
}

.admin-nav-btn-danger {
  background: rgba(239, 35, 60, 0.12);
  border-color: rgba(239, 35, 60, 0.3);
  color: #ff7f90;
}

.admin-nav-btn-danger:hover {
  background: rgba(239, 35, 60, 0.22);
  border-color: #ef233c;
  color: #ffffff;
}

/* 800px Kiosk Optimized Stage Segmented Control */
.admin-tab {
  padding: 8px 4px;
  border-radius: 12px;
  font-family: 'Prompt', sans-serif;
  font-weight: 700;
  color: #a4bcc8;
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-height: 52px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.admin-tab-label {
  font-size: 13.5px;
  line-height: 1.15;
  font-weight: 800;
}

.admin-tab-sub {
  font-size: 10.5px;
  font-family: 'Space Mono', monospace;
  opacity: 0.7;
}

.admin-tab:active {
  transform: scale(0.96);
}

.admin-tab:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.04);
}

.admin-tab.active {
  background: #172c38;
  border-color: var(--admin-accent);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.admin-tab.active .admin-tab-sub {
  color: var(--admin-accent);
  opacity: 1;
}

/* Toast Notification (Floats above sticky bottom bar, constrained to 800px) */
.admin-toast {
  position: fixed;
  bottom: 84px;
  left: 50%;
  transform: translateX(-50%) translateY(140%);
  width: calc(100% - 32px);
  max-width: 520px;
  background: #10261e;
  border: 1.5px solid #2ef387;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 14px;
  font-family: 'Prompt', sans-serif;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  z-index: 100;
  opacity: 0;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

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

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #081115;
}

::-webkit-scrollbar-thumb {
  background: #1c3644;
  border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--admin-accent);
}

/* Simulation Scenarios Buttons (SUS Testing) */
.sim-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 8px 6px;
  border-radius: 12px;
  border: 1px solid var(--admin-border);
  background: #0c1820;
  color: #d1e2eb;
  font-family: 'Prompt', sans-serif;
  cursor: pointer;
  transition: all 0.15s ease;
  min-height: 54px;
  text-align: center;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.sim-btn:active {
  transform: scale(0.96);
}

.sim-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}

.sim-btn.active {
  border-color: #22d3ee !important;
  background: #112836 !important;
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.4) !important;
}

.sim-btn-normal:hover, .sim-btn-normal.active {
  border-color: #2ef387 !important;
  color: #2ef387;
}

.sim-btn-warning:hover, .sim-btn-warning.active {
  border-color: #f59e0b !important;
  color: #f59e0b;
}

.sim-btn-danger:hover, .sim-btn-danger.active {
  border-color: #ef233c !important;
  color: #ff6b7d;
}

.sim-btn-amber:hover, .sim-btn-amber.active {
  border-color: #fbbf24 !important;
  color: #fbbf24;
}
