/* Hu3Hmong — Account & Community */

.account-main { padding: 32px 0 72px; min-height: 60vh; }

/* Auth */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--white);
  position: relative;
}

.auth-lang {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 4px;
  background: rgba(75, 31, 94, 0.05);
  border-radius: 999px;
  padding: 4px;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: var(--shadow);
  transition: padding 0.4s ease;
}

.auth-card--expanded {
  padding-bottom: 28px;
}

.auth-card__logo { display: flex; justify-content: center; margin-bottom: 20px; }
.auth-card__logo img { height: 56px; width: auto; }

.auth-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  background: rgba(75, 31, 94, 0.04);
  border-radius: 999px;
  padding: 4px;
}

.auth-tab {
  flex: 1;
  padding: 10px;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 700;
  color: rgba(75, 31, 94, 0.6);
  border-radius: 999px;
  transition: var(--transition);
}

.auth-tab--active {
  background: linear-gradient(135deg, var(--red), var(--gold));
  color: var(--white);
}

.auth-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--purple-950);
  text-align: center;
  margin-bottom: 8px;
}

.auth-sub { text-align: center; color: rgba(75, 31, 94, 0.6); font-size: 0.875rem; margin-bottom: 24px; }

.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-form[hidden] { display: none !important; }
#setupPasswordFields { display: flex; flex-direction: column; gap: 16px; }
#setupPasswordFields[hidden] { display: none; }

.auth-field label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: rgba(75, 31, 94, 0.8);
  margin-bottom: 6px;
}

.auth-field__optional {
  color: rgba(75, 31, 94, 0.45);
  font-weight: 500;
}

.auth-field input,
.auth-field select,
.auth-field textarea {
  width: 100%;
  padding: 13px 16px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.15);
  border-radius: var(--radius);
  color: var(--purple-950);
  font-size: 0.9375rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
  box-sizing: border-box;
}

.auth-field textarea {
  min-height: 84px;
  line-height: 1.5;
  resize: vertical;
}

.auth-field input:focus,
.auth-field select:focus,
.auth-field textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 163, 78, 0.15);
}

.auth-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 17px 28px;
  margin-top: 4px;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 48%, var(--gold) 100%);
  background-size: 200% auto;
  color: var(--white);
  font-size: 1.0625rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 2px solid rgba(201, 163, 78, 0.3);
  box-shadow: 0 4px 14px rgba(198, 40, 57, 0.25);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-position 0.35s ease;
  cursor: pointer;
}

.auth-submit:hover {
  background-position: right center;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(198, 40, 57, 0.35);
}

.auth-submit:active { transform: translateY(-1px); }

.auth-submit--login {
  animation: auth-btn-pulse 2.8s ease-in-out infinite;
}

@keyframes auth-btn-pulse {
  0%, 100% {
    box-shadow: 0 4px 14px rgba(198, 40, 57, 0.25);
  }
  50% {
    box-shadow: 0 6px 20px rgba(198, 40, 57, 0.35);
  }
}

.auth-submit--secondary {
  font-size: 0.9375rem;
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 48%, var(--gold) 100%);
  background-size: 200% auto;
  color: var(--white);
  border-color: rgba(201, 163, 78, 0.3);
  box-shadow: 0 4px 14px rgba(198, 40, 57, 0.22);
  animation: none;
}

.auth-submit--secondary:hover {
  background-position: right center;
  box-shadow: 0 6px 20px rgba(198, 40, 57, 0.32);
}

.auth-submit:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: rgba(75, 31, 94, 0.4);
  font-size: 0.75rem;
}

.auth-divider::before, .auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(75, 31, 94, 0.1);
}

.auth-social { display: flex; flex-direction: column; gap: 10px; }

/* Google Sign-In — official material button style */
.auth-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  background: #fff;
  border: 1px solid #747775;
  border-radius: 4px;
  font-family: 'Roboto', system-ui, sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  letter-spacing: 0.25px;
  color: #1f1f1f;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
  -webkit-font-smoothing: antialiased;
}

.auth-google-btn:hover {
  background: #f8faff;
  border-color: #747775;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 1px 3px 1px rgba(60, 64, 67, 0.15);
}

