/* Standalone personal portal presentation; does not affect the public website. */
:root { color-scheme: light; }
body:has(.portal-login) { margin:0; }
.app-root:has(.portal-login) { min-height:100vh; background:linear-gradient(160deg,#f4f7fb 0%,#eaf0f7 100%); color:#172b48; font-family:Arial,"Noto Sans Hebrew",sans-serif; }
.app-root:has(.portal-login) .app-header { background:#102a48; color:#fff; padding:20px 28px; text-align:center; border-bottom:3px solid #cfaa69; }
.app-root:has(.portal-login) .app-header-title { font-size:19px; font-weight:700; }
.app-root:has(.portal-login) .app-main { display:flex; align-items:center; justify-content:center; min-height:calc(100vh - 155px); padding:32px 16px; box-sizing:border-box; }
.app-root:has(.portal-login) .page-container { width:100%; max-width:520px; padding:0; margin:0 auto; box-sizing:border-box; }
.app-root:has(.portal-login) .portal-login { background:#fff; box-shadow:0 20px 60px rgba(10,31,62,.12); border:1px solid #dbe4ef; border-radius:16px; padding:clamp(24px,5vw,48px); text-align:right; direction:rtl; }
.portal-login h1 { font-size:clamp(27px,4vw,34px); color:#102a48; margin:0 0 12px; line-height:1.3; }
.portal-login > p { color:#465a70; line-height:1.7; font-size:16px; margin:0 0 28px; }
.portal-login form { display:flex; flex-direction:column; align-items:stretch; gap:10px; width:100%; }
.portal-login form label { display:block; font-size:15px; font-weight:600; color:#203b57; margin-top:8px; }
.portal-login form input { display:block; box-sizing:border-box; width:100%; min-width:0; height:49px; padding:12px 14px; font-size:17px; border:1px solid #b9c8d8; border-radius:9px; background:#fff; color:#102a48; direction:ltr; text-align:right; }
.portal-login form input:focus { outline:3px solid #d4e5f5; border-color:#195f97; }
.portal-login form button[type=submit] { width:100%; margin-top:18px; min-height:49px; border:0; border-radius:9px; color:white; background:#123d68; font-size:17px; font-weight:700; cursor:pointer; }
.portal-login form button[type=submit]:hover { background:#0e3154; }
.portal-login button:not([type=submit]) { display:block; margin:22px auto 0; padding:8px 12px; background:transparent; border:0; color:#195f97; font-size:15px; text-decoration:underline; cursor:pointer; }
.portal-login button:focus-visible { outline:3px solid #edba66; outline-offset:3px; }
.portal-login [role=alert] { padding:12px; border-radius:8px; background:#fff3f0; color:#982d24; margin:0 0 16px; }
.portal-login [role=status] { padding:12px; border-radius:8px; background:#eaf8f0; color:#17613e; margin:0 0 16px; }
.app-root:has(.portal-login) .app-footer { padding:18px; text-align:center; font-size:13px; color:#53667e; background:transparent; }
@media(max-width:600px) { .app-root:has(.portal-login) .app-main { align-items:flex-start; min-height:calc(100vh - 120px); padding:20px 14px; } .app-root:has(.portal-login) .portal-login { border-radius:13px; padding:25px 20px; } }

.app-root .accounts-summary-label,.app-root .accounts-summary-value,.app-root .accounts-summary-updated{color:#fff}

.accounts-summary{background:#12365a!important}
.accounts-summary-metric,.accounts-summary-trend{color:white!important}

.portal-header{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:16px;margin-bottom:20px}
.portal-header button{padding:10px 18px;border-radius:8px;border:1px solid #aec0d2;background:#fff;color:#123d68;font-size:15px;cursor:pointer}
#portal-month{min-width:130px;padding:9px 12px;border:1px solid #aec0d2;border-radius:8px;background:#fff;font-size:15px}

/* Signed-in portal: isolated styling, consistent with login and the Ben-Zvi website. */
body:has(.accounts-summary){background:#edf2f7;color:#172b48}
.app-root:has(.accounts-summary){padding:0;min-height:100vh;background:#edf2f7;color:#172b48;font-family:Arial,"Noto Sans Hebrew",sans-serif}
.app-root:has(.accounts-summary) .app-header{border-radius:0;box-shadow:none;background:#102a48;border-bottom:3px solid #c9a365;padding:19px 20px}
.app-root:has(.accounts-summary) .app-main{padding:28px 16px 48px}
.app-root:has(.accounts-summary) .page-container{max-width:1100px;width:100%;border-radius:14px;border:1px solid #dde5ee;box-shadow:0 12px 38px rgba(18,47,81,.09);padding:clamp(18px,3vw,34px);overflow:visible;direction:rtl}
.app-root:has(.accounts-summary) .page-title{font-size:clamp(24px,3vw,32px);color:#102a48}
.app-root:has(.accounts-summary) .app-footer{color:#53667e;padding:20px}
.app-root:has(.accounts-summary) .accounts-summary{background:#12365a!important;border:1px solid #275078;box-shadow:0 8px 22px rgba(13,42,73,.14);border-radius:12px;padding:22px 25px}
.app-root:has(.accounts-summary) :is(.accounts-summary-label,.accounts-summary-value,.accounts-summary-updated,.accounts-summary-trend,.accounts-summary-metric,.accounts-summary-metric-value){color:#fff!important}
.app-root:has(.accounts-summary) .accounts-summary-label{font-size:15px;opacity:.95}
.app-root:has(.accounts-summary) .accounts-summary-value{font-size:clamp(24px,3.5vw,36px);line-height:1.3;direction:ltr;unicode-bidi:isolate}
.app-root:has(.accounts-summary) .accounts-summary-updated{opacity:.85}
.app-root:has(.accounts-summary) .accounts-month-selector{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:18px 0}
.app-root:has(.accounts-summary) .accounts-month-selector button,.app-root:has(.accounts-summary) .button-secondary,.app-root:has(.accounts-summary) .portal-header button{min-height:40px;padding:8px 16px;border:1px solid #a6b8ca;border-radius:8px;background:#fff;color:#123d68;font-weight:600}
.app-root:has(.accounts-summary) .accounts-month-selector select,.app-root:has(.accounts-summary) #portal-month{min-height:40px;padding:8px 12px;border:1px solid #a6b8ca;border-radius:8px;background:#fff;color:#102a48}
.app-root:has(.accounts-summary) button:focus-visible,.app-root:has(.accounts-summary) select:focus-visible{outline:3px solid #b07b29;outline-offset:3px}
.app-root:has(.accounts-summary) .accounts-table th,.app-root:has(.accounts-summary) .accounts-table td{text-align:right}
.app-root:has(.accounts-summary) .accounts-table th{font-weight:700;background:#102a48;color:white}
.app-root:has(.accounts-summary) .table-wrapper{border:1px solid #dee6ef;border-radius:10px;overflow-x:auto}
.app-root:has(.accounts-summary) .accounts-table tbody tr:hover{background:#eaf2f8}
@media(max-width:600px){.app-root:has(.accounts-summary) .app-main{padding:14px 10px 30px}.app-root:has(.accounts-summary) .page-container{padding:18px 14px}.app-root:has(.accounts-summary) .accounts-summary{padding:18px;gap:14px}.app-root:has(.accounts-summary) .accounts-summary-value{font-size:25px}.app-root:has(.accounts-summary) .accounts-table{min-width:590px}}

/* Signed-in dashboard: accessible contrast, RTL navigation and responsive tables. */
.app-root .accounts-summary {
  background: #12365a !important;
  background-image: none !important;
  color: #fff;
}
.app-root .accounts-summary :is(.accounts-summary-label,.accounts-summary-value,.accounts-summary-updated,.accounts-summary-metric,.accounts-summary-metric-value) {
  color: #fff !important;
}
.app-root .accounts-month-selector {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.app-root .accounts-month-selector button,
.app-root .portal-header button {
  min-height: 42px;
  padding: 9px 16px;
  border: 1px solid #b4c4d3;
  border-radius: 8px;
  background: #fff;
  color: #123d68;
  cursor: pointer;
}
.app-root .accounts-month-selector select,
.app-root #portal-month {
  min-height: 42px;
  padding: 8px 12px;
  border: 1px solid #b4c4d3;
  border-radius: 8px;
  background: #fff;
  color: #102a48;
}
.app-root .accounts-table { width: 100%; }
.app-root .accounts-table td { overflow-wrap: anywhere; }
@media (max-width: 600px) {
  .app-root .accounts-summary { flex-wrap: wrap; }
  .app-root .accounts-summary-metrics { align-items: flex-start; text-align: right; }
}
