* { margin:0; padding:0; box-sizing:border-box; }
body { 
  font-family:'Inter',sans-serif; 
  background:#F5F7FA; 
  color:#102542; 
  padding-bottom:calc(6rem + env(safe-area-inset-bottom, 0)); 
  line-height:1.5;
  font-size:15px;
  min-height:100vh;
  position:relative;
}

header { 
  background:#102542; 
  color:#fff; 
  padding:0.5rem; 
  text-align:center; 
  font-weight:600; 
  position:fixed; 
  top:0; 
  width:100%; 
  z-index:10; 
  box-shadow:0 2px 4px rgba(0,0,0,0.1);
  display:flex;
  justify-content:center;
  align-items:center;
}

.logo-img {
  height: 40px;
  width: auto;
}

main { 
  padding: 1rem 1rem 5rem;
  max-width: 600px; 
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* Fix untuk iOS Safari dan browser lain */
@supports (-webkit-touch-callout: none) {
  nav.bottom-nav {
    position: fixed;
    position: -webkit-fixed;
  }
}

/* Pastikan navbar sentiasa kelihatann */
html {
  height: 100%;
  overflow-x: hidden;
}

/* Prevent navbar dari hilang saat scroll */
.bottom-nav {
  -webkit-transform: translate3d(0,0,0);
  transform: translate3d(0,0,0);
}

nav.bottom-nav { 
  position:fixed; 
  bottom:0; 
  left:0;
  right:0;
  width:100%; 
  display:flex; 
  justify-content:space-around; 
  background:#fff; 
  padding:0.6rem 0; 
  padding-bottom: env(safe-area-inset-bottom, 0.5rem);
  box-shadow:0 -2px 8px rgba(0,0,0,0.1); 
  border-top:1px solid #F0F0F0;
  z-index: 999;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
  will-change: transform;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

nav button { 
  background:none; 
  border:none; 
  font-size:0.8rem; 
  color:#6B7280; 
  cursor:pointer; 
  display:flex;
  flex-direction:column;
  align-items:center;
  padding:0.5rem 0.6rem;
  gap:0.25rem;
  transition:all 0.2s ease;
  min-width:65px;
}

nav button.active {
  color:#0066FF;
}

nav button svg {
  width:22px;
  height:22px;
  stroke-width:2;
  transition:all 0.2s ease;
}

nav button.active svg {
  fill:#0066FF;
  stroke:#0066FF;
}

nav button:not(.active) svg {
  fill:none;
  stroke:currentColor;
}

.hidden { display:none; }

.section-title {
  font-size:1.4rem;
  font-weight:600;
  margin-bottom:1.5rem;
  color:#102542;
}

.card {
  background:#fff;
  border-radius:12px;
  padding:1.5rem;
  margin-bottom:1rem;
  box-shadow:0 2px 8px rgba(0,0,0,0.05);
}

.stamp-card-container {
  background: linear-gradient(145deg, #0066FF, #00AAFF);
  border-radius: 16px;
  padding: 0.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 10px 20px rgba(0, 102, 255, 0.2);
  transform: perspective(800px) rotateX(2deg);
  transition: all 0.3s ease;
}

.stamp-card-container:hover {
  transform: perspective(800px) rotateX(0);
  box-shadow: 0 15px 30px rgba(0, 102, 255, 0.3);
}

.stamp-card-inner {
  background: #ffffff;
  border-radius: 12px;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
}

.stamp-card-inner::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0) 70%);
  opacity: 0.2;
  pointer-events: none;
}

.card-pattern {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  opacity: 0.03;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23000000' fill-opacity='1' fill-rule='evenodd'/%3E%3C/svg%3E");
  background-size: 80px;
}

input, select, textarea { 
  padding:0.75rem 1rem; 
  margin:0.5rem 0 1rem; 
  width:100%; 
  border:1px solid #E0E0E0;
  border-radius:8px;
  font-family:'Inter',sans-serif;
  font-size:15px;
}

textarea {
  min-height:80px;
  resize:vertical;
}

#message-content {
  min-height: 100px;
  max-height: 800px; /* Tetapkan ketinggian maksimum jika perlu */
  overflow-y: auto; /* Tambah scrollbar jika melebihi ketinggian maksimum */
  transition: height 0.1s ease;
}

/* Tambahkan style ini untuk mengekalkan format perenggan */
.stamp-reward div {
  white-space: pre-line; /* Ini akan mengekalkan perenggan (line breaks) */
}

/* Pastikan textarea juga menunjukkan format perenggan dengan betul */
#stamp-card-description {
  white-space: pre-line;
  min-height: 80px;
  /* max-height: 300px; */ /* Buang max-height supaya boleh auto expand */
  /* overflow-y: auto; */ /* Buang overflow supaya tidak ada scrollbar */
  transition: height 0.1s ease;
  resize: none; /* Prevent manual resize to let auto-resize work properly */
}

input:focus, select:focus, textarea:focus {
  outline:none;
  border-color:#0066FF;
  box-shadow:0 0 0 2px rgba(0,102,255,0.1);
}

.btn {
  padding:0.75rem 1.5rem;
  margin: 0.5rem 0 1rem;
  background:#0066FF;
  color:#fff;
  border:none;
  border-radius:8px;
  cursor:pointer;
  font-weight:500;
  transition:all 0.2s ease;
  width:100%;
  font-size:15px;
}

.btn:hover { 
  background:#0055cc; 
}

.btn-secondary {
  background:#F0F5FF;
  color:#0066FF;
}

.btn-secondary:hover {
  background:#E0ECFF;
}

.text-center {
  text-align:center;
}

/* Customer Logout Button - Enhanced Styling */
.customer-actions {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
  gap: 8px;
  padding: 0 1.5rem; /* Match card padding */
}

.customer-actions .btn-logout {
  background: #F8F9FA;
  color: #6B7280;
  border: 1px solid #E5E7EB;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 12px; /* Match card border radius */
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05); /* Match card shadow */
  width: 100%; /* Full width like the card */
  margin: 0;
  min-height: 48px; /* Better touch target */
}

.customer-actions .btn-logout:hover {
  background: #F3F4F6;
  color: #4B5563;
  border-color: #D1D5DB;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.customer-actions .btn-logout:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.customer-actions .btn-logout svg {
  width: 18px;
  height: 18px;
  stroke-width: 2;
}

.mb-1 { margin-bottom:0.5rem; }
.mb-2 { margin-bottom:1rem; }
.mb-3 { margin-bottom:1.5rem; }
.mt-1 { margin-top:0.5rem; }
.mt-2 { margin-top:1rem; }
.mt-3 { margin-top:1.5rem; }

.shop-logo { 
  width:60px; 
  height:60px; 
  object-fit:cover;
  border-radius:8px;
  margin-right:1rem; 
}

.shop-no-logo {
  width:60px;
  height:60px;
  background:#F0F5FF;
  border-radius:8px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#0066FF;
  font-weight:bold;
  font-size:1.2rem;
  margin-right:1rem;
}