.auth-google-btn:active {
  background: #f1f3f4;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3);
}

.auth-google-btn:focus-visible {
  outline: none;
  border-color: #4285f4;
  box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.35);
}

.auth-google-btn__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.auth-google-btn__icon svg { display: block; width: 18px; height: 18px; }

.auth-google-btn__text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.auth-social__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.875rem;
  transition: transform 0.25s, box-shadow 0.25s;
}

.auth-social__btn:hover { transform: translateY(-2px); }

.auth-social__btn--fb { background: #1877f2; color: var(--white); }
.auth-social__btn--gg { background: #ffffff; color: var(--purple-950); border: 1px solid rgba(75, 31, 94, 0.15); }
.auth-social__btn--otp { background: rgba(75, 31, 94, 0.04); color: var(--purple-950); border: 1px solid rgba(75, 31, 94, 0.15); }

.auth-switch {
  text-align: center;
  margin-top: 20px;
  font-size: 0.875rem;
  color: rgba(75, 31, 94, 0.6);
}

.auth-switch a { color: var(--purple-800); font-weight: 600; }

.auth-back:hover { color: var(--purple-950); }

.auth-show-accounts {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px dashed rgba(75, 31, 94, 0.3);
  background: rgba(75, 31, 94, 0.03);
  color: var(--purple-950);
  font-size: 0.875rem;
  font-weight: 700;
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}

.auth-show-accounts:hover {
  background: rgba(75, 31, 94, 0.06);
  border-color: rgba(75, 31, 94, 0.45);
  color: var(--purple-950);
}

.auth-show-accounts__chevron {
  font-size: 0.75rem;
  transition: transform 0.35s ease;
}

.auth-show-accounts.is-open .auth-show-accounts__chevron { transform: rotate(180deg); }

.auth-accounts-panel {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.45s ease, opacity 0.35s ease, margin 0.35s ease;
  margin-top: 0;
}

.auth-accounts-panel.is-open {
  max-height: 280px;
  opacity: 1;
  margin-top: 12px;
  padding-top: 4px;
}

.auth-accounts-panel[hidden] { display: block !important; }

.auth-accounts__title {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(75, 31, 94, 0.5);
  margin-bottom: 10px;
}

.auth-accounts__list { display: flex; flex-direction: column; gap: 8px; }

.auth-account-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  text-align: left;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.1);
  border-radius: var(--radius);
  transition: border-color 0.25s, background 0.25s, transform 0.2s;
}

.auth-account-item:hover {
  border-color: rgba(75, 31, 94, 0.25);
  background: rgba(75, 31, 94, 0.04);
  transform: translateX(4px);
}

.auth-account-item--selected {
  border-color: rgba(201, 163, 78, 0.65);
  background: rgba(201, 163, 78, 0.05);
  box-shadow: 0 0 0 2px rgba(201, 163, 78, 0.12);
}

.auth-account-item__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.875rem;
  color: var(--white);
  flex-shrink: 0;
}

.auth-account-item__avatar--admin { background: linear-gradient(135deg, var(--red), var(--gold)); }
.auth-account-item__avatar--customer { background: linear-gradient(135deg, var(--purple-800), var(--gold)); }

.auth-account-item__body { flex: 1; min-width: 0; }
.auth-account-item__name { font-weight: 700; font-size: 0.875rem; color: var(--purple-950); }
.auth-account-item__creds {
  font-size: 0.75rem;
  color: rgba(75, 31, 94, 0.6);
  margin-top: 2px;
  font-family: ui-monospace, monospace;
}

.auth-account-item__badge {
  font-size: 0.625rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 999px;
  flex-shrink: 0;
}

.auth-account-item__badge--admin {
  background: rgba(198, 40, 57, 0.08);
  color: var(--red);
  border: 1px solid rgba(198, 40, 57, 0.2);
}

.auth-account-item__badge--customer {
  background: rgba(201, 163, 78, 0.1);
  color: var(--gold);
  border: 1px solid rgba(201, 163, 78, 0.2);
}

.auth-back {
  display: block;
  text-align: center;
  margin-top: 16px;
  color: rgba(75, 31, 94, 0.5);
  font-size: 0.875rem;
}

