/* Profile-only surfaces: keep the rest of the application's layout unchanged. */
.profile-shell {
  --profile-border: #2b2529;
  --profile-red: #d93645;
  --profile-muted: #b9b2b5;
  gap: 22px;
  min-width: 0;
}
.profile-shell .simple-page-header { align-items: center; padding: 0 0 6px; }
.profile-shell .simple-page-header h3 { font-size: clamp(28px, 3vw, 38px); letter-spacing: .005em; line-height: 1.15; }
.profile-shell .simple-page-header p { margin-top: 6px; font-size: 15px; }
.profile-shell .simple-page-header .operator-action { min-height: 56px; min-width: 220px; font-size: 17px; }
.profile-shell .simple-surface {
  padding: clamp(20px, 2.4vw, 30px);
  border: 1px solid var(--profile-border);
  border-radius: 16px;
  background: linear-gradient(145deg, #131316, #0b0c0e 65%);
  box-shadow: inset 0 1px 0 #ffffff08, 0 8px 24px #0003;
}
.profile-shell .simple-page-header ~ .simple-surface:first-of-type { border-top: 1px solid var(--profile-border); }
.profile-shell .surface-heading { align-items: start; margin-bottom: 20px; }
.profile-shell .surface-heading h4 {
  padding: 0;
  border: 0;
  font-size: 22px;
  letter-spacing: .005em;
  line-height: 1.25;
}
.profile-shell .surface-heading p { max-width: 68ch; margin: 7px 0 0; font-size: 14px; line-height: 1.6; }
.profile-shell .profile-section-label {
  display: block;
  margin-bottom: 8px;
  color: #ed8b95;
  font: 800 12px/1.4 "Nunito", sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.profile-shell .profile-identity-card {
  gap: 22px;
  border-left: 3px solid var(--profile-red);
  background: radial-gradient(ellipse at right top, #6f20271a, transparent 65%), linear-gradient(145deg, #141316, #0c0d0f);
}
.profile-shell .profile-avatar { width: 82px; height: 82px; border-radius: 18px; border: 1px solid #ffffff14; box-shadow: 0 4px 14px #0005; }
.profile-shell .profile-identity-card h4 { font-size: 26px; line-height: 1.25; overflow-wrap: anywhere; }
.profile-shell .profile-identity-card p { font-size: 13px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.profile-shell .profile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: start; }
.profile-shell .profile-readonly-row { grid-template-columns: minmax(95px, .35fr) minmax(0, 1fr); padding: 14px 0; border-color: #ffffff09; font-size: 14px; }
.profile-shell .profile-readonly-row span { color: var(--profile-muted); }
.profile-shell .profile-readonly-row strong { font-weight: 750; }
.profile-shell .profile-community-row { align-items: start; gap: 16px; padding: 16px 0; border-color: #ffffff09; }
.profile-shell .profile-community-row > div { min-width: 0; overflow-wrap: anywhere; }
.profile-shell .profile-community-row strong { font-size: 16px; }
.profile-shell .profile-community-row span { font-size: 13px; line-height: 1.5; }
.profile-shell .designation-tags { flex-shrink: 0; max-width: 45%; }
.profile-shell .designation-tag { border: 1px solid #6c343d; border-radius: 7px; background: #31181d55; color: #ecc6cb; font-size: 12px !important; }
.profile-shell .profile-billing-detail { margin-top: 8px; font-size: 13px; }
.profile-shell .empty-state { padding: 18px 0; color: var(--profile-muted); }
.profile-shell #billingCard { padding: 0; overflow: hidden; }
.profile-shell .billing-card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 26px 30px;
  border-bottom: 1px solid #56303a;
  background: radial-gradient(ellipse at right top, #802d3515, transparent 65%), linear-gradient(120deg, #171417, #0e0f11);
}
.profile-shell .billing-card-heading > div { min-width: 0; }
.profile-shell .billing-card-heading h4 { margin: 0; font: 600 26px/1.25 "Fredoka", sans-serif; letter-spacing: .005em; }
.profile-shell .billing-access-badge { flex-shrink: 0; padding: 8px 12px; border: 1px solid #5c333a; border-radius: 8px; background: #27181d; color: #f0c9ce; font: 800 13px/1.4 "Nunito", sans-serif; }
.profile-shell .billing-overview { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(0, 1fr); gap: 26px; padding: 26px 30px; }
.profile-shell .billing-overview > div { min-width: 0; }
.profile-shell .billing-overview-label { display: block; margin-bottom: 9px; font-size: 13px; color: var(--profile-muted); font-weight: 750; }
.profile-shell #billingStatusText { margin: 0; max-width: 65ch; font-size: 16px; line-height: 1.65; }
.profile-shell .billing-slot-overview { padding-left: 26px; border-left: 1px solid var(--profile-border); }
.profile-shell #billingSlotsValue { display: block; font: 600 26px/1.2 "Fredoka", sans-serif; font-variant-numeric: tabular-nums; }
.profile-shell #billingSlotsDetail { display: block; margin-top: 6px; font-size: 13px; line-height: 1.5; color: var(--profile-muted); }
.profile-shell #billingSummaryList { display: grid; gap: 10px; margin: 0; padding: 0 30px; }
.profile-shell #billingSummaryList:empty { display: none; }
.profile-shell #billingSummaryList .dashboard-list-row { gap: 14px; padding: 16px; border: 1px solid var(--profile-border); border-radius: 10px; background: #090a0c; }
.profile-shell #billingSummaryList .dashboard-list-row strong { font: 800 15px/1.5 "Nunito", sans-serif; }
.profile-shell #billingSummaryList .dashboard-list-row span { font-size: 13px; line-height: 1.5; }
.profile-shell #billingSummaryList .row-actions { flex-wrap: wrap; }
.profile-shell .billing-payment-controls { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: end; padding: 22px 30px 0; }
.profile-shell .billing-payment-controls .field { min-width: 0; gap: 8px; }
.profile-shell .billing-payment-controls label { font: 800 15px/1.5 "Nunito", sans-serif; }
.profile-shell #billingPaymentMethod { min-height: 50px; font-size: 15px; border-color: #403237; border-radius: 10px; }
.profile-shell #billingPaymentHint { margin: 0; padding-bottom: 12px; color: var(--profile-muted); font-size: 14px; line-height: 1.6; }
.profile-shell .billing-plan-options { padding: 24px 30px 0; }
.profile-shell .billing-subheading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; margin-bottom: 16px; }
.profile-shell .billing-subheading h5 { margin: 0; font: 600 20px/1.4 "Fredoka", sans-serif; }
.profile-shell .billing-subheading p, .profile-shell .billing-subheading > span { margin: 5px 0 0; font-size: 13px; color: var(--profile-muted); line-height: 1.6; }
.profile-shell .billing-plan-grid, .profile-shell .billing-slot-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.profile-shell .billing-plan-choice {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  min-width: 0;
  padding: 22px;
  border: 1px solid #513139;
  border-bottom: 4px solid #76303c;
  border-radius: 12px;
  background: linear-gradient(150deg, #1a191d, #0a0b0d 75%);
  box-shadow: inset 0 1px 0 #ffffff0c, 0 6px 14px #0004;
  color: var(--text);
  text-align: left;
  white-space: normal;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}
.profile-shell .billing-plan-choice:not(:disabled):hover { transform: translateY(-2px); border-color: #c84a59; box-shadow: inset 0 1px 0 #ffffff13, 0 8px 18px #0006; }
.profile-shell .billing-plan-choice:focus-visible { outline: 2px solid #f0a3ac; outline-offset: 4px; }
.profile-shell .billing-plan-choice:not(:disabled):active { transform: translateY(1px); }
.profile-shell .billing-plan-period { font: 800 15px/1.4 "Nunito", sans-serif; }
.profile-shell .billing-plan-price { font: 600 clamp(26px, 2.5vw, 34px)/1.25 "Fredoka", sans-serif; font-variant-numeric: tabular-nums; }
.profile-shell .billing-plan-detail { color: var(--profile-muted); font: 600 13px/1.5 "Nunito", sans-serif; }
.profile-shell .billing-plan-action { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 8px; padding-top: 14px; border-top: 1px solid #5f303950; color: #f2c6cc; font: 800 14px/1.5 "Nunito", sans-serif; }
.profile-shell .billing-plan-action > span { font-size: 20px; }
.profile-shell .billing-slot-options { margin: 24px 30px 0; padding-top: 22px; border-top: 1px solid #56303a; }
.profile-shell .billing-slot-grid .button { min-width: 0; min-height: 50px; padding: 12px; font-size: 14px; white-space: normal; }
.profile-shell .billing-renewal-actions { padding: 18px 30px 0; }
.profile-shell .billing-renewal-actions:not(:has(button:not(.hidden))) { display: none; }
.profile-shell .billing-terms { margin: 22px 30px 0; padding-top: 16px; border-top: 1px solid var(--profile-border); color: var(--profile-muted); font-size: 13px; line-height: 1.75; }
.profile-shell #billingStatusBox { margin: 20px 30px 26px; }
.profile-shell #billingStatusBox:not(.show) { display: none; }
.profile-shell #billingCard { padding-bottom: 26px; }
.profile-shell #billingCard:has(#billingStatusBox.show) { padding-bottom: 0; }
.profile-shell .profile-metric { border: 1px solid var(--profile-border); background: linear-gradient(145deg, #17151a, #0c0d0f); }
.profile-shell .profile-metric span { font-size: 12px; text-transform: none; letter-spacing: .01em; }
.profile-shell .profile-bar-track { height: 8px; background: #242126; }
.profile-shell .profile-bar-fill { background: linear-gradient(90deg, #852b3a, #d93645); }
.profile-shell .export-column-preferences { margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--profile-border); }
.profile-shell .export-column-preferences h4 { margin: 0 0 10px; font-size: 20px; }
.profile-shell .export-column-preferences p { max-width: 85ch; color: var(--profile-muted); font-size: 14px; line-height: 1.65; }
.profile-shell .export-column-preferences fieldset { min-width: 0; margin: 20px 0; padding: 0; border: 0; }
.profile-shell .export-column-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.profile-shell .export-column-options label { display: flex; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--profile-border); border-radius: 9px; background: #0b0c0f; font-size: 14px; }
.profile-shell .export-column-options input { width: 16px; height: 16px; flex: 0 0 auto; }
.profile-shell .export-column-preferences [role="status"] { display: inline-block; margin: 8px 12px; font-size: 14px; }
.profile-shell [hidden], .profile-shell .hidden { display: none !important; }
@media (max-width: 1000px) {
  .profile-shell .profile-grid { grid-template-columns: minmax(0, 1fr); }
  .profile-shell .billing-plan-choice { padding: 18px; }
  .profile-shell .profile-drive-header-actions .operator-action { min-width: 0; }
}
@media (max-width: 640px) {
  .profile-shell { gap: 16px; }
  .profile-shell .simple-page-header { align-items: stretch; flex-direction: column; gap: 18px; }
  .profile-shell .profile-drive-header-actions { align-items: stretch; flex-direction: column; }
  .profile-shell .profile-identity-card { gap: 16px; }
  .profile-shell .profile-avatar { width: 64px; height: 64px; border-radius: 14px; }
  .profile-shell .profile-identity-card h4 { font-size: 23px; }
  .profile-shell .profile-readonly-row { grid-template-columns: minmax(0, 1fr); gap: 5px; }
  .profile-shell .profile-community-row { flex-direction: column; gap: 10px; }
  .profile-shell .designation-tags { justify-content: start; max-width: 100%; }
  .profile-shell .billing-card-heading { align-items: start; flex-direction: column; gap: 14px; padding: 22px 20px; }
  .profile-shell .billing-overview { grid-template-columns: minmax(0, 1fr); padding: 22px 20px; gap: 20px; }
  .profile-shell .billing-slot-overview { padding: 18px 0 0; border-left: 0; border-top: 1px solid var(--profile-border); }
  .profile-shell #billingSummaryList { padding: 0 20px; }
  .profile-shell #billingSummaryList .dashboard-list-row { align-items: stretch; flex-direction: column; }
  .profile-shell .billing-payment-controls { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 20px 20px 0; }
  .profile-shell #billingPaymentHint { padding: 0; }
  .profile-shell .billing-plan-options { padding: 22px 20px 0; }
  .profile-shell .billing-plan-grid, .profile-shell .billing-slot-grid { grid-template-columns: minmax(0, 1fr); }
  .profile-shell .billing-plan-choice { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 18px; padding: 18px; }
  .profile-shell .billing-plan-price { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .profile-shell .billing-plan-action { grid-column: 1 / -1; }
  .profile-shell .billing-slot-options { margin: 22px 20px 0; }
  .profile-shell .billing-renewal-actions { padding: 18px 20px 0; }
  .profile-shell .billing-terms { margin: 20px 20px 0; }
  .profile-shell #billingStatusBox { margin: 18px 20px 22px; }
  .profile-shell .export-column-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 380px) {
  .profile-shell .export-column-options { grid-template-columns: minmax(0, 1fr); }
  .profile-shell .billing-plan-choice { grid-template-columns: minmax(0, 1fr); }
  .profile-shell .billing-plan-price { grid-column: auto; grid-row: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .profile-shell .billing-plan-choice { transition: none; }
  .profile-shell .billing-plan-choice:not(:disabled):hover, .profile-shell .billing-plan-choice:not(:disabled):active { transform: none; }
}