.card-image {
  width:100%;
  height:160px;
  object-fit:cover;
  border-radius:8px;
  margin-bottom:1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.card-image:hover {
  transform: scale(1.02);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.card-image-container {
  text-align:center;
  margin-bottom:1.5rem;
  background:#f8f9fa;
  padding:1rem;
  border-radius:8px;
}

.card-no-image {
  width:100%;
  height:150px;
  background:#F0F5FF;
  border-radius:8px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#0066FF;
  margin-bottom:1rem;
}

.spinner { 
  border: 3px solid #f3f3f3; 
  border-top: 3px solid #0066FF; 
  border-radius: 50%; 
  width: 15px; 
  height: 15px; 
  animation: spin 1s linear infinite; 
  display: inline-block; 
  margin-left: 10px; 
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.stamp-container { 
  display:flex; 
  flex-wrap:wrap; 
  gap:8px; 
  margin-top:1rem; 
  justify-content: center;
}

.stamp { 
  width:46px; 
  height:46px; 
  border:1px solid #E0E0E0; 
  border-radius:50%; 
  display:flex; 
  align-items:center; 
  justify-content:center; 
  font-size:1rem; 
  background:#fff; 
  box-shadow:0 3px 6px rgba(0,0,0,0.1);
  transition: all 0.2s ease;
  position: relative;
  z-index: 1;
}

.stamp::before {
  content: "";
  position: absolute;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,1) 0%, rgba(240,240,240,1) 100%);
  z-index: -1;
}

.stamp.active { 
  background:#0066FF; 
  color:#fff;
  border:none;
  transform: scale(1.05);
  box-shadow: 0 4px 10px rgba(0, 102, 255, 0.3);
}

.stamp.active::before {
  display: none;
}

.stamp.gift.active {
  background: linear-gradient(145deg, #FFD700, #FFA500);
  color: #7A5200;
  font-weight: bold;
  border: none;
  box-shadow: 0 5px 15px rgba(255, 215, 0, 0.4);
  transform: scale(1.1);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stamp.gift.active svg {
  width: 24px;
  height: 24px;
  stroke: #7A5200;
  stroke-width: 2.5;
}

.stamp.gift.active::before {
  display: none;
}

.stamp.gift {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stamp.gift svg {
  width: 24px;
  height: 24px;
  stroke: #A0AEC0;
  stroke-width: 2.5;
}

.stamp-reward {
  margin-top: 1rem;
  padding: 12px;
  background: #FFF9E9;
  border-radius: 8px;
  /* border-left: 3px solid #FFD700; */
}

.stamp-reward-title {
  color: #7A5200;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.shop-header {
  display:flex;
  align-items:center;
  margin-bottom:1rem;
}

.shop-info {
  flex:1;
}

.shop-name {
  font-weight:600;
  font-size:1.1rem;
  margin-bottom:0.25rem;
}

.text-muted {
  color:#6B7280;
  font-size:0.9rem;
}

.customer-list {
  max-height:400px;
  overflow-y:auto;
}

.customer-row {
  display:flex;
  align-items:center;
  padding:0.75rem 0;
  border-bottom:1px solid #E0E0E0;
}

.customer-row:last-child {
  border-bottom:none;
}

.customer-info {
  flex:1;
  padding-right:15px;
}

.customer-name {
  font-weight:500;
}

.customer-phone {
  color:#6B7280;
  font-size:0.9rem;
}

.badge {
  background:#F0F5FF;
  color:#0066FF;
  padding:0.25rem 0.75rem;
  border-radius:999px;
  font-size:0.8rem;
  font-weight:500;
  white-space:nowrap;
  min-width:65px;
  text-align:center;
}

.badge-new {
  background:#FFEDD5;
  color:#F97316;
}

.badge-full {
  background:#DCFCE7;
  color:#22C55E;
}

.badge-pending {
  background:#FEF3C7;
  color:#D97706;
}

.badge-approved {
  background:#DCFCE7;
  color:#16A34A;
}

.badge-rejected {
  background:#FEE2E2;
  color:#DC2626;
}

.qr-container {
  background:#fff;
  padding:1.5rem;
  border-radius:8px;
  text-align:center;
  margin-top:1.5rem;
  box-shadow:0 2px 8px rgba(0,0,0,0.05);
}

.status-text {
  margin-top:1rem;
  font-weight:500;
}

.status-success {
  color:#22C55E;
}

.status-error {
  color:#EF4444;
}

.status-warning {
  color:#F97316;
}

.status-pending {
  color:#D97706;
}

.tab-buttons {
  display: flex;
  margin-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.tab-button {
  flex: 1;
  padding: 0.75rem 1rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  font-size: 0.9rem;
  color: #666;
  transition: all 0.3s ease;
}

.tab-button.active {
  color: #007bff;
  border-bottom-color: #007bff;
  font-weight: 500;
}

.tab-button:hover {
  color: #007bff;
  background-color: #f8f9fa;
}

.add-btn {
  position:fixed;
  bottom:80px;
  right:20px;
  width:50px;
  height:50px;
  background:#0066FF;
  color:#fff;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 4px 10px rgba(0,0,0,0.2);
  z-index:5;
  cursor:pointer;
  border:none;
}

.add-btn svg {
  width:24px;
  height:24px;
  stroke-width:2;
}

.modal {
  position:fixed;
  top:0;
  left:0;
  right:0;
  bottom:0;
  background:rgba(0,0,0,0.5);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:100;
  padding:1rem;
}

.modal-content {
  background:#fff;
  border-radius:12px;
  padding:1.5rem;
  width:100%;
  max-width:400px;
  box-shadow:0 4px 20px rgba(0,0,0,0.2);
}

.modal-title {
  font-size:1.2rem;
  font-weight:600;
  margin-bottom:1rem;
}

.modal-actions {
  display:flex;
  gap:10px;
  margin-top:1rem;
}

.modal-actions button {
  flex:1;
}

.customer-actions {
  display:flex;
  justify-content:flex-end;
  margin-top:1rem;
  gap:8px;
}

.customer-actions button {
  padding:0.3rem 0.8rem;
  font-size:0.8rem;
  border-radius:4px;
}

.registration-status {
  text-align: center;
  padding: 2rem 1rem;
}

.registration-status .spinner {
  margin: 0 auto;
  display: block;
  width: 40px;
  height: 40px;
  margin-bottom: 1.5rem;
}

.progress-circle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #F0F5FF;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: #0066FF;
  font-size: 1.5rem;
}

/* Login css */
/* Gaya untuk halaman login yang ditambah baik */
.login-container {
  background: linear-gradient(to bottom right, #EFF6FF, #DBEAFE);
  padding: 2rem 1.5rem;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0, 102, 255, 0.1);
}

.login-logo {
  height: 5rem;
  width: auto;
  margin: 0 auto 0.5rem;
}

.login-tagline {
  color: #2563EB;
  font-weight: 500;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

.login-card {
  background-color: white;
  padding: 1.5rem;
  border-radius: 1rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.login-title {
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  color: #1F2937;
  margin-bottom: 1rem;
}

.login-subtitle {
  text-align: center;
  color: #6B7280;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}

.input-with-icon {
  position: relative;
  margin-bottom: 1rem;
}

.input-icon {
  position: absolute;
  top: 45%;
  left: 0.75rem;
  transform: translateY(-50%);
  color: #9CA3AF;
}

.phone-input {
  width: 100%;
  padding: 0.75rem 0.75rem 0.75rem 2.5rem;
  background-color: #F9FAFB;
  border: 1px solid #E5E7EB;
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: all 0.2s ease;
}

.phone-input:focus {
  outline: none;
  border-color: #2563EB;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.login-button {
  width: 100%;
  padding: 0.75rem;
  background-color: #2563EB;
  color: white;
  border: none;
  border-radius: 0.5rem;
  font-weight: 500;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.login-button:hover {
  background-color: #1D4ED8;
}

.button-icon {
  margin-left: 0.25rem;
}

.separator {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 1.5rem 0;
}

.separator::before,
.separator::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid #E5E7EB;
}

.separator-text {
  padding: 0 0.5rem;
  color: #6B7280;
  font-size: 0.875rem;
}

.seller-button {
  width: 100%;
  padding: 0.75rem;
  background-color: #F3F4F6;
  color: #4B5563;
  border: 1px solid #D1D5DB;
  border-radius: 0.5rem;
  font-weight: 500;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.seller-button:hover {
  background-color: #E5E7EB;
}

.seller-icon {
  margin-right: 0.5rem;
}

.trust-text {
  text-align: center;
  color: #6B7280;
  font-size: 0.75rem;
  margin-top: 1.5rem;
}

/* Animasi untuk elemen visual */
@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

@keyframes glow {
  0% { opacity: 0.7; }
  50% { opacity: 1; }
  100% { opacity: 0.7; }
}

/* Styles for Home Dashboard */
.dashboard-card {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 102, 255, 0.15);
  margin-bottom: 1.5rem;
}

.dashboard-header {
  background: linear-gradient(to right, #0066FF, #3392FF);
  padding: 1.00rem;
  color: white;
}

.dashboard-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0;
}

.dashboard-subtitle {
  color: rgba(255, 255, 255, 0.8);
  margin-top: 0.25rem;
}

.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
}

.stat-card {
  padding: 0.75rem;
  transition: all 0.2s ease;
}

.stat-card:hover {
  opacity: 0.9;
}

.stat-card-customers {
  background-color: #F0F5FF;
  cursor: pointer;
}

.stat-card-customers:hover {
  background-color: #E0ECFF;
}

.stat-card-rewards {
  background-color: #F3F0FF;
  border-left: 1px solid white;
}

.stat-card-rewards:hover {
  background-color: #EAE0FF;
}

.stat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.stat-title {
  font-size: 0.9rem;
  font-weight: 500;
  color: #1E40AF;
}

.rewards-title {
  color: #5B21B6;
}

/* Perbaikan untuk stat-icon agar bulat sempurna di semua perangkat */
.stat-icon {
  width: 2rem !important;
  height: 2rem !important;
  min-width: 2rem !important;
  min-height: 2rem !important;
  border-radius: 9999px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin-left: 10px !important;
  overflow: hidden !important;
}

.customers-icon {
  background-color: #2563EB !important;
  color: white !important;
}

.rewards-icon {
  background-color: #7C3AED !important;
  color: white !important;
}

/* Pada perangkat mobile lebih kecil, kita bisa sesuaikan ukuran */
@media (max-width: 360px) {
  .stat-icon {
    width: 1.8rem !important;
    height: 1.8rem !important;
    min-width: 1.8rem !important;
    min-height: 1.8rem !important;
  }
  
  .stat-icon svg {
    width: 14px !important;
    height: 14px !important;
  }
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
}

.customers-value {
  color: #1E40AF;
}

.rewards-value {
  color: #5B21B6;
}
.help-section {
  background: #F0F5FF;
  padding: 1rem;
  border-radius: 8px;
}

.help-buttons {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.help-button {
  display: flex;
  align-items: center;
  background: #fff;
  padding: 0.75rem;
  border-radius: 8px;
  text-decoration: none;
  color: #102542;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.help-icon {
  width: 40px;
  height: 40px;
  background: #E0ECFF;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
  color: #0066FF;
}

/* Animasi Bounce untuk Stamp */
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.stamp.active:hover {
  animation: bounce 0.8s ease infinite;
}

.stamp.gift:hover {
  animation: bounce 0.8s ease infinite;
}

.history-item {
  padding: 0.75rem;
  border-bottom: 1px solid #E0E0E0;
  position: relative;
}

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

.history-date {
  font-size: 0.75rem;
  color: #6B7280;
  margin-bottom: 0.25rem;
}

.history-shop {
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.history-reward {
  font-size: 0.9rem;
  color: #4B5563;
}

.empty-state {
  text-align: center;
  padding: 2rem 1rem;
  color: #6B7280;
}

.empty-state-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #D1D5DB;
}

.empty-state-lucide {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  min-height: 300px;
}

.empty-state-icon-lucide {
  width: 80px;
  height: 80px;
  margin-bottom: 1.5rem;
  opacity: 0.2;
}

.empty-state-text {
  color: #6B7280;
  font-size: 0.9rem;
  max-width: 250px;
  margin: 0 auto;
  text-align: center;  /* Tambah ni */
  line-height: 1.5;
}

/* Logo preview container */
.logo-preview-container {
  width: 150px;
  height: 150px;
  margin: 1rem auto;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #F0F5FF;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.logo-preview-image {
  max-width: 100%;
  max-height: 100%;
}

.logo-preview-placeholder {
  color: #6B7280;
  font-size: 0.9rem;
  text-align: center;
}

/* Image upload container */
.image-upload-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 10px;
}

.image-preview {
  width: 100%;
  height: 200px;
  border: 2px dashed #ccc;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  overflow: hidden;
  position: relative;
}

.image-preview.empty {
  background-color: #f9f9f9;
}

.image-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.upload-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: #666;
}

.upload-placeholder svg {
  width: 40px;
  height: 40px;
  color: #999;
}

/* mata password */
.input-with-icon-right {
  position: relative;
  margin-bottom: 1rem;
}

.input-with-icon-right input {
  width: 100%;
  padding: 0.75rem 2.5rem 0.75rem 1rem;
  border: 1px solid #E5E7EB;
  border-radius: 0.5rem;
  font-size: 1rem;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  transform: translateY(-50%);
  color: #9CA3AF;
  cursor: pointer;
}

.password-toggle:hover {
  color: #6B7280;
}

/* Progress bar styles */
.progress-bar-container {
  width: 100%;
  height: 10px;
  background-color: #E0E0E0;
  border-radius: 5px;
  margin-bottom: 10px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(to right, #0066FF, #00AAFF);
  border-radius: 5px;
  transition: width 0.5s ease;
}

.blast-progress-card {
  padding: 15px;
  background-color: #F0F5FF;
  border-radius: 8px;
  border-left: 3px solid #0066FF;
}

.blast-no-image {
  background-color: #f5f5f5;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 20px;
  text-align: center;
  color: #888;
  margin-top: 10px;
}

.blast-image {
  max-width: 100%;
  max-height: 200px;
  border-radius: 8px;
  display: block;
  margin: 0 auto;
}

/* Badge styles for blast history */
.badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 500;
}

.badge-approved {
  background-color: #DCFCE7;
  color: #16A34A;
}

.badge-rejected {
  background-color: #FEE2E2;
  color: #DC2626;
}

.badge-new {
  background-color: #FFEDD5;
  color: #F97316;
}

.blast-image {
  max-width: 100%;
  max-height: 200px;
  border-radius: 8px;
  display: block;
  margin: 0 auto;
}

/* History section */
.history-item {
  padding: 12px;
  border-bottom: 1px solid #E0E0E0;
}

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

.history-date {
  font-size: 0.8rem;
  color: #6B7280;
  margin-bottom: 5px;
}

.history-reward {
  font-size: 0.9rem;
  color: #4B5563;
  margin-top: 5px;
}

/* Layout utilities */
.d-flex {
  display: flex;
  align-items: center;
}

.flex-1 {
  flex: 1;
}

/* Empty state for no content */
.empty-state-lucide {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  text-align: center;
}

.empty-state-icon-lucide {
  width: 50px;
  height: 50px;
  opacity: 0.2;
  margin-bottom: 15px;
}

.empty-state-text {
  color: #6B7280;
  max-width: 250px;
  margin: 0 auto;
}

/* Styles for subscription tab */
.package-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

@media (max-width: 600px) {
  .package-grid {
    grid-template-columns: 1fr;
  }
}

.package-card {
  background: #fff;
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.2s ease;
  position: relative;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.package-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

.package-card.highlight {
  border: 2px solid #0066FF;
  box-shadow: 0 4px 12px rgba(0,102,255,0.15);
}

.package-badge {
  position: absolute;
  top: -12px;            /* Naikkan sedikit ke atas */
  left: 50%;
  transform: translateX(-50%);
  background: #0066FF;
  color: white;
  padding: 4px 1px;     /* Tambah sedikit padding untuk ruang yang lebih baik */
  border-radius: 50px;   /* Bulatkan lebih untuk penampilan yang lebih moden */
  font-size: 0.75rem;    /* Kecilkan sedikit saiz font */
  font-weight: 600;      /* Buat font sedikit lebih tebal */
  min-width: 100px;      /* Lebar minimum lebih sesuai untuk teks */
  text-align: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1); /* Tambah bayangan untuk kedalaman */
  letter-spacing: 0.2px; /* Tambah sedikit ruang antara huruf */
  text-transform: uppercase; /* Opsional: jadikan huruf besar semua */
}

.package-amount {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #102542;
}

.package-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0066FF;
  margin-bottom: 0.5rem;
}

.package-discount {
  background: #DCFCE7;
  color: #16A34A;
  padding: 3px 8px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  display: inline-block;
  margin-bottom: 0.5rem;
}

.package-desc {
  color: #6B7280;
  margin-bottom: 1rem;
}

.subscription-info {
  padding: 0.5rem;
}

.subscription-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.subscription-title {
  font-weight: 600;
}

.subscription-stats {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: #6B7280;
}

/* Styles for payment notification */
.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  max-width: 350px;
  display: flex;
  align-items: center;
  padding: 16px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  z-index: 1000;
}

.notification.success {
  background-color: #DCFCE7;
  border-left: 4px solid #16A34A;
  color: #166534;
}

.notification.error {
  background-color: #FEE2E2;
  border-left: 4px solid #DC2626;
  color: #991B1B;
}

.notification-icon {
  margin-right: 12px;
}

.notification-content {
  flex: 1;
}

.notification-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.notification-message {
  font-size: 0.9rem;
}

.notification-close {
  cursor: pointer;
  font-size: 1.2rem;
  font-weight: bold;
  margin-left: 12px;
}

/* Styles for payment success/failed pages */
.success-container, .failed-container {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
  padding: 3rem 2rem;
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.success-icon, .failed-icon {
  margin: 0 auto 1.5rem;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.success-icon {
  background-color: rgba(22, 163, 74, 0.1);
}

.failed-icon {
  background-color: rgba(220, 38, 38, 0.1);
}

.success-title, .failed-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.success-title {
  color: #16A34A;
}

.failed-title {
  color: #DC2626;
}

.success-message, .failed-message {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  color: #374151;
}

.success-details, .failed-details {
  font-size: 0.9rem;
  color: #6B7280;
  margin-bottom: 0.5rem;
}

.success-button, .failed-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: #0066FF;
  color: white;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  transition: background-color 0.2s ease;
}

.success-button:hover, .failed-button:hover {
  background-color: #0055CC;
}

.success-redirect, .failed-redirect {
  font-size: 0.8rem;
  color: #9CA3AF;
}

/* Badge untuk amaran had pelanggan */
.badge-warning {
  background: #FEF3C7;
  color: #D97706;
}

/* Alert untuk amaran had pelanggan */
.alert {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.alert-warning {
  background-color: #FEF3C7;
  border-left: 4px solid #D97706;
  color: #92400E;
}

/* Quota display styling */
.quota-text {
  font-size: 0.9rem;
  color: #6B7280;
}

.quota-progress-container {
  width: 100%;
  height: 6px;
  background-color: #E0E0E0;
  border-radius: 3px;
  margin-top: 0.5rem;
  overflow: hidden;
}

.quota-progress {
  height: 100%;
  border-radius: 3px;
  transition: width 0.5s ease;
}

.quota-warning {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: #D97706;
}

.quota-warning a {
  color: #D97706;
  text-decoration: underline;
}

/* Button with spinner styles for Add customer */
.btn .spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top: 2px solid #fff;
  border-radius: 50%;
  margin-left: 8px;
  animation: spin 1s linear infinite;
  display: inline-block;
  vertical-align: middle;
}

/* Style for disabled button */
.btn:disabled {
  background-color: #B0B0B0;
  cursor: not-allowed;
  opacity: 0.7;
}

.btn-secondary:disabled {
  background-color: #E0E0E0;
  color: #808080;
  cursor: not-allowed;
  opacity: 0.7;
}

/* Tambah style untuk login button disabled */
.login-button:disabled {
  background-color: #B0B0B0 !important;
  cursor: not-allowed !important;
  opacity: 0.7 !important;
  pointer-events: none !important;
}

/* Fix for spinner alignment in buttons */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Status text in modal */
#add-customer-status {
  margin: 10px 0;
  min-height: 20px;
  text-align: center;
}

/* Improved transitions */
.hidden {
  display: none !important;
}

/* Add smooth transition to buttons */
.btn, .btn-secondary {
  transition: background-color 0.2s ease, opacity 0.2s ease;
}

/* Penunjuk notifikasi untuk tab */
.tab-button .notification-indicator {
  position: absolute;
  top: 0;
  right: 0;
  width: 8px;
  height: 8px;
  background-color: #EF4444; /* Warna merah */
  border-radius: 50%;
  transform: translate(0, -3px);
}

/* Untuk tab dengan jumlah notifikasi */
.tab-button .notification-count {
  position: absolute;
  top: -8px;
  right: -5px;
  background-color: #EF4444;
  color: white;
  font-size: 10px;
  font-weight: bold;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

/* Untuk memastikan posisi relatif pada tab button */
.tab-button {
  position: relative;
}

/* Fixed history container - PENAMBAHBAIKAN #1 */
.history-container {
  max-height: 400px;
  overflow-y: auto;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  background: #fff;
}

/* Style untuk tip Add to Home */
.add-to-home-tip {
  background: linear-gradient(to right, #e0f2fe, #dbeafe);
  border-radius: 12px;
  padding: 16px;
  margin-top: 16px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(0, 102, 255, 0.08);
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px dashed #93c5fd;
}

.add-to-home-tip:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 102, 255, 0.12);
}

.tip-content {
  display: flex;
  align-items: center;
}

.tip-character {
  width: 60px; /* Besarkan dari 40px ke 50px */
  height: 60px; /* Besarkan dari 40px ke 50px */
  min-width: 60px; /* Besarkan dari 40px ke 50px */
  margin-right: 16px; /* Tambah margin kanan */
  display: flex;
  align-items: center;
  justify-content: center;
}


.tip-character img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tip-text {
  flex: 1;
}

.tip-text p {
  margin: 0;
  color: #1e40af;
  font-size: 1rem; /* Besarkan font dari 0.9rem ke 1rem */
  line-height: 1.5;
}

/* Style untuk modal panduan */
.guide-modal {
  background: #fff;
  border-radius: 16px;
  width: 90%;
  max-width: 400px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.guide-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: #2563eb;
  color: #fff;
}

.guide-header h3 {
  margin: 0;
  font-size: 1.1rem;
}

.close-guide {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  font-weight: bold;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.guide-content {
  padding: 20px;
}

.guide-step {
  display: flex;
  align-items: flex-start;
  margin-bottom: 16px;
}

.guide-step:last-child {
  margin-bottom: 0;
}

.step-number {
  width: 28px;
  height: 28px;
  background: #2563eb;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  margin-right: 12px;
  font-size: 0.9rem;
  margin-top: 2px;
}

.guide-step p {
  margin: 0;
  flex: 1;
  line-height: 1.5;
}

/* Responsive styling */
@media (max-width: 375px) {
  .tip-character {
    width: 45px; /* Tetap lebih besar dari versi asal */
    height: 45px;
    min-width: 45px;
  }
  
  .tip-text p {
    font-size: 0.9rem; /* Tetap lebih besar dari versi asal */
  }
}

/* Styles untuk butang import/export database */
.database-actions {
  display: none !important;
}

.database-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  background: #F0F5FF;
  color: #0066FF;
  border: 1px solid #E0ECFF;
  transition: all 0.2s ease;
  flex: 1;
  min-width: 100px;
  max-width: 150px;
}

.database-action-btn:hover {
  background: #E0ECFF;
}

/* Modal untuk upload */
.upload-modal-content {
  max-width: 500px;
}

.upload-preview {
  max-height: 300px;
  overflow-y: auto;
  margin: 15px 0;
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  padding: 10px;
}

.upload-preview table {
  width: 100%;
  border-collapse: collapse;
}

.upload-preview th, .upload-preview td {
  padding: 8px;
  text-align: left;
  border-bottom: 1px solid #E0E0E0;
}

.upload-preview th {
  background-color: #F0F5FF;
  color: #0066FF;
  font-weight: 500;
}

.upload-status {
  margin-top: 10px;
  padding: 10px;
  border-radius: 8px;
  background-color: #F0F5FF;
  color: #0066FF;
}

.upload-error {
  background-color: #FEE2E2;
  color: #DC2626;
}

.upload-success {
  background-color: #DCFCE7;
  color: #16A34A;
}

/* Responsive adjustments */
@media (max-width: 480px) {
  .database-actions {
    flex-direction: row;
  }
  
  .database-action-btn {
    flex: 1;
    min-width: 0;
    font-size: 13px;
    padding: 8px;
  }
}

/* Perbaikan untuk container pencarian dan filter */
.search-filter-container {
  display: flex;
  margin-bottom: 1rem;
  gap: 8px;
  align-items: center;
  height: 44px;
}

/* Perbaikan untuk container input pencarian */
.search-container {
  position: relative;
  flex: 1;
  height: 100%;
}

/* Perbaikan untuk input pencarian */
.search-container input {
  width: 100%;
  height: 100%;
  padding: 0 40px 0 12px;
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  font-size: 15px;
  margin: 0;
}

/* Perbaikan untuk ikon pencarian */
.search-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #6B7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin: 0;
  height: 20px;
  width: 20px;
}

/* Action buttons group sebelah search */
.action-buttons-group {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

/* Styling untuk semua action buttons (filter, download, upload) */
.action-icon-btn,
.filter-button {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6B7280;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 0;
  padding: 0;
  position: relative;
}

.action-icon-btn:hover,
.filter-button:hover {
  background: #F0F5FF;
  color: #0066FF;
  border-color: #E0ECFF;
}

.filter-indicator {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 12px;
  height: 12px;
  background-color: #0066FF;
  border-radius: 50%;
  display: none;
}

.filter-modal-content {
  padding: 1.5rem;
  max-width: 320px;
}

.filter-section {
  margin-bottom: 1.5rem;
}

.filter-section h4 {
  margin-bottom: 0.75rem;
  font-size: 1rem;
}

.filter-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-option {
  padding: 8px 12px;
  background: #F0F5FF;
  border: 1px solid #E0E0E0;
  border-radius: 6px;
  font-size: 0.9rem;
  cursor: pointer;
}

.filter-option.active {
  background: #0066FF;
  color: white;
  border-color: #0066FF;
}

#no-results-message {
  padding: 2rem 1rem;
}

/* Shortcut Menu Styles */
.shortcut-menu {
  display: flex;
  justify-content: space-around;
  background-color: white;
  margin: 0 16px 16px;
  padding: 12px 4px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.shortcut-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 25%;
  cursor: pointer;
}

.shortcut-item svg {
  margin-bottom: 8px;
}

.shortcut-item span {
  font-size: 12px;
  font-weight: 500;
  color: #1F2937;
  text-align: center;
}

/* Efek hover opsional */
.shortcut-item:hover {
  opacity: 0.8;
}

/* Responsive styles dengan fix untuk navbar */
@media (max-width: 768px) {
  nav.bottom-nav {
    padding: 0.4rem 0;
    padding-bottom: env(safe-area-inset-bottom, 0.4rem);
  }
  
  body {
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0));
  }
}