.auth-back:hover { color: var(--purple-950); }

/* Account layout */
.account-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 32px;
  align-items: start;
}

.account-nav {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 12px;
  position: sticky;
  top: 96px;
  box-shadow: var(--shadow);
}

.account-nav__user {
  padding: 16px;
  text-align: center;
  border-bottom: 1px solid rgba(75, 31, 94, 0.08);
  margin-bottom: 8px;
}

.account-nav__avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--red), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin: 0 auto 10px;
}

.account-nav__name { font-weight: 700; color: var(--purple-950); font-size: 0.9375rem; }

.account-nav__btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 12px 16px;
  border-radius: var(--radius);
  color: rgba(75, 31, 94, 0.7);
  font-weight: 600;
  font-size: 0.875rem;
  text-align: left;
  transition: var(--transition);
}

.account-nav__btn:hover { background: rgba(75, 31, 94, 0.04); color: var(--purple-800); }
.account-nav__btn--active { background: rgba(75, 31, 94, 0.06); color: var(--purple-800); font-weight: 700; }

.account-nav__btn--logout {
  margin-top: 8px;
  border-top: 1px solid rgba(75, 31, 94, 0.08);
  padding-top: 16px;
  color: var(--red);
}

.account-nav__btn--logout:hover {
  background: rgba(198, 40, 57, 0.06);
  color: var(--red-dark);
}

.account-panel { animation: step-in 0.35s ease; }
.account-panel[hidden] { display: none !important; }

.account-panel__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--purple-950);
  margin-bottom: 24px;
}

/* Order cards */
.order-list { display: flex; flex-direction: column; gap: 16px; }

.order-card {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 20px;
  transition: border-color 0.3s, transform 0.3s;
  box-shadow: var(--shadow);
}

.order-card:hover { border-color: rgba(201, 163, 78, 0.3); transform: translateY(-2px); }

.order-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.order-card__id { font-weight: 700; color: var(--purple-950); font-size: 0.9375rem; }
.order-card__date { font-size: 0.8125rem; color: rgba(75, 31, 94, 0.6); }

