/* FitClub 43-009 - ứng dụng học viên / huấn luyện viên (giao diện điện thoại) */
body.member { background: var(--mist); min-height: 100vh; -webkit-tap-highlight-color: transparent; }

/* ---------- Đăng nhập ---------- */
.auth { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 24px 18px;
    background: radial-gradient(ellipse at top, #1B4A78 0%, var(--ink) 70%); }
.auth-back { text-decoration: none; }
.auth-logo { width: 112px; height: 112px; margin-bottom: 14px; filter: drop-shadow(0 8px 20px rgba(0,0,0,.35)); }
.auth-card { width: 100%; max-width: 400px; background: var(--paper); border-radius: 18px; padding: 26px 22px; }
.auth-card h1 { font-size: 1.5rem; letter-spacing: -0.02em; color: var(--ink); }
.auth-note { color: var(--muted); font-size: .9rem; margin-top: 8px; }
.btn-block { width: 100%; margin-top: 20px; }
.link-btn { font: inherit; background: none; border: 0; color: var(--teal); padding: 12px 0 0; cursor: pointer; width: 100%; }

/* ---------- Khung ứng dụng ---------- */
.shell { max-width: 640px; margin: 0 auto; min-height: 100vh; padding-bottom: calc(78px + env(safe-area-inset-bottom)); }
.appbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px; padding: 10px 14px;
    padding-top: calc(10px + env(safe-area-inset-top)); background: var(--ink); color: #fff; }
.appbar-logo { width: 36px; height: 36px; flex: none; }
.appbar-text { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.appbar-text strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 1.02rem; }
.appbar-text span { font-size: .8rem; color: #A9C7B1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { background: none; border: 0; color: #fff; font-size: 2rem; line-height: 1; padding: 0 8px 4px 2px; cursor: pointer; }
.avatar-link { text-decoration: none; flex: none; }
.avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; display: block; }
.avatar-text { display: grid; place-items: center; background: var(--ember); color: #fff; font-weight: 800; }

.view { padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.view h2 { font-size: 1.3rem; letter-spacing: -0.01em; color: var(--ink); }
.section-title { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-top: 6px; }
.section-title h3 { font-size: 1rem; color: var(--ink); }
.section-title a, .section-title button { font: inherit; font-size: .88rem; font-weight: 600; color: var(--teal); background: none; border: 0; cursor: pointer; text-decoration: none; padding: 0; }
.card { background: var(--paper); border-radius: 16px; padding: 14px 16px; }
.card h3 { font-size: 1rem; margin-bottom: 8px; color: var(--ink); }
.muted { color: var(--muted); font-size: .88rem; }
.empty { color: var(--muted); text-align: center; padding: 18px 8px; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.btn-sm { padding: 7px 14px; font-size: .88rem; border-radius: 9px; }
.btn-line { background: var(--paper); color: var(--ink); border: 1.5px solid var(--line); }
.btn-line:hover { background: var(--mist); color: var(--ink); }
.btn-green { background: var(--good); color: #fff; }
.btn-green:hover { background: #15803D; color: #fff; }
.btn-danger-line { background: var(--paper); color: var(--bad); border: 1.5px solid #F2C4C0; }
.btn-danger-line:hover { background: var(--bad); color: #fff; }
.fab { position: fixed; right: max(16px, calc(50% - 304px)); bottom: calc(88px + env(safe-area-inset-bottom)); z-index: 15;
    border-radius: 999px; padding: 13px 20px; box-shadow: 0 10px 24px rgba(15, 45, 74, .28); }

/* ---------- Thẻ cân nặng / chỉ số ---------- */
.hero-card { background: var(--ink); color: #EAF3EC; }
.hero-card .muted { color: #A9C7B1; }
.weight-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.weight-now { font-size: 2.5rem; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.weight-now small { font-size: 1rem; font-weight: 600; color: #A9C7B1; margin-left: 4px; }
.delta { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: .9rem; }
.delta.good { color: #7DDC9A; }
.delta.bad { color: #FF9C8F; }
.delta.neutral { color: #FFB066; }
.card .delta.good { color: var(--good); }
.card .delta.bad { color: var(--bad); }
.card .delta.neutral { color: #C2410C; }
.hero-card .delta.neutral { color: #FFB066; }
.weight-meta { display: flex; gap: 16px; margin-top: 8px; font-size: .88rem; color: #A9C7B1; flex-wrap: wrap; }
.weight-meta b { color: #fff; }

.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tile { background: var(--paper); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tile .label { font-size: .8rem; color: var(--muted); }
.tile .value { font-size: 1.4rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ink); }
.tile .value small { font-size: .8rem; font-weight: 600; color: var(--muted); margin-left: 2px; }
.tile.link { cursor: pointer; text-decoration: none; color: inherit; }
.tile.accent { background: linear-gradient(135deg, #FF8A00, #FFA733); color: #fff; }
.tile.accent .value, .tile.accent .value small { color: #fff; }
.tile.accent .label { color: rgba(255,255,255,.9); }

/* ---------- Vòng tiến độ tuần ---------- */
.progress-card { display: flex; align-items: center; gap: 16px; }
.ring { width: 84px; height: 84px; flex: none; }
.ring .bg { fill: none; stroke: var(--mist); stroke-width: 10; }
.ring .fg { fill: none; stroke: var(--teal); stroke-width: 10; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; }
.ring text { font-size: 20px; font-weight: 800; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.progress-text strong { display: block; font-size: 1.05rem; color: var(--ink); }
.bar { height: 8px; background: var(--mist); border-radius: 4px; overflow: hidden; }
.bar span { display: block; height: 100%; background: linear-gradient(90deg, #2563EB, #38BDF8); border-radius: 4px; }

/* ---------- Danh sách ---------- */
.list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.list > li { padding: 11px 0; border-bottom: 1px solid var(--line); }
.list > li:last-child { border-bottom: 0; }
.item-title { font-weight: 650; color: var(--text); }
.item-meta { font-size: .84rem; color: var(--muted); margin-top: 2px; }
.item-body { margin-top: 6px; white-space: pre-line; font-size: .94rem; }
.pill { display: inline-block; font-size: .72rem; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: var(--teal-soft); color: var(--teal); margin-right: 6px; white-space: nowrap; vertical-align: middle; }
.pill.warn { background: #FFF4E5; color: #C2410C; }
.pill.bad { background: #FDE3E0; color: var(--bad); }
.pill.good { background: #DDF2E2; color: var(--good); }
.pill.gray { background: #EEF1EC; color: var(--muted); }
.pill.blue { background: #E3F0FD; color: #1565C0; }

/* Buổi tập */
.session { display: grid; grid-template-columns: 52px 1fr; gap: 10px; align-items: start; }
.session-time { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink); font-size: .9rem; padding-top: 1px; }
.session.done .item-title { text-decoration: line-through; text-decoration-color: rgba(14,122,52,.5); color: var(--muted); }

/* Học viên */
.trainee { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; text-decoration: none; color: inherit; }
.trainee .avatar { width: 44px; height: 44px; }
.trainee .avatar-text { background: var(--teal-soft); color: var(--teal); }
.trainee-right { text-align: right; font-variant-numeric: tabular-nums; }
.trainee-right b { display: block; color: var(--ink); }
.trainee .bar { margin-top: 6px; }

/* ---------- Bộ chọn ---------- */
.segmented { display: flex; background: var(--paper); border-radius: 12px; padding: 4px; gap: 4px; }
.segmented button { flex: 1; font: inherit; font-weight: 650; font-size: .92rem; border: 0; background: none; padding: 9px 6px; border-radius: 9px; cursor: pointer; color: var(--muted); }
.segmented button.on { background: var(--ink); color: #fff; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { font: inherit; font-size: .86rem; font-weight: 650; white-space: nowrap; border: 1.5px solid var(--line); background: var(--paper); color: var(--text); padding: 6px 13px; border-radius: 999px; cursor: pointer; }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.period-nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.period-nav button { font: inherit; font-size: 1.3rem; width: 42px; height: 38px; background: var(--paper); border: 0; border-radius: 10px; cursor: pointer; color: var(--ink); }
.period-nav strong { text-align: center; flex: 1; color: var(--ink); }
.search { position: relative; }
.search input { padding-left: 14px; border-radius: 12px; }

/* Thống kê nhỏ */
.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mini-stats div { background: var(--paper); border-radius: 12px; padding: 10px; text-align: center; }
.mini-stats b { display: block; font-size: 1.2rem; font-variant-numeric: tabular-nums; color: var(--ink); }
.mini-stats span { font-size: .75rem; color: var(--muted); }

/* Lịch tháng */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal .dow { text-align: center; font-size: .72rem; color: var(--muted); font-weight: 700; padding-bottom: 2px; }
.cal button { font: inherit; aspect-ratio: 1 / 1; border: 0; border-radius: 10px; background: var(--paper); cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--text); padding: 0; }
.cal button.out { visibility: hidden; }
.cal button.today { outline: 2px solid var(--ember); }
.cal button.sel { background: var(--ink); color: #fff; }
.cal .num { font-size: .9rem; font-weight: 650; font-variant-numeric: tabular-nums; }
.dots { display: flex; gap: 2px; height: 6px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.dots i.done { background: var(--good); }
.dots i.plan { background: var(--ember-dark); }
.dots i.miss { background: var(--bad); }
.legend { display: flex; gap: 14px; font-size: .78rem; color: var(--muted); flex-wrap: wrap; }
.legend span::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; background: var(--line); }
.legend .l-done::before { background: var(--good); }
.legend .l-plan::before { background: var(--ember-dark); }
.legend .l-miss::before { background: var(--bad); }

/* Biểu đồ */
.chart { display: block; width: 100%; height: auto; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .axis { font-size: 11px; fill: var(--muted); font-variant-numeric: tabular-nums; }
.chart .line { fill: none; stroke: var(--teal); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: rgba(37, 99, 235, .10); }
.chart .pt { fill: var(--paper); stroke: var(--teal); stroke-width: 2; }
.chart .pt.last { fill: var(--teal); }
.chart .bar-total { fill: #E2E8F0; }
.chart .bar-done { fill: var(--teal); }
.chart .bar-label { font-size: 10px; fill: var(--muted); text-anchor: middle; }
.chart .bar-val { font-size: 10px; fill: var(--ink); text-anchor: middle; font-weight: 700; }
.spark { display: block; width: 100%; height: 64px; margin-top: 6px; }
.spark .line { fill: none; stroke: var(--ember); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.spark .area { fill: rgba(255, 138, 0, .16); }
.spark .dot { fill: var(--ember); }

/* Bảng chỉ số */
.record { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px 10px; margin-top: 6px; font-variant-numeric: tabular-nums; }
.record div span { display: block; font-size: .72rem; color: var(--muted); }
.record div b { font-size: .95rem; color: var(--ink); }
.record-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* ---------- Bảng trượt (biểu mẫu) ---------- */
.sheet { border: 0; padding: 0; margin: auto auto 0; width: 100%; max-width: 640px; max-height: 92vh; border-radius: 20px 20px 0 0; background: var(--paper); }
.sheet::backdrop { background: rgba(15, 45, 74, .5); }
.sheet-inner { padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); overflow-y: auto; max-height: 92vh; }
.sheet-inner h3 { font-size: 1.15rem; color: var(--ink); }
.sheet-grab { width: 44px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 12px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.form-grid .full { grid-column: 1 / -1; }
.weekday-picks { display: flex; gap: 6px; flex-wrap: wrap; }
.weekday-picks label { margin: 0; display: inline-flex; }
.weekday-picks input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.weekday-picks span { display: inline-grid; place-items: center; width: 42px; height: 38px; border-radius: 10px; border: 1.5px solid var(--line); font-weight: 700; font-size: .85rem; cursor: pointer; }
.weekday-picks input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.weekday-picks input:focus-visible + span { outline: 3px solid var(--ember); }
.sheet-actions { display: flex; gap: 10px; margin-top: 18px; }
.sheet-actions .btn { flex: 1; }

/* ---------- Thanh tab dưới ---------- */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; justify-content: center;
    background: #fff; border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.tabbar a { flex: 1; max-width: 128px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 2px 9px;
    font-size: .7rem; font-weight: 650; color: var(--muted); text-decoration: none; white-space: nowrap; }
.tabbar svg { width: 23px; height: 23px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tabbar a.active { color: var(--ink); }
.tabbar a.active svg { stroke: var(--teal); }
.tabbar a.active .tab-dot { background: var(--ember); }
.tab-dot { width: 18px; height: 3px; border-radius: 2px; background: transparent; margin-top: 1px; }

/* Menu trang Tôi */
.menu-list { list-style: none; margin: 0; padding: 0; background: var(--paper); border-radius: 16px; overflow: hidden; }
.menu-list a, .menu-list button { display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 15px 16px; font: inherit; font-weight: 600;
    text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); color: var(--text); text-decoration: none; cursor: pointer; }
.menu-list li:last-child a, .menu-list li:last-child button { border-bottom: 0; }
.menu-list .chev { color: var(--muted); font-size: 1.2rem; }
.menu-list .danger { color: var(--bad); }
.profile { display: flex; gap: 14px; align-items: center; }
.profile .avatar { width: 60px; height: 60px; font-size: 1.4rem; }

.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(92px + env(safe-area-inset-bottom)); z-index: 30;
    background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 12px; max-width: 90vw; }
.toast.error { background: var(--bad); }
.metrics-tbl { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; font-size: .9rem; }
.metrics-tbl th, .metrics-tbl td { padding: 7px 6px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
.metrics-tbl th:first-child, .metrics-tbl td:first-child { text-align: left; }
.metrics-tbl th { color: var(--muted); font-weight: 600; font-size: .78rem; }
.scroll-x { overflow-x: auto; }
.trainee-link { display: block; text-decoration: none; color: inherit; }
.card .link-btn { padding: 0; text-align: left; color: inherit; }
.view-panel { display: flex; flex-direction: column; gap: 12px; }

html, body.member { overflow-x: hidden; }
.tile .delta, .tile .label { white-space: normal; overflow-wrap: anywhere; }
.tile .delta.good, .trainee-right .delta.good { color: var(--good); }
.tile .delta.bad, .trainee-right .delta.bad { color: var(--bad); }
.tile .delta.neutral, .trainee-right .delta.neutral { color: #C2410C; }
.tile.accent .delta { color: #fff !important; }
.hero-card .delta { white-space: normal; text-align: right; max-width: 55%; }

/* ============================================================================
   ĐĂNG NHẬP 2 CỘT - giống màn đăng nhập app FitClub 43-009
   ============================================================================ */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.auth-split {
    flex-direction: row; justify-content: space-between; align-items: center; gap: 48px;
    padding: 48px clamp(20px, 6vw, 120px);
    background:
        radial-gradient(60% 70% at 85% 50%, rgba(22, 119, 240, .28) 0%, transparent 70%),
        radial-gradient(50% 60% at 10% 90%, rgba(255, 196, 0, .16) 0%, transparent 70%),
        linear-gradient(110deg, rgba(4, 18, 34, .94) 0%, rgba(6, 30, 56, .86) 45%, rgba(4, 18, 34, .92) 100%),
        url("/assets/login-bg.jpg") center / cover no-repeat,
        #04121F;
    color: #fff;
}
.login-brand { flex: 1 1 600px; max-width: 800px; display: flex; flex-direction: column; gap: 64px; align-self: stretch; justify-content: space-between; }
.login-brand-head { display: flex; gap: 22px; align-items: flex-start; }
.login-badge { width: 76px; height: 76px; border-radius: 22px; padding: 6px; background: linear-gradient(145deg, rgba(255,255,255,.18), rgba(255,255,255,.05));
    border: 1.5px solid rgba(255,255,255,.35); box-shadow: 0 16px 40px rgba(0,0,0,.5); }
.login-name { font-size: clamp(1.8rem, 3.2vw, 2.4rem); font-weight: 900; letter-spacing: 2px; line-height: 1.05; text-shadow: 0 3px 16px rgba(0,0,0,.6); }
.login-name span { color: #FFC400; }
.login-sub { font-size: .8rem; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase; color: #5CB8FF; margin-top: 6px; }
.login-stats { display: flex; gap: 0; margin: 20px 0 0; }
.login-stats > div { padding: 0 26px; border-left: 1px solid rgba(255,255,255,.18); }
.login-stats > div:first-child { padding-left: 0; border-left: 0; }
.login-stats dd { margin: 0; font-size: 1.9rem; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
.login-stats dd.hl { color: #FFC400; }
.login-stats dt { order: 2; margin-top: 4px; font-size: .72rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: rgba(255,255,255,.62); margin-top: 2px; }
.login-stats > div { display: flex; flex-direction: column; }
.login-chip { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase;
    color: #5CB8FF; padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(92,184,255,.45); background: rgba(22,119,240,.14); }
.login-chip i { width: 9px; height: 9px; border-radius: 50%; background: #2FB8F5; box-shadow: 0 0 10px #2FB8F5; }
.login-hero h1 { font-size: clamp(1.9rem, 3.1vw, 2.9rem); font-weight: 900; line-height: 1.15; letter-spacing: -0.02em; margin: 22px 0 30px; text-shadow: 0 4px 20px rgba(0,0,0,.5); }
.hl-text { white-space: nowrap; color: #FFC400; background: linear-gradient(90deg, #FFC400, #FFD60A); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
    border-bottom: 3px solid transparent; border-image: linear-gradient(90deg, #FF8A00, rgba(255,196,0,0)) 1; padding-bottom: 2px; }
.login-features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.login-features li { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: 16px; min-height: 150px;
    background: linear-gradient(160deg, rgba(255,255,255,.12), rgba(255,255,255,.03)); border: 1px solid rgba(255,255,255,.16);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); transition: transform .2s ease, border-color .2s ease; }
.login-features li:hover { transform: translateY(-4px); border-color: rgba(255,214,10,.5); }
.login-features strong { font-size: .95rem; margin-top: 8px; }
.login-features small { font-size: .8rem; color: rgba(255,255,255,.66); line-height: 1.45; }
.fi { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; box-shadow: 0 8px 18px rgba(0,0,0,.35); }
.fi svg { width: 22px; height: 22px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fi-blue { background: linear-gradient(135deg, #1677F0, #0B4FB3); }
.fi-yellow { background: linear-gradient(135deg, #FFD60A, #E6A100); }
.fi-yellow svg { stroke: #0B3D1F; }
.fi-green { background: linear-gradient(135deg, #12A150, #0B6E36); }
.fi-orange { background: linear-gradient(135deg, #FF9F1A, #D16A00); }
.login-slogan { font-size: 1.35rem; font-weight: 700; color: rgba(255,255,255,.88); margin: 0; }

.login-card { flex: 0 0 auto; width: 100%; max-width: 440px; padding: 34px 32px 26px; text-align: center; color: #fff;
    background: linear-gradient(160deg, rgba(40, 92, 160, .55) 0%, rgba(14, 40, 78, .55) 100%);
    border: 1.5px solid rgba(255,255,255,.28); border-radius: 26px; backdrop-filter: blur(22px); -webkit-backdrop-filter: blur(22px);
    box-shadow: 0 30px 80px rgba(0,0,0,.55); }
.card-logo { display: block; margin: 0 auto; width: 68px; height: 68px; border-radius: 18px; background: #fff; padding: 4px; box-shadow: 0 10px 26px rgba(0,0,0,.35); }
.card-chip { display: inline-block; margin-top: 14px; font-size: .72rem; font-weight: 800; letter-spacing: 1.2px; color: #FFC400;
    padding: 4px 12px; border-radius: 999px; border: 1px solid rgba(255,196,0,.5); background: rgba(255,196,0,.12); }
.login-card h2 { font-size: 1.75rem; font-weight: 900; margin: 12px 0 6px; color: #fff; }
.login-card .auth-note { color: rgba(255,255,255,.75); margin: 0 auto 20px; max-width: 32ch; }
.login-card .auth-note.center { margin: 0 auto; font-size: .82rem; }
.field { position: relative; margin-bottom: 14px; }
.field > svg { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; fill: none; stroke: #2E6BD8; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.field input { padding: 16px 46px 16px 48px; border-radius: 14px; border: 2px solid transparent; background: #EEF3FA; font-size: 1rem; }
.field input:focus { border-color: #1677F0; background: #fff; box-shadow: 0 0 0 4px rgba(22,119,240,.25); }
.eye { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: none; border: 0; cursor: pointer; padding: 6px; }
.eye svg { width: 20px; height: 20px; fill: none; stroke: #64748B; stroke-width: 2; }
.btn-login { margin-top: 8px; padding: 16px; border-radius: 14px; font-weight: 800; letter-spacing: 1px; color: #fff;
    background: linear-gradient(90deg, #0B63F5 0%, #1E8BF0 100%); box-shadow: 0 12px 28px rgba(11,99,245,.45); }
.btn-login:hover { background: linear-gradient(90deg, #0A55D6 0%, #1677F0 100%); color: #fff; }
.btn-login svg { width: 18px; height: 18px; fill: none; stroke: #fff; stroke-width: 2.2; }
.login-card .error { color: #FFB4AB; }
.card-divider { display: flex; align-items: center; gap: 12px; margin: 14px 0; color: rgba(255,255,255,.5); font-size: .8rem; }
.card-divider::before, .card-divider::after { content: ""; flex: 1; height: 1px; background: rgba(255,255,255,.18); }
.card-home { display: inline-block; margin-top: 14px; color: #8CC8FF; font-size: .85rem; text-decoration: none; font-weight: 600; }

@media (max-width: 1100px) {
    .login-features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .login-features li { min-height: 0; }
}
@media (max-width: 860px) {
    .auth-split { flex-direction: column; justify-content: flex-start; padding: 28px 18px 36px; gap: 26px; }
    .login-brand { gap: 0; flex: 0 0 auto; align-self: auto; }
    .login-hero, .login-slogan, .login-stats { display: none; }
    .login-brand-head { justify-content: center; align-items: center; }
    .login-card { padding: 26px 20px 22px; }
    .login-card .card-logo { display: none; }
    .login-name { font-size: 1.5rem; white-space: nowrap; letter-spacing: 1px; }
    .login-sub { font-size: .66rem; letter-spacing: 1px; }
    .login-badge { width: 60px; height: 60px; border-radius: 18px; }
}

/* ============================================================================
   MÁY TÍNH (>= 1024px): bố cục giống app FitClub 43-009 - sidebar navy, topbar trắng
   Điện thoại giữ dạng app với thanh tab dưới.
   ============================================================================ */
.tabbar .tab-brand, .tabbar .tab-foot, .tabbar .tab-ext, .appbar-clock, .me-chip-text { display: none; }
@media (min-width: 1024px) {
    body.member { background: var(--mist); }
    .shell { max-width: none; padding: 0 0 32px 256px; }
    .tabbar {
        top: 0; bottom: 0; left: 0; right: auto; width: 256px; flex-direction: column; justify-content: flex-start; gap: 4px;
        background: #0F2D4A; border: 0; padding: 0 12px 0; z-index: 25; overflow-y: auto;
    }
    .tabbar .tab-brand { display: flex; flex-direction: row; justify-content: flex-start; font-size: 1rem; text-transform: none; border-left: 0; border-radius: 0; }
    .tab-brand { display: flex; align-items: center; gap: 10px; padding: 18px 8px 16px; margin: 0 -12px 10px; padding-left: 20px;
        border-bottom: 1px solid rgba(255,255,255,.08); text-decoration: none; }
    .tab-brand img { width: 40px; height: 40px; border-radius: 50%; background: #fff; }
    .tab-brand b { display: block; color: #fff; font-size: 1.05rem; font-weight: 800; letter-spacing: .3px; white-space: nowrap; }
    .tab-brand small { display: block; color: #FF8A00; font-size: .7rem; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; }
    .tabbar a { max-width: none; flex: 0 0 auto; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 12px 14px;
        font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; color: rgba(255,255,255,.78);
        border-left: 3.5px solid transparent; border-radius: 8px; }
    .tabbar a:hover { background: rgba(255,255,255,.06); color: #fff; }
    .tabbar a.active { background: rgba(255,255,255,.1); color: #fff; border-left-color: #FF8A00; }
    .tabbar a.active svg { stroke: #FF8A00; }
    .tabbar svg { width: 19px; height: 19px; }
    .tab-dot { display: none; }
    .tabbar .tab-foot { display: block; }
    .tabbar .tab-ext { display: flex; }
    .tab-foot { display: block; margin: auto -12px 0; padding: 16px; text-align: center; border-top: 1px solid rgba(255,255,255,.06); background: #0A2137; }
    .tab-foot b { display: block; color: #FF8A00; font-size: .78rem; }
    .tab-foot span { color: rgba(255,255,255,.45); font-size: .7rem; }
    .tab-ext { margin-top: 8px; border: 1px dashed rgba(255,255,255,.2); }

    .appbar { background: #fff; color: var(--text); border-bottom: 1px solid var(--line); padding: 12px 32px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
    .appbar-logo { display: none; }
    .appbar-text strong { font-size: 1.15rem; color: var(--ink); }
    .appbar-text span { color: var(--muted); }
    .icon-btn { color: var(--ink); }
    .appbar-clock { display: inline-flex; align-items: center; gap: 8px; padding: 7px 16px; border: 1px solid var(--line); border-radius: 999px;
        background: #fff; font-size: .82rem; color: var(--muted); white-space: nowrap; margin-right: 14px; font-variant-numeric: tabular-nums; }
    .appbar-clock i { width: 8px; height: 8px; border-radius: 50%; background: #16A34A; }
    .appbar-clock b { color: #16A34A; font-weight: 700; }
    .appbar-clock strong { color: var(--text); }
    .avatar-link { display: flex; align-items: center; gap: 10px; padding: 5px 12px 5px 5px; border: 1px solid var(--line); border-radius: 12px; }
    .me-chip-text { display: flex; flex-direction: column; line-height: 1.2; }
    .me-chip-text b { color: var(--text); font-size: .88rem; }
    .me-chip-text span { color: var(--muted); font-size: .72rem; text-transform: uppercase; }

    .view { max-width: 1240px; margin: 0 auto; padding: 28px 32px; gap: 16px; }
    .view h2 { font-size: 1.55rem; }
    .card, .tile, .mini-stats div, .menu-list { border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(0,0,0,.05); }
    .card { border-radius: 12px; padding: 18px 20px; }
    .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
    .tile { border-radius: 12px; padding: 18px; }
    .tile .value { font-size: 1.8rem; }
    .segmented { max-width: 520px; }
    .view-panel { gap: 16px; }
    .fab { right: 32px; bottom: 32px; }
    .sheet { margin: auto; border-radius: 16px; max-width: 680px; }
    .sheet-grab { display: none; }
    .toast { bottom: 32px; }
    .cal button { aspect-ratio: auto; height: 64px; }
}

/* Ô chọn ngôn ngữ */
.login-card { position: relative; }
.lang-slot { position: absolute; top: 14px; right: 14px; }
.appbar-lang { flex: none; margin-right: 6px; }
.appbar-lang select { max-width: 92px; }
