@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300..800;1,300..800&family=Cinzel:wght@500;700;800&display=swap');

:root {
  --du-emerald-950: #022c22;
  --du-emerald-900: #064e3b;
  --du-emerald-800: #065f46;
  --du-emerald-700: #047857;
  --du-emerald-600: #059669;
  --du-emerald-500: #10b981;
  --du-emerald-100: #d1fae5;
  --du-emerald-50:  #ecfdf5;

  --du-gold-600: #d97706;
  --du-gold-500: #eab308;
  --du-gold-400: #facc15;
  --du-gold-100: #fef9c3;
  --du-gold-50:  #fffbeb;

  --du-slate-900: #0f172a;
  --du-slate-800: #1e293b;
  --du-slate-600: #475569;
  --du-slate-400: #94a3b8;
  --du-slate-200: #e2e8f0;
  --du-slate-100: #f8fafc;

  --du-font-sans: 'Plus Jakarta Sans', sans-serif;
  --du-font-serif: 'Cinzel', Georgia, serif;

  --du-radius-xl: 16px;
  --du-radius-lg: 12px;
  --du-radius-md: 10px;

  --du-shadow-card: 0 8px 24px -4px rgba(2, 44, 34, 0.08), 0 3px 8px -2px rgba(0, 0, 0, 0.04);
  --du-shadow-glow: 0 8px 22px -4px rgba(4, 120, 87, 0.3);
}

/* Background Vegas Slideshow Canvas strictly behind everything */
.vegas-slide, .vegas-container {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: -9999 !important;
  pointer-events: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.vegas-wrapper, .vegas-overlay, .vegas-slide-inner {
  z-index: -9999 !important;
  pointer-events: none !important;
}

html, body {
  height: 100vh;
  max-height: 100vh;
  margin: 0;
  padding: 0;
  overflow: hidden !important;
}

body {
  font-family: var(--du-font-sans);
  background-color: #f0fdf4 !important;
  color: var(--du-slate-900);
  position: relative;
  z-index: 1;
  overflow: hidden !important;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Digital Signage Viewport Container - Zero Scroll */
.du-container {
  width: 100%;
  max-width: 1480px;
  margin: 0 auto;
  padding: 0.65rem 1.25rem;
  box-sizing: border-box;
  position: relative;
  z-index: 10;
  height: 100vh;
  max-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  transform: translateZ(0);
}

@media (min-width: 1680px) {
  .du-container {
    max-width: 1680px;
    padding: 0.85rem 1.75rem;
  }
}

/* Header Row & Live Digital Clock */
.du-header {
  text-align: center;
  margin-bottom: 0.4rem;
  position: relative;
  width: 100%;
  flex-shrink: 0;
}

.du-header-idle {
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: du-fade-in 0.3s ease-out;
  background: transparent;
  width: 100%;
}

/* Live Digital Clock Badge - High Performance Solid Background */
.du-clock-widget {
  background: #064e3b;
  border: 1px solid rgba(234, 179, 8, 0.4);
  border-radius: 30px;
  padding: 0.22rem 0.95rem;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.2rem;
  transform: translateZ(0);
}

.du-clock-time {
  font-family: var(--du-font-sans);
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--du-gold-400);
  letter-spacing: 0.04em;
}

.du-clock-date {
  font-size: 0.775rem;
  font-weight: 600;
  color: #f8fafc;
  border-left: 1px solid rgba(255, 255, 255, 0.25);
  padding-left: 0.55rem;
}

/* Horizontal Active Greeting Banner - High Performance Solid Background */
.du-header-active {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1.2rem;
  text-align: left;
  animation: du-pop-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  background: #ffffff;
  border: 2px solid var(--du-emerald-500);
  padding: 0.65rem 1.25rem;
  box-shadow: 0 10px 25px rgba(4, 120, 87, 0.15);
  max-width: 900px;
  margin: 0 auto;
  border-radius: var(--du-radius-xl);
  box-sizing: border-box;
  transform: translateZ(0);
}

.du-header-active-info {
  flex: 1;
  min-width: 0;
}

@keyframes du-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes du-pop-in {
  from { opacity: 0; transform: scale(0.95) translateY(-5px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.du-logo-wrapper {
  position: relative;
  margin-bottom: 0.1rem;
}

.du-logo-img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.25));
  transition: transform 0.2s ease;
}

@media (min-width: 1400px) {
  .du-logo-img {
    width: 60px;
    height: 60px;
  }
}

.du-logo-img:hover {
  transform: scale(1.03);
}

/* Institutional Title with Text Outline / Outfill */
.du-institution-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.02em;
  margin: 0 0 0.12rem 0;
  text-transform: uppercase;
  -webkit-text-stroke: 1.2px #022c22;
  text-shadow: 
    0 2px 6px rgba(0, 0, 0, 0.9),
    0 0 12px rgba(2, 44, 34, 0.8),
    -1px -1px 0 #022c22,
     1px -1px 0 #022c22,
    -1px  1px 0 #022c22,
     1px  1px 0 #022c22;
}

