/* ===== Attendance Automatic Page Styles ===== */

/* Page Header */
.attendance-automatic .page-header {
  margin-bottom: 2rem;
  padding: 2rem 0 1rem 0;
}

.attendance-automatic .header-content {
  max-width: 800px;
}

.attendance-automatic .page-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
  color: #4a4a4a;
  background: linear-gradient(135deg, #8bc34a, #6a9e34);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

html.dark-mode .attendance-automatic .page-title {
  background: linear-gradient(135deg, #ecf0f1, #a8d85f);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.attendance-automatic .page-subtitle {
  font-size: 1.1rem;
  color: #546e7a;
  margin: 0;
  font-weight: 400;
}

html.dark-mode .attendance-automatic .page-subtitle {
  color: #95a5a6;
}

/* Navigation Tabs */
.attendance-automatic .inner-tabs {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  background: white;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

html.dark-mode .attendance-automatic .inner-tabs {
  background: #2a2a2a;
}

/* Tab Button - Flat color secondary UI control */
.attendance-automatic .tab-button {
  flex: 1;
  padding: 1rem 1.5rem;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  font-family: 'Sora', system-ui, sans-serif;
  color: #495057;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.attendance-automatic .tab-button:hover {
  background: white;
  color: #4a6e1a;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.attendance-automatic .tab-button.active {
  background: linear-gradient(135deg, #8bc34a, #7ab82d);
  color: white;
  box-shadow: 0 3px 10px rgba(139, 195, 74, 0.3);
  transform: translateY(-1px);
}

.attendance-automatic .tab-button.active:hover {
  box-shadow: 0 4px 12px rgba(139, 195, 74, 0.4);
}

html.dark-mode .attendance-automatic .tab-button {
  background: linear-gradient(135deg, #1e1e1e, #2a2a2a);
  color: #d1d5db;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

html.dark-mode .attendance-automatic .tab-button:hover {
  background: #1a1a1a;
  color: #a5d461;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

html.dark-mode .attendance-automatic .tab-button.active {
  background: linear-gradient(135deg, #8bc34a, #7ab82d);
  color: white;
  box-shadow: 0 3px 10px rgba(139, 195, 74, 0.3);
}

html.dark-mode .attendance-automatic .tab-button.active:hover {
  box-shadow: 0 4px 12px rgba(139, 195, 74, 0.4);
}

.attendance-automatic .tab-button i {
  font-size: 1.125rem;
}

/* Main Content */
.attendance-automatic .automatic-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* Scanner Methods Section */
.attendance-automatic .scanner-methods-section {
  animation: fadeInUp 0.4s ease-out;
}

.attendance-automatic .methods-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 2rem;
  align-items: center;
}

.attendance-automatic .method-card {
  background: white;
  border-radius: 20px;
  padding: 2.5rem;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 2px solid transparent;
}

.attendance-automatic .method-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.attendance-automatic .fingerprint-method {
  border-color: rgba(59, 130, 246, 0.2);
}

.attendance-automatic .fingerprint-method:hover {
  border-color: rgba(59, 130, 246, 0.4);
}

.attendance-automatic .card-method {
  border-color: rgba(34, 197, 94, 0.2);
}

.attendance-automatic .card-method:hover {
  border-color: rgba(34, 197, 94, 0.4);
}

html.dark-mode .attendance-automatic .method-card {
  background: #2a2a2a;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.attendance-automatic .method-icon {
  width: 100px;
  height: 100px;
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 3rem;
  transition: all 0.3s ease;
}

.attendance-automatic .fingerprint-method .method-icon {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.15));
  color: #3b82f6;
}

.attendance-automatic .card-method .method-icon {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(22, 163, 74, 0.15));
  color: #22c55e;
}

.attendance-automatic .method-card:hover .method-icon {
  transform: scale(1.1);
}

.attendance-automatic .method-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--header-color);
  margin: 0 0 0.75rem 0;
}

html.dark-mode .attendance-automatic .method-title {
  color: #ecf0f1;
}

.attendance-automatic .method-description {
  color: #64748b;
  font-size: 0.95rem;
  margin: 0 0 1.5rem 0;
  line-height: 1.6;
}

html.dark-mode .attendance-automatic .method-description {
  color: #94a3b8;
}

.attendance-automatic .method-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(34, 197, 94, 0.1);
  color: #16a34a;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.9rem;
}

html.dark-mode .attendance-automatic .method-status {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
}

.attendance-automatic .method-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #cbd5e1;
  font-size: 1.25rem;
}

html.dark-mode .attendance-automatic .method-divider {
  color: #64748b;
}

/* Scanner Control Section */
.attendance-automatic .scanner-control-section {
  animation: fadeInUp 0.4s ease-out 0.1s backwards;
}

.attendance-automatic .control-card {
  background: white;
  border-radius: 20px;
  padding: 3rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 2px solid rgba(139, 195, 74, 0.1);
}

html.dark-mode .attendance-automatic .control-card {
  background: #2a2a2a;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  border-color: rgba(139, 195, 74, 0.2);
}

.attendance-automatic .scanner-display {
  text-align: center;
  margin-bottom: 2.5rem;
}

.attendance-automatic .scanner-animation {
  position: relative;
  width: 180px;
  height: 180px;
  margin: 0 auto 2rem;
}