@media (max-width: 480px) {
  nav.bottom-nav {
    padding: 0.3rem 0;
    padding-bottom: env(safe-area-inset-bottom, 0.3rem);
  }
  
  nav button {
    font-size: 0.7rem;
    padding: 0.4rem 0.5rem;
    min-width: 60px;
  }
  
  nav button svg {
    width: 18px;
    height: 18px;
  }
}

/* Fix untuk zoom levels */
@media (min-resolution: 2dppx) {
  nav.bottom-nav {
    border-top-width: 0.5px;
  }
}

/* Ensure navbar stays visible at all zoom levels */
@media (max-height: 500px) {
  body {
    padding-bottom: calc(5rem + env(safe-area-inset-bottom, 0));
  }
  
  nav.bottom-nav {
    padding: 0.25rem 0;
    padding-bottom: env(safe-area-inset-bottom, 0.25rem);
  }
  
  nav button {
    padding: 0.25rem 0.5rem;
  }
}

/* Pastikan semua modal ada z-index yang betul */
.modal {
  z-index: 1000;
}

/* Fix untuk elemen yang mungkin overlap navbar */
section {
  position: relative;
  z-index: 1;
}

/* Ensure navbar is always on top of other fixed elements */
.add-btn {
  bottom: calc(80px + env(safe-area-inset-bottom, 0));
  z-index: 998; /* Lower than navbar */
}

