/* =====================================================================
   PF Member Portal — member-facing styles (mobile-first, no inline CSS)
   ===================================================================== */
:root {
    --mp-font-scale: 1;
    --mp-teal: #3f8a86;
    --mp-teal-dark: #2f6f6b;
    --mp-navy: #1f3d7a;
    --mp-navy-2: #24408a;
    --mp-amber: #e6a817;
    --mp-red: #c0392b;
    --mp-ink: #253045;
    --mp-muted: #6b7280;
    --mp-line: #e3e7ee;
    --mp-bg: #eef1f6;
    --mp-card: #ffffff;
    --mp-radius: 8px;
    --mp-shadow: 0 1px 2px rgba(20, 30, 60, 0.04);
    --mp-card-border: 1px solid #e2e5ec;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: "Segoe UI", Roboto, system-ui, -apple-system, Arial, sans-serif;
    font-size: calc(15px * var(--mp-font-scale));
    color: var(--mp-ink);
    background: var(--mp-bg);
    line-height: 1.5;
}

a { color: var(--mp-navy-2); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
h1, h2, h3 { margin: 0; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

/* ---------- Ticker ---------- */
.mp-ticker { background: #f4f8fb; border-bottom: 1px solid var(--mp-line); }
.mp-ticker__inner {
    max-width: none; margin: 0; padding: 6px 16px;
    display: flex; flex-wrap: wrap; gap: 6px 20px; justify-content: space-between;
    font-size: calc(12.5px * var(--mp-font-scale)); color: var(--mp-navy-2); font-weight: 600;
}
.mp-ticker__item i { margin-right: 6px; }

/* ---------- Utility bar (login) ---------- */
.mp-utility { background: #f2f4f7; border-bottom: 1px solid var(--mp-line); }
.mp-utility__inner {
    max-width: none; margin: 0; padding: 6px 16px; min-height: 40px;
    display: flex; align-items: center; justify-content: flex-end; gap: 16px;
}
.mp-utility__link { color: var(--mp-teal-dark); font-weight: 600; font-size: calc(13px * var(--mp-font-scale)); }

/* ---------- Font-size stepper ---------- */
.mp-fontsize { display: inline-flex; gap: 6px; }
.mp-fontsize__btn {
    min-width: 30px; height: 30px; padding: 0 6px;
    border: 1px solid var(--mp-line); background: #fff; border-radius: 6px;
    font-weight: 700; color: var(--mp-ink); cursor: pointer;
}
.mp-fontsize__btn:hover { background: #eef2f7; }

/* ---------- Brand bar ---------- */
.mp-brandbar { background: #fff; border-bottom: 3px solid var(--mp-teal); }
.mp-brandbar__inner {
    max-width: none; margin: 0; padding: 16px; min-height: 86px;
    display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
}
.mp-brandbar__logos { display: flex; align-items: center; gap: 12px; color: inherit; }
.mp-brandbar__logos:hover { text-decoration: none; }
.mp-brandbar__logo-img { height: 52px; width: auto; }
.mp-brandbar__mark {
    width: 52px; height: 52px; flex-shrink: 0; border-radius: 50%;
    background: var(--mp-navy); color: #fff; font-weight: 800; font-size: calc(17px * var(--mp-font-scale));
    display: flex; align-items: center; justify-content: center;
}
.mp-brandbar__names { display: flex; flex-direction: column; }
.mp-brandbar__title { font-weight: 800; color: var(--mp-teal-dark); font-size: calc(15px * var(--mp-font-scale)); line-height: 1.2; }
.mp-brandbar__title + .mp-brandbar__title { color: var(--mp-amber); font-size: calc(12.5px * var(--mp-font-scale)); }
.mp-brandbar__subtitle { color: var(--mp-muted); font-size: calc(12px * var(--mp-font-scale)); }

.mp-brandbar__tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.mp-uan-chip {
    display: inline-flex; align-items: center; gap: 8px;
    background: #eaf3f2; border: 1px solid #cfe4e2; border-radius: 999px; padding: 5px 14px;
}
.mp-uan-chip i { color: var(--mp-teal-dark); font-size: 1.4em; }
.mp-uan-chip__uan { display: block; font-weight: 700; color: var(--mp-teal-dark); font-size: calc(13px * var(--mp-font-scale)); }
.mp-uan-chip__name { display: block; font-weight: 700; color: var(--mp-ink); font-size: calc(12.5px * var(--mp-font-scale)); }

.mp-logout-form { margin: 0; }
.mp-logout-btn {
    background: var(--mp-red); color: #fff; border: 0; border-radius: 6px;
    padding: 8px 14px; font-weight: 700; cursor: pointer; font-size: calc(13.5px * var(--mp-font-scale));
}
.mp-logout-btn:hover { filter: brightness(0.95); }

/* ---------- Main nav ---------- */
.mp-nav { background: var(--mp-teal); color: #fff; }
.mp-nav__inner { max-width: none; margin: 0; padding: 0 8px; }
.mp-nav__toggle {
    display: flex; align-items: center; gap: 8px; width: 100%;
    background: transparent; color: #fff; border: 0; padding: 12px 8px;
    font-weight: 700; font-size: calc(15px * var(--mp-font-scale)); cursor: pointer;
}
.mp-nav__list { list-style: none; margin: 0; padding: 0; display: none; }
.mp-nav__list.is-open { display: block; }
.mp-nav__li { position: relative; border-top: 1px solid rgba(255,255,255,0.15); }
.mp-nav__link {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 12px 14px; color: #fff; background: transparent; border: 0;
    font-size: calc(14.5px * var(--mp-font-scale)); font-weight: 600; cursor: pointer; text-align: left;
}
.mp-nav__link:hover, .mp-nav__link.is-active { background: rgba(0,0,0,0.14); text-decoration: none; }
.mp-nav__link.is-active { box-shadow: inset 0 -3px 0 var(--mp-amber); }
.mp-nav__caret { margin-left: auto; transition: transform 0.2s; }
.mp-nav__li--has-menu.is-open .mp-nav__caret { transform: rotate(180deg); }
.mp-nav__menu { list-style: none; margin: 0; padding: 0; display: none; background: rgba(0,0,0,0.16); }
.mp-nav__li--has-menu.is-open .mp-nav__menu { display: block; }
.mp-nav__menu a {
    display: flex; align-items: center; gap: 10px; padding: 11px 14px 11px 34px;
    color: #eaf5f4; font-size: calc(13.8px * var(--mp-font-scale));
}
.mp-nav__menu a:hover { background: rgba(0,0,0,0.22); text-decoration: none; }
.mp-nav__menu i { width: 18px; text-align: center; opacity: 0.9; }

/* ---------- Page shell (generous gap after the header/nav, like the demo mt-80 + divide20) ---------- */
.mp-page { padding: 40px 0 40px; }
.mp-page__inner { max-width: none; margin: 0; padding: 0 16px; }

.mp-flash { border-radius: 8px; padding: 12px 14px; margin-bottom: 16px; font-weight: 600; }
.mp-flash--ok { background: #e7f6ec; color: #1c7a3f; border: 1px solid #bfe6ca; }
.mp-flash--err { background: #fdecea; color: #9a2820; border: 1px solid #f3c7c2; }

/* ---------- Footer (main row ~66px + a ~14px accent strip = ~80px) ---------- */
.mp-footer { background: #24343f; color: #cfd7dd; border-bottom: 14px solid var(--mp-teal); }
.mp-footer__inner {
    max-width: none; margin: 0; padding: 10px 16px; min-height: 66px;
    display: flex; flex-direction: column; gap: 10px; text-align: center; justify-content: center;
    font-size: calc(13px * var(--mp-font-scale));
}
.mp-footer__ver { opacity: 0.7; margin-left: 6px; }
.mp-footer__follow { margin-right: 10px; font-weight: 600; }
.mp-footer__social { display: inline-flex; gap: 8px; }
.mp-footer__social a {
    width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,0.12);
    display: inline-flex; align-items: center; justify-content: center; color: #fff;
}
.mp-footer__social a:hover { background: var(--mp-teal); text-decoration: none; }
.mp-footer__col--right a { color: #fff; font-weight: 600; }

/* =====================================================================
   Login page
   ===================================================================== */
.mp-login-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }
.mp-notice-panel { background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); overflow: hidden; }
.mp-notice-panel__title {
    background: var(--mp-teal); color: #fff; padding: 12px 16px;
    font-size: calc(16px * var(--mp-font-scale)); display: flex; align-items: center; gap: 8px;
}
.mp-notice-panel__list { list-style: none; margin: 0; padding: 12px 16px; }
.mp-notice-panel__list li { padding: 9px 0; border-bottom: 1px dashed var(--mp-line); font-size: calc(14px * var(--mp-font-scale)); }
.mp-notice-panel__list li:last-child { border-bottom: 0; }

.mp-login-card {
    background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius);
    padding: 40px 22px 24px; position: relative; margin-top: 26px;
}
.mp-login-card__avatar {
    position: absolute; top: -26px; left: 50%; transform: translateX(-50%);
    width: 60px; height: 60px; border-radius: 50%; background: #fff; border: 3px solid var(--mp-teal);
    display: flex; align-items: center; justify-content: center; color: var(--mp-teal); font-size: 26px;
}
.mp-login-card__form { display: flex; flex-direction: column; gap: 14px; }
.mp-login-card__actions { display: flex; gap: 10px; }
.mp-login-card__forgot { display: inline-block; margin-top: 4px; font-weight: 600; }

/* ---------- Forms (shared) ---------- */
.mp-field { display: flex; flex-direction: column; gap: 6px; }
.mp-field label { font-weight: 600; font-size: calc(13.5px * var(--mp-font-scale)); }
.mp-req { color: var(--mp-red); }
.mp-field input, .mp-field select, .mp-field textarea {
    width: 100%; padding: 10px 12px; border: 1px solid #cfd6e0; border-radius: 7px;
    font-size: calc(14px * var(--mp-font-scale)); font-family: inherit; background: #fff; color: var(--mp-ink);
}
.mp-field input:focus, .mp-field select:focus, .mp-field textarea:focus {
    outline: 0; border-color: var(--mp-teal); box-shadow: 0 0 0 3px rgba(63,138,134,0.15);
}
.mp-input-icon { position: relative; }
.mp-input-icon input { padding-right: 42px; }
.mp-input-icon__btn {
    position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
    background: transparent; border: 0; padding: 8px; color: var(--mp-muted); cursor: pointer;
}
.mp-error-text { background: #fdecea; color: #9a2820; border: 1px solid #f3c7c2; border-radius: 7px; padding: 9px 12px; margin: 0; font-weight: 600; }

.mp-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 10px 18px; border: 0; border-radius: 7px; font-weight: 700; cursor: pointer;
    font-size: calc(14px * var(--mp-font-scale)); font-family: inherit;
}
.mp-btn--primary { background: var(--mp-teal); color: #fff; }
.mp-btn--primary:hover { background: var(--mp-teal-dark); text-decoration: none; }
.mp-btn--muted { background: #6b7280; color: #fff; }
.mp-btn--muted:hover { filter: brightness(0.95); }
.mp-btn--nav { background: var(--mp-navy-2); color: #fff; }

/* ---------- Captcha ---------- */
.mp-captcha-row { display: flex; align-items: center; gap: 12px; }
.mp-captcha-box {
    display: inline-flex; gap: 4px; padding: 6px 10px; border-radius: 6px;
    background: repeating-linear-gradient(45deg, #eef1f5, #eef1f5 6px, #e4e8ee 6px, #e4e8ee 12px);
    border: 1px solid #cfd6e0;
}
.mp-captcha-box__char { font-weight: 800; font-size: calc(18px * var(--mp-font-scale)); letter-spacing: 2px; color: #2a3a63; font-style: italic; }
.mp-captcha-refresh { color: var(--mp-teal-dark); font-size: 18px; }

/* ---------- Login service cards (one outer container, flat tiles) ---------- */
.mp-servicecards { margin-top: 20px; background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); padding: 16px; }
.mp-servicecards__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.mp-scard {
    background: #fff; border-radius: var(--mp-radius); min-height: 200px;
    padding: 22px 12px; text-align: center; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
    color: var(--mp-ink); border: var(--mp-card-border);
}
.mp-scard:hover { text-decoration: none; border-color: var(--mp-teal); }
.mp-scard__icon {
    width: 54px; height: 54px; border-radius: 14px; background: #eaf3f2; color: var(--mp-teal-dark);
    display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.mp-scard__title { font-weight: 700; font-size: calc(14.5px * var(--mp-font-scale)); }
.mp-scard__desc { color: var(--mp-muted); font-size: calc(12.5px * var(--mp-font-scale)); }

/* =====================================================================
   Home
   ===================================================================== */
.mp-home { display: grid; grid-template-columns: 1fr; gap: 18px; margin-bottom: 18px; }
.mp-home__main, .mp-home__notices { display: flex; flex-direction: column; gap: 14px; }

.mp-notice {
    display: flex; align-items: flex-start; gap: 12px;
    border-radius: var(--mp-radius); padding: 14px 14px; box-shadow: var(--mp-shadow);
}
.mp-notice--danger { background: #fdecea; border: 1px solid #f3c7c2; }
.mp-notice--info { background: #eaf4fb; border: 1px solid #cbe4f5; }
.mp-notice__icon { font-size: 18px; }
.mp-notice--danger .mp-notice__icon { color: var(--mp-red); }
.mp-notice--info .mp-notice__icon { color: var(--mp-navy-2); }
.mp-notice__body { flex: 1; font-size: calc(14px * var(--mp-font-scale)); font-weight: 500; }
.mp-notice__badge { display: inline-block; background: var(--mp-red); color: #fff; font-size: 11px; font-weight: 800; border-radius: 4px; padding: 2px 7px; margin-right: 8px; text-transform: uppercase; }
.mp-notice__close { background: transparent; border: 0; font-size: 22px; line-height: 1; color: var(--mp-muted); cursor: pointer; }

/* Quick links */
.mp-quicklinks { background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); padding: 16px; }
.mp-quicklinks__title { font-size: calc(16px * var(--mp-font-scale)); color: var(--mp-muted); text-transform: uppercase; letter-spacing: 0.04em; display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.mp-quicklinks__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.mp-qcard {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center;
    border: 1px solid var(--mp-line); border-radius: var(--mp-radius); padding: 18px 10px; min-height: 200px; color: var(--mp-ink);
}
.mp-qcard:hover { text-decoration: none; border-color: var(--mp-teal); background: #f7fbfb; }
.mp-qcard__icon { width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 20px; }
.mp-qcard__icon--amber { background: #fdf1d8; color: #b8860b; }
.mp-qcard__icon--blue { background: #e4edfb; color: #2c5fb3; }
.mp-qcard__icon--rose { background: #fbe4ea; color: #c03a63; }
.mp-qcard__icon--teal { background: #dff1f0; color: var(--mp-teal-dark); }
.mp-qcard__icon--green { background: #e2f3e5; color: #2f8a45; }
.mp-qcard__icon--slate { background: #e8ebf0; color: #55617a; }
.mp-qcard__label { font-weight: 700; font-size: calc(13.8px * var(--mp-font-scale)); }
.mp-qcard__hint { color: var(--mp-muted); font-size: calc(12px * var(--mp-font-scale)); }

/* Profile card */
.mp-profile-card { background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); padding: 16px; }
.mp-profile-card__title { display: flex; align-items: center; gap: 8px; color: var(--mp-teal-dark); font-size: calc(16px * var(--mp-font-scale)); border-bottom: 2px solid var(--mp-line); padding-bottom: 12px; margin-bottom: 8px; }

.mp-kv { margin: 0; }
.mp-kv__row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 2px; border-bottom: 1px solid var(--mp-line); }
.mp-kv__row dt { font-weight: 700; color: var(--mp-ink); margin: 0; }
.mp-kv__row dd { margin: 0; color: var(--mp-ink); text-align: right; }

.mp-disclose { border-top: 1px solid var(--mp-line); }
.mp-disclose summary { cursor: pointer; padding: 12px 2px; font-weight: 700; color: var(--mp-teal-dark); list-style: none; display: flex; align-items: center; gap: 8px; }
.mp-disclose summary::-webkit-details-marker { display: none; }

/* =====================================================================
   Shared content components (used by module pages)
   ===================================================================== */
.mp-panel { background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); padding: 16px; margin-bottom: 18px; }
.mp-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-bottom: 2px solid var(--mp-line); padding-bottom: 12px; margin-bottom: 14px; }
.mp-panel__title { display: flex; align-items: center; gap: 8px; color: var(--mp-teal-dark); font-size: calc(17px * var(--mp-font-scale)); }
.mp-panel__hint { color: var(--mp-muted); font-size: calc(13px * var(--mp-font-scale)); }

.mp-page-title { display: flex; align-items: center; gap: 10px; color: var(--mp-navy); font-size: calc(19px * var(--mp-font-scale)); margin-bottom: 14px; }

.mp-table-wrap { overflow-x: auto; }
.mp-table { width: 100%; border-collapse: collapse; font-size: calc(13px * var(--mp-font-scale)); }
.mp-table th, .mp-table td { border: 1px solid var(--mp-line); padding: 9px 10px; text-align: left; vertical-align: top; }
.mp-table thead th { background: var(--mp-teal); color: #fff; font-weight: 700; }
.mp-table tbody tr:nth-child(even) { background: #f7f9fc; }
.mp-table .mp-th-group { text-align: center; }

.mp-badge { display: inline-block; border-radius: 999px; padding: 3px 10px; font-size: calc(12px * var(--mp-font-scale)); font-weight: 700; }
.mp-badge--green { background: #e2f3e5; color: #2f8a45; }
.mp-badge--amber { background: #fdf1d8; color: #a9760a; }
.mp-badge--red { background: #fdecea; color: var(--mp-red); }
.mp-badge--slate { background: #e8ebf0; color: #55617a; }
.mp-badge--blue { background: #e4edfb; color: #2c5fb3; }

.mp-form-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.mp-section-head { background: var(--mp-navy); color: #fff; padding: 9px 14px; border-radius: 6px; font-weight: 700; margin: 4px 0 14px; }
.mp-empty { text-align: center; color: var(--mp-muted); padding: 26px 12px; }

.mp-actions-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.mp-field--full { grid-column: 1 / -1; margin-top: 14px; }

/* =====================================================================
   Responsive — tablet / desktop
   ===================================================================== */
@media (min-width: 720px) {
    .mp-quicklinks__grid { grid-template-columns: repeat(3, 1fr); }
    .mp-servicecards__grid { grid-template-columns: repeat(3, 1fr); }
    .mp-login-grid { grid-template-columns: 3fr minmax(300px, 1fr); align-items: start; }
    .mp-login-card { margin-top: 0; }
    .mp-footer__inner { flex-direction: row; justify-content: space-between; align-items: center; text-align: left; }
    .mp-form-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 992px) {
    .mp-servicecards__grid { grid-template-columns: repeat(7, 1fr); }
    .mp-quicklinks__grid { grid-template-columns: repeat(6, 1fr); }
    /* Top row: notices (col-7) + Member Profile (col-5) */
    .mp-home { grid-template-columns: 7fr 5fr; align-items: start; }

    /* Desktop nav becomes a horizontal bar with hover/click dropdowns */
    .mp-nav__toggle { display: none; }
    .mp-nav__list { display: flex !important; }
    .mp-nav__li { border-top: 0; }
    .mp-nav__link { padding: 14px 14px; white-space: nowrap; }
    .mp-nav__menu {
        position: absolute; top: 100%; left: 0; min-width: 240px; z-index: 40;
        background: #fff; box-shadow: 0 8px 24px rgba(0,0,0,0.18); border-radius: 0 0 8px 8px; padding: 6px 0;
    }
    .mp-nav__li--has-menu.is-open .mp-nav__menu { display: block; }
    .mp-nav__li--has-menu:hover .mp-nav__menu { display: block; }
    .mp-nav__menu a { color: var(--mp-ink); padding: 10px 16px; }
    .mp-nav__menu a:hover { background: #eef4f3; color: var(--mp-teal-dark); }
    .mp-nav__menu i { color: var(--mp-teal-dark); }
}

@media (min-width: 1100px) {
    .mp-quicklinks__grid { grid-template-columns: repeat(6, 1fr); }
}

/* ---------- Service history table ---------- */
.mp-nowrap { white-space: nowrap; }
.mp-svc-group td { font-weight: 800; color: #fff; }
.mp-svc-group--primary-member-id td { background: var(--mp-amber); color: #4a3200; }
.mp-svc-group--due-for-transfer-scheme-certificate-surrender td { background: var(--mp-navy-2); }
.mp-svc-group--other-member-ids td { background: var(--mp-teal-dark); }
.mp-svc-table td, .mp-svc-table th { font-size: calc(12px * var(--mp-font-scale)); }

/* ---------- Passbook ---------- */
.mp-passbook-closing {
    margin: 12px 0 0;
    text-align: right;
    font-weight: 800;
    color: var(--mp-teal-dark);
    font-size: calc(15px * var(--mp-font-scale));
}

/* ---------- UAN Card ---------- */
.mp-uan-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.mp-uan-toolbar .mp-page-title { margin: 0; }
.mp-btn--link { background: none; border: none; color: var(--mp-navy-2); font-weight: 700; cursor: pointer; padding: 6px 8px; text-decoration: underline; }
.mp-btn--link:hover { color: var(--mp-teal-dark); }

.mp-uan-viewer { background: #525659; border: 1px solid var(--mp-line); border-radius: var(--mp-radius); overflow: hidden; }
.mp-uan-viewer__frame { display: block; width: 100%; height: 78vh; min-height: 520px; border: 0; }

.mp-uan-stage { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }

.mp-uan-card {
    background: #fff;
    border: 1px solid var(--mp-line);
    border-radius: var(--mp-radius);
    box-shadow: var(--mp-shadow);
    width: 420px;
    max-width: 100%;
    padding: 16px 18px 18px;
    color: var(--mp-ink);
}

.mp-uan-card__head { display: flex; align-items: flex-start; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--mp-line); margin-bottom: 14px; }
.mp-uan-card__logo { flex-shrink: 0; }
.mp-uan-card__logo img { width: 52px; height: 52px; object-fit: contain; }
.mp-uan-card__mark { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 50%; background: var(--mp-teal); color: #fff; font-weight: 800; font-size: calc(18px * var(--mp-font-scale)); letter-spacing: 1px; }
.mp-uan-card__org { display: flex; flex-direction: column; gap: 1px; }
.mp-uan-card__org-line { font-weight: 800; color: var(--mp-teal-dark); font-size: calc(14px * var(--mp-font-scale)); line-height: 1.25; }
.mp-uan-card__org-sub { color: var(--mp-muted); font-size: calc(11px * var(--mp-font-scale)); margin-top: 2px; }

.mp-uan-card__body { display: flex; gap: 16px; }
.mp-uan-card__fields { flex: 1; min-width: 0; }
.mp-uan-card__photo { flex-shrink: 0; width: 104px; }
.mp-uan-card__photo img { width: 104px; height: 128px; object-fit: cover; border: 1px solid var(--mp-line); }
.mp-uan-card__photo-empty { display: flex; align-items: center; justify-content: center; width: 104px; height: 128px; border: 1px solid var(--mp-line); color: var(--mp-line); font-size: 48px; background: #f6f8fb; }

.mp-uan-card__uan { margin-bottom: 16px; }
.mp-uan-card__uan-label { display: block; color: var(--mp-ink); font-weight: 700; font-size: calc(12px * var(--mp-font-scale)); }
.mp-uan-card__uan-value { display: block; color: var(--mp-red); font-weight: 800; font-size: calc(22px * var(--mp-font-scale)); letter-spacing: 1px; }
.mp-uan-card__uan-value--sm { font-size: calc(18px * var(--mp-font-scale)); }
.mp-uan-card__hi { display: block; font-weight: 700; color: var(--mp-ink); font-size: calc(12px * var(--mp-font-scale)); }

.mp-uan-card__list { margin: 0; }
.mp-uan-card__row { margin-bottom: 14px; }
.mp-uan-card__row dt { color: var(--mp-ink); font-weight: 700; font-size: calc(12px * var(--mp-font-scale)); line-height: 1.3; }
.mp-uan-card__row dd { margin: 3px 0 0; font-weight: 700; color: #111827; font-size: calc(14px * var(--mp-font-scale)); }

.mp-uan-card--back .mp-uan-card__head--back { justify-content: center; }
.mp-uan-card__site { font-weight: 800; color: var(--mp-ink); font-size: calc(13px * var(--mp-font-scale)); }
.mp-uan-card__back-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.mp-uan-card__qr { display: flex; justify-content: flex-end; min-height: 120px; margin-bottom: 16px; }
.mp-uan-card__qr img, .mp-uan-card__qr canvas { width: 120px; height: 120px; }
.mp-uan-card__note p { margin: 0 0 8px; color: var(--mp-ink); font-size: calc(12px * var(--mp-font-scale)); line-height: 1.5; }
.mp-uan-card__printed { margin: 12px 0 0; text-align: right; font-style: italic; color: var(--mp-muted); font-size: calc(11px * var(--mp-font-scale)); }

@media (max-width: 480px) {
    .mp-uan-card__body { flex-direction: column-reverse; }
    .mp-uan-card__photo, .mp-uan-card__photo img, .mp-uan-card__photo-empty { width: 100%; }
    .mp-uan-card__photo img, .mp-uan-card__photo-empty { height: 160px; }
}

@media print {
    body * { visibility: hidden; }
    .mp-uan-stage, .mp-uan-stage * { visibility: visible; }
    .mp-uan-stage { position: absolute; left: 0; top: 0; width: 100%; gap: 16px; }
    .mp-uan-card { border-color: #333; box-shadow: none; page-break-inside: avoid; }
}

/* ---------- PMVBRY course modules ---------- */
.mp-course-modules { margin: 4px 0 16px; padding-left: 22px; }
.mp-course-modules li { padding: 5px 0; font-weight: 600; }

/* ---------- PMVBRY certificate ---------- */
.mp-certificate {
    border: 2px solid var(--mp-teal);
    border-radius: var(--mp-radius);
    padding: 28px 20px;
    margin-bottom: 16px;
    text-align: center;
    background: #fbfdfc;
    box-shadow: inset 0 0 0 4px #eaf3f2;
}
.mp-certificate__seal {
    width: 56px; height: 56px; margin: 0 auto 12px;
    border-radius: 50%; background: #fdf1d8; color: var(--mp-amber);
    display: flex; align-items: center; justify-content: center; font-size: 26px;
}
.mp-certificate__title { color: var(--mp-navy); font-size: calc(22px * var(--mp-font-scale)); margin-bottom: 10px; }
.mp-certificate__lead { color: var(--mp-muted); margin: 0 0 4px; }
.mp-certificate__name {
    color: var(--mp-teal-dark); font-weight: 800;
    font-size: calc(22px * var(--mp-font-scale)); margin: 4px 0 12px;
}
.mp-certificate__body { max-width: 560px; margin: 0 auto 14px; color: var(--mp-ink); }
.mp-certificate__date { color: var(--mp-muted); font-weight: 600; margin: 0; }

/* ---------- Alert popup modal ---------- */
.mp-modal-open { overflow: hidden; }
.mp-modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: flex-start; justify-content: center; padding: 20px 14px; overflow-y: auto; }
.mp-modal__backdrop { position: fixed; inset: 0; background: rgba(20, 28, 45, 0.55); }
.mp-modal__dialog { position: relative; z-index: 1; width: 100%; max-width: 820px; background: #fff; border-radius: var(--mp-radius); box-shadow: 0 20px 60px rgba(0,0,0,0.35); margin: auto; overflow: hidden; }
.mp-modal__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--mp-line); }
.mp-modal__title { display: flex; align-items: center; gap: 10px; color: var(--mp-red); font-size: calc(18px * var(--mp-font-scale)); }
.mp-modal__close { background: #fff; border: 1px solid var(--mp-line); border-radius: 6px; width: 34px; height: 34px; font-size: 20px; line-height: 1; cursor: pointer; color: var(--mp-muted); }
.mp-modal__close:hover { background: #f2f4f7; }
.mp-modal__body { padding: 18px; display: flex; flex-direction: column; gap: 16px; }
.mp-modal__alert { display: flex; align-items: flex-start; gap: 12px; background: #fdecea; border: 1px solid #f3c7c2; border-radius: 8px; padding: 16px; color: var(--mp-red); }
.mp-modal__alert i { font-size: 18px; margin-top: 2px; }
.mp-modal__alert p { margin: 0 0 4px; font-weight: 600; }
.mp-modal__alert-lead { font-weight: 800; }
.mp-modal__points { background: #eaf4fb; border: 1px solid #cbe4f5; border-radius: 8px; padding: 16px 18px; }
.mp-modal__points ul { list-style: none; margin: 0; padding: 0; }
.mp-modal__points li { display: flex; align-items: flex-start; gap: 10px; padding: 6px 0; font-weight: 600; color: var(--mp-ink); }
.mp-modal__points li i { color: var(--mp-navy-2); margin-top: 3px; }
.mp-modal__sign { text-align: right; font-weight: 800; margin: 8px 0 0; color: var(--mp-ink); }
.mp-modal__foot { display: flex; justify-content: flex-end; padding: 14px 18px; border-top: 1px solid var(--mp-line); }
.mp-modal__foot .mp-btn--primary { background: var(--mp-red); }
.mp-modal__foot .mp-btn--primary:hover { filter: brightness(0.95); }

/* ---------- Login OTP (second factor) ---------- */
.mp-otp-wrap { max-width: 520px; margin: 40px auto; }
.mp-otp-alert {
    display: flex; align-items: flex-start; gap: 10px; text-align: center; justify-content: center;
    background: #e7f6ec; border: 1px solid #bfe6ca; color: #1c6b3a; border-radius: var(--mp-radius);
    padding: 16px 18px; margin-bottom: 18px; font-size: calc(14px * var(--mp-font-scale));
}
.mp-otp-alert i { margin-top: 2px; }
.mp-otp-card { background: #fff; border: var(--mp-card-border); border-radius: var(--mp-radius); overflow: hidden; }
.mp-otp-card__head {
    background: var(--mp-teal-dark); color: #fff; text-align: center; padding: 18px 16px;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    font-weight: 700; font-size: calc(16px * var(--mp-font-scale));
}
.mp-otp-card__head i { font-size: 22px; }
.mp-otp-card__body { padding: 22px 20px; display: flex; flex-direction: column; gap: 14px; }
.mp-otp-validity { margin: 0; color: var(--mp-muted); font-size: calc(13px * var(--mp-font-scale)); }
.mp-otp-validity strong { color: var(--mp-teal-dark); }
.mp-otp-actions { display: flex; gap: 12px; }
.mp-otp-actions .mp-btn { flex: 1; }
.mp-btn--outline-danger { background: #fff; color: var(--mp-red); border: 1px solid var(--mp-red); }
.mp-btn--outline-danger:hover { background: #fdecea; text-decoration: none; }
.mp-otp-resend { text-align: center; }
.mp-linklike { background: none; border: 0; color: var(--mp-navy-2); font-weight: 600; cursor: pointer; font-family: inherit; font-size: calc(13px * var(--mp-font-scale)); padding: 0; }
.mp-linklike:hover { text-decoration: underline; }

/* ---------- Profile / Member Details page ---------- */
.mp-profile { display: grid; grid-template-columns: 1fr; gap: 20px; }
.mp-profile__aside { display: flex; flex-direction: column; gap: 18px; }
.mp-profile__photo { display: flex; flex-direction: column; align-items: stretch; }
.mp-profile__avatar {
    width: 100%; max-width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
    border: var(--mp-card-border); border-radius: var(--mp-radius); background: #f2f4f7;
}
.mp-profile__avatar--empty {
    display: flex; align-items: center; justify-content: center;
    color: #b7c0cf; font-size: 96px;
}
.mp-profile__photo-form { max-width: 100%; margin-top: -6px; }
.mp-profile__change {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    background: #55606f; color: #fff; padding: 8px 12px; border-radius: 0 0 var(--mp-radius) var(--mp-radius);
    font-weight: 600; cursor: pointer; font-size: calc(13.5px * var(--mp-font-scale));
}
.mp-profile__change:hover { background: #46505d; }
.mp-profile__file { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.mp-profile__quicklinks { display: flex; flex-direction: column; gap: 8px; }
.mp-profile__quicklinks-title { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--mp-ink); margin: 0 0 4px; }
.mp-profile__quicklinks a { color: var(--mp-navy-2); font-weight: 600; }

.mp-profile__main { min-width: 0; }
.mp-profile__name { color: var(--mp-ink); font-size: calc(18px * var(--mp-font-scale)); }
.mp-profile__name span { color: var(--mp-muted); font-weight: 600; }
.mp-profile__contact { list-style: none; margin: 10px 0 4px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.mp-profile__contact li { display: flex; align-items: center; gap: 10px; color: var(--mp-ink); font-weight: 600; }
.mp-profile__contact i { color: var(--mp-teal-dark); width: 18px; text-align: center; }
.mp-profile__tab {
    display: inline-block; font-weight: 700; color: var(--mp-ink);
    border-bottom: 3px solid var(--mp-teal); padding: 12px 4px 8px; margin: 8px 0 4px;
}

.mp-detail-list { margin: 0; }
.mp-detail-list__row { display: grid; grid-template-columns: 1fr; gap: 2px 16px; padding: 12px 2px; }
.mp-detail-list__row dt { font-weight: 700; color: var(--mp-ink); margin: 0; }
.mp-detail-list__row dd { margin: 0; color: var(--mp-ink); }

.mp-profile__edit { margin-top: 18px; }
.mp-profile__edit > summary { display: inline-flex; list-style: none; cursor: pointer; }
.mp-profile__edit > summary::-webkit-details-marker { display: none; }
.mp-profile__edit-form { margin-top: 16px; border-top: 1px solid var(--mp-line); padding-top: 16px; }
.mp-profile__edit-checks { display: flex; flex-wrap: wrap; gap: 18px; margin: 14px 0; }
.mp-profile__edit-checks label { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }

@media (min-width: 768px) {
    .mp-detail-list__row { grid-template-columns: 260px 1fr; }
}
@media (min-width: 900px) {
    /* Photo = Bootstrap col-md-4 (33.33%), the rest for name/contact/details */
    .mp-profile { grid-template-columns: 33.333% 1fr; align-items: start; }
}

/* ---------- White content page (e.g. Member Details) — the whole page is white, no card ---------- */
/* Content sits in a 1320px container (like the demo .container), aligned left. */
.mp-body--white { background: #fff; }
.mp-card-page { background: transparent; padding: 0 8px; max-width: 1320px; }
.mp-page-title--divider {
    border-bottom: 2px solid var(--mp-amber);
    padding-bottom: 14px; margin-bottom: 22px; color: #8a6d1a;
}
