/* Yognikshala PWA Installation Component Stylesheet */
/* Location: /yoga1/assets/css/pwa_installer.css */
/* Time Zone: Asia/Kolkata (Indian Standard Time) */

:root {
  --pwa-primary: #047857;
  --pwa-primary-hover: #065f46;
  --pwa-accent: #e8721e;
  --pwa-accent-light: #fef3c7;
  --pwa-bg-glass: rgba(255, 253, 248, 0.98);
  --pwa-dark-bg: rgba(15, 23, 42, 0.96);
}

/* Smart Top App Bar for Installed Android App Users in Web Browser */
#pwa-smart-top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 99998;
  background: linear-gradient(135deg, #047857 0%, #064e3b 100%);
  color: #ffffff;
  padding: 10px 16px;
  box-shadow: 0 4px 15px rgba(4, 120, 87, 0.35);
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  animation: slideDownTopBar 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-family: 'Manrope', system-ui, -apple-system, sans-serif;
}

@keyframes slideDownTopBar {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

/* Bottom Floating Install Banner (HIDDEN per user request: Floating FAB is used exclusively) */
#pwa-install-banner-wrapper {
  display: none !important;
}

.pwa-banner-card {
  background: var(--pwa-bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 2px solid rgba(232, 114, 30, 0.35);
  border-radius: 24px;
  box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.35), 0 8px 20px -4px rgba(43, 27, 18, 0.15), inset 0 2px 1px #ffffff;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.pwa-banner-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #047857 0%, #e8721e 50%, #f59e0b 100%);
}

.pwa-banner-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.pwa-app-identity {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pwa-app-icon-badge {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(135deg, #047857 0%, #064e3b 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px -2px rgba(4, 120, 87, 0.4), inset 0 1.5px 1.5px rgba(255, 255, 255, 0.6);
  flex-shrink: 0;
  overflow: hidden;
}

.pwa-app-icon-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pwa-app-details h4 {
  margin: 0;
  font-family: 'Manrope', 'Plus Jakarta Sans', sans-serif;
  font-size: 1rem;
  font-weight: 800;
  color: #1e293b;
  line-height: 1.25;
}

.pwa-app-details p {
  margin: 2px 0 0;
  font-size: 0.78rem;
  color: #64748b;
  font-weight: 600;
}

.pwa-close-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(226, 232, 240, 0.7);
  border: none;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.pwa-close-btn:hover {
  background: #cbd5e1;
  color: #0f172a;
}

.pwa-banner-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pwa-btn-install {
  flex: 1;
  background: linear-gradient(135deg, #047857 0%, #065f46 100%);
  color: #ffffff !important;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 0.88rem;
  padding: 12px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 20px -3px rgba(4, 120, 87, 0.45), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none !important;
}

.pwa-btn-install:hover {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  transform: translateY(-2px);
  box-shadow: 0 12px 26px -3px rgba(4, 120, 87, 0.6);
}

.pwa-btn-install:active {
  transform: translateY(1px);
}

.pwa-btn-later {
  background: rgba(241, 245, 249, 0.8);
  color: #475569;
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(203, 213, 225, 0.6);
  cursor: pointer;
  transition: all 0.2s ease;
}

.pwa-btn-later:hover {
  background: #e2e8f0;
  color: #1e293b;
}

/* Floating App Install Header Pill / Button */
.pwa-header-install-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #047857 0%, #065f46 100%);
  color: #ffffff !important;
  font-size: 0.78rem;
  font-weight: 800;
  padding: 6px 14px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 4px 12px -2px rgba(4, 120, 87, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  text-decoration: none !important;
  user-select: none;
}

.pwa-header-install-pill:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 18px -2px rgba(4, 120, 87, 0.55);
}

/* Modal Overlay & Dialog Containers */
#pwa-direct-modal-wrapper,
#pwa-ios-modal-wrapper,
#pwa-guide-modal-wrapper {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

#pwa-direct-modal-wrapper.show {
  display: flex !important;
}

#pwa-ios-modal-wrapper.show {
  display: flex;
  align-items: flex-end;
}

#pwa-guide-modal-wrapper.show {
  display: flex;
}

.pwa-guide-dialog {
  background: #ffffff;
  border-radius: 26px;
  padding: 24px 20px;
  width: 100%;
  max-width: 440px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
  animation: modalScaleUp 0.32s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  border: 1px solid rgba(0,0,0,0.08);
}

@keyframes modalScaleUp {
  from { transform: scale(0.9) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

.pwa-guide-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.pwa-modal-title {
  margin: 0;
  font-family: 'Manrope', 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 1.15rem;
  color: #0f172a;
}

.pwa-modal-sub {
  font-size: 0.8rem;
  color: #64748b;
  font-weight: 600;
}

/* Feature Badges for Android Installation Benefits */
.pwa-feature-badge-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
  margin: 12px 0;
}

.pwa-feature-badge-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 9px 12px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #334155;
}

.pwa-feature-badge-item i {
  color: #047857;
  font-size: 1rem;
  width: 20px;
  text-align: center;
}

.pwa-inapp-alert {
  background: #fef3c7;
  border: 1px solid #f59e0b;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 0.82rem;
  color: #92400e;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.4;
}

.pwa-inapp-alert i {
  font-size: 1.1rem;
  color: #d97706;
  margin-top: 2px;
}

.pwa-steps-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pwa-step-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 12px 14px;
  border-radius: 14px;
}

.pwa-step-num {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #047857;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.pwa-step-text {
  font-size: 0.85rem;
  color: #334155;
  line-height: 1.35;
}

.pwa-modal-footer {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}

.pwa-btn-copy-link {
  flex: 1;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.pwa-btn-copy-link:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.pwa-btn-done {
  flex: 1;
  background: #047857;
  border: none;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.88rem;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pwa-btn-done:hover {
  background: #065f46;
}

.pwa-ios-drawer {
  background: #ffffff;
  border-radius: 28px 28px 16px 16px;
  padding: 24px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 -20px 40px rgba(0, 0, 0, 0.25);
  animation: slideUpModal 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes slideUpModal {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.pwa-ios-step {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: #f8fafc;
  border-radius: 14px;
  margin-top: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
}

.pwa-ios-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #047857;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.8rem;
  flex-shrink: 0;
}

/* Toast Notification Animation */
@keyframes fadeInToast {
  from { transform: translateY(-20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Screen Size Adaptations */
@media (max-width: 640px) {
  .pwa-guide-dialog {
    padding: 20px 16px;
    border-radius: 22px;
  }
  .pwa-app-icon-badge {
    width: 44px;
    height: 44px;
  }
}