/* Fix untuk keyboard iOS yang kadang push navbar */
@supports (-webkit-touch-callout: none) {
  /* iOS only */
  body.keyboard-open {
    padding-bottom: 0;
  }
  
  body.keyboard-open nav.bottom-nav {
    display: none;
  }
}

/* Toast notification untuk back to exit */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 14px;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  text-align: center;
  min-width: 200px;      /* <-- Minimum width */
  font-weight: 500;      /* <-- Slightly bold */
  letter-spacing: 0.3px; /* <-- Letter spacing */
}

/* Tambahan untuk tip templat */
.template-tip {
  background-color: #FFF9E9;
  border-left: 3px solid #FFD700;
  padding: 10px;
  margin: 10px 0;
  border-radius: 4px;
  font-size: 14px;
}

.template-tip a {
  color: #0066FF;
  text-decoration: underline;
}

.template-tip a:hover {
  text-decoration: none;
}

.toast.show {
  opacity: 1;
}

/* Splash Screen */
#splash-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh; /* Guna vh instead of % */
  min-height: 100%; /* Tambah min-height */
  background-color: #FFFFFF; /* Default light theme */
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
  /* Tambah ini untuk memastikan splash screen mengambil ruang penuh */
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

@media (prefers-color-scheme: dark) {
  #splash-screen {
    background-color: #000000; /* Dark theme */
  }
}