@media (min-width: 1400px) {
  .du-institution-name {
    font-size: 1.35rem;
    -webkit-text-stroke: 1.4px #022c22;
  }
}

.du-kiosk-tagline {
  font-size: 0.75rem;
  font-weight: 700;
  color: #ffffff;
  background: #064e3b;
  border: 1px solid rgba(234, 179, 8, 0.4);
  padding: 0.12rem 0.7rem;
  border-radius: 30px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}

.du-kiosk-tagline i {
  color: var(--du-gold-400);
}

/* High-Visibility Announcement Ticker Bar (GPU Hardware Accelerated) */
.du-announcement-ticker {
  background: linear-gradient(135deg, #064e3b 0%, #022c22 100%);
  border: 2px solid var(--du-gold-500);
  border-radius: var(--du-radius-lg);
  padding: 0.45rem 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 0.55rem;
  box-shadow: 0 5px 16px rgba(0, 0, 0, 0.18);
  flex-shrink: 0;
  transform: translateZ(0);
  contain: content;
}

.du-announcement-badge {
  background: linear-gradient(135deg, #d97706, #b45309);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 800;
  padding: 0.25rem 0.8rem;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(217, 119, 6, 0.35);
  letter-spacing: 0.02em;
}

@media (min-width: 1400px) {
  .du-announcement-badge {
    font-size: 0.925rem;
    padding: 0.3rem 0.95rem;
  }
}

.du-announcement-marquee {
  flex: 1;
  min-width: 0;
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.015em;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
  will-change: transform;
}

@media (min-width: 1400px) {
  .du-announcement-marquee {
    font-size: 1.3rem;
  }
}

/* Main Grid Layout - Zero Scroll Fit */
.du-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  align-items: stretch;
}

@media (min-width: 992px) {
  .du-grid {
    grid-template-columns: 490px 1fr;
    gap: 1.15rem;
  }
}

@media (min-width: 1400px) {
  .du-grid {
    grid-template-columns: 550px 1fr;
    gap: 1.35rem;
  }
}

@media (min-width: 1680px) {
  .du-grid {
    grid-template-columns: 600px 1fr;
    gap: 1.5rem;
  }
}

/* Left Column wrapper */
.du-left-col {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

/* Right Column wrapper */
.du-right-col {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

/* Summary Kiosk Stats Counter Bar */
.du-stats-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
  flex-shrink: 0;
}

.du-stat-card {
  background: #ffffff;
  border-radius: var(--du-radius-lg);
  border: 1.5px solid rgba(6, 95, 70, 0.12);
  padding: 0.55rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  box-shadow: 0 2px 8px rgba(2, 44, 34, 0.04);
  min-width: 0;
  box-sizing: border-box;
  transform: translateZ(0);
}

.du-stat-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--du-emerald-100);
  color: var(--du-emerald-800);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.du-stat-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.du-stat-val {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  line-height: 1.15;
  margin: 0;
  white-space: nowrap;
}

.du-stat-time {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0;
  white-space: nowrap;
}

.du-stat-val-sm {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.du-stat-lbl {
  font-size: 0.625rem;
  font-weight: 600;
  color: var(--du-slate-600);
  margin-top: 0.1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Display Mode Big Stats Grid (3 Columns) */
.du-display-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
  margin-bottom: 0.45rem;
}

.du-display-stat-card {
  background: linear-gradient(135deg, var(--du-emerald-900) 0%, var(--du-emerald-950) 100%);
  border: 1.5px solid rgba(234, 179, 8, 0.35);
  border-radius: var(--du-radius-lg);
  padding: 0.45rem 0.4rem;
  text-align: center;
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(2, 44, 34, 0.15);
}

.du-display-stat-num {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--du-gold-400);
  line-height: 1.1;
}

.du-display-stat-label {
  font-size: 0.625rem;
  font-weight: 700;
  color: var(--du-emerald-100);
  margin-top: 0.12rem;
}

/* 3D Gradient Progress Bar Charts for Visit Purposes */
.du-charts-grid-stacked {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 0.45rem;
}

.du-chart-box-stacked {
  background: var(--du-slate-50);
  border: 1.5px solid var(--du-slate-200);
  border-radius: var(--du-radius-lg);
  padding: 0.5rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  box-sizing: border-box;
  width: 100%;
}

.du-chart-title-stacked {
  font-size: 0.775rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.du-bar-chart-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  width: 100%;
}

.du-bar-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  width: 100%;
}

