/* My Profile — ImpromptuIndian brand palette */

body.page-customer-app.page-profile {
  background: var(--ci-page-bg, #f9fafb);
}

body.page-customer-app.page-profile main {
  background: var(--ci-page-bg, #f9fafb);
}

body.page-profile .ci-sidebar .menu-item.active {
  background: var(--ci-brand) !important;
  color: #fff !important;
  border-radius: 0.5rem;
}

body.page-profile .ci-sidebar .menu-item.active::before {
  display: none;
}

body.page-profile .ci-sidebar .menu-item.active i,
body.page-profile .ci-sidebar .menu-item.active svg {
  color: #fff;
}

/* Page header */
.profile-page-header h1 {
  color: var(--ci-text);
  font-weight: 700;
}

.profile-page-subtitle,
.profile-muted,
body.page-profile .text-gray-500,
body.page-profile .text-gray-400 {
  color: var(--ci-text-muted);
}

body.page-profile .text-gray-300 {
  color: var(--ci-text);
}

.profile-section-icon {
  color: var(--ci-brand);
}

.profile-section-title {
  color: var(--ci-text);
}

.profile-link {
  color: var(--ci-brand);
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
}

.profile-link:hover {
  color: var(--ci-brand-hover);
}

/* Cards */
.profile-card {
  position: relative;
  background: var(--ci-card-bg);
  border: 1px solid var(--ci-border);
  border-radius: 14px;
  box-shadow: var(--ci-card-shadow);
}

.profile-overview-card {
  overflow: visible;
}

/* Avatar — solid maroon, no extra glow ring */
.profile-avatar-wrap {
  flex-shrink: 0;
}

.profile-avatar,
#avatarContainer {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: var(--ci-brand) !important;
  background-image: none !important;
  color: #fff !important;
  border: 2px solid #fff !important;
  box-shadow: var(--ci-card-shadow) !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

@media (min-width: 640px) {
  .profile-avatar,
  #avatarContainer {
    width: 5rem;
    height: 5rem;
    font-size: 1.875rem;
  }
}

@media (min-width: 768px) {
  .profile-avatar,
  #avatarContainer {
    width: 6rem;
    height: 6rem;
    font-size: 2.25rem;
  }
}

.profile-avatar-wrap:hover #avatarContainer,
#avatarContainer:hover {
  transform: scale(1.02);
  box-shadow: var(--ci-card-shadow-hover) !important;
}

.profile-avatar-upload {
  position: absolute;
  bottom: 0;
  right: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  border-radius: 999px;
  border: none;
  background: var(--ci-brand);
  color: #fff;
  cursor: pointer;
  transition: opacity 0.2s ease, background 0.15s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.profile-avatar-upload:hover {
  background: var(--ci-brand-hover);
}

.profile-verified-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  background: var(--ci-brand);
  color: #fff;
  border: none;
}

.profile-verified-badge i,
.profile-verified-badge svg {
  color: #fff;
}

/* Stat cards */
.profile-stat-card {
  background: var(--ci-card-bg);
  border: 1px solid var(--ci-border);
  border-radius: 14px;
  box-shadow: var(--ci-card-shadow);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.profile-stat-card:hover {
  box-shadow: var(--ci-card-shadow-hover);
  transform: translateY(-1px);
}

.profile-stat-value {
  color: var(--ci-brand);
  font-variant-numeric: tabular-nums;
}

/* Form fields */
.profile-field-label {
  color: var(--ci-brand);
}

.profile-field-input {
  background: #f9fafb;
  border: 1px solid var(--ci-border);
  color: var(--ci-text);
}

.profile-field-input--editable {
  background: #fff;
}

.profile-field-input--editable:focus {
  outline: none;
  border-color: var(--ci-brand);
  box-shadow: 0 0 0 2px var(--ci-brand-light);
}

/* Address pills */
.addr-pill {
  padding: 0.6rem 0.9rem;
  border-radius: 8px;
  border: 1px solid var(--ci-border);
  background: #fff;
  color: var(--ci-text);
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
}

.addr-pill:hover {
  border-color: #d1d5db;
  background: #f9fafb;
}

.addr-pill.active {
  background: var(--ci-brand);
  color: #fff;
  border-color: var(--ci-brand);
  box-shadow: none;
}

/* Inputs shared with new-order */
body.page-profile .blk-input {
  background: #fff;
  border: 1px solid var(--ci-border);
  color: var(--ci-text);
}

body.page-profile .blk-input:focus {
  border-color: var(--ci-brand);
  box-shadow: 0 0 0 2px var(--ci-brand-light);
}

/* Status rows */
.profile-status-row {
  background: #f9fafb;
  border: 1px solid var(--ci-border);
  transition: border-color 0.15s ease;
}

.profile-status-row:hover {
  border-color: var(--ci-brand-ring);
}

.profile-progress-badge {
  background: var(--ci-brand-light);
  color: var(--ci-brand);
  font-weight: 700;
}

.profile-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid var(--ci-border);
  background: #fff;
  color: var(--ci-text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.profile-btn-outline:hover {
  background: #f9fafb;
  border-color: #d1d5db;
}

/* Recent orders */
.profile-order-item {
  padding: 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--ci-border);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.profile-order-item:hover {
  border-color: var(--ci-brand-ring);
  background: #fafafa;
}

.profile-order-ref {
  color: var(--ci-text);
  font-weight: 600;
}

.profile-order-status {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  background: var(--ci-brand-light);
  color: var(--ci-brand);
}

.profile-order-status--success {
  background: rgba(5, 150, 105, 0.12);
  color: #059669;
}

.profile-order-status--pending {
  background: rgba(217, 119, 6, 0.12);
  color: #d97706;
}

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
  animation: fadeInFallback 0.5s ease 0.3s forwards;
}

.reveal.show {
  opacity: 1;
  transform: translateY(0);
}

@keyframes fadeInFallback {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes countUp {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

[id$="OrdersCount"] {
  animation: countUp 0.8s ease-out;
  font-variant-numeric: tabular-nums;
}

/* Scrollbar */
.no-scrollbar::-webkit-scrollbar {
  width: 8px;
}

.no-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}

.no-scrollbar::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 4px;
}

.no-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: thin;
  scrollbar-color: #d1d5db transparent;
}

/* Disable legacy gradient overlays that caused avatar glow */
body.page-profile .bg-gradient-to-br {
  background: var(--ci-card-bg) !important;
  background-image: none !important;
  animation: none !important;
}

body.page-profile .bg-gradient-to-br::before {
  display: none !important;
  content: none !important;
}

/* Tab active (if used) */
.tab-active {
  background-color: var(--ci-brand) !important;
  color: #fff !important;
  border-color: var(--ci-brand) !important;
}

*:focus-visible {
  outline: 2px solid var(--ci-brand);
  outline-offset: 2px;
}

main {
  animation: fadeIn 0.5s ease-in;
}

.hidden {
  display: none !important;
}

/* Map modal reuse from new-order */
body.page-profile .no-modal-panel,
body.page-profile .no-modal-close,
body.page-profile .no-btn-secondary,
body.page-profile .no-map-search,
body.page-profile .no-map-search-input,
body.page-profile .no-map-canvas,
body.page-profile .no-text-brand {
  /* defined in new-order.css */
}