.splash-content {
  text-align: center;
  /* Tambah ini untuk memastikan content berada di tengah */
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.splash-logo {
  width: 120px;
  height: 120px;
  animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
  0% { transform: scale(0.95); }
  50% { transform: scale(1.05); }
  100% { transform: scale(0.95); }
}

#splash-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

/* Mini Splash Screen untuk Pull-to-Refresh */
#refresh-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background-color: #0066FF;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9998; /* Sedikit lebih rendah dari splash screen asal */
  transition: transform 0.3s ease-out;
  transform: translateY(-100%);
}

#refresh-indicator.visible {
  transform: translateY(0);
}

.refresh-content {
  text-align: center;
}

.refresh-logo {
  width: 40px;
  height: 40px;
  animation: pulse 1.5s infinite ease-in-out;
}

/* ========== IMPROVED APPROVAL POPUP STYLES - START ========== */
/* Main Modal Container */
.approval-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.approval-modal.closing {
  opacity: 0;
}

.approval-modal.show {
  opacity: 1;
}

/* Backdrop with Blur */
.approval-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* Modal Content Container */
.approval-modal-content {
  position: relative;
  background: linear-gradient(135deg, #0066FF 0%, #0055CC 100%);
  border-radius: 16px; /* Changed from 24px */
  max-width: 320px; /* Changed from 420px */
  width: 90%;
  padding: 2px;
  transform: scale(0.8) translateY(20px);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.approval-modal.show .approval-modal-content {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* Inner White Container */
.approval-modal-inner {
  position: relative;
  z-index: 2;
  background: white;
  border-radius: 14px; /* Changed from 22px */
  padding: 1.25rem; /* Changed from 2rem */
  overflow: visible;
}

/* Confetti Container */
.confetti-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 100;
  border-radius: 24px;
}

.confetti {
  position: absolute;
  width: 10px;
  height: 10px;
  top: -10px;
  animation: confettiFall linear infinite;
}

.confetti-square {
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

.confetti-circle {
  border-radius: 50%;
}

@keyframes confettiFall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}

/* Success Animation */
.success-animation {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
  animation: bounceIn 0.6s ease-out 0.3s both;
}

@keyframes bounceIn {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.success-circle {
  width: 60px; /* Changed from 80px */
  height: 60px; /* Changed from 80px */
  background: linear-gradient(135deg, #0066FF, #0055CC); /* Changed to Ridim blue */
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.checkmark {
  width: 35px; /* Changed from 50px */
  height: 35px; /* Changed from 50px */
  stroke-width: 3;
  stroke: white;
  stroke-miterlimit: 10;
}

.checkmark-circle {
  stroke-dasharray: 166;
  stroke-dashoffset: 166;
  animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) 0.5s forwards;
}

.checkmark-check {
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 1.1s forwards;
}

@keyframes stroke {
  100% {
    stroke-dashoffset: 0;
  }
}

/* Welcome Badge - Fixed Position */
.welcome-badge {
  position: absolute;
  top: -12px;
  right: 25px;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: white;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(245, 87, 108, 0.4);
  animation: slideDown 0.5s ease-out 0.2s both;
  z-index: 10;
}

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

/* Header Styles */
.approval-modal-header {
  text-align: center;
  margin-bottom: 1.5rem;
  animation: fadeInUp 0.5s ease-out 0.4s both;
}

.approval-modal-header h2 {
  margin: 0;
  font-size: 1.4rem; /* Changed from 1.8rem */
  font-weight: 800;
  background: linear-gradient(135deg, #0066FF, #0055CC); /* Changed to Ridim blue */
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-fill-color: transparent;
}

.approval-modal-header .subtitle {
  margin: 0.3rem 0 0; /* Changed from 0.5rem */
  color: #6B7280;
  font-size: 0.85rem; /* Changed from 1rem */
}

/* Modal Body Container */
.approval-modal-body {
  position: relative;
  z-index: 2;
  padding: 0;
}

/* Shop Showcase */

/* Specific untuk popup approval sahaja */
.approval-modal .shop-logo-container img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* For popup only */
}

.approval-modal .shop-logo {
  margin-right: 0; /* Remove margin in popup */
  border-radius: 20px; /* Match container radius */
}
.shop-showcase {
  text-align: center;
  margin-bottom: 2rem;
  animation: fadeInUp 0.5s ease-out 0.5s both;
}

.shop-logo-container {
  width: 70px; /* Changed from 100px */
  height: 70px; /* Changed from 100px */
  margin: 0 auto 0.75rem; /* Changed from 1rem */
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  border-radius: 16px; /* Changed from 20px */
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.shop-logo-container:hover {
  transform: scale(1.05);
}

.shop-logo-container.no-logo {
  background: linear-gradient(135deg, #0066FF, #0055CC); /* Changed to Ridim blue */
}

.shop-logo-container img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Changed from cover to contain */
}

.shop-initial {
  font-size: 2rem; /* Changed from 3rem */
  font-weight: 700;
  color: white;
}

.shop-name {
  margin: 0;
  font-size: 1.2rem; /* Changed from 1.5rem */
  font-weight: 700;
  color: #1F2937;
}

/* Achievement Card */
.achievement-card {
  display: flex;
  align-items: center;
  gap: 0.75rem; /* Changed from 1rem */
  padding: 0.75rem; /* Changed from 1rem */
  background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
  border-radius: 10px; /* Changed from 12px */
  margin-bottom: 1rem; /* Changed from 1.5rem */
  animation: fadeInUp 0.5s ease-out 0.6s both;
}

.achievement-icon {
  width: 36px; /* Changed from 48px */
  height: 36px; /* Changed from 48px */
  background: white;
  border-radius: 10px; /* Changed from 12px */
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.achievement-icon svg {
  width: 20px; /* Changed from 24px */
  height: 20px; /* Changed from 24px */
  stroke: #f97316;
}

.achievement-text {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.achievement-text strong {
  color: #7c2d12;
  font-size: 0.85rem; /* Changed from 0.95rem */
}

.achievement-text span {
  color: #c2410c;
  font-size: 0.75rem; /* Changed from 0.85rem */
}

/* Benefits List */
.benefits-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem; /* Changed from 0.75rem */
  margin-bottom: 1rem; /* Changed from 1.5rem */
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  opacity: 0;
  animation: fadeInLeft 0.4s ease-out forwards;
}

.benefit-item:nth-child(1) { animation-delay: 0.7s; }
.benefit-item:nth-child(2) { animation-delay: 0.8s; }
.benefit-item:nth-child(3) { animation-delay: 0.9s; }

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

.benefit-icon {
  width: 20px; /* Changed from 24px */
  height: 20px; /* Changed from 24px */
  background: linear-gradient(135deg, #0066FF, #0055CC); /* Changed to Ridim blue */
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem; /* Smaller checkmark */
  flex-shrink: 0;
}

.benefit-item span {
  color: #4B5563;
  font-size: 0.85rem; /* Changed from 0.95rem */
}

/* Footer Button */
.approval-modal-footer {
  display: flex;
  justify-content: center;
  animation: fadeInUp 0.5s ease-out 1s both;
}

.btn-view-card {
  display: flex;
  align-items: center;
  gap: 0.4rem; /* Changed from 0.5rem */
  padding: 0.75rem 1.5rem; /* Changed from 1rem 2rem */
  background: linear-gradient(135deg, #0066FF, #0055CC); /* Changed to Ridim blue */
  color: white;
  border: none;
  border-radius: 10px; /* Changed from 12px */
  font-size: 0.9rem; /* Changed from 1rem */
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 102, 255, 0.4); /* Blue shadow */
}

.btn-view-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 102, 255, 0.5); /* Blue shadow */
}

.btn-view-card:active {
  transform: translateY(0);
}

.btn-view-card svg {
  width: 16px; /* Smaller arrow */
  height: 16px;
  transition: transform 0.3s ease; /* Animation untuk hover */
}

.btn-view-card:hover svg {
  transform: translateX(4px);
}

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

/* Mobile Responsive untuk Popup */
@media (max-width: 480px) {
  .approval-modal-content {
    width: 95%;
    margin: 1rem;
  }
  
  .approval-modal-inner {
    padding: 1.5rem;
  }
  
  .approval-modal-header h2 {
    font-size: 1.5rem;
  }
  
  .shop-logo-container {
    width: 80px;
    height: 80px;
  }
  
  .shop-initial {
    font-size: 2.5rem;
  }
  
  .achievement-card {
    padding: 0.75rem;
  }
  
  .btn-view-card {
    padding: 0.875rem 1.5rem;
  }
}
/* ========== IMPROVED APPROVAL POPUP STYLES - END ========== */

/* Class untuk button Lihat Kad Saya yang berdenyut */
.btn-view-card-pulse {
  animation: redeemPulseAnimation 2s infinite, redeemGlowAnimation 2s infinite;
  background: linear-gradient(45deg, #0066FF, #00AAFF) !important;
  color: white !important;
  font-weight: 600 !important;
  position: relative;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.3);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-view-card-pulse::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: redeemShimmerAnimation 3s infinite;
}

/* Hover effect untuk button yang berdenyut */
.btn-view-card-pulse:hover {
  animation: redeemPulseAnimation 1s infinite, redeemGlowAnimation 1s infinite;
  transform: scale(1.02);
}

.btn-view-card-pulse:hover svg {
  transform: translateX(4px);
}

/* Keyframes untuk animasi button yang berdenyut */
@keyframes redeemPulseAnimation {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 15px rgba(0, 102, 255, 0.4);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 102, 255, 0.6);
  }
}

@keyframes redeemGlowAnimation {
  0%, 100% {
    box-shadow: 0 4px 15px rgba(0, 102, 255, 0.4);
  }
  50% {
    box-shadow: 0 6px 25px rgba(0, 102, 255, 0.7), 0 0 30px rgba(0, 170, 255, 0.3);
  }
}

@keyframes redeemShimmerAnimation {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

/* Prevent iOS Safari auto-zoom on input focus */
@supports (-webkit-touch-callout: none) {
  .phone-input,
  input[type="text"],
  input[type="tel"],
  input[type="email"],
  input[type="number"],
  textarea {
    font-size: 16px !important;
  }
}

/* Alternative: Target iOS specifically */
@media screen and (-webkit-min-device-pixel-ratio: 0) {
  .phone-input,
  input[type="text"],
  input[type="tel"],
  input[type="email"],
  input[type="number"],
  textarea {
    font-size: 16px !important;
  }
}

/* Modal Setup Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 400px;
    text-align: center;
}

.modal-buttons {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    justify-content: center;
}

.modal-buttons button {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.modal-buttons button:first-child {
    background: #ccc;
}

.modal-buttons button:last-child {
    background: #007bff;
    color: white;
}

/* Image Modal Styles */
.image-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.image-modal.show {
  opacity: 1;
  visibility: visible;
}

.image-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.image-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 80vh;
  z-index: 10000;
}

.image-modal-content img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.image-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.3s ease;
}

.image-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Styling untuk input kuantitas */
.quantity-selector {
  margin-bottom: 15px;
  text-align: center; /* Tambahkan ini untuk memusatkan label */
}

.quantity-selector label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}

.quantity-input {
  display: inline-flex; /* Ubah dari flex ke inline-flex */
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  margin: 0 auto; /* Tambahkan ini untuk memusatkan elemen */
  width: auto; /* Ubah dari default ke auto */
  max-width: 180px; /* Batasi lebar maksimum */
}

.quantity-controls {
  display: inline-flex; /* Ubah dari flex ke inline-flex */
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  margin: 0 auto; /* Tambahkan ini untuk memusatkan elemen */
  width: auto; /* Ubah dari default ke auto */
  max-width: 180px; /* Batasi lebar maksimum */
}

.quantity-btn {
  background: #f5f5f5;
  border: none;
  color: #333;
  font-size: 18px;
  font-weight: bold;
  height: 40px;
  width: 40px;
  cursor: pointer;
  flex-shrink: 0; /* Mencegah tombol menyusut */
}

.quantity-btn:hover {
  background: #e5e5e5;
}

#stamp-quantity {
  width: 60px;
  height: 40px;
  border: none;
  text-align: center;
  font-size: 16px;
  -moz-appearance: textfield;
  margin: 0 8px; /* Tambahkan margin kiri dan kanan untuk memberikan ruang */
}

