/* ═══════════════════════════════════════════
   BUTTONS - with angled corners
═══════════════════════════════════════════ */
.btn {
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  border: none;
  outline: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  position: relative;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, #0a2a4a, #0d3560);
  color: var(--accent-bright);
  border: 1px solid var(--border-active);
  padding: 10px 23px;
  clip-path: polygon(13px 0%, 100% 0%, calc(100% - 13px) 100%, 0% 100%);
  box-shadow: var(--glow-sm), inset 0 1px 0 rgba(0,200,255,0.1);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0d3560, #103f72);
  box-shadow: var(--glow-md);
  color: var(--accent-pulse);
}

.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-mid);
  padding: 10px 23px;
  clip-path: polygon(13px 0%, 100% 0%, calc(100% - 13px) 100%, 0% 100%);
}

.btn-secondary:hover {
  border-color: var(--border-active);
  color: var(--accent-bright);
  box-shadow: var(--glow-sm);
}

.btn-danger {
  background: rgba(255, 51, 85, 0.08);
  color: var(--accent-red);
  border: 1px solid rgba(255, 51, 85, 0.3);
  padding: 10px 23px;
  clip-path: polygon(13px 0%, 100% 0%, calc(100% - 13px) 100%, 0% 100%);
}

.btn-danger:hover {
  background: rgba(255, 51, 85, 0.15);
  box-shadow: 0 0 15px rgba(255, 51, 85, 0.3);
}

.btn-amber {
  background: linear-gradient(135deg, rgba(255,140,0,0.1), rgba(255,100,0,0.05));
  color: var(--accent-amber);
  border: 1px solid rgba(255, 140, 0, 0.35);
  padding: 10px 23px;
  clip-path: polygon(13px 0%, 100% 0%, calc(100% - 13px) 100%, 0% 100%);
}

.btn-amber:hover {
  box-shadow: var(--glow-amber);
}

.btn-sm {
  padding: 8px 15px;
  font-size: 13px;
}

/* ═══════════════════════════════════════════
   STATUS ITEMS (for status screen)
═══════════════════════════════════════════ */
.status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
  margin-bottom: 25px;
}

.status-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-faint);
  padding: 15px 18px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  transition: var(--transition);
}

.status-item:hover {
  border-color: var(--border-subtle);
}

.status-item-label {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 5px;
}

.status-item-value {
  font-family: var(--font-mono);
  font-size: 15px;
  color: var(--accent-green);
}

.status-item-value.warn {
  color: var(--accent-amber);
}

.info-block {
  background: var(--bg-surface);
  border: 1px solid var(--border-faint);
  border-left: 3px solid var(--border-active);
  padding: 15px 18px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.info-block-content {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  white-space: pre-wrap;
}

/* ═══════════════════════════════════════════
   BADGES with dot indicator
═══════════════════════════════════════════ */
.badge {
  font-family: var(--font-badge);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 4px 13px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.badge-active {
  color: var(--accent-green);
  background: rgba(0, 255, 157, 0.07);
  border: 1px solid rgba(0, 255, 157, 0.25);
}

.badge-active::before {
  background: var(--accent-green);
  box-shadow: var(--glow-green);
}

.badge-warning {
  color: var(--accent-amber);
  background: rgba(255, 140, 0, 0.07);
  border: 1px solid rgba(255, 140, 0, 0.25);
}

.badge-warning::before {
  background: var(--accent-amber);
  box-shadow: var(--glow-amber);
}

.badge-error {
  color: var(--accent-red);
  background: rgba(255, 51, 85, 0.07);
  border: 1px solid rgba(255, 51, 85, 0.25);
}

.badge-error::before {
  background: var(--accent-red);
}

.badge-info {
  color: var(--accent-primary);
  background: rgba(0, 180, 255, 0.07);
  border: 1px solid var(--border-mid);
}

.badge-info::before {
  background: var(--accent-primary);
  box-shadow: var(--glow-sm);
}

.badge-neutral {
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border-subtle);
}

.badge-neutral::before {
  background: var(--text-muted);
}

/* ═══════════════════════════════════════════
   FORM INPUTS - solid backgrounds
═══════════════════════════════════════════ */
.field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 15px;
}

.field-label {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.field-input,
input[type="text"],
input[type="url"],
input[type="password"],
input[type="number"],
input[type="email"],
select,
textarea {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 15px;
  padding: 10px 15px;
  outline: none;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  width: 100%;
}

.field-input:focus,
input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--glow-sm);
  background: var(--bg-panel);
}

.field-input::placeholder,
input::placeholder,
textarea::placeholder {
  color: var(--text-disabled);
}

.field-input.error {
  border-color: rgba(255, 51, 85, 0.5);
}

/* ═══════════════════════════════════════════
   CUSTOM CHECKBOX
═══════════════════════════════════════════ */
.checkbox-group {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.checkbox-box {
  width: 20px;
  height: 20px;
  border: 1px solid var(--border-mid);
  background: var(--bg-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
}

.checkbox-box.checked {
  border-color: var(--accent-primary);
  background: rgba(0, 180, 255, 0.1);
  box-shadow: var(--glow-sm);
}

.checkbox-mark {
  width: 10px;
  height: 8px;
  border-left: 2px solid var(--accent-bright);
  border-bottom: 2px solid var(--accent-bright);
  transform: rotate(-45deg) translateY(-2px);
}

.checkbox-label {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════
   TOGGLE SWITCH
═══════════════════════════════════════════ */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 45px;
  height: 23px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border-mid);
  transition: var(--transition);
  border-radius: 12px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 15px;
  width: 15px;
  left: 3px;
  bottom: 3px;
  background: var(--text-disabled);
  transition: var(--transition);
  border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
  background: rgba(0, 180, 255, 0.15);
  border-color: var(--accent-primary);
  box-shadow: var(--glow-sm);
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(22px);
  background: var(--accent-bright);
  box-shadow: 0 0 5px rgba(0, 180, 255, 0.6);
}

.toggle-switch input:focus + .toggle-slider {
  box-shadow: 0 0 1px var(--accent-primary);
}