.status-badge {
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status-badge--pending { background: rgba(201, 163, 78, 0.08); color: var(--gold); border: 1px solid rgba(201, 163, 78, 0.3); }
.status-badge--production { background: rgba(91, 33, 182, 0.08); color: var(--purple-950); border: 1px solid rgba(91, 33, 182, 0.25); }
.status-badge--shipping { background: rgba(59, 130, 246, 0.08); color: #1d4ed8; border: 1px solid rgba(59, 130, 246, 0.25); }
.status-badge--delivered { background: rgba(22, 163, 74, 0.08); color: #15803d; border: 1px solid rgba(22, 163, 74, 0.25); }
.status-badge--canceled { background: rgba(220, 38, 38, 0.08); color: #b91c1c; border: 1px solid rgba(220, 38, 38, 0.25); }

.order-card__items {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.order-card__item {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: 10px;
  background: rgba(75, 31, 94, 0.025);
}

.order-card__thumb {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  object-fit: cover;
  background: rgba(75, 31, 94, 0.03);
}

.order-card__product {
  min-width: 0;
}

.order-card__product-name {
  color: var(--purple-950);
  font-size: 0.9375rem;
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 3px;
}

.order-card__product-desc {
  color: rgba(75, 31, 94, 0.66);
  display: -webkit-box;
  font-size: 0.8125rem;
  line-height: 1.45;
  margin-bottom: 4px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.order-card__product-meta {
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 800;
}

.order-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.order-card__total {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--purple-800);
}

.order-card__btn {
  padding: 10px 20px;
  background: transparent;
  border: 1px solid rgba(75, 31, 94, 0.2);
  border-radius: 999px;
  color: var(--purple-950);
  font-weight: 700;
  font-size: 0.8125rem;
  transition: var(--transition);
}

.order-card__btn:hover { background: rgba(75, 31, 94, 0.05); }

/* Order detail */
.order-detail-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
}

@media (max-width: 1024px) {
  .order-detail-grid {
    grid-template-columns: 1fr;
  }
}

/* Order timeline */
.order-timeline-card {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.order-timeline-card--canceled {
  border-color: rgba(220, 38, 38, 0.24);
  background: rgba(220, 38, 38, 0.04);
}

.order-timeline-canceled {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 18px;
  color: #b91c1c;
  font-size: 0.875rem;
  font-weight: 700;
}

.order-timeline {
  display: flex;
  justify-content: space-between;
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.order-timeline-track {
  position: absolute;
  top: 22px;
  left: 12.5%;
  right: 12.5%;
  height: 4px;
  background: rgba(75, 31, 94, 0.08);
  z-index: 1;
  border-radius: 2px;
}

.order-timeline__progress {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--red) 0%, var(--gold) 100%);
  border-radius: 2px;
  transition: width 0.4s ease;
}

.timeline-step {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  text-align: center;
}

.timeline-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid rgba(75, 31, 94, 0.15);
  color: rgba(75, 31, 94, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  margin-bottom: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
  flex-shrink: 0;
}

.timeline-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: rgba(75, 31, 94, 0.5);
  transition: color 0.3s ease;
}

.timeline-step--active .timeline-icon {
  border-color: var(--purple-800);
  color: var(--purple-800);
  background: rgba(75, 31, 94, 0.05);
}

.timeline-step--active .timeline-label {
  color: var(--purple-800);
}

.timeline-step--completed .timeline-icon {
  background: linear-gradient(135deg, var(--red), var(--gold));
  border-color: transparent;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(198, 40, 57, 0.2);
}

.timeline-step--completed .timeline-label {
  color: var(--purple-950);
  font-weight: 700;
}

.timeline-step--active .timeline-icon {
  background: linear-gradient(135deg, #2563eb, #38bdf8);
  border-color: #bfdbfe;
  color: #ffffff;
  box-shadow: 0 0 0 7px rgba(59, 130, 246, 0.18), 0 8px 18px rgba(37, 99, 235, 0.32);
  transform: translateY(-2px) scale(1.04);
}

.timeline-step--active .timeline-label {
  color: #1d4ed8;
  font-weight: 800;
}

@media (max-width: 600px) {
  .order-timeline::before,
  .order-timeline-track,
  .order-timeline__progress {
    display: none;
  }
  
  .order-timeline {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding-left: 20px;
  }
  
  .order-timeline::after {
    content: '';
    position: absolute;
    top: 10px;
    bottom: 10px;
    left: 39px;
    width: 3px;
    background: rgba(75, 31, 94, 0.08);
    z-index: 1;
  }
  
  .timeline-step {
    flex-direction: row;
    align-items: center;
    gap: 16px;
    width: 100%;
    text-align: left;
  }
  
  .timeline-icon {
    width: 38px;
    height: 38px;
    margin-bottom: 0;
    font-size: 0.95rem;
  }
}

/* Order info card group (Combined info) */
.order-info-card-group {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.order-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

@media (max-width: 768px) {
  .order-info-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

.order-info-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.order-info-col__title {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  font-weight: 700;
  border-bottom: 1px dashed rgba(75, 31, 94, 0.1);
  padding-bottom: 8px;
  margin-bottom: 4px;
}

.order-info-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.order-info-item label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: rgba(75, 31, 94, 0.45);
  letter-spacing: 0.04em;
}

.order-info-item value, 
.order-info-item p {
  font-size: 0.9375rem;
  color: var(--purple-950);
  line-height: 1.5;
  margin: 0;
}

/* Table for order items */
.order-items-card {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.order-items-card__title {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  font-weight: 700;
  margin-bottom: 20px;
}

.order-items-table {
  width: 100%;
  border-collapse: collapse;
}

.order-items-table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: rgba(75, 31, 94, 0.5);
  letter-spacing: 0.06em;
  border-bottom: 2px solid rgba(75, 31, 94, 0.08);
}

.order-items-table td {
  padding: 16px;
  border-bottom: 1px solid rgba(75, 31, 94, 0.06);
  vertical-align: middle;
}

.order-items-table tr:last-child td {
  border-bottom: none;
}

.order-items-table__prod {
  display: flex;
  align-items: center;
  gap: 16px;
}

.order-items-table__prod img {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  object-fit: cover;
  background: rgba(75, 31, 94, 0.03);
}

.order-items-table__name {
  font-weight: 600;
  color: var(--purple-950);
  font-size: 0.9375rem;
}

.order-items-table__qty {
  font-weight: 500;
  color: rgba(75, 31, 94, 0.8);
}

.order-items-table__price {
  font-weight: 500;
  color: rgba(75, 31, 94, 0.8);
}

.order-items-table__total {
  font-weight: 700;
  color: var(--purple-800);
}

@media (max-width: 600px) {
  .order-items-table thead {
    display: none;
  }
  
  .order-items-table tbody, 
  .order-items-table tr, 
  .order-items-table td {
    display: block;
    width: 100%;
  }
  
  .order-items-table tr {
    padding: 16px 0;
    border-bottom: 1px solid rgba(75, 31, 94, 0.08);
  }
  
  .order-items-table tr:last-child {
    border-bottom: none;
  }
  
  .order-items-table td {
    padding: 6px 0;
    border-bottom: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  
  .order-items-table td.cell-prod {
    display: block;
    padding-bottom: 12px;
  }
  
  .order-items-table td::before {
    content: attr(data-label);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: rgba(75, 31, 94, 0.5);
  }
  
  .order-items-table td.cell-prod::before {
    display: none;
  }
}

.order-pricing { position: sticky; top: 96px; }

.pricing-box {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow);
}

.pricing-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 0.875rem;
  color: rgba(75, 31, 94, 0.8);
}

.pricing-row--discount { color: var(--red); font-weight: 700; }
.pricing-row--discount span:last-child { color: var(--red); }

.pricing-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 16px;
  margin-top: 8px;
  border-top: 2px solid rgba(75, 31, 94, 0.1);
}

.pricing-total__label { font-weight: 700; color: var(--purple-950); }
.pricing-total__val {
  font-size: 1.75rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--red), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Profile & addresses */
.profile-form, .addr-form {
  max-width: 520px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.password-card {
  max-width: 560px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow);
}

.password-card__head {
  display: flex;
  gap: 14px;
  align-items: center;
  padding-bottom: 18px;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(75, 31, 94, 0.08);
}

.password-card__icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--red), var(--gold));
  color: var(--white);
  font-size: 1rem;
}