#stamp-quantity::-webkit-outer-spin-button,
#stamp-quantity::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.quantity-controls input[type="number"]::-webkit-outer-spin-button,
.quantity-controls input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.quantity-controls input[type="number"] {
  width: 60px;
  height: 40px;
  border: none;
  text-align: center;
  font-size: 16px;
  -moz-appearance: textfield;
  margin: 0 8px; /* Tambahkan margin kiri dan kanan untuk memberikan ruang */
}

/* Report Filter Styles - DIPERBAIKI SEPENUHNYA */
.report-filter-section {
  background: #F8FAFE;
  border: 1px solid #E0ECFF;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

.date-filter-wrapper {
  margin-bottom: 20px;
}

.date-filter-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.date-input-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.date-input-group label {
  font-weight: 600;
  color: #102542;
  font-size: 14px;
  margin: 0;
}

.date-input {
  padding: 12px 16px;
  border: 2px solid #E0ECFF;
  border-radius: 8px;
  font-size: 14px;
  background: white;
  transition: all 0.2s ease;
  margin: 0;
}

.date-input:focus {
  outline: none;
  border-color: #0066FF;
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

.filter-action-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-primary {
  background: linear-gradient(145deg, #0066FF, #3392FF);
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 102, 255, 0.2);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 102, 255, 0.3);
}

.btn-secondary {
  background: white;
  color: #6B7280;
  border: 2px solid #E0E0E0;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  border-color: #0066FF;
  color: #0066FF;
  transform: translateY(-1px);
}

.quick-filter-section {
  border-top: 1px solid #E0ECFF;
  padding-top: 20px;
}

.quick-filter-label {
  font-weight: 600;
  color: #102542;
  font-size: 14px;
  margin-bottom: 12px;
}

.quick-filter-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-quick-filter {
  background: white;
  color: #0066FF;
  border: 2px solid #E0ECFF;
  padding: 10px 16px;
  border-radius: 20px;
  font-weight: 500;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-quick-filter:hover {
  background: #F0F5FF;
  border-color: #0066FF;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 102, 255, 0.1);
}

.btn-quick-filter.active {
  background: #0066FF;
  color: white;
  border-color: #0066FF;
}

.btn-small {
  padding: 8px 16px;
  font-size: 13px;
  background: #F0F5FF;
  border: 1px solid #E0ECFF;
  color: #0066FF;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.2s ease;
}

.btn-small:hover {
  background: #E0ECFF;
  border-color: #0066FF;
}

/* Compact Report Filter - Mobile Optimized */
.report-filter-section-compact {
  background: #F8FAFE;
  border: 1px solid #E0ECFF;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 16px;
}

.date-filter-compact {
  margin-bottom: 12px;
}

.date-inputs-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.date-input-compact {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.date-input-compact label {
  font-weight: 600;
  color: #102542;
  font-size: 12px;
  margin: 0;
}

.date-input-small {
  padding: 8px 10px;
  border: 1px solid #E0ECFF;
  border-radius: 6px;
  font-size: 13px;
  background: white;
  margin: 0;
  transition: border-color 0.2s ease;
}

.date-input-small:focus {
  outline: none;
  border-color: #0066FF;
  box-shadow: 0 0 0 2px rgba(0, 102, 255, 0.1);
}

.action-buttons-compact {
  display: flex;
  gap: 8px;
}

.btn-compact {
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 500;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  flex: 1;
  justify-content: center;
  border: none;
}

.btn-primary-compact {
  background: linear-gradient(145deg, #0066FF, #3392FF);
  color: white;
  box-shadow: 0 1px 3px rgba(0, 102, 255, 0.2);
}

.btn-primary-compact:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0, 102, 255, 0.3);
}

.btn-secondary-compact {
  background: white;
  color: #6B7280;
  border: 1px solid #E0E0E0;
}

.btn-secondary-compact:hover {
  border-color: #0066FF;
  color: #0066FF;
}

.quick-filters-horizontal {
  display: flex;
  gap: 6px;
  padding-top: 10px;
  border-top: 1px solid #E0ECFF;
}

.quick-btn {
  background: white;
  color: #0066FF;
  border: 1px solid #E0ECFF;
  padding: 6px 12px;
  border-radius: 16px;
  font-weight: 500;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
  flex: 1;
  text-align: center;
  white-space: nowrap;
}

.quick-btn:hover {
  background: #F0F5FF;
  border-color: #0066FF;
}

.quick-btn.active {
  background: #0066FF;
  color: white;
  border-color: #0066FF;
}

/* Mobile Responsive - Extra Small Screens */
@media (max-width: 360px) {
  .report-filter-section-compact {
    padding: 10px;
  }
  
  .date-inputs-row {
    gap: 6px;
  }
  
  .btn-compact {
    padding: 7px 10px;
    font-size: 11px;
  }
  
  .quick-btn {
    padding: 5px 8px;
    font-size: 10px;
  }
}

/* Landscape Mobile */
@media (max-width: 480px) and (orientation: landscape) {
  .date-inputs-row {
    grid-template-columns: 1fr 1fr 1fr 1fr;
    align-items: end;
  }
  
  .action-buttons-compact {
    grid-column: span 2;
  }
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 15px;
  margin-top: 10px;
}

.summary-card {
  background: #F8FAFE;
  padding: 20px 15px;
  border-radius: 12px;
  text-align: center;
  border: 1px solid #E0ECFF;
  transition: all 0.2s ease;
}

.summary-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 102, 255, 0.1);
}