.attendance-automatic .pulse-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  border: 3px solid #8bc34a;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: pulse 2s ease-out infinite;
  opacity: 0;
}

@keyframes pulse {
  0% {
    transform: translate(-50%, -50%) scale(0.5);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 0;
  }
}

.attendance-automatic .scanner-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 140px;
  height: 140px;
  background: linear-gradient(135deg, #8bc34a, #7ab82d);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: white;
  box-shadow: 0 8px 32px rgba(139, 195, 74, 0.3);
}

html.dark-mode .attendance-automatic .scanner-icon {
  background: linear-gradient(135deg, #8bc34a, #689f38);
}

.attendance-automatic .scanner-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--header-color);
  margin: 0 0 0.75rem 0;
}

html.dark-mode .attendance-automatic .scanner-title {
  color: #ecf0f1;
}

.attendance-automatic .scanner-message {
  color: #64748b;
  font-size: 1.05rem;
  margin: 0;
}

html.dark-mode .attendance-automatic .scanner-message {
  color: #94a3b8;
}

.attendance-automatic .control-buttons {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}

.attendance-automatic .control-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  border: none;
  border-radius: 12px;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: inherit;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.attendance-automatic .control-btn i {
  font-size: 1.25rem;
}

.attendance-automatic .start-btn {
  background: linear-gradient(135deg, #8bc34a, #7ab82d);
  color: white;
}

.attendance-automatic .start-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(139, 195, 74, 0.4);
}

.attendance-automatic .stop-btn {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.attendance-automatic .stop-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

.attendance-automatic .control-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Scan Result Alert */
.attendance-automatic .scan-result-alert {
  animation: slideDown 0.3s ease-out;
  margin-bottom: 2rem;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.attendance-automatic .alert-content {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  border-left: 4px solid #10b981;
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

html.dark-mode .attendance-automatic .alert-content {
  background: linear-gradient(135deg, #065f46, #047857);
  border-left-color: #10b981;
}

.attendance-automatic .alert-icon {
  font-size: 2rem;
  color: #059669;
  flex-shrink: 0;
}

html.dark-mode .attendance-automatic .alert-icon {
  color: #34d399;
}

.attendance-automatic .alert-text {
  flex: 1;
}

.attendance-automatic .alert-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #065f46;
  margin: 0 0 0.25rem 0;
}

html.dark-mode .attendance-automatic .alert-title {
  color: #d1fae5;
}

.attendance-automatic .alert-message {
  color: #047857;
  margin: 0;
  font-size: 0.95rem;
}

html.dark-mode .attendance-automatic .alert-message {
  color: #a7f3d0;
}

.attendance-automatic .alert-close {
  background: transparent;
  border: none;
  color: #059669;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.attendance-automatic .alert-close:hover {
  background: rgba(5, 150, 105, 0.1);
}

html.dark-mode .attendance-automatic .alert-close {
  color: #34d399;
}

/* Statistics Section */
.attendance-automatic .auto-stats-section {
  animation: fadeInUp 0.4s ease-out 0.2s backwards;
}

.attendance-automatic .scanner-status-icon {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.15));
  color: #3b82f6;
}

/* Scanner status text adjustment for long messages */
.attendance-automatic #scannerStatus {
  font-size: 1.5rem;
  line-height: 1.3;
}

.attendance-automatic .time-icon {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(124, 58, 237, 0.15));
  color: #8b5cf6;
}

.attendance-automatic .count-icon {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.15));
  color: #f59e0b;
}

.attendance-automatic .success-icon {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(22, 163, 74, 0.15));
  color: #22c55e;
}

/* Recent Scans Section */
.attendance-automatic .recent-scans-section {
  animation: fadeInUp 0.4s ease-out 0.3s backwards;
}

.attendance-automatic .scans-card {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

html.dark-mode .attendance-automatic .scans-card {
  background: #2a2a2a;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.attendance-automatic .empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
  color: #94a3b8;
}

.attendance-automatic .empty-state i {
  font-size: 4rem;
  margin-bottom: 1rem;
  opacity: 0.4;
}

.attendance-automatic .empty-state p {
  font-size: 1.1rem;
  margin: 0;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design */
@media (max-width: 968px) {
  .attendance-automatic .methods-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .attendance-automatic .method-divider {
    transform: rotate(90deg);
    margin: 0;
  }
}

@media (max-width: 768px) {
  .attendance-automatic .page-title {
    font-size: 2rem;
  }

  .attendance-automatic .control-card {
    padding: 2rem;
  }

  .attendance-automatic .scanner-animation {
    width: 140px;
    height: 140px;
  }

  .attendance-automatic .scanner-icon {
    width: 110px;
    height: 110px;
    font-size: 3rem;
  }

  .attendance-automatic .control-buttons {
    flex-direction: column;
  }

  .attendance-automatic .control-btn {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .attendance-automatic .page-title {
    font-size: 1.75rem;
  }

  .attendance-automatic .page-subtitle {
    font-size: 1rem;
  }

  .attendance-automatic .method-card {
    padding: 2rem;
  }

  .attendance-automatic .method-icon {
    width: 80px;
    height: 80px;
    font-size: 2.5rem;
  }

  .attendance-automatic .control-card,
  .attendance-automatic .scans-card {
    padding: 1.5rem;
  }
}