.du-bar-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.725rem;
  font-weight: 700;
}

.du-bar-name {
  color: var(--du-slate-800);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 70%;
}

.du-bar-value-badge {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--du-emerald-800);
  background: var(--du-emerald-100);
  padding: 0.05rem 0.45rem;
  border-radius: 10px;
  white-space: nowrap;
}

.du-bar-value-badge.du-bar-gold {
  color: var(--du-gold-600);
  background: var(--du-gold-100);
}

.du-bar-track {
  width: 100%;
  height: 9px;
  background: var(--du-slate-200);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
  position: relative;
}

.du-bar-fill-3d {
  height: 100%;
  border-radius: 10px;
  background: linear-gradient(180deg, #10b981 0%, #047857 100%);
  box-shadow: 0 1px 3px rgba(4, 120, 87, 0.3);
  transition: width 0.4s ease;
}

.du-bar-fill-3d-gold {
  height: 100%;
  border-radius: 10px;
  background: linear-gradient(180deg, #facc15 0%, #d97706 100%);
  box-shadow: 0 1px 3px rgba(217, 119, 6, 0.3);
  transition: width 0.4s ease;
}

/* Leaderboard Hall of Fame - Top 3 High-Performance Card */
.du-leaderboard-card {
  background: #ffffff;
  border-radius: var(--du-radius-xl);
  border: 1.5px solid rgba(6, 95, 70, 0.12);
  box-shadow: var(--du-shadow-card);
  padding: 0.85rem 1.15rem;
  box-sizing: border-box;
  flex-shrink: 0;
  transform: translateZ(0);
  contain: content;
}

.du-leaderboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.55rem;
  padding-bottom: 0.35rem;
  border-bottom: 1.5px solid var(--du-slate-200);
}

.du-leaderboard-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.du-leaderboard-tabs {
  display: flex;
  gap: 0.35rem;
}

.du-tab-btn {
  font-size: 0.725rem;
  font-weight: 700;
  padding: 0.15rem 0.6rem;
  border-radius: 20px;
  border: 1px solid var(--du-slate-200);
  background: var(--du-slate-100);
  color: var(--du-slate-600);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.du-tab-btn.active {
  background: var(--du-emerald-700);
  color: #ffffff;
  border-color: var(--du-emerald-700);
}

.du-leaderboard-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.du-leader-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.85rem;
  background: var(--du-slate-50);
  border: 1.5px solid var(--du-slate-200);
  border-radius: var(--du-radius-lg);
  transition: transform 0.15s ease;
}

.du-leader-item:hover {
  background: #ffffff;
  border-color: var(--du-emerald-500);
  transform: translateX(3px);
}

.du-rank-badge {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
}

.du-rank-1 { background: linear-gradient(135deg, #f59e0b, #d97706); box-shadow: 0 2px 6px rgba(217, 119, 6, 0.4); }
.du-rank-2 { background: linear-gradient(135deg, #94a3b8, #64748b); box-shadow: 0 2px 5px rgba(100, 116, 139, 0.3); }
.du-rank-3 { background: linear-gradient(135deg, #d97706, #b45309); box-shadow: 0 2px 5px rgba(180, 83, 9, 0.3); }
.du-rank-other { background: var(--du-emerald-700); }

.du-leader-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2.5px solid var(--du-emerald-600);
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

@media (min-width: 1400px) {
  .du-leader-avatar {
    width: 56px;
    height: 56px;
  }
}

.du-leader-info {
  flex: 1;
  min-width: 0;
}

.du-leader-name {
  font-size: 0.925rem;
  font-weight: 800;
  color: var(--du-slate-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0 0 0.1rem 0;
}

@media (min-width: 1400px) {
  .du-leader-name {
    font-size: 1.05rem;
  }
}

.du-leader-meta {
  font-size: 0.75rem;
  color: var(--du-slate-600);
}

.du-leader-count-badge {
  font-size: 0.775rem;
  font-weight: 800;
  color: var(--du-emerald-800);
  background: var(--du-emerald-100);
  padding: 0.2rem 0.65rem;
  border-radius: 14px;
  white-space: nowrap;
}

/* Kiosk Form Card - High Performance */
.du-card {
  background: #ffffff;
  border-radius: var(--du-radius-xl);
  border: 1.5px solid rgba(6, 95, 70, 0.12);
  box-shadow: var(--du-shadow-card);
  padding: 0.95rem 1.15rem;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: visible;
  flex: 1;
  min-height: 0;
  transform: translateZ(0);
}

@media (min-width: 1400px) {
  .du-card {
    padding: 1.15rem 1.35rem;
  }
}

.du-card-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0 0 0.15rem 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.du-card-subtitle {
  font-size: 0.75rem;
  color: var(--du-slate-600);
  margin: 0 0 0.55rem 0;
  line-height: 1.3;
}

/* Form Controls */
.du-form-group {
  margin-bottom: 0.55rem;
  position: relative;
}

.du-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--du-emerald-900);
  margin-bottom: 0.2rem;
}

.du-input-group {
  position: relative;
}

.du-input-icon {
  position: absolute;
  left: 0.8rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--du-emerald-700);
  font-size: 0.85rem;
  pointer-events: none;
}

.du-input {
  width: 100%;
  padding: 0.55rem 0.7rem 0.55rem 2.2rem;
  font-family: var(--du-font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--du-slate-900);
  background: var(--du-slate-100);
  border: 2px solid var(--du-slate-200);
  border-radius: var(--du-radius-lg);
  outline: none;
  transition: border-color 0.15s ease, background 0.15s ease;
  box-sizing: border-box;
}

.du-input:focus {
  background: #ffffff;
  border-color: var(--du-emerald-600);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
}

/* Autocomplete Floating Dropdown */
.du-autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 250;
  background: #ffffff;
  border-radius: var(--du-radius-lg);
  border: 1.5px solid var(--du-emerald-500);
  box-shadow: 0 10px 24px rgba(2, 44, 34, 0.15);
  max-height: 230px;
  overflow-y: auto;
  padding: 0.25rem 0;
}

.du-autocomplete-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 0.65rem;
  cursor: pointer;
  transition: background 0.15s ease;
  border-bottom: 1px solid var(--du-slate-100);
}

.du-autocomplete-item:last-child {
  border-bottom: none;
}

.du-autocomplete-item:hover,
.du-autocomplete-item.active {
  background: var(--du-emerald-50);
}

.du-ac-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--du-emerald-600);
  flex-shrink: 0;
}

.du-ac-info {
  flex: 1;
  min-width: 0;
}

.du-ac-name {
  font-size: 0.775rem;
  font-weight: 700;
  color: var(--du-slate-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.du-ac-meta {
  font-size: 0.675rem;
  color: var(--du-slate-600);
}

.du-ac-note {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--du-gold-600);
  background: var(--du-gold-50);
  border: 1px solid rgba(217, 119, 6, 0.25);
  padding: 0.08rem 0.35rem;
  border-radius: 4px;
  margin-top: 0.1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.du-ac-arrow {
  font-size: 0.7rem;
  color: var(--du-slate-400);
  margin-left: auto;
}

/* Purpose Selection Grid */
.du-purpose-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.4rem;
  box-sizing: border-box;
}

.du-purpose-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 0.55rem;
  background: var(--du-slate-100);
  border: 1.5px solid var(--du-slate-200);
  border-radius: var(--du-radius-md);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
  user-select: none;
  min-height: 40px;
  box-sizing: border-box;
}

.du-purpose-item:hover {
  border-color: var(--du-emerald-500);
  background: #ffffff;
}

.du-purpose-item.active {
  background: var(--du-emerald-50);
  border-color: var(--du-emerald-600);
}

.du-purpose-left {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  flex: 1;
  padding-right: 0.15rem;
}

.du-purpose-icon-bg {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: #ffffff;
  color: var(--du-emerald-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  flex-shrink: 0;
}

.du-purpose-item.active .du-purpose-icon-bg {
  background: var(--du-emerald-600);
  color: #ffffff;
}

.du-purpose-text {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--du-slate-800);
  white-space: normal;
  word-break: break-word;
  line-height: 1.2;
}

.du-purpose-item.active .du-purpose-text {
  color: var(--du-emerald-950);
}

.du-check-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1.5px solid var(--du-slate-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.5rem;
  color: transparent;
  transition: background 0.15s ease, border-color 0.15s ease;
  flex-shrink: 0;
}

.du-purpose-item.active .du-check-dot {
  background: var(--du-emerald-600);
  border-color: var(--du-emerald-600);
  color: #ffffff;
}

/* Submit Button */
.du-btn-primary {
  width: 100%;
  padding: 0.6rem 1rem;
  font-family: var(--du-font-sans);
  font-size: 0.875rem;
  font-weight: 800;
  color: #ffffff;
  background: linear-gradient(135deg, var(--du-emerald-700) 0%, var(--du-emerald-900) 100%);
  border: none;
  border-radius: var(--du-radius-lg);
  cursor: pointer;
  box-shadow: var(--du-shadow-glow);
  transition: transform 0.15s ease, background 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  letter-spacing: 0.01em;
  margin-top: 0.55rem;
}

.du-btn-primary:hover {
  transform: translateY(-1px);
  background: linear-gradient(135deg, var(--du-emerald-600) 0%, var(--du-emerald-800) 100%);
}

.du-btn-primary:active {
  transform: translateY(0);
}

/* Embedded Quote Widget inside Form Card (Bottom Anchored) */
.du-card-quote {
  margin-top: 0.55rem;
  padding-top: 0;
}

.du-card-quote-box {
  background: #f0fdf4;
  border: 1.5px dashed rgba(4, 120, 87, 0.3);
  border-radius: var(--du-radius-md);
  padding: 0.6rem 0.85rem;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  box-sizing: border-box;
}

.du-card-quote-icon {
  color: var(--du-gold-600);
  font-size: 0.95rem;
  margin-top: 0.15rem;
  flex-shrink: 0;
}

@media (min-width: 1400px) {
  .du-card-quote-icon {
    font-size: 1.1rem;
  }
}

.du-card-quote-content {
  flex: 1;
  min-width: 0;
}

.du-card-quote-text {
  font-size: 0.9rem;
  font-weight: 700;
  font-style: italic;
  color: var(--du-emerald-950);
  line-height: 1.35;
  margin: 0;
  white-space: normal;
  word-break: break-word;
}

@media (min-width: 1400px) {
  .du-card-quote-text {
    font-size: 1rem;
  }
}

.du-card-quote-author {
  display: block;
  font-size: 0.775rem;
  font-weight: 800;
  color: var(--du-emerald-800);
  margin-top: 0.2rem;
  letter-spacing: 0.01em;
}

@media (min-width: 1400px) {
  .du-card-quote-author {
    font-size: 0.825rem;
  }
}

/* Horizontal Avatar Display on LEFT */
.du-large-avatar-wrapper {
  position: relative;
  display: inline-block;
  flex-shrink: 0;
}

.du-large-avatar-img {
  width: 75px;
  height: 75px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #ffffff;
  box-shadow: 0 4px 14px rgba(6, 78, 59, 0.15);
  background: #ffffff;
}

.du-avatar-status-badge {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--du-emerald-600);
  border: 2px solid #ffffff;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}

.du-greeting-msg {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0 0 0.12rem 0;
  line-height: 1.25;
}

.du-greeting-purpose {
  font-size: 0.775em;
  font-weight: 700;
  color: var(--du-emerald-700);
  background: var(--du-emerald-100);
  padding: 0.1rem 0.5rem;
  border-radius: 20px;
  display: inline-block;
  margin-left: 0.25rem;
}

.du-greeting-sub {
  font-size: 0.75rem;
  color: var(--du-slate-600);
  margin: 0;
}

/* Recent Visitors Section - High Performance Zero Scroll Fit */
.du-recent-section {
  background: #ffffff;
  border-radius: var(--du-radius-xl);
  border: 1.5px solid rgba(6, 95, 70, 0.12);
  box-shadow: var(--du-shadow-card);
  padding: 0.8rem 1.1rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-sizing: border-box;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  transform: translateZ(0);
  contain: content;
}

@media (min-width: 1400px) {
  .du-recent-section {
    padding: 0.95rem 1.25rem;
  }
}

.du-recent-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.45rem;
  padding-bottom: 0.35rem;
  border-bottom: 1.5px solid var(--du-slate-200);
  flex-shrink: 0;
}