.summary-card .number {
  font-size: 28px;
  font-weight: 700;
  color: #0066FF;
  margin-bottom: 8px;
  display: block;
}

.summary-card .label {
  font-size: 12px;
  color: #6B7280;
  text-transform: uppercase;
  font-weight: 500;
  letter-spacing: 0.5px;
}

.report-table-container {
  overflow-x: auto;
  margin-top: 15px;
  border-radius: 8px;
  border: 1px solid #E0E0E0;
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
}

.report-table th,
.report-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid #F0F0F0;
}

.report-table th {
  background: #F8FAFE;
  font-weight: 600;
  color: #102542;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.report-table tr:hover {
  background: #F8FAFE;
}

.top-customers-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 15px;
}

.customer-rank-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background: #F8FAFE;
  border-radius: 10px;
  border: 1px solid #E0ECFF;
  transition: all 0.2s ease;
}

.customer-rank-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 102, 255, 0.1);
}

.customer-rank-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.rank-number {
  background: linear-gradient(145deg, #0066FF, #3392FF);
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 2px 4px rgba(0, 102, 255, 0.2);
  flex-shrink: 0;
}

.customer-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.customer-name {
  font-weight: 600;
  color: #102542;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.customer-id {
  font-size: 12px;
  color: #6B7280;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stamp-count {
  font-weight: 700;
  color: #0066FF;
  font-size: 16px;
  background: #F0F5FF;
  padding: 8px 12px;
  border-radius: 20px;
  border: 1px solid #E0ECFF;
  white-space: nowrap;
  flex-shrink: 0;
}

.empty-report {
  text-align: center;
  padding: 50px 20px;
  color: #6B7280;
}

.empty-report svg {
  margin-bottom: 20px;
  opacity: 0.3;
}

.empty-report h4 {
  color: #102542;
  margin-bottom: 8px;
  font-weight: 600;
}

.empty-report p {
  color: #6B7280;
  font-size: 14px;
  line-height: 1.5;
}

/* Responsive Design */
@media (max-width: 768px) {
  .date-filter-row {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .filter-action-buttons {
    flex-direction: column;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
  }
  
  .quick-filter-buttons {
    flex-direction: column;
  }
  
  .btn-quick-filter {
    width: 100%;
    justify-content: center;
  }
  
  .summary-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .customer-rank-item {
    padding: 12px;
    align-items: center;
  }
  
  .customer-rank-info {
    gap: 10px;
  }
  
  .stamp-count {
    font-size: 15px;
    padding: 6px 10px;
  }
}

@media (max-width: 480px) {
  .report-filter-section {
    padding: 16px;
  }
  
  .date-filter-wrapper {
    margin-bottom: 16px;
  }
  
  .quick-filter-section {
    padding-top: 16px;
  }
  
  .summary-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  
  .summary-card {
    padding: 15px 10px;
  }
  
  .summary-card .number {
    font-size: 24px;
  }
  
  .summary-card .label {
    font-size: 11px;
  }
  
  .customer-rank-item {
    padding: 10px;
    align-items: center;
  }
  
  .customer-rank-info {
    gap: 8px;
  }
  
  .rank-number {
    width: 24px;
    height: 24px;
    font-size: 12px;
  }
  
  .customer-name {
    font-size: 14px;
  }
  
  .customer-id {
    font-size: 11px;
  }
  
  .stamp-count {
    font-size: 14px;
    padding: 5px 8px;
  }
  
  .btn-small {
    width: 100%;
    text-align: center;
  }
}

/* Sembunyikan database-actions yang lama */
.database-actions {
  display: none !important;
}

/* Upload Modal Styles */
.upload-modal-content {
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
}

.upload-explanation {
  margin-bottom: 20px;
}

.info-box {
  display: flex;
  gap: 12px;
  padding: 16px;
  background: #F0F9FF;
  border: 1px solid #BAE6FD;
  border-radius: 8px;
  color: #0369A1;
}

.info-box svg {
  flex-shrink: 0;
  margin-top: 2px;
}

.info-box h4 {
  margin: 0 0 4px 0;
  font-size: 16px;
  font-weight: 600;
}

.info-box p {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
}

.template-section {
  margin-bottom: 24px;
}

.template-section h4 {
  margin-bottom: 12px;
  font-size: 16px;
  color: #102542;
}

.template-preview {
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 16px;
}

.template-preview table {
  width: 100%;
  border-collapse: collapse;
}

.template-preview th,
.template-preview td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #E0E0E0;
}

.template-preview th {
  background: #F8FAFC;
  font-weight: 600;
  color: #102542;
  font-size: 14px;
}

.template-preview td {
  font-size: 14px;
  color: #374151;
}

.template-download-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: #F0F5FF;
  color: #0066FF;
  border: 1px solid #E0ECFF;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.template-download-btn:hover {
  background: #E0ECFF;
}

.upload-area {
  margin-bottom: 20px;
}

.upload-area h4 {
  margin-bottom: 12px;
  font-size: 16px;
  color: #102542;
}

.upload-drop-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
  border: 2px dashed #D1D5DB;
  border-radius: 12px;
  background: #F9FAFB;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.upload-drop-zone:hover {
  border-color: #0066FF;
  background: #F0F5FF;
}

.upload-drop-zone svg {
  color: #6B7280;
  margin-bottom: 16px;
}

.upload-drop-zone:hover svg {
  color: #0066FF;
}