.password-card__title {
  color: var(--purple-950);
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.password-card__desc {
  color: rgba(75, 31, 94, 0.62);
  font-size: 0.875rem;
  line-height: 1.5;
}

.addr-list { display: flex; flex-direction: column; gap: 14px; margin-top: 20px; }

.account-addresses__add { margin-bottom: 16px; }

.address-modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  align-items: safe center;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.address-modal[hidden] { display: none; }

.address-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
}

.address-modal__dialog {
  position: relative;
  width: min(520px, 100%);
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: auto;
  padding: 28px;
  background: var(--white);
  border: 1px solid rgba(75, 31, 94, 0.12);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.24);
  transform: scale(0.96) translateY(12px);
  transition: transform 0.2s ease;
}

.address-modal.is-open .address-modal__dialog { transform: scale(1) translateY(0); }

.address-modal__title {
  margin: 0 40px 20px 0;
  color: var(--purple-950);
  font-family: var(--font-display);
  font-size: 1.25rem;
}

.address-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: rgba(75, 31, 94, 0.65);
  transition: background 0.2s, color 0.2s;
}

.address-modal__close:hover { background: rgba(75, 31, 94, 0.08); color: var(--purple-950); }

.address-modal__actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 4px; }

.address-modal__cancel {
  padding: 12px 20px;
  border: 1px solid rgba(75, 31, 94, 0.18);
  border-radius: 999px;
  color: rgba(75, 31, 94, 0.72);
  font-weight: 700;
}

.address-modal__cancel:hover { background: rgba(75, 31, 94, 0.05); color: var(--purple-950); }

.addr-card {
  position: relative;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 18px;
  transition: border-color 0.3s;
  box-shadow: var(--shadow);
}

.addr-card--default { border-color: rgba(201, 163, 78, 0.45); }

