﻿/* Extracted from site-new.css. Legacy rules remain in site-new.css until visual verification is complete. */

.mobile-menu-account {
  display: grid;
  gap: 0.65rem;
  padding: 0.35rem 0.55rem 0.45rem;
}

.mobile-menu-user,
.mobile-menu-subscription {
  margin: 0;
  color: var(--muted-foreground);
  font-size: 0.82rem;
  line-height: 1.35;
}

button.mobile-menu-user {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: .65rem;
  align-items: center;
  width: 100%;
  min-height: 3.4rem;
  padding: .55rem .6rem;
  border: 0;
  border-radius: 9px;
  background: var(--secondary);
  color: var(--foreground);
  cursor: pointer;
  font-family: inherit;
  text-align: left;
}

button.mobile-menu-user[hidden] { display: none; }

button.mobile-menu-user:hover,
button.mobile-menu-user:focus-visible { color: var(--primary); }

.mobile-menu-user-icon {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 50%;
  background: var(--card);
  color: var(--primary);
}

.mobile-menu-user-icon svg { width: 1.15rem; height: 1.15rem; }

.mobile-menu-user-copy { display: grid; gap: .1rem; min-width: 0; }

.mobile-menu-user-copy strong { font-size: .86rem; }

.mobile-menu-user-copy > span {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: .76rem;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-menu-user-chevron { color: var(--muted-foreground); font-size: 1.35rem; line-height: 1; }

.account-modal .account-modal-panel { display: flex; flex-direction: column; width: min(56rem, calc(100vw - 2rem)); height: min(40rem, calc(100dvh - 2rem)); min-height: 0; overflow: hidden; }

.account-modal .account-modal-panel::-webkit-scrollbar { display: none; }

.account-modal-layout { display: grid; flex: 1 1 auto; grid-template-columns: 24% minmax(0, 1fr); min-height: 0; margin: 0 -1.25rem -1.25rem; }

.account-tabs { display: flex; flex-direction: column; gap: .3rem; padding: .25rem 1rem 1.25rem 1.25rem; overflow: hidden; border-right: 1px solid var(--border); scrollbar-width: none; }

.account-tabs::-webkit-scrollbar { display: none; }

.account-tab { width: 100%; padding: .65rem .75rem; border: 0; border-radius: 8px; background: transparent; color: var(--muted-foreground); cursor: pointer; font: inherit; font-size: .86rem; font-weight: 750; text-align: left; white-space: nowrap; }

.account-tab.is-active { background: var(--secondary); color: var(--primary); }

.account-modal-content { min-width: 0; overflow-y: auto; padding: .25rem 1.5rem 1.5rem; scrollbar-width: none; scrollbar-color: var(--border) transparent; }

.account-section[hidden] { display: none; }

.account-section { min-width: 0; }

.account-section h3 { margin: 0 0 .75rem; color: var(--foreground); font-size: 1rem; }

.account-info-grid { display: grid; gap: .65rem; }

.account-info-card { display: grid; grid-template-columns: minmax(0, .42fr) minmax(0, 1fr); gap: .75rem; padding: .75rem; border-radius: 10px; background: var(--secondary); font-size: .86rem; }

.account-info-card span { color: var(--muted-foreground); }

.account-info-card strong { min-width: 0; overflow-wrap: anywhere; }

.account-info-value { display: grid; justify-items: start; gap: .55rem; min-width: 0; }

.account-password-form { display: grid; gap: .75rem; max-width: 24rem; }

.account-payment-list { display: grid; gap: .55rem; }

.account-payment { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .25rem .75rem; padding: .75rem; border: 1px solid var(--border); border-radius: 10px; }

.account-payment > * { min-width: 0; overflow-wrap: anywhere; }

.account-payment strong { color: var(--foreground); font-size: .86rem; }

.account-payment span, .account-payment time { color: var(--muted-foreground); font-size: .76rem; }

.account-payment-promo { grid-column: 1 / -1; color: var(--primary) !important; }

.account-payment-status { text-align: right; }

@media (max-width: 900px) {
  .account-modal { place-items: end center; padding: 0; }
  .account-modal .account-modal-panel { width: calc(100% - 1rem); height: min(40rem, calc(100dvh - 1rem)); min-height: 0; max-height: calc(100dvh - 1rem); margin-bottom: .5rem; padding: 1.15rem; border-radius: 18px; }
  .account-modal-layout { display: flex; flex-direction: column; min-height: 0; margin: 0; }
  .account-tabs { flex-direction: row; margin-bottom: 1rem; padding: 0 0 .75rem; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--border); }
  .account-tab { flex: 0 0 auto; width: auto; padding: .5rem .7rem; text-align: center; }
  .account-modal-content { flex: 1 1 auto; min-height: 0; padding: 0; }
  .account-info-card { grid-template-columns: minmax(0, .42fr) minmax(0, 1fr); }
  .account-payment strong { font-size: .76rem; }
  .account-payment span, .account-payment time { font-size: .66rem; }
}

@media (max-width: 480px) {
  .account-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .35rem;
    overflow: visible;
  }

  .account-tab {
    width: 100%;
    min-width: 0;
    padding-inline: .4rem;
  }

  .account-info-card { grid-template-columns: 1fr; gap: .25rem; }
}

.usage-plan-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.usage-plan-summary {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.usage-plan-summary strong {
  overflow: hidden;
  color: var(--foreground);
  font-size: 0.9rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.usage-plan-state {
  flex: 0 0 auto;
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 50%;
  background: #a9b5c5;
  box-shadow: 0 0 0 4px rgba(169, 181, 197, 0.16);
}

#usage-panel.is-paid .usage-plan-state {
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(10, 159, 118, 0.14);
}

#usage-panel.is-free .usage-plan-state {
  background: var(--primary);
  box-shadow: 0 0 0 4px rgba(11, 117, 255, 0.12);
}

.subscription-email-form {
  display: flex;
  align-items: end;
  gap: 0.65rem;
  margin-top: 0.75rem;
}

.subscription-email-form[hidden] {
  display: none;
}

.subscription-email-form label {
  flex: 1 1 12rem;
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

.subscription-email-form input {
  width: 100%;
}

.subscription-email-form .button {
  flex: 0 0 auto;
}

.task-stats {
  display: grid;
  gap: 0.65rem;
  white-space: normal;
}

.usage-overview {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
}

.usage-value {
  color: var(--foreground);
  font-family: var(--font-headings);
  font-size: 1.2rem;
  font-weight: 700;
}

.usage-value small {
  color: var(--muted-foreground);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
}

.usage-progress {
  height: 0.4rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--muted);
}

.usage-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
  transition: width 300ms ease, background-color 300ms ease;
}

.usage-progress.is-low span { background: #d58a18; }

.usage-progress.is-critical span { background: var(--danger); }

.usage-meta {
  color: var(--muted-foreground);
  font-size: 0.78rem;
}

.usage-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.usage-metric {
  display: grid;
  gap: 0.15rem;
  padding: 0.65rem;
  border-radius: 9px;
  background: var(--secondary);
}

.usage-metric strong {
  color: var(--foreground);
  font-size: 1.1rem;
}

.usage-metric span {
  color: var(--muted-foreground);
  font-size: 0.75rem;
}

.usage-progress { height: 8px; overflow: hidden; border-radius: 4px; background: #e7ebf0; }

.usage-progress > i { display: block; height: 100%; background: var(--accent); }