.upload-text strong {
  display: block;
  font-size: 16px;
  color: #102542;
  margin-bottom: 4px;
}

.upload-text p {
  margin: 0 0 8px 0;
  color: #6B7280;
  font-size: 14px;
}

.upload-text small {
  color: #9CA3AF;
  font-size: 12px;
}

/* Pagination Styles */
.pagination-container {
  background: #fff;
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.pagination-btn {
  background: #fff;
  border: 1px solid #E0E0E0;
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  color: #6B7280;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pagination-btn:hover:not(.disabled) {
  background: #F9FAFB;
  border-color: #D1D5DB;
  color: #374151;
}

.pagination-btn.active {
  background: #0066FF;
  border-color: #0066FF;
  color: #fff;
}

.pagination-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.pagination-dots {
  color: #9CA3AF;
  padding: 0 0.25rem;
  font-size: 0.875rem;
}

.pagination-info {
  text-align: center;
  font-size: 0.875rem;
  color: #6B7280;
  margin-top: 0.5rem;
}

/* Responsive pagination untuk telefon */
@media (max-width: 480px) {
  .pagination {
    gap: 0.125rem;
  }
  
  .pagination-btn {
    padding: 0.375rem 0.5rem;
    min-width: 36px;
    height: 36px;
    font-size: 0.8rem;
  }
  
  .pagination-info {
    font-size: 0.8rem;
  }
  
  .pagination-container {
    padding: 0.75rem;
  }
}

/* Sembunyikan beberapa butang halaman pada skrin kecil */
@media (max-width: 360px) {
  .pagination-btn:not(.active):not(:first-child):not(:last-child):not(:nth-child(2)):not(:nth-last-child(2)) {
    display: none;
  }
}

/* Responsive untuk mobile - PENTING! */
@media (max-width: 480px) {
  .search-filter-container {
    flex-wrap: nowrap !important;
    gap: 8px;
    height: 44px;
  }
  
  .search-container {
    flex: 1;
    min-width: 0;
  }
  
  .action-buttons-group {
    flex-shrink: 0;
    gap: 6px;
  }
  
  .action-icon-btn,
  .filter-button {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }
  
  .action-icon-btn svg,
  .filter-button svg {
    width: 18px;
    height: 18px;
  }
}

/* TAMBAH STYLES BARU INI - Subscription info section */
.subscription-dates {
  display: flex;
  justify-content: space-between;
  margin-top: 0.5rem;
  gap: 1rem;
}

.date-item {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.date-label {
  font-size: 0.8rem;
  color: #6B7280;
  margin-bottom: 0.25rem;
}

.date-value {
  font-weight: 600;
  color: #374151;
  font-size: 0.9rem;
}

.badge-active {
  background: #DCFCE7;
  color: #16A34A;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.badge-inactive {
  background: #FEE2E2;
  color: #DC2626;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

/* Responsive design for subscription dates */
@media (max-width: 480px) {
  .subscription-dates {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .date-item {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}
/* AKHIR STYLES BARU */

/* Styling untuk paparan cop semasa dalam modal */
.current-cop-display {
  background-color: #f8f9fa;
  padding: 12px;
  border-radius: 8px;
  margin-top: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #e9ecef;
}

.cop-label {
  font-weight: 500;
  color: #495057;
  font-size: 0.9rem;
}

.cop-count {
  background-color: #F0F5FF;
  color: #0066FF;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  min-width: 65px;
  text-align: center;
}

.cop-count.cop-full {
  background-color: #DCFCE7;
  color: #22C55E;
}

/* Responsive untuk mobile */
@media (max-width: 768px) {
  .current-cop-display {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
  
  .cop-label {
    font-size: 0.85rem;
  }
}

/* Styling untuk paparan pelanggan dalam modal - konsisten dengan database */
.customer-info-modal {
  background-color: #f8f9fa;
  padding: 12px;
  border-radius: 8px;
  margin-top: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #e9ecef;
}

.customer-details {
  flex: 1;
}

.customer-info-modal .customer-name {
  font-weight: 500;
  color: #374151;
  font-size: 0.9rem;
  margin-bottom: 2px;
}

.customer-info-modal .customer-phone {
  color: #6B7280;
  font-size: 0.8rem;
}

.customer-info-modal .badge {
  background-color: #F0F5FF;
  color: #0066FF;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
}

.customer-info-modal .badge.badge-full {
  background-color: #DCFCE7;
  color: #22C55E;
}

/* Responsive untuk mobile */
@media (max-width: 768px) {
  .customer-info-modal {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
  
  .customer-details {
    text-align: center;
  }
}

/* Styling untuk customer-row dalam modal - konsisten dengan database */
.modal-content .customer-row {
  background-color: #f8f9fa;
  padding: 12px;
  border-radius: 8px;
  margin-top: 8px;
  border: 1px solid #e9ecef;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-content .customer-row .customer-info {
  flex: 1;
  text-align: left;
}

.modal-content .customer-row .customer-name {
  font-weight: 500;
  color: #374151;
  margin-bottom: 2px;
  font-size: 1rem;
}

.modal-content .customer-row .customer-phone {
  color: #6B7280;
  font-size: 0.9rem;
}

.modal-content .customer-row .badge {
  background: #F0F5FF;
  color: #0066FF;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
  min-width: 65px;
  text-align: center;
  flex-shrink: 0;
}

.modal-content .customer-row .badge.badge-full {
  background: #DCFCE7;
  color: #22C55E;
}

/* Responsive untuk mobile - kekalkan layout 2 baris */
@media (max-width: 768px) {
  .modal-content .customer-row {
    /* Kekalkan flex layout horizontal */
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
  }
  
  .modal-content .customer-row .customer-info {
    /* Kekalkan text-align left */
    text-align: left;
    flex: 1;
  }
  
  .modal-content .customer-row .customer-name {
    font-size: 0.95rem;
    margin-bottom: 1px;
  }
  
  .modal-content .customer-row .customer-phone {
    font-size: 0.85rem;
  }
  
  .modal-content .customer-row .badge {
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    min-width: 55px;
  }
}

/* Customer info display in modals */
.customer-info-display {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 12px;
  border: 1px solid #e9ecef;
}

.customer-info-display .customer-row {
  margin: 0;
}

.customer-info-display .customer-info {
  flex: 1;
}

.customer-info-display .customer-name {
  font-weight: 600;
  color: #333;
  margin-bottom: 4px;
}

.customer-info-display .customer-phone {
  color: #666;
  font-size: 14px;
}

.customer-info-display .badge {
  flex-shrink: 0;
}

/* Gift icon styling */
.badge-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gift-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: #22C55E;
  color: white;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(34, 197, 94, 0.2);
}

.gift-icon:hover {
  background: #16A34A;
  transform: scale(1.05);
  box-shadow: 0 4px 8px rgba(34, 197, 94, 0.3);
}

.gift-icon:active {
  transform: scale(0.95);
}

.gift-icon svg {
  width: 16px;
  height: 16px;
}

/* Styling untuk halaman Dalam Proses Penambahbaikan */
.maintenance-page {
  text-align: center;
  padding: 40px 20px;
}

.maintenance-icon {
  color: #FFA500 !important;
  margin-bottom: 20px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    opacity: 1;
  }
}

.maintenance-title {
  color: #333;
  font-weight: 600;
  font-size: 1.2rem;
  margin-bottom: 12px;
}

.maintenance-description {
  color: #6c757d;
  font-size: 0.9rem;
  line-height: 1.5;
  max-width: 400px;
  margin: 0 auto 24px;
}

.back-button {
  background: #f8f9fa;
  color: #6c757d;
  border: 1px solid #dee2e6;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
}

.back-button:hover {
  background: #e9ecef;
  color: #495057;
  text-decoration: none;
}

/* Customer Settings Tab Styles */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #333;
}

.form-group input[type="text"],
.form-group input[type="date"] {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="date"]:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.form-group input:disabled {
  background-color: #f8f9fa;
  color: #6c757d;
  cursor: not-allowed;
}

.form-group small {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.875rem;
}

.status-text {
  margin: 1rem 0;
  padding: 0.5rem;
  border-radius: 4px;
  font-size: 0.875rem;
}

.status-text.success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.status-text.error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Tab buttons update for 3 tabs */
.tab-buttons {
  display: flex;
  margin-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.tab-button {
  flex: 1;
  padding: 0.75rem 1rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  font-size: 0.9rem;
  color: #666;
  transition: all 0.3s ease;
}

.tab-button.active {
  color: #007bff;
  border-bottom-color: #007bff;
  font-weight: 500;
}

.tab-button:hover {
  color: #007bff;
  background-color: #f8f9fa;
}