.addr-card__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.addr-card__label { font-weight: 700; color: var(--purple-800); font-size: 0.875rem; }

.addr-card__default {
  font-size: 0.6875rem;
  font-weight: 800;
  padding: 3px 10px;
  background: linear-gradient(135deg, var(--red), var(--gold));
  color: var(--white);
  border-radius: 999px;
}

.addr-card__text { font-size: 0.875rem; color: rgba(75, 31, 94, 0.8); line-height: 1.6; margin-bottom: 12px; }

.addr-card__actions { display: flex; gap: 12px; }

.addr-card__actions button {
  font-size: 0.8125rem;
  font-weight: 600;
  color: rgba(75, 31, 94, 0.6);
  transition: color 0.2s;
}

.addr-card__actions button:hover { color: var(--purple-950); }

.addr-card__delete {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(198, 40, 57, 0.08);
  color: var(--red);
  font-size: 0.9375rem;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.8);
  transition: opacity 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.addr-card:hover .addr-card__delete,
.addr-card:focus-within .addr-card__delete {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.addr-card__delete:hover,
.addr-card__delete:focus-visible {
  background: var(--red);
  color: var(--white);
}

@media (hover: none) {
  .addr-card__delete {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
  }
}

/* Community */
.community-layout { max-width: 680px; margin: 0 auto; }

.group-banner {
  height: 160px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: linear-gradient(135deg, #4c1d95, #ef4444, var(--gold));
  background-size: cover;
  background-position: center;
  position: relative;
}

.group-banner__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 40%, rgba(75, 31, 94, 0.95));
  border-radius: inherit;
}

.group-header {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 0 20px 20px;
  margin-bottom: 20px;
  margin-top: -40px;
  position: relative;
  z-index: 2;
  box-shadow: var(--shadow);
}

.group-header__title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--purple-950);
  padding-top: 48px;
}

.group-header__meta { font-size: 0.8125rem; color: rgba(75, 31, 94, 0.6); }

.composer {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  margin-bottom: 20px;
  cursor: pointer;
  transition: border-color 0.3s;
  box-shadow: var(--shadow);
}

.composer:hover { border-color: rgba(75, 31, 94, 0.25); }

.composer__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--red), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}

.composer__input {
  flex: 1;
  color: rgba(75, 31, 94, 0.6);
  font-size: 0.9375rem;
}

.composer__media { color: var(--gold); font-size: 1.25rem; }

/* Post card */
.post-card {
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.08);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
  overflow: hidden;
  transition: border-color 0.3s;
  box-shadow: var(--shadow);
}

.post-card:hover { border-color: rgba(75, 31, 94, 0.15); }

.post-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 16px 0;
}

.post-card__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--purple-800), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--white);
  font-size: 0.875rem;
}

.post-card__meta { flex: 1; }
.post-card__author { font-weight: 700; color: var(--purple-950); font-size: 0.9375rem; }
.post-card__time { font-size: 0.75rem; color: rgba(75, 31, 94, 0.5); }

.post-card__text {
  padding: 12px 16px;
  color: rgba(75, 31, 94, 0.85);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.post-card__media {
  display: grid;
  gap: 2px;
}

.post-card__media--1 { grid-template-columns: 1fr; }
.post-card__media--2 { grid-template-columns: 1fr 1fr; }

.post-card__media img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  cursor: pointer;
}

.post-card__actions {
  display: flex;
  border-top: 1px solid rgba(75, 31, 94, 0.08);
  padding: 4px;
}

.post-action {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  color: rgba(75, 31, 94, 0.7);
  font-weight: 600;
  font-size: 0.8125rem;
  border-radius: var(--radius);
  transition: var(--transition);
}

.post-action:hover { background: rgba(75, 31, 94, 0.04); color: var(--purple-950); }

.post-action--liked { color: var(--red); }
.post-action--liked i { animation: heart-pop 0.4s ease; }

@keyframes heart-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.35); }
  100% { transform: scale(1); }
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  visibility: hidden;
  pointer-events: none;
}

.modal.is-open { visibility: visible; pointer-events: auto; }

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  opacity: 0;
  transition: opacity 0.3s;
}

