/* Domestic portal scale remains unchanged. Shared local font and type hierarchy. */
body { --ui-unit:1px; --ui-control:15px; }
body.agent-portal { --at-page:32px; --at-body:16px; --at-control:15px; --at-caption:15px; }
body.user-portal { --ut-page:32px; --ut-section:22px; --ut-body:16px; --ut-control:15px; --ut-caption:15px; }
body:is(.user-portal,.agent-portal,.geo-login-page) :is(button,input,select,textarea,label,th,td,small,.modal-tip,.table-tip,.form-help,.pricing-description,.badge) { font-size:15px!important; }
body.agent-portal .sidebar nav a,
body.agent-portal .sidebar nav a b,
body.user-portal .user-sidebar :is(.user-nav-main,.user-nav-item),
body.user-portal .user-sidebar :is(.user-nav-main,.user-nav-item) b { font-size:17px!important; font-weight:500!important; }
body.user-portal .user-nav-sub a,
body.user-portal .user-nav-branch>summary { font-size:15px!important; }
body :is(.agent-page-title,.user-page-heading) { font-size:32px!important;font-weight:700; }
body :is(.panel h2,.table-toolbar h2,.message-heading h2) { font-size:22px!important; }
body :is(.app-modal>header strong,.enterprise-modal>header strong) { font-size:20px!important; }
.public-overview-shell { max-width:1760px;margin:20px auto;padding:30px; }
.public-overview { min-width:320px; }
[data-message-count] { border-radius:14px;background:#ee526a;color:#fff;padding:2px 6px;font-size:15px; }
@media(max-width:760px){.public-overview-shell{margin:10px;padding:12px;}}
/* Agent list and pricing refinements reuse the enterprise toolbar and dialog. */
.agent-portal .agent-management-page .table-toolbar .tool-btn.add { order: 6; }
.agent-portal .agent-management-page summary[hidden] { display: none; }
/* Match the enterprise list's name emphasis, account colors and rendered rows.
   Keep the scope on the direct list cells so embedded modal tables are untouched. */
.agent-portal .agent-management-page > .table-wrap > .data-table > tbody > tr > td:not(.empty) { height: 63px; }
.agent-portal .agent-management-page .data-table .agent-account-cell { color: #2f3640; }
.agent-portal .agent-management-page .agent-name-note { font-size: inherit !important; font-weight: 400; line-height: inherit; }
.agent-portal .agent-management-page .agent-status-note { margin-left: 8px; }
.agent-portal .agent-management-page .round-actions > form > .outline-action { font-weight: 600; }
.agent-portal .agent-edit-modal { text-align: left; white-space: normal; }
.agent-portal .agent-edit-modal h3 { margin: 0 0 18px; }
.agent-portal .agent-edit-modal .profile-form { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); align-items: start; gap: 20px 24px; margin-bottom: 24px; }
.agent-portal .agent-edit-modal .profile-form label { display: grid; grid-template-columns: minmax(0,1fr); gap: 8px; min-width: 0; margin: 0; text-align: left; }
.agent-portal .agent-edit-modal [data-logo-permission][hidden],
.agent-portal .agent-edit-modal [data-inherited-logo][hidden] { display: none !important; }
.agent-portal .agent-edit-modal [data-inherited-logo] { grid-column: 1 / -1; margin: 0; }
.agent-portal .agent-edit-modal .profile-form label > span:first-child { padding: 0; white-space: normal; }
.agent-portal .agent-edit-modal .profile-form :is(input,select) { width: 100%; min-width: 0; height: 42px; padding: 0 12px; border: 1px solid #d2deef; border-radius: 8px; color: #263c53; background: #fbfdff; }
.agent-portal .agent-edit-modal .profile-form small { margin: 0; color: #738298; }
.agent-portal .agent-edit-modal .enterprise-form-body :is(small,.modal-tip) { display: block; }
.agent-portal .agent-edit-modal .modal-tip { margin-left: 0; }
.agent-portal .agent-edit-modal .oem-domain-management { margin-top: 0; }
.agent-portal .agent-edit-modal .oem-domain-add { display: flex; align-items: flex-end; gap: 12px; }
.agent-portal .agent-edit-modal .oem-domain-add > label { display: grid; flex: 1; gap: 8px; min-width: 0; margin: 0; }
.agent-portal .agent-edit-modal .oem-domain-add > label > input { width: 100%; min-width: 0; height: 45px; min-height: 45px; }
.agent-portal .agent-edit-modal .oem-domain-add > .primary-btn { flex: 0 0 auto; height: 45px; min-height: 45px; margin: 0; white-space: nowrap; }
.agent-portal .agent-edit-modal .oem-domain-help { margin-top: 14px; }
/* Settings live inside a section, so give their rows the same label column
   as the enterprise form's direct fields. Keep radio labels inline. */
.agent-portal .enterprise-modal .enterprise-settings > label,
.agent-portal .enterprise-modal .enterprise-settings > .enterprise-status-field {
  display: grid; grid-template-columns: 80px minmax(0,1fr); align-items: center;
  gap: 12.6px; min-width: 0; margin: 0 0 11.7px; text-align: left;
}
.agent-portal .enterprise-modal .enterprise-settings > label > span:first-child,
.agent-portal .enterprise-modal .enterprise-status-field > span:first-child {
  padding: 0; color: #525b67; text-align: right; white-space: nowrap; font-weight: 600;
}
.agent-portal .enterprise-modal .enterprise-status-field > .radio-row {
  justify-content: flex-start; min-height: 45px; margin: 0; padding: 0 !important;
}
.agent-portal .enterprise-modal .enterprise-opening-row {
  display: grid; grid-template-columns: minmax(0,1.25fr) minmax(0,1fr); gap: 24px; align-items: center;
}
.agent-portal .enterprise-modal .enterprise-opening-row > label {
  display: grid; grid-template-columns: 80px minmax(0,1fr); gap: 12.6px;
  align-items: center; min-width: 0; margin: 0; text-align: left;
}
.agent-portal .enterprise-modal .enterprise-opening-row > label:last-child { grid-template-columns: 104px minmax(0,1fr); }
.agent-portal .enterprise-modal .enterprise-opening-row > label > span {
  padding: 0; color: #525b67; text-align: right; white-space: nowrap;
}
.agent-portal .enterprise-modal .enterprise-opening-row :is(input,select) { width: 100%; min-width: 0; }
@media (max-width: 680px) {
  .agent-portal .enterprise-modal .enterprise-opening-row { grid-template-columns: minmax(0,1fr); gap: 12px; }
  .agent-portal .enterprise-modal .enterprise-opening-row > label { grid-template-columns: 104px minmax(0,1fr); }
}
.agent-portal .pricing-head-actions { display: flex; align-items: center; gap: 9px; flex-shrink: 0; }
.agent-portal .content-pricing .pricing-head-actions > :is(a,details) { margin: 0; }
.agent-portal .content-pricing .pricing-head-actions summary { list-style: none; }
.agent-portal .content-pricing .pricing-head-actions summary::-webkit-details-marker { display: none; }
.agent-portal .content-pricing .pricing-toolbar { align-items: center; text-align: center; }
.agent-portal .content-pricing :is(.pricing-head-actions .primary-btn,.pricing-toolbar > button) { background: #0e9cff; box-shadow: none; }
.agent-portal .content-pricing .pricing-metrics article::before { content: ''; position: absolute; }
@media (max-width: 760px) {
  .agent-portal .content-pricing .pricing-head-actions { flex-wrap: wrap; }
}
/* The compact price-and-unit control follows the approved pricing design,
   with one shared border instead of the standard full-size form field. */
.agent-portal .pricing-table .price-input {
  display: inline-flex; align-items: stretch; box-sizing: border-box;
  width: calc(120 * var(--ui-unit)); height: calc(30 * var(--ui-unit));
  margin: auto; padding: 0; overflow: hidden;
  border: 1px solid #ccc; border-radius: calc(3 * var(--ui-unit)); background: #fff;
  box-shadow: none;
}
.agent-portal .pricing-table .price-input:focus-within { border-color: #00f; }
.agent-portal .pricing-table .price-input > input {
  flex: 1 1 0; box-sizing: border-box; width: 0; min-width: 0; height: 100%; min-height: 0;
  margin: 0; padding: 0 calc(8 * var(--ui-unit)); border: 0; border-radius: 0;
  color: #ff3f52; background: #fff; text-align: center; line-height: 1; font-weight: 400;
}
.agent-portal .pricing-table .price-input > input:focus { outline: none; box-shadow: none; }
.agent-portal .pricing-table .price-input > span {
  display: flex; align-items: center; justify-content: center; flex: 0 0 calc(34 * var(--ui-unit));
  box-sizing: border-box; height: 100%; padding: 0;
  color: #999; background: #f5f7fa; font-size: var(--ui-control); line-height: 1;
}
.agent-portal .pricing-target-dialog { --ui-dialog-width: calc(520 * var(--ui-unit)); top: 50%; transform: translate(-50%,-50%); }
.agent-portal .pricing-target-dialog .pricing-target-form { display: block; margin: 0; }
.agent-portal .pricing-target-dialog .pricing-target-form label { min-width: 0; }
.agent-portal .pricing-target-dialog .pricing-target-form select { width: 100%; }
.agent-portal .pricing-target-dialog footer { display: flex; justify-content: center; gap: 8px; padding: 12px 24px; border-top: 1px solid #e4eaf2; }
@media (max-width: 760px) {
  .agent-portal .agent-edit-modal .profile-form { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

/* Shared reports use the live overview components, without authenticated chrome. */
.user-portal.public-report-page { min-width: 320px; }
.user-portal .public-report-shell {
  max-width: 1760px; margin: 20px auto; padding: 30px;
  min-height: calc(100vh / var(--ui-scale) - 40px);
  border: 1px solid #fff; border-radius: 20px; background: var(--ud-canvas);
}
.user-portal .public-report-content { margin: 0; padding: 0; min-width: 0; }
@media (max-width: 860px) {
  .user-portal .public-report-shell { margin: 12px; padding: 12px; }
}
.agent-portal .opening-plan-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin:16px 0 24px; }
.agent-portal .opening-plan-card { display:grid; gap:8px; padding:18px; border:1px solid var(--ui-border,#d3e0f2); border-radius:12px; background:#f4f8fd; }
.agent-portal .opening-plan-card strong { font-size:18px; font-weight:700; }
.agent-portal .opening-plan-card > span { color:#0e9cff; font-size:22px; font-weight:700; }
.agent-portal .opening-preview { margin:16px 0; padding:14px 16px; border-radius:8px; background:#f0f7ff; line-height:1.7; font-size:15px; }
.agent-portal .opening-preview-error { color:#bb333d; background:#fff2f3; }
.agent-portal .opening-prices-modal .app-modal { width:min(620px,calc(100vw - 32px)); }
.agent-portal .opening-prices-modal .modal-form > .opening-price-row { display:grid; grid-template-columns:180px minmax(0,1fr); align-items:center; gap:24px; margin-bottom:18px; }
.agent-portal .opening-prices-modal .opening-price-row > span:first-child { white-space:nowrap; padding-top:0; }
.agent-portal .opening-price-control { display:flex; align-items:center; gap:10px; }
.agent-portal .opening-price-control input { min-width:0; width:100%; }
.agent-portal .enterprise-modal .package-correction-form .enterprise-form-body > label { grid-template-columns:170px minmax(0,1fr); }
.agent-portal .enterprise-modal .package-correction-form .enterprise-form-body > label > span { white-space:normal; overflow:visible; }
.agent-portal .enterprise-modal form[data-opening-mode] .enterprise-form-body > label { grid-template-columns:140px minmax(0,1fr); }
@media (max-width:640px) { .agent-portal .enterprise-modal :is(.package-correction-form,form[data-opening-mode]) .enterprise-form-body > label { grid-template-columns:1fr; } }
.agent-portal .opening-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; margin:12px 0 24px; }
.agent-portal .opening-metrics article { display:grid; gap:12px; padding:22px; background:#f1f6fc; border-radius:14px; }
.agent-portal .opening-metrics strong { font-size:30px; font-weight:700; color:#223a52; }
@media (max-width:760px) { .agent-portal :is(.opening-plan-list,.opening-metrics,.opening-price-row) { grid-template-columns:1fr; } }
@media (max-width:600px) { .agent-portal .opening-prices-modal .modal-form > .opening-price-row { grid-template-columns:1fr; gap:10px; } }

.geo-login-brand .geo-oem-wordmark{width:230px;height:70px;object-fit:contain;}

/* Agent retail prices share the existing package dialog and portal palette. */
.customer-package-prices { scroll-margin-top:24px; }
.agent-portal .agent-quota-sections { display:grid; gap:16px; }
.agent-portal .agent-quota-sections > .workspace-panel { min-height:0; margin:0; }
.agent-portal .retail-order-panel { min-height:0; }
.customer-package-panel { padding:28px; border-radius:16px; background:#fff; }
.retail-section-heading h2 { margin:0 0 10px; color:#263c53; font-size:22px; }
.package-price-help { margin:0 0 16px; color:#70839c; font-size:15px; line-height:1.7; }
.retail-plan-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; margin:18px 0; }
.retail-plan-card { display:grid; gap:12px; min-width:0; padding:22px; border:1px solid #d3e0f2; border-radius:12px; background:#f6f9fd; }
.retail-plan-heading { display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; }
.retail-plan-heading h3 { margin:0; font-size:18px; color:#263c53; }
.retail-plan-heading > span { color:#70839c; font-size:15px; }
.retail-plan-card .package-price-help { margin:0; }
.retail-plan-price { color:#0e9cff; font-size:28px; font-weight:700; }
.retail-plan-price small { margin-left:10px; color:#70839c; font-weight:400; }
.retail-plan-cost { display:flex; justify-content:space-between; flex-wrap:wrap; gap:12px; border-top:1px solid #dbe6f2; padding-top:16px; color:#51657d; }
.agent-portal .customer-package-prices .table-toolbar { flex-wrap:wrap; gap:16px; }
.agent-portal .customer-package-prices .opening-price-control > span { white-space:nowrap; }
.agent-portal .customer-package-prices .opening-prices-modal footer { display:flex; align-items:center; justify-content:center; gap:12px; }
@media(max-width:760px) { .retail-plan-grid { grid-template-columns:1fr; } .customer-package-panel { padding:20px; } }
/* Partner catalogs share the existing blue/white account workspace. */
.agent-portal .partner-pricing-panel{min-height:0;padding:28px}
.agent-portal .partner-pricing-panel .table-toolbar{min-height:40px;padding:0 0 12px;margin:0}
.partner-kind-agency .partner-plan-editor{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:24px}
.partner-kind-agency .partner-plan-editor .form-hint{grid-column:1 / -1}
@media(max-width:680px){.partner-kind-agency .partner-plan-editor{grid-template-columns:1fr}}
.partner-tabs{display:flex;flex-wrap:wrap;gap:12px;margin:18px 0}
.partner-tabs a{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:0 22px;border:1px solid #d6e3f0;border-radius:22px;color:#445b76;background:#f4f7fb;text-decoration:none;font-size:15px}
.partner-tabs a.active{background:#109fff;border-color:#109fff;color:#fff}
.partner-tabs.secondary a{border-radius:8px}
.partner-plan-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:22px;max-width:1000px}
.partner-plan-editor{padding:22px;border:1px solid #d6e3f0;border-radius:12px;min-width:0;background:#f8fbff}
.partner-plan-editor legend{padding:0 10px;font-size:18px;font-weight:600;color:#253b53}
.partner-price-form label{display:flex;flex-direction:column;gap:8px;margin-bottom:18px;font-size:15px}
.partner-price-form input,.partner-price-form select{box-sizing:border-box;width:100%;min-height:42px;padding:8px 12px;border:1px solid #cad9eb;border-radius:8px;background:#fff;color:#344b65;font:inherit}
.partner-price-form input:focus,.partner-price-form select:focus{outline:2px solid #90cdfd;outline-offset:2px}
.partner-form-footer{margin-top:28px;display:flex;flex-wrap:wrap;align-items:center;gap:16px}
.partner-pricing-panel .form-hint{font-size:15px;line-height:1.7;color:#6e829b;margin-bottom:20px}