.du-recent-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

@media (min-width: 1400px) {
  .du-recent-title {
    font-size: 1.05rem;
  }
}

.du-recent-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--du-emerald-700);
  background: var(--du-emerald-100);
  padding: 0.12rem 0.5rem;
  border-radius: 12px;
}

/* Visitor Cards Grid - 6 Items Compact Grid */
.du-visitor-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.45rem;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  align-content: start;
}

@media (min-width: 1400px) {
  .du-visitor-grid {
    gap: 0.6rem;
  }
}

@media (max-width: 640px) {
  .du-visitor-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile layout: allow the kiosk content to grow and scroll naturally. */
@media (max-width: 767px) {
  html,
  body {
    height: auto;
    max-height: none;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  .du-container {
    height: auto;
    max-height: none;
    min-height: 100vh;
    overflow: visible;
    padding: 0.75rem;
    transform: none;
  }

  .du-grid,
  .du-left-col,
  .du-right-col,
  .du-card,
  .du-stats-bar,
  .du-display-stats-grid,
  .du-purpose-list,
  .du-announcement-ticker,
  .du-recent-section,
  .du-visitor-grid {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  .du-grid {
    flex: none;
    grid-template-columns: minmax(0, 1fr);
  }

  .du-left-col,
  .du-right-col {
    display: flex;
  }

  .du-stats-bar,
  .du-display-stats-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .du-stat-card,
  .du-display-stat-card,
  .du-purpose-item,
  .du-visitor-item {
    min-width: 0;
  }

  .du-stat-time {
    font-size: 0.7rem;
  }

  .du-institution-name {
    font-size: clamp(0.85rem, 4.2vw, 1.1rem);
    line-height: 1.15;
  }

  .du-kiosk-tagline {
    max-width: 100%;
    text-align: center;
    white-space: normal;
  }

  .du-announcement-marquee {
    min-width: 0;
  }

  /* Keep the startup dialog centered in the actual mobile viewport. */
  .du-modal-overlay {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100dvh;
    min-height: 100dvh;
    max-height: 100dvh;
    box-sizing: border-box;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .du-modal-content {
    width: min(100%, 380px);
    max-height: calc(100dvh - 2rem);
    overflow-y: auto;
    margin: auto;
  }
}

.du-visitor-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.65rem;
  background: var(--du-slate-50);
  border-radius: var(--du-radius-lg);
  border: 1.5px solid var(--du-slate-200);
  transition: transform 0.15s ease, background 0.15s ease;
  min-width: 0;
  overflow: hidden;
}

@media (min-width: 1400px) {
  .du-visitor-item {
    padding: 0.55rem 0.75rem;
    gap: 0.65rem;
  }
}

.du-visitor-item:hover {
  background: #ffffff;
  border-color: var(--du-emerald-500);
  transform: translateY(-2px);
}

.du-v-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--du-emerald-600);
  flex-shrink: 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
}

@media (min-width: 1400px) {
  .du-v-avatar {
    width: 40px;
    height: 40px;
  }
}

.du-v-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.du-v-name {
  font-size: 0.775rem;
  font-weight: 700;
  color: var(--du-slate-900);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

@media (min-width: 1400px) {
  .du-v-name {
    font-size: 0.85rem;
  }
}

.du-v-meta {
  font-size: 0.675rem;
  color: var(--du-slate-600);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.08rem;
  min-width: 0;
}

@media (min-width: 1400px) {
  .du-v-meta {
    font-size: 0.725rem;
  }
}

.du-v-room {
  color: var(--du-emerald-700);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Modal Overlay */
.du-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(2, 44, 34, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.du-modal-content {
  width: 100%;
  max-width: 380px;
  background: #ffffff;
  border-radius: var(--du-radius-xl);
  padding: 1.75rem 1.5rem;
  text-align: center;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.2);
}

.du-modal-logo {
  width: 65px;
  height: 65px;
  margin: 0 auto 1rem auto;
  object-fit: contain;
}

.du-modal-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--du-emerald-950);
  margin: 0 0 0.35rem 0;
}

.du-modal-desc {
  font-size: 0.8rem;
  color: var(--du-slate-600);
  margin: 0 0 1.25rem 0;
  line-height: 1.4;
}