.modal.is-open .modal__backdrop { opacity: 1; }

.modal__box {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.1);
  border-radius: var(--radius-lg);
  padding: 24px;
  transform: scale(0.95) translateY(12px);
  transition: transform 0.35s ease;
  box-shadow: var(--shadow);
}

.modal.is-open .modal__box { transform: scale(1) translateY(0); }

.modal__title {
  font-weight: 700;
  color: var(--purple-950);
  font-size: 1.125rem;
  margin-bottom: 16px;
}

.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  color: rgba(75, 31, 94, 0.5);
  font-size: 1.25rem;
}

.modal textarea {
  width: 100%;
  min-height: 120px;
  padding: 14px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.15);
  border-radius: var(--radius);
  color: var(--purple-950);
  font-size: 0.9375rem;
  resize: vertical;
  outline: none;
  margin-bottom: 16px;
}

.modal textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201,163,78,0.15); }

.upload-zone {
  border: 2px dashed rgba(75, 31, 94, 0.2);
  border-radius: var(--radius);
  padding: 32px 20px;
  text-align: center;
  color: rgba(75, 31, 94, 0.6);
  font-size: 0.875rem;
  margin-bottom: 16px;
  cursor: pointer;
  transition: border-color 0.3s, background 0.3s;
}

.upload-zone:hover, .upload-zone--drag { border-color: var(--gold); background: rgba(75, 31, 94, 0.04); }
.upload-zone i { font-size: 2rem; color: var(--gold); margin-bottom: 8px; display: block; }

.upload-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.upload-preview img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; }

.modal__actions { display: flex; gap: 12px; justify-content: flex-end; }

.modal__cancel {
  padding: 12px 24px;
  color: rgba(75, 31, 94, 0.6);
  font-weight: 600;
}

/* Post detail */
.post-detail-page { max-width: 680px; margin: 0 auto; padding-bottom: 100px; }

.comment-section {
  background: rgba(75, 31, 94, 0.02);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 16px;
}

.comment-item {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(75, 31, 94, 0.06);
}

.comment-item__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--purple-800);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}

.comment-item__bubble {
  background: rgba(75, 31, 94, 0.04);
  border-radius: 12px;
  padding: 10px 14px;
  flex: 1;
}

.comment-item__author { font-weight: 700; font-size: 0.8125rem; color: var(--purple-950); margin-bottom: 2px; }
.comment-item__text { font-size: 0.875rem; color: rgba(75, 31, 94, 0.85); line-height: 1.5; }

.comment-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  border-top: 1px solid rgba(75, 31, 94, 0.1);
  padding: 12px 20px;
  z-index: 100;
}

.comment-bar__inner {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
}

.comment-bar__input {
  flex: 1;
  padding: 12px 18px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.15);
  border-radius: 999px;
  color: var(--purple-950);
  outline: none;
}

.comment-bar__input:focus { border-color: var(--gold); }

.comment-bar__send {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--red), var(--gold));
  color: var(--white);
  display: flex;
  color: rgba(75, 31, 94, 0.7);
  font-weight: 600;
  font-size: 0.8125rem;
  border-radius: var(--radius);
  transition: var(--transition);
}

.post-action:hover { background: rgba(75, 31, 94, 0.04); color: var(--purple-950); }

.post-action--liked { color: var(--red); }
.post-action--liked i { animation: heart-pop 0.4s ease; }

@keyframes heart-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.35); }
  100% { transform: scale(1); }
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  visibility: hidden;
  pointer-events: none;
}

.modal.is-open { visibility: visible; pointer-events: auto; }

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  opacity: 0;
  transition: opacity 0.3s;
}

.modal.is-open .modal__backdrop { opacity: 1; }

.modal__box {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.1);
  border-radius: var(--radius-lg);
  padding: 24px;
  transform: scale(0.95) translateY(12px);
  transition: transform 0.35s ease;
  box-shadow: var(--shadow);
}

.modal.is-open .modal__box { transform: scale(1) translateY(0); }

.modal__title {
  font-weight: 700;
  color: var(--purple-950);
  font-size: 1.125rem;
  margin-bottom: 16px;
}

