.customer-app {
  min-height: 100vh;
  background: var(--light);
}

/* Auth Styles */
.customer-app .auth-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--secondary) 0%, #059669 100%);
  padding: 20px;
}

.customer-app .auth-card {
  background: var(--white);
  padding: 40px;
  border-radius: var(--radius);
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-xl);
}

.customer-app .auth-header {
  text-align: center;
  margin-bottom: 24px;
}

.customer-app .auth-header .logo {
  display: flex;
  justify-content: center;
  margin-bottom: 8px;
}

.customer-app .auth-header p {
  color: var(--gray);
  margin: 0;
}

/* WhatsApp Auth Header */
.whatsapp-auth-header {
  text-align: center;
  margin-bottom: 24px;
}

.whatsapp-big-icon {
  font-size: 56px;
  display: block;
  margin-bottom: 16px;
  line-height: 1;
}

.whatsapp-auth-header h2 {
  color: var(--dark);
  margin-bottom: 8px;
  font-size: 24px;
}

.whatsapp-subtitle {
  color: var(--gray);
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
}

/* Phone Input Wrapper */
.phone-input-wrapper {
  margin-bottom: 20px;
  text-align: left;
}

.phone-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 8px;
  font-size: 14px;
}

.label-icon {
  font-size: 16px;
}

.phone-hint {
  display: block;
  font-size: 12px;
  color: var(--gray);
  margin-top: 6px;
}

.phone-input-field {
  font-size: 18px;
  letter-spacing: 0.5px;
  padding: 14px 14px 14px 90px !important;
  width: 100% !important;
  border-radius: var(--radius-sm) !important;
}

/* intl-tel-input customization */
.iti {
  width: 100%;
}

.iti__selected-flag {
  padding: 0 12px;
  background: var(--light);
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
  border: 2px solid var(--gray-lighter);
  border-right: none;
}

.iti__selected-flag:hover,
.iti__selected-flag:focus {
  background: var(--gray-lighter);
}

.iti__country-list {
  max-height: 220px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-lighter);
}

.iti__country {
  padding: 10px 12px;
}

.iti__country:hover {
  background: var(--light);
}

.iti__country.iti__highlight {
  background: #d1fae5;
}

.iti__dial-code {
  color: var(--gray);
}

/* Button with icon */
#send-otp-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--secondary);
  margin-top: 8px;
}

#send-otp-btn:hover {
  background: #059669;
}

.btn-icon {
  font-size: 18px;
}

/* Auth Footer Text */
.auth-footer-text {
  text-align: center;
  font-size: 12px;
  color: var(--gray);
  margin-top: 16px;
  margin-bottom: 0;
}

/* Legacy support */
.phone-input-group {
  display: flex;
  align-items: center;
  margin-bottom: 24px;
}

.country-code {
  background: var(--light);
  padding: 12px 16px;
  border: 2px solid var(--gray-lighter);
  border-right: none;
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
  font-weight: 600;
  color: var(--gray);
}

.phone-input {
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0 !important;
  font-size: 18px;
}

.otp-inputs {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 24px;
}

.otp-input {
  width: 48px;
  height: 56px;
  border: 2px solid var(--gray-lighter);
  border-radius: var(--radius-sm);
  text-align: center;
  font-size: 24px;
  font-weight: 700;
}

.otp-input:focus {
  outline: none;
  border-color: var(--secondary);
}

.resend-text {
  margin-top: 16px;
  font-size: 14px;
  color: var(--gray);
  text-align: center;
}

.resend-text a {
  color: var(--secondary);
  text-decoration: none;
  font-weight: 600;
}

/* App Header */
.app-header {
  background: var(--white);
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

/* App Main */
.app-main {
  max-width: 800px;
  margin: 0 auto;
  padding: 24px;
}

.welcome-section {
  margin-bottom: 32px;
}

.welcome-section h1 {
  font-size: 28px;
  margin-bottom: 4px;
}

.welcome-section p {
  color: var(--gray);
}

/* Cards Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

/* Loyalty Card */
.loyalty-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.loyalty-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-header-section {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  border-bottom: 1px solid var(--gray-lighter);
}

.card-logo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  overflow: hidden;
  flex-shrink: 0;
}

.card-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-info h3 {
  font-size: 18px;
  margin-bottom: 4px;
}

.card-info p {
  color: var(--gray);
  font-size: 14px;
  margin: 0;
}

.card-stamps-section {
  padding: 20px;
}

.stamps-mini-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 6px;
  margin-bottom: 12px;
}

.stamp-mini {
  aspect-ratio: 1;
  border-radius: 50%;
  border: 2px dashed var(--gray-lighter);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: all 0.3s;
}

.stamp-mini.filled {
  background: var(--primary);
  border: 2px solid var(--primary);
  color: var(--white);
}

.stamp-mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.card-progress {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.progress-text {
  font-weight: 600;
  color: var(--primary);
}

.card-badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.badge-completed {
  background: #dcfce7;
  color: #166534;
}

.badge-active {
  background: #e0e7ff;
  color: #3730a3;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-icon {
  font-size: 64px;
  display: block;
  margin-bottom: 16px;
}

.empty-state h3 {
  margin-bottom: 8px;
}

.empty-state p {
  color: var(--gray);
}

/* Card Detail Modal */
.card-detail-modal {
  max-width: 480px;
}

.card-detail-header {
  text-align: center;
  margin-bottom: 24px;
}

.detail-logo {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: var(--light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  margin: 0 auto 16px;
  overflow: hidden;
}

.detail-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-detail-header h2 {
  margin-bottom: 4px;
}

.card-detail-header p {
  color: var(--gray);
  margin: 0;
}

.card-detail-stamps {
  background: var(--light);
  padding: 24px;
  border-radius: var(--radius-sm);
  margin-bottom: 24px;
}

.stamp-grid-large {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.stamp-large {
  aspect-ratio: 1;
  border-radius: 50%;
  border: 3px dashed var(--gray-lighter);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: all 0.3s;
  background: var(--white);
}

.stamp-large.filled {
  background: var(--primary);
  border: 3px solid var(--primary);
  color: var(--white);
}

.stamp-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.stamp-progress-text {
  text-align: center;
  font-weight: 600;
  color: var(--primary);
  font-size: 18px;
  margin: 0;
}

.reward-info {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  padding: 20px;
  border-radius: var(--radius-sm);
  text-align: center;
  margin-bottom: 24px;
}

.reward-icon {
  font-size: 40px;
  margin-bottom: 8px;
}

.reward-info h3 {
  color: #92400e;
  margin-bottom: 4px;
}

.reward-info p {
  color: #a16207;
  margin: 0;
}

.card-detail-info {
  border-top: 1px solid var(--gray-lighter);
  padding-top: 20px;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gray);
}

.info-icon {
  font-size: 20px;
}

/* Modal Overlay */
.modal-overlay {
  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: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  padding: 20px;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9);
  transition: transform 0.3s;
  position: relative;
}

.modal-overlay.active .modal {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: var(--gray);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.modal-close:hover {
  background: var(--light);
}

/* Responsive */
@media (max-width: 480px) {
  .cards-grid {
    grid-template-columns: 1fr;
  }
  
  .stamps-mini-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .otp-input {
    width: 42px;
    height: 48px;
    font-size: 20px;
  }
}