.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  color: rgba(75, 31, 94, 0.5);
  font-size: 1.25rem;
}

.modal textarea {
  width: 100%;
  min-height: 120px;
  padding: 14px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.15);
  border-radius: var(--radius);
  color: var(--purple-950);
  font-size: 0.9375rem;
  resize: vertical;
  outline: none;
  margin-bottom: 16px;
}

.modal textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201,163,78,0.15); }

.upload-zone {
  border: 2px dashed rgba(75, 31, 94, 0.2);
  border-radius: var(--radius);
  padding: 32px 20px;
  text-align: center;
  color: rgba(75, 31, 94, 0.6);
  font-size: 0.875rem;
  margin-bottom: 16px;
  cursor: pointer;
  transition: border-color 0.3s, background 0.3s;
}

.upload-zone:hover, .upload-zone--drag { border-color: var(--gold); background: rgba(75, 31, 94, 0.04); }
.upload-zone i { font-size: 2rem; color: var(--gold); margin-bottom: 8px; display: block; }

.upload-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.upload-preview img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; }

.modal__actions { display: flex; gap: 12px; justify-content: flex-end; }

.modal__cancel {
  padding: 12px 24px;
  color: rgba(75, 31, 94, 0.6);
  font-weight: 600;
}

/* Post detail */
.post-detail-page { max-width: 680px; margin: 0 auto; padding-bottom: 100px; }

.comment-section {
  background: rgba(75, 31, 94, 0.02);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 16px;
}

.comment-item {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(75, 31, 94, 0.06);
}

.comment-item__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--purple-800);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}

.comment-item__bubble {
  background: rgba(75, 31, 94, 0.04);
  border-radius: 12px;
  padding: 10px 14px;
  flex: 1;
}

.comment-item__author { font-weight: 700; font-size: 0.8125rem; color: var(--purple-950); margin-bottom: 2px; }
.comment-item__text { font-size: 0.875rem; color: rgba(75, 31, 94, 0.85); line-height: 1.5; }

.comment-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  border-top: 1px solid rgba(75, 31, 94, 0.1);
  padding: 12px 20px;
  z-index: 100;
}

.comment-bar__inner {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
}

.comment-bar__input {
  flex: 1;
  padding: 12px 18px;
  background: #ffffff;
  border: 1px solid rgba(75, 31, 94, 0.15);
  border-radius: 999px;
  color: var(--purple-950);
  outline: none;
}

.comment-bar__input:focus { border-color: var(--gold); }

.comment-bar__send {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--red), var(--gold));
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.empty-state-box {
  text-align: center;
  padding: 48px 20px;
  color: rgba(75, 31, 94, 0.6);
}

@keyframes step-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 900px) {
  .account-layout { grid-template-columns: 1fr; }
  .account-nav { 
    position: static; 
    display: flex; 
    flex-wrap: wrap; 
    gap: 8px; 
    padding-bottom: 12px;
    align-items: center;
  }
  .account-nav::-webkit-scrollbar { display: none; }
  .account-nav__user { display: none; }
  .account-nav__btn { flex: 1 1 auto; justify-content: center; min-width: 120px; padding: 10px 16px; border-radius: 999px; }
  .account-nav__btn--logout {
    margin-top: 0;
    padding-top: 10px;
    border-top: none;
    background: rgba(198, 40, 57, 0.06);
  }
  .order-detail-grid { grid-template-columns: 1fr; }
  .order-pricing { position: static; }
}

@media (max-width: 480px) {
  .auth-card { padding: 28px 20px; }
  .group-banner { height: 120px; }
  
  .profile-form, .addr-form {
    gap: 12px;
  }

  .address-modal { padding: 12px; }
  .address-modal__dialog {
    padding: 24px 20px;
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
  }
  .address-modal__actions { flex-direction: column-reverse; }
  .address-modal__actions > * { width: 100%; text-align: center; }
  
  .password-card {
    padding: 16px;
  }
  
  .order-info-card-group, .order-items-card, .pricing-box {
    padding: 16px;
  }
  
  .comment-bar__inner {
    padding-bottom: env(safe-area-inset-bottom);
  }
}
