/* IndoPe App Shell - structural Android-style UI layer */
:root {
    --tp-bg: #f5f7fb;
    --tp-surface: #ffffff;
    --tp-surface-soft: #edf6ff;
    --tp-text: #142033;
    --tp-muted: #667085;
    --tp-line: rgba(21, 75, 120, 0.12);
    --tp-blue: #1769e0;
    --tp-green: #18a67a;
    --tp-orange: #ff7a59;
    --tp-red: #e5484d;
    --tp-shadow: 0 18px 44px rgba(21, 75, 120, 0.14);
    --tp-soft-shadow: 0 8px 24px rgba(21, 75, 120, 0.09);
    --tp-radius-xl: 28px;
    --tp-radius-lg: 22px;
    --tp-radius-md: 16px;
    --tp-app-top: 76px;
    --tp-app-bottom: 82px;
}

[data-theme="dark"] {
    --tp-bg: #0d1321;
    --tp-surface: #131c2e;
    --tp-surface-soft: #182642;
    --tp-text: #eef4ff;
    --tp-muted: #9eb0c8;
    --tp-line: rgba(146, 173, 212, 0.16);
    --tp-shadow: 0 18px 44px rgba(0, 0, 0, 0.38);
    --tp-soft-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

body.tp-native-app *,
body.tp-native-app *::before,
body.tp-native-app *::after {
    box-sizing: border-box;
}

body.tp-native-app {
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% -10%, rgba(23, 105, 224, 0.17), transparent 32%),
        radial-gradient(circle at 100% 0%, rgba(24, 166, 122, 0.16), transparent 30%),
        var(--tp-bg) !important;
    color: var(--tp-text) !important;
    padding-top: var(--tp-app-top) !important;
    padding-bottom: var(--tp-app-bottom) !important;
    font-family: Inter, Roboto, "Segoe UI", system-ui, -apple-system, sans-serif !important;
}

body.tp-native-app.tp-auth-screen {
    padding-bottom: 22px !important;
}

body.tp-native-app > .navbar,
body.tp-native-app > .sidebar,
body.tp-native-app > .sidebar-overlay,
body.tp-native-app .tp-app-host > .navbar,
body.tp-native-app .tp-app-host > .sidebar,
body.tp-native-app .tp-app-host > .sidebar-overlay {
    display: none !important;
}

body.tp-native-app .navbar:not(.tp-appbar),
body.tp-native-app .sidebar,
body.tp-native-app .sidebar-overlay,
body.tp-native-app .sidebar-menu,
body.tp-native-app .sidebar-footer,
body.tp-native-app .legacy-navbar,
body.tp-native-app .legacy-sidebar,
body.tp-native-app .tp-legacy-hidden {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

body.tp-native-app .container {
    padding-top: 0 !important;
    background: transparent !important;
}

.tp-appbar {
    position: fixed;
    inset: 0 0 auto 0;
    height: var(--tp-app-top);
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px max(16px, env(safe-area-inset-left)) 10px max(16px, env(safe-area-inset-left));
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid var(--tp-line);
    box-shadow: 0 10px 30px rgba(21, 75, 120, 0.11);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

[data-theme="dark"] .tp-appbar {
    background: rgba(19, 28, 46, 0.9);
}

.tp-appbar-brand {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 12px;
}

.tp-appbar-brand img {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    box-shadow: 0 12px 24px rgba(23, 105, 224, 0.22);
}

.tp-appbar-title {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.tp-appbar-title strong {
    font-size: 1.08rem;
    line-height: 1.15;
    font-weight: 900;
    color: var(--tp-text);
}

.tp-appbar-title span {
    font-size: 0.72rem;
    line-height: 1.1;
    font-weight: 750;
    color: var(--tp-muted);
}

.tp-appbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tp-icon-button {
    width: 42px;
    height: 42px;
    display: inline-grid;
    place-items: center;
    border: 0;
    border-radius: 16px;
    color: var(--tp-blue);
    background: var(--tp-surface-soft);
    box-shadow: inset 0 0 0 1px var(--tp-line);
    text-decoration: none;
}

.tp-bottom-nav {
    position: fixed;
    z-index: 1200;
    left: 12px;
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    min-height: 66px;
    display: none;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    padding: 8px;
    border: 1px solid var(--tp-line);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 18px 42px rgba(21, 75, 120, 0.18);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

[data-theme="dark"] .tp-bottom-nav {
    background: rgba(19, 28, 46, 0.92);
}

.tp-bottom-nav a {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-radius: 18px;
    color: var(--tp-muted);
    text-decoration: none;
    font-size: 0.66rem;
    font-weight: 850;
}

.tp-bottom-nav a i {
    font-size: 1rem;
}

.tp-bottom-nav a.is-active {
    color: #fff;
    background: linear-gradient(135deg, var(--tp-blue), #3a86ff);
    box-shadow: 0 10px 20px rgba(23, 105, 224, 0.24);
}

@media (max-width: 760px) {
    .tp-bottom-nav {
        display: grid;
    }
}

.tp-app-main {
    width: min(100%, 1120px);
    margin-inline: auto !important;
    padding-inline: 14px !important;
}

body.tp-admin-screen .tp-app-main {
    width: min(100%, 1360px);
}

.tp-page-hero {
    position: relative;
    overflow: hidden;
    display: grid;
    gap: 14px;
    margin: 8px 0 18px;
    padding: 22px;
    border-radius: 30px;
    color: #fff;
    background:
        radial-gradient(circle at 86% 8%, rgba(255,255,255,.28), transparent 25%),
        linear-gradient(135deg, #1769e0, #18a67a);
    box-shadow: var(--tp-shadow);
}

.tp-page-hero::after {
    content: "";
    position: absolute;
    right: -34px;
    bottom: -44px;
    width: 150px;
    height: 150px;
    border-radius: 45px;
    background: rgba(255,255,255,.14);
    transform: rotate(18deg);
}

.tp-page-hero small {
    opacity: .82;
    font-weight: 800;
    text-transform: uppercase;
}

.tp-page-hero h1 {
    margin: 0;
    font-size: clamp(1.45rem, 4vw, 2.3rem);
    line-height: 1.05;
    color: #fff !important;
    font-weight: 950;
}

.tp-page-hero p {
    max-width: 650px;
    margin: 0;
    color: rgba(255,255,255,.86) !important;
    font-weight: 650;
}

.tp-hero-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tp-hero-chips span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 8px 11px;
    background: rgba(255,255,255,.16);
    color: #fff;
    font-size: .78rem;
    font-weight: 850;
}

.tp-action-rail {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
    gap: 12px;
    margin: 0 0 18px;
}

.tp-action-tile {
    min-height: 92px;
    display: grid;
    align-content: center;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--tp-line);
    border-radius: 24px;
    background: var(--tp-surface);
    color: var(--tp-text);
    text-decoration: none;
    box-shadow: var(--tp-soft-shadow);
}

.tp-action-tile span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: var(--tp-blue);
    background: linear-gradient(135deg, rgba(23,105,224,.13), rgba(24,166,122,.12));
}

.tp-action-tile strong {
    font-size: .84rem;
    line-height: 1.15;
    font-weight: 900;
}

.tp-action-tile.is-active {
    color: #fff;
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green));
}

.tp-action-tile.is-active span {
    color: #fff;
    background: rgba(255,255,255,.18);
}

.tp-module-menu {
    margin: 0 0 18px;
    border: 1px solid var(--tp-line);
    border-radius: 20px;
    background: var(--tp-surface);
    box-shadow: var(--tp-soft-shadow);
}

.tp-module-menu summary {
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 16px;
    color: var(--tp-text);
    cursor: pointer;
    list-style: none;
    font-weight: 900;
}

.tp-module-menu summary::-webkit-details-marker { display: none; }
.tp-module-menu summary span { display: inline-flex; align-items: center; gap: 9px; }
.tp-module-menu summary i { color: var(--tp-blue); }
.tp-module-menu summary small { color: var(--tp-muted); font-size: .72rem; }
.tp-module-menu-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; padding: 0 12px 12px; }
.tp-module-menu-grid a { min-height: 44px; display: flex; align-items: center; gap: 9px; padding: 9px 11px; border-radius: 14px; color: var(--tp-text); background: var(--tp-surface-2); text-decoration: none; font-size: .78rem; font-weight: 800; }
.tp-module-menu-grid a:hover { color: var(--tp-blue); }

@media (max-width: 640px) {
    .tp-module-menu { border-radius: 16px; }
    .tp-module-menu summary small { display: none; }
    .tp-module-menu-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tp-module-menu-grid a { min-width: 0; overflow-wrap: anywhere; }
}

.tp-login-shell {
    width: min(100%, 1040px);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(280px, .95fr) minmax(320px, 1fr);
    align-items: center;
    gap: 26px;
    padding: 18px;
}

.tp-login-hero {
    display: grid;
    gap: 18px;
    padding: 26px;
    border-radius: 34px;
    background: linear-gradient(135deg, rgba(23,105,224,.12), rgba(24,166,122,.12));
    border: 1px solid var(--tp-line);
    box-shadow: var(--tp-soft-shadow);
}

.tp-login-hero img {
    width: min(100%, 420px);
    justify-self: center;
}

.tp-login-hero h1 {
    margin: 0;
    color: var(--tp-text) !important;
    font-size: clamp(1.65rem, 4vw, 2.8rem);
    line-height: 1;
    font-weight: 950;
}

.tp-login-hero p {
    margin: 0;
    color: var(--tp-muted);
    font-weight: 700;
}

.tp-record-list {
    display: grid;
    gap: 14px;
    margin: 12px 0;
}

.tp-record-card {
    display: grid;
    gap: 10px;
    padding: 16px;
    border: 1px solid var(--tp-line);
    border-radius: 24px;
    background: var(--tp-surface);
    box-shadow: var(--tp-soft-shadow);
}

.tp-record-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    border-radius: 24px 0 0 24px;
    background: linear-gradient(180deg, var(--tp-blue), var(--tp-green));
}

.tp-record-card.tp-card-pending::before,
.tp-transaction-card.tp-card-pending {
    border-left-color: #f5a524 !important;
}

.tp-record-card.tp-card-failed::before,
.tp-record-card.tp-card-rejected::before,
.tp-transaction-card.tp-card-failed,
.tp-transaction-card.tp-card-rejected {
    border-left-color: var(--tp-red) !important;
}

.tp-record-card.tp-card-refunded::before,
.tp-transaction-card.tp-card-refunded {
    border-left-color: var(--tp-blue) !important;
}

.tp-record-card.tp-card-success::before,
.tp-record-card.tp-card-successful::before,
.tp-record-card.tp-card-completed::before,
.tp-record-card.tp-card-approved::before,
.tp-transaction-card.tp-card-success,
.tp-transaction-card.tp-card-successful,
.tp-transaction-card.tp-card-completed,
.tp-transaction-card.tp-card-approved {
    border-left-color: var(--tp-green) !important;
}

.tp-money-record .tp-record-value {
    font-variant-numeric: tabular-nums;
}

.tp-reference-record .tp-record-value {
    font-family: Inter, Roboto, "Segoe UI", system-ui, sans-serif;
}

.tp-record-card {
    position: relative;
    overflow: hidden;
}

.tp-record-field {
    display: grid;
    grid-template-columns: 124px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 4px 0;
}

.tp-record-label {
    color: var(--tp-muted);
    font-size: .7rem;
    font-weight: 950;
    text-transform: uppercase;
}

.tp-record-value {
    min-width: 0;
    color: var(--tp-text);
    font-weight: 720;
    word-break: break-word;
}

.tp-record-field:first-child .tp-record-value,
.tp-record-field:nth-child(2) .tp-record-value {
    font-weight: 950;
}

.tp-record-value form {
    display: grid;
    gap: 9px;
}

.tp-form-card {
    margin: 12px 0;
    padding: 18px;
    border: 1px solid var(--tp-line);
    border-radius: 28px;
    background: var(--tp-surface);
    box-shadow: var(--tp-soft-shadow);
}

.tp-form-card-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    color: var(--tp-text);
}

.tp-form-card-title span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green));
}

.tp-form-card-title strong {
    font-size: 1.05rem;
    font-weight: 950;
}

.tp-native-form {
    display: grid;
    gap: 13px;
}

.tp-native-form label {
    color: var(--tp-muted);
    font-size: .82rem;
    font-weight: 850;
}

.tp-native-form input,
.tp-native-form textarea,
.tp-native-form select {
    min-height: 48px;
}

.tp-module-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--tp-line) !important;
    border-radius: 26px !important;
    background: var(--tp-surface) !important;
    box-shadow: var(--tp-soft-shadow) !important;
}

.tp-transaction-card {
    display: grid !important;
    gap: 8px !important;
    padding: 16px !important;
    border-left: 5px solid var(--tp-blue) !important;
}

.tp-lifafa-card {
    border-left: 5px solid var(--tp-green) !important;
}

.tp-status-chip {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: 28px;
    padding: 5px 10px !important;
    border-radius: 999px !important;
    font-size: .72rem !important;
    font-weight: 950 !important;
    text-transform: uppercase;
}

.tp-status-pending,
.tp-status-processing {
    color: #a15c00 !important;
    background: rgba(245, 165, 36, .15) !important;
}

.tp-status-completed,
.tp-status-success,
.tp-status-successful,
.tp-status-approved,
.tp-status-active,
.tp-status-enabled {
    color: #087553 !important;
    background: rgba(24, 166, 122, .15) !important;
}

.tp-status-rejected,
.tp-status-failed,
.tp-status-disabled {
    color: #b4232a !important;
    background: rgba(229, 72, 77, .15) !important;
}

.tp-status-refunded {
    color: var(--tp-blue) !important;
    background: rgba(23, 105, 224, .14) !important;
}

.tp-status-cancelled,
.tp-status-canceled {
    color: #6b7280 !important;
    background: rgba(107, 114, 128, .14) !important;
}

.tp-empty-state {
    display: grid;
    justify-items: center;
    gap: 10px;
    margin: 16px 0;
    padding: 28px 18px;
    border: 1px dashed var(--tp-line);
    border-radius: 28px;
    background: linear-gradient(135deg, rgba(23,105,224,.07), rgba(24,166,122,.07));
    color: var(--tp-muted);
    text-align: center;
}

.tp-empty-state img {
    width: 96px;
    height: 96px;
    object-fit: contain;
}

.tp-empty-state strong {
    color: var(--tp-text);
    font-size: 1rem;
    font-weight: 950;
}

.tp-skeleton {
    position: relative;
    overflow: hidden;
    min-height: 88px;
    border-radius: 24px;
    background: linear-gradient(90deg, rgba(23,105,224,.08), rgba(24,166,122,.09), rgba(23,105,224,.08));
    background-size: 220% 100%;
    animation: tpSkeleton 1.4s ease-in-out infinite;
}

@keyframes tpSkeleton {
    from { background-position: 100% 0; }
    to { background-position: -100% 0; }
}

body.tp-admin-screen .tp-record-list {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.tp-wallet-atm-card,
.tp-api-hero-card,
.tp-api-admin-summary,
.tp-api-grid,
.tp-docs-grid {
    width: min(100%, 1180px);
    margin-inline: auto;
}

.tp-wallet-atm-card {
    position: relative;
    overflow: hidden;
    border-radius: 32px;
    padding: 24px;
    color: #fff;
    background:
        radial-gradient(circle at 88% 14%, rgba(255,255,255,.34), transparent 24%),
        radial-gradient(circle at 16% 78%, rgba(24,166,122,.55), transparent 34%),
        linear-gradient(135deg, #10213f 0%, #1769e0 52%, #18a67a 100%);
    box-shadow: 0 26px 70px rgba(23, 105, 224, .28);
}

.tp-wallet-atm-card::after {
    content: "";
    position: absolute;
    inset: auto -55px -80px auto;
    width: 220px;
    height: 220px;
    border-radius: 999px;
    border: 34px solid rgba(255,255,255,.13);
}

.tp-atm-card-top,
.tp-atm-meta,
.tp-atm-actions {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.tp-atm-card-top span,
.tp-atm-balance span {
    display: block;
    font-size: .78rem;
    font-weight: 800;
    text-transform: uppercase;
    color: rgba(255,255,255,.72);
}

.tp-atm-card-top strong {
    display: block;
    margin-top: 4px;
    font-size: 1.05rem;
}

.tp-atm-card-top img {
    width: 52px;
    height: 52px;
}

.tp-atm-balance {
    position: relative;
    z-index: 1;
    margin-block: 30px 24px;
}

.tp-atm-balance strong {
    display: block;
    margin-top: 8px;
    font-size: clamp(2rem, 6vw, 3.6rem);
    line-height: 1;
    font-weight: 950;
}

.tp-atm-meta span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.2);
    font-size: .82rem;
    font-weight: 800;
}

.tp-atm-actions {
    margin-top: 18px;
    justify-content: flex-start;
}

.tp-atm-actions a,
.tp-action-row button,
.tp-native-form button,
.tp-api-request-form button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    border: 0;
    border-radius: 16px;
    padding: 10px 14px;
    font-weight: 900;
    text-decoration: none;
    color: #fff !important;
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green));
    box-shadow: 0 12px 30px rgba(23,105,224,.18);
}

.tp-atm-actions a {
    color: #10213f !important;
    background: rgba(255,255,255,.92);
    box-shadow: none;
}

.tp-api-hero-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 340px);
    gap: 18px;
    align-items: stretch;
    padding: 26px;
    border-radius: 30px;
    color: #fff;
    background: linear-gradient(135deg, #10213f, #1769e0 58%, #18a67a);
    box-shadow: 0 22px 58px rgba(16,33,63,.2);
}

.tp-api-hero-card h1 {
    margin: 8px 0;
    font-size: clamp(2rem, 6vw, 3.4rem);
    font-weight: 950;
}

.tp-api-hero-card p {
    max-width: 680px;
    color: rgba(255,255,255,.8);
    font-weight: 700;
}

.tp-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.14);
    font-weight: 900;
    font-size: .82rem;
}

.tp-api-status-panel {
    display: grid;
    align-content: center;
    gap: 10px;
    padding: 18px;
    border-radius: 24px;
    background: rgba(255,255,255,.13);
    border: 1px solid rgba(255,255,255,.22);
}

.tp-api-status-panel strong {
    font-size: 1.2rem;
}

.tp-api-status-panel small {
    color: rgba(255,255,255,.72);
}

.tp-api-grid,
.tp-docs-grid,
.tp-api-admin-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
}

.tp-api-product-card,
.tp-doc-card,
.tp-api-admin-summary article {
    padding: 20px;
    border-radius: 24px;
    background: var(--tp-surface);
    border: 1px solid var(--tp-line);
    box-shadow: var(--tp-shadow-soft);
}

.tp-api-product-card > span {
    display: inline-grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 18px;
    color: var(--tp-blue);
    background: linear-gradient(135deg, rgba(23,105,224,.12), rgba(24,166,122,.12));
}

.tp-api-product-card h2,
.tp-doc-card h2,
.tp-module-card h2 {
    margin: 10px 0 8px;
    font-size: 1.05rem;
    font-weight: 950;
    color: var(--tp-ink);
}

.tp-doc-card pre,
.tp-doc-card code,
.tp-record-details pre {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    border-radius: 16px;
    padding: 12px;
    white-space: pre-wrap;
    color: #d8fff0;
    background: #10213f;
}

.tp-secret-grid,
.tp-field-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 12px;
}

.tp-secret-grid > div {
    padding: 14px;
    border-radius: 18px;
    background: var(--tp-soft);
    border: 1px solid var(--tp-line);
}

.tp-secret-grid span,
.tp-muted-note {
    display: block;
    color: var(--tp-muted);
    font-size: .78rem;
    font-weight: 800;
}

.tp-secret-grid code {
    display: block;
    margin-top: 6px;
    word-break: break-all;
    color: var(--tp-ink);
    font-weight: 900;
}

.tp-chip-row,
.tp-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.tp-chip-row span {
    padding: 9px 12px;
    border-radius: 999px;
    background: var(--tp-soft);
    border: 1px solid var(--tp-line);
    font-weight: 800;
    color: var(--tp-ink);
}

.tp-api-admin-summary article span {
    display: block;
    font-size: 2rem;
    font-weight: 950;
    color: var(--tp-blue);
}

.tp-api-admin-summary article strong,
.tp-api-admin-summary article small {
    display: block;
}

.tp-api-admin-summary article small {
    color: var(--tp-muted);
    font-weight: 700;
}

.tp-api-admin-form,
.tp-api-user-form,
.tp-api-request-form {
    display: grid;
    gap: 12px;
}

.tp-api-admin-form label,
.tp-api-user-form label,
.tp-api-request-form label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 850;
}

.tp-native-form input,
.tp-native-form select,
.tp-native-form textarea {
    min-height: 44px;
    border-radius: 16px !important;
    border: 1px solid var(--tp-line) !important;
    padding: 10px 12px !important;
    background: var(--tp-surface) !important;
    color: var(--tp-ink) !important;
}

.tp-danger-button {
    background: linear-gradient(135deg, #dd2c5a, #ff7a59) !important;
}

.tp-alert {
    width: min(100%, 1180px);
    margin-inline: auto;
    padding: 13px 16px;
    border-radius: 18px;
    font-weight: 850;
    border: 1px solid var(--tp-line);
}

.tp-alert-success {
    color: #075f46;
    background: rgba(24,166,122,.12);
}

.tp-alert-danger {
    color: #9f1239;
    background: rgba(225,29,72,.12);
}

.tp-record-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 10px;
}

.tp-record-details {
    margin-top: 12px;
    border-top: 1px solid var(--tp-line);
    padding-top: 10px;
}

.tp-record-details summary {
    cursor: pointer;
    color: var(--tp-blue);
    font-weight: 900;
}

/* Source-level money page rebuild components */
body.tp-money-source-page {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(247,250,252,.98), rgba(235,244,255,.9)),
        radial-gradient(circle at 10% 0%, rgba(23,105,224,.12), transparent 30%);
    color: var(--tp-ink);
}

.tp-money-page {
    width: min(1180px, calc(100% - 28px));
    margin: 0 auto;
    padding: 86px 0 110px;
}

.tp-money-top-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 320px);
    gap: 16px;
    align-items: stretch;
    padding: 24px;
    border-radius: 30px;
    color: #fff;
    background: linear-gradient(135deg, #10213f, #1769e0 58%, #18a67a);
    box-shadow: 0 24px 62px rgba(16,33,63,.2);
}

.tp-money-top-copy h1 {
    margin: 10px 0 8px;
    font-size: clamp(2rem, 6vw, 3.5rem);
    font-weight: 950;
    line-height: .98;
}

.tp-money-top-copy p {
    max-width: 720px;
    color: rgba(255,255,255,.78);
    font-weight: 750;
}

.tp-money-mini-balance {
    display: grid;
    align-content: center;
    gap: 8px;
    padding: 18px;
    border-radius: 24px;
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.22);
}

.tp-money-mini-balance span {
    color: rgba(255,255,255,.72);
    font-size: .78rem;
    text-transform: uppercase;
    font-weight: 850;
}

.tp-money-mini-balance strong {
    font-size: 1.7rem;
    font-weight: 950;
}

.tp-money-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(74px, 1fr));
    gap: 10px;
    margin: 16px 0;
}

.tp-money-tabs a {
    display: grid;
    place-items: center;
    gap: 6px;
    min-height: 72px;
    border-radius: 20px;
    background: var(--tp-surface);
    border: 1px solid var(--tp-line);
    box-shadow: var(--tp-shadow-soft);
    color: var(--tp-ink);
    text-decoration: none;
    font-weight: 900;
    font-size: .76rem;
}

.tp-money-tabs i {
    color: var(--tp-blue);
    font-size: 1.05rem;
}

.tp-money-grid {
    display: grid;
    gap: 16px;
}

.tp-money-grid.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.tp-money-action-card,
.tp-history-card {
    padding: 20px;
    border-radius: 26px;
    background: var(--tp-surface);
    border: 1px solid var(--tp-line);
    box-shadow: var(--tp-shadow-soft);
}

.tp-money-section-title {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.tp-money-section-title > span {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    flex: 0 0 auto;
    border-radius: 18px;
    color: var(--tp-blue);
    background: linear-gradient(135deg, rgba(23,105,224,.12), rgba(24,166,122,.12));
}

.tp-money-section-title h2 {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 950;
}

.tp-money-section-title p {
    margin: 3px 0 0;
    color: var(--tp-muted);
    font-weight: 700;
}

.tp-money-form {
    display: grid;
    gap: 13px;
}

.tp-money-form label {
    display: grid;
    gap: 7px;
    color: var(--tp-ink);
    font-weight: 900;
}

.tp-money-form input,
.tp-money-form textarea,
.tp-money-form select {
    width: 100%;
    min-height: 50px;
    border: 1px solid var(--tp-line);
    border-radius: 18px;
    padding: 12px 14px;
    background: var(--tp-soft);
    color: var(--tp-ink);
    font: inherit;
    font-weight: 800;
}

.tp-money-form input:focus,
.tp-money-form textarea:focus {
    outline: none;
    border-color: rgba(23,105,224,.48);
    box-shadow: 0 0 0 4px rgba(23,105,224,.1);
}

.tp-money-form button,
.tp-secondary-link {
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 0;
    border-radius: 18px;
    padding: 12px 16px;
    text-decoration: none;
    color: #fff !important;
    font-weight: 950;
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green));
    box-shadow: 0 14px 34px rgba(23,105,224,.18);
}

.tp-money-form button:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.tp-secondary-link {
    color: var(--tp-blue) !important;
    background: rgba(23,105,224,.08);
    box-shadow: none;
    border: 1px solid var(--tp-line);
}

.tp-info-strip {
    padding: 12px 14px;
    border-radius: 18px;
    color: var(--tp-muted);
    background: var(--tp-soft);
    border: 1px solid var(--tp-line);
    font-weight: 750;
}

.tp-limit-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}

.tp-limit-grid > div {
    display: grid;
    gap: 4px;
    padding: 13px;
    border-radius: 18px;
    background: var(--tp-soft);
    border: 1px solid var(--tp-line);
}

.tp-limit-grid span,
.tp-limit-grid small {
    color: var(--tp-muted);
    font-size: .76rem;
    font-weight: 800;
}

.tp-limit-grid strong {
    font-size: 1rem;
    font-weight: 950;
    color: var(--tp-ink);
}

.tp-qr-panel {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 16px;
    border-radius: 24px;
    background: var(--tp-soft);
    border: 1px dashed rgba(23,105,224,.32);
}

.tp-qr-panel img {
    width: 150px;
    height: 150px;
    object-fit: contain;
    border-radius: 18px;
    background: #fff;
    padding: 8px;
}

.tp-qr-panel strong,
.tp-qr-panel span {
    display: block;
}

.tp-qr-panel strong {
    font-size: 1.2rem;
    font-weight: 950;
    color: var(--tp-ink);
}

.tp-qr-panel span {
    margin-top: 6px;
    color: var(--tp-muted);
    font-weight: 750;
}

.tp-history-list {
    display: grid;
    gap: 13px;
}

.tp-history-card {
    display: grid;
    gap: 11px;
}

.tp-history-card-head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
}

.tp-history-title {
    display: flex;
    align-items: center;
    gap: 11px;
}

.tp-history-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 17px;
    background: linear-gradient(135deg, rgba(23,105,224,.12), rgba(24,166,122,.12));
    color: var(--tp-blue);
}

.tp-history-title strong,
.tp-history-amount {
    font-weight: 950;
    color: var(--tp-ink);
}

.tp-history-title small,
.tp-history-meta {
    color: var(--tp-muted);
    font-weight: 750;
}

.tp-history-amount {
    text-align: right;
    font-size: 1.2rem;
}

.tp-history-details {
    border-top: 1px solid var(--tp-line);
    padding-top: 10px;
}

.tp-history-details summary {
    cursor: pointer;
    color: var(--tp-blue);
    font-weight: 900;
}

.tp-history-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.tp-history-detail-grid div {
    padding: 11px;
    border-radius: 15px;
    background: var(--tp-soft);
    border: 1px solid var(--tp-line);
}

.tp-history-detail-grid span {
    display: block;
    color: var(--tp-muted);
    font-size: .74rem;
    font-weight: 850;
}

.tp-history-detail-grid strong {
    display: block;
    margin-top: 4px;
    word-break: break-word;
}

.tp-pay-confirm-modal {
    position: fixed;
    inset: 0;
    display: none;
    place-items: center;
    z-index: 9999;
    padding: 18px;
    background: rgba(16,33,63,.58);
    backdrop-filter: blur(12px);
}

.tp-pay-confirm-modal.active {
    display: grid;
}

.tp-pay-confirm-box {
    width: min(420px, 100%);
    padding: 20px;
    border-radius: 26px;
    background: var(--tp-surface);
    box-shadow: 0 30px 80px rgba(16,33,63,.28);
}

@media (max-width: 760px) {
    .tp-money-page {
        width: min(100% - 18px, 1180px);
        padding-top: 76px;
    }

    .tp-money-top-card,
    .tp-money-grid.two,
    .tp-qr-panel {
        grid-template-columns: 1fr;
    }

    .tp-money-tabs {
        overflow-x: auto;
        grid-template-columns: repeat(5, minmax(86px, 1fr));
    }
}

body.tp-data-heavy .tp-record-card {
    min-height: 132px;
}

body.tp-money-module .tp-page-hero {
    background:
        radial-gradient(circle at 86% 8%, rgba(255,255,255,.28), transparent 25%),
        linear-gradient(135deg, #0f5bd5, #14a171);
}

/* Phase 2 source-rebuilt user modules */
.tp-phase2-page {
    width: min(100% - 32px, 1180px);
    margin: 0 auto;
    padding: calc(var(--tp-app-top, 82px) + 18px) 0 calc(var(--tp-app-bottom, 90px) + 28px);
}

.tp-phase2-grid {
    display: grid;
    gap: 16px;
}

.tp-phase2-grid.two {
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
    align-items: start;
}

.tp-phase2-panel {
    background: var(--tp-surface);
    border: 1px solid var(--tp-line);
    border-radius: 28px;
    box-shadow: var(--tp-shadow-sm);
    padding: 20px;
    overflow: hidden;
}

.tp-phase2-panel.soft {
    background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(244,248,255,.94));
}

.tp-phase2-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.tp-phase2-title {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.tp-phase2-title i,
.tp-phase2-icon {
    width: 46px;
    height: 46px;
    display: inline-grid;
    place-items: center;
    border-radius: 18px;
    color: var(--tp-blue);
    background: linear-gradient(135deg, rgba(23,105,224,.13), rgba(24,166,122,.12));
    box-shadow: inset 0 0 0 1px var(--tp-line);
}

.tp-phase2-title h2,
.tp-phase2-title h3 {
    margin: 0;
    color: var(--tp-ink);
    font-size: 1rem;
    font-weight: 850;
}

.tp-phase2-title p {
    margin: 3px 0 0;
    color: var(--tp-muted);
    font-size: .78rem;
    font-weight: 650;
}

.tp-phase2-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tp-phase2-chip,
.tp-status-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 32px;
    padding: 7px 11px;
    border-radius: 999px;
    color: var(--tp-muted);
    background: rgba(244,248,255,.95);
    border: 1px solid var(--tp-line);
    font-size: .74rem;
    font-weight: 750;
    text-decoration: none;
}

.tp-status-chip.success,
.tp-status-chip.active,
.tp-status-chip.completed,
.tp-status-chip.valid {
    color: #087a55;
    background: rgba(24,166,122,.12);
    border-color: rgba(24,166,122,.22);
}

.tp-status-chip.pending,
.tp-status-chip.warning {
    color: #986500;
    background: rgba(255,193,7,.14);
    border-color: rgba(255,193,7,.28);
}

.tp-status-chip.failed,
.tp-status-chip.error,
.tp-status-chip.over,
.tp-status-chip.invalid,
.tp-status-chip.danger {
    color: #b42318;
    background: rgba(244,63,94,.12);
    border-color: rgba(244,63,94,.24);
}

.tp-phase2-form {
    display: grid;
    gap: 14px;
}

.tp-field {
    display: grid;
    gap: 7px;
}

.tp-field label {
    color: var(--tp-muted);
    font-size: .73rem;
    font-weight: 800;
}

.tp-field input,
.tp-field textarea,
.tp-field select,
.tp-phase2-page .form-input,
.tp-phase2-page .input-field,
.tp-phase2-page .search-input,
.tp-phase2-page .form-textarea,
.tp-phase2-page .input-enhanced {
    width: 100%;
    min-height: 52px;
    border: 1px solid var(--tp-line) !important;
    border-radius: 18px !important;
    background: var(--tp-surface) !important;
    color: var(--tp-ink) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.72);
    padding: 13px 15px !important;
    font: inherit;
    font-size: .92rem;
    outline: none;
}

.tp-field textarea,
.tp-phase2-page textarea.form-input,
.tp-phase2-page textarea.input-field {
    min-height: 120px;
    resize: vertical;
}

.tp-field input:focus,
.tp-field textarea:focus,
.tp-field select:focus,
.tp-phase2-page .form-input:focus,
.tp-phase2-page .input-field:focus,
.tp-phase2-page .search-input:focus {
    border-color: rgba(23,105,224,.5) !important;
    box-shadow: 0 0 0 4px rgba(23,105,224,.1) !important;
}

.tp-action-button,
.tp-phase2-page .btn-primary,
.tp-phase2-page .btn-send,
.tp-phase2-page .edit-submit-btn,
.tp-phase2-page .popup-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    border: 0 !important;
    border-radius: 17px !important;
    padding: 0 18px !important;
    color: #fff !important;
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green)) !important;
    font-weight: 850 !important;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 14px 26px rgba(23,105,224,.18) !important;
}

.tp-action-button.secondary,
.tp-phase2-page .btn-secondary,
.tp-phase2-page .show-more-btn {
    color: var(--tp-blue) !important;
    background: rgba(23,105,224,.1) !important;
    border: 1px solid rgba(23,105,224,.17) !important;
    box-shadow: none !important;
}

.tp-action-button.danger,
.tp-phase2-page .btn-danger,
.tp-phase2-page .modal-btn-delete {
    background: linear-gradient(135deg, #ef4444, #f97316) !important;
}

.tp-android-wallet-card,
.tp-gift-hero-card {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    padding: 22px;
    color: #fff;
    background:
        radial-gradient(circle at 86% 12%, rgba(255,255,255,.28), transparent 24%),
        linear-gradient(135deg, #1769e0, #18a67a);
    box-shadow: 0 22px 48px rgba(23,105,224,.22);
}

.tp-android-wallet-card small,
.tp-gift-hero-card small {
    display: block;
    opacity: .78;
    font-weight: 750;
}

.tp-android-wallet-card strong,
.tp-gift-hero-card strong {
    display: block;
    margin-top: 8px;
    font-size: clamp(1.45rem, 4vw, 2.25rem);
    line-height: 1;
}

.tp-transaction-card {
    background: var(--tp-surface);
    border: 1px solid var(--tp-line);
    border-radius: 24px;
    padding: 16px;
    box-shadow: var(--tp-shadow-sm);
}

.tp-transaction-main {
    display: grid;
    grid-template-columns: 48px minmax(0,1fr) auto;
    gap: 12px;
    align-items: center;
}

.tp-transaction-avatar {
    width: 48px;
    height: 48px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    color: var(--tp-blue);
    background: rgba(23,105,224,.1);
}

.tp-transaction-title {
    color: var(--tp-ink);
    font-weight: 850;
    overflow-wrap: anywhere;
}

.tp-transaction-meta {
    margin-top: 4px;
    color: var(--tp-muted);
    font-size: .76rem;
    font-weight: 650;
}

.tp-transaction-amount {
    text-align: right;
    white-space: nowrap;
    color: var(--tp-ink);
    font-size: 1.02rem;
    font-weight: 900;
}

.tp-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.tp-detail-item {
    padding: 11px 12px;
    border-radius: 16px;
    background: rgba(244,248,255,.9);
    border: 1px solid var(--tp-line);
}

.tp-detail-item span {
    display: block;
    color: var(--tp-muted);
    font-size: .68rem;
    font-weight: 800;
}

.tp-detail-item strong {
    display: block;
    margin-top: 3px;
    color: var(--tp-ink);
    font-size: .83rem;
    overflow-wrap: anywhere;
}

.tp-empty-state-card {
    min-height: 220px;
    display: grid;
    place-items: center;
    text-align: center;
    gap: 8px;
    color: var(--tp-muted);
    background: var(--tp-surface);
    border: 1px dashed rgba(23,105,224,.24);
    border-radius: 28px;
    padding: 26px;
}

.tp-empty-state-card img {
    width: 82px;
    height: 82px;
    object-fit: contain;
}

.tp-widget-shell {
    border-radius: 30px;
    overflow: hidden;
    border: 1px solid var(--tp-line);
    background: #09111f;
    box-shadow: var(--tp-shadow-sm);
}

.tp-widget-shell #root,
.tp-widget-shell .game-root {
    min-height: 560px;
}

.tp-legacy-shell,
.sidebar,
.navbar,
.sidebar-overlay,
.layout-wrapper > .navbar {
    display: none !important;
}

.tp-phase2-page .hidden {
    display: none;
}

@media (max-width: 840px) {
    .tp-phase2-page {
        width: min(100% - 18px, 1180px);
        padding-top: calc(var(--tp-app-top, 76px) + 10px);
    }

    .tp-phase2-grid.two,
    .tp-detail-grid {
        grid-template-columns: 1fr;
    }

    .tp-phase2-panel {
        padding: 16px;
        border-radius: 24px;
    }

    .tp-transaction-main {
        grid-template-columns: 44px minmax(0,1fr);
    }

    .tp-transaction-amount {
        grid-column: 2;
        text-align: left;
    }
}

body.tp-module-home:not(.tp-admin-screen) .tp-action-rail {
    grid-template-columns: repeat(4, minmax(110px, 1fr));
}

body.tp-module-wallet .tp-module-card,
body.tp-module-wallet .tp-module-card {
    border-radius: 30px !important;
}

/* Final IndoPe theme quarantine: neutralize legacy palettes and Bootstrap-like blocks inside app pages. */
body.tp-native-app * {
    letter-spacing: 0 !important;
}

body.tp-native-app .text-indigo-600,
body.tp-native-app .text-purple-600,
body.tp-native-app .text-sky-600,
body.tp-native-app [style*="#0ea5e9"],
body.tp-native-app [style*="#6366f1"],
body.tp-native-app [style*="#7c6ef0"],
body.tp-native-app [style*="#154B78"],
body.tp-native-app [style*="#4EA853"] {
    color: var(--tp-blue) !important;
    -webkit-text-fill-color: var(--tp-blue) !important;
}

body.tp-native-app [style*="#ec4899"],
body.tp-native-app [style*="#8b5cf6"],
body.tp-native-app [style*="#4361ee"] {
    color: var(--tp-green) !important;
    -webkit-text-fill-color: var(--tp-green) !important;
}

body.tp-native-app .bg-indigo-600,
body.tp-native-app .bg-purple-600,
body.tp-native-app .bg-sky-600,
body.tp-native-app .bg-blue-600,
body.tp-native-app .btn-primary,
body.tp-native-app .auth-tab.active,
body.tp-native-app .tab.active,
body.tp-native-app button:not(.tp-icon-button):not(.swal2-close),
body.tp-native-app [style*="background: #0ea5e9"],
body.tp-native-app [style*="background:#0ea5e9"],
body.tp-native-app [style*="background: #6366f1"],
body.tp-native-app [style*="background:#6366f1"],
body.tp-native-app [style*="background: #7c6ef0"],
body.tp-native-app [style*="background:#7c6ef0"],
body.tp-native-app [style*="background: #4361ee"],
body.tp-native-app [style*="background:#4361ee"] {
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green)) !important;
    background-color: var(--tp-blue) !important;
}

body.tp-native-app a:not(.tp-action-tile):not(.tp-bottom-nav a):not(.tp-icon-button)[style*="background"],
body.tp-native-app div[style*="background: #0ea5e9"],
body.tp-native-app div[style*="background:#0ea5e9"],
body.tp-native-app span[style*="background: #0ea5e9"],
body.tp-native-app span[style*="background:#0ea5e9"] {
    background: linear-gradient(135deg, var(--tp-blue), var(--tp-green)) !important;
}

body.tp-native-app .border,
body.tp-native-app .border-b,
body.tp-native-app .border-t,
body.tp-native-app [class*="border-slate"],
body.tp-native-app [class*="border-gray"] {
    border-color: var(--tp-line) !important;
}

body.tp-native-app .rounded,
body.tp-native-app .rounded-lg,
body.tp-native-app .rounded-xl,
body.tp-native-app .rounded-2xl,
body.tp-native-app .modal-content,
body.tp-native-app .swal2-popup {
    border-radius: var(--tp-radius-lg) !important;
}

body.tp-native-app table:not(.tp-source-table-rebuilt) {
    width: 100%;
    border-collapse: separate !important;
    border-spacing: 0 12px !important;
}

.tp-panel,
section,
.card,
.auth-card,
.form-card,
.history-card-wrap,
.transaction-item,
.lifafa-card,
.bg-white {
    border-radius: var(--tp-radius-xl) !important;
}

body.tp-native-app .feature-card i,
body.tp-native-app .svc-icon,
body.tp-native-app .qa-icon,
body.tp-native-app .section-icon,
body.tp-native-app .card-icon,
body.tp-native-app .transaction-item .w-12,
body.tp-native-app .lifafa-card i,
body.tp-native-app main i[class*="fa-"] {
    filter: none !important;
}

body.tp-native-app .svc-icon,
body.tp-native-app .qa-icon,
body.tp-native-app .section-icon,
body.tp-native-app .card-icon {
    border-radius: 20px !important;
    background: linear-gradient(135deg, rgba(23,105,224,.13), rgba(24,166,122,.12)) !important;
    color: var(--tp-blue) !important;
    box-shadow: inset 0 0 0 1px var(--tp-line) !important;
}

.tp-empty-art {
    width: 86px !important;
    height: 86px !important;
    object-fit: contain !important;
}

@media (max-width: 860px) {
    .tp-login-shell {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 12px;
    }

    .tp-login-hero {
        padding: 20px;
    }
}

@media (max-width: 720px) {
    body.tp-native-app {
        --tp-app-top: 70px;
        --tp-app-bottom: 88px;
    }

    .tp-appbar-title span {
        display: none;
    }

    .tp-appbar-brand img {
        width: 42px;
        height: 42px;
    }

    .tp-page-hero {
        padding: 19px;
        border-radius: 26px;
    }

    .tp-card-table td {
        grid-template-columns: 104px minmax(0, 1fr);
    }

    .tp-action-rail {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 9px;
        overflow: visible;
        padding-bottom: 0;
    }

    body.tp-module-home:not(.tp-admin-screen) .tp-action-rail {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .tp-action-tile {
        min-height: 82px;
        padding: 10px;
    }

    .tp-action-tile span {
        width: 36px;
        height: 36px;
    }

    .tp-action-tile strong {
        font-size: .72rem;
    }

    .tp-record-field {
        grid-template-columns: 94px minmax(0, 1fr);
    }

    body.tp-admin-screen .tp-record-list {
        grid-template-columns: 1fr;
    }
}
/* Shared professional UI layer. Loaded only for rendered HTML surfaces. */
.tp-professional-ui {
    color-scheme: light dark;
    scroll-behavior: smooth;
}

.tp-professional-ui body {
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.tp-professional-ui .tp-action-card,
.tp-professional-ui .tp-link-card,
.tp-professional-ui .tp-service-card,
.tp-professional-ui .tp-panel,
.tp-professional-ui .tp-module-card,
.tp-professional-ui .tp-admin-panel,
.tp-professional-ui .tp-admin-record {
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

@media (hover: hover) {
    .tp-professional-ui .tp-action-card:hover,
    .tp-professional-ui .tp-link-card:hover,
    .tp-professional-ui .tp-service-card:hover {
        transform: translateY(-3px);
        border-color: color-mix(in srgb, var(--tp-primary, #3157d8) 30%, transparent);
        box-shadow: 0 18px 36px rgba(15, 23, 42, .12);
    }
}

.tp-professional-ui .tp-action-icon,
.tp-professional-ui .tp-link-icon,
.tp-professional-ui .tp-service-icon,
.tp-professional-ui .tp-premium-list-icon {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    aspect-ratio: 1;
    line-height: 1;
}

.tp-professional-ui .tp-action-icon i,
.tp-professional-ui .tp-link-icon i,
.tp-professional-ui .tp-service-icon i,
.tp-professional-ui .tp-premium-list-icon i {
    width: 1.15em;
    text-align: center;
    font-size: 1.08rem;
}

.tp-professional-control {
    touch-action: manipulation;
    transition: transform .16s ease, box-shadow .16s ease, background-color .16s ease, border-color .16s ease;
}

.tp-professional-control:focus-visible,
.tp-professional-ui a:focus-visible,
.tp-professional-ui input:focus-visible,
.tp-professional-ui select:focus-visible,
.tp-professional-ui textarea:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--tp-primary, #3157d8) 28%, transparent);
    outline-offset: 2px;
}

.tp-table-scroll {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    border-radius: 16px;
    -webkit-overflow-scrolling: touch;
}

.tp-professional-table {
    width: 100%;
    min-width: 620px;
}

.tp-professional-table th {
    letter-spacing: .04em;
    text-transform: uppercase;
}

.tp-professional-ui .tp-empty-state,
.tp-professional-ui .tp-admin-empty {
    min-height: 180px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 8px;
    padding: 28px 18px;
    border: 1px dashed color-mix(in srgb, var(--tp-primary, #3157d8) 28%, transparent);
    border-radius: 20px;
    text-align: center;
}

@media (max-width: 640px) {
    .tp-professional-ui .tp-action-card,
    .tp-professional-ui .tp-link-card,
    .tp-professional-ui .tp-service-card {
        min-width: 0;
    }

    .tp-professional-ui .tp-section-title {
        align-items: flex-start;
        gap: 12px;
    }

    .tp-professional-table {
        min-width: 540px;
    }
}
/* IndoPe 2026 user brand foundation */
:root {
    --ip-blue-50: #f3f7ff;
    --ip-blue-100: #eaf2ff;
    --ip-blue-200: #cfe0ff;
    --ip-blue-500: #1c65e6;
    --ip-blue-600: #1557d6;
    --ip-blue-700: #1048b5;
    --ip-blue-800: #0b3c91;
    --ip-orange-50: #fff7ed;
    --ip-orange-500: #f58220;
    --ip-orange-600: #df6b0d;
    --ip-green-50: #e9f8f1;
    --ip-green-500: #22b573;
    --ip-green-600: #159c62;
    --ip-ink: #102a56;
    --ip-text: #1b2b44;
    --ip-muted: #66758a;
    --ip-line: #d9e4f2;
    --ip-canvas: #f6f9fd;
    --ip-surface: #ffffff;
    --ip-radius-sm: 10px;
    --ip-radius-md: 16px;
    --ip-radius-lg: 22px;
    --ip-radius-xl: 30px;
    --ip-shadow-sm: 0 4px 14px rgba(16, 42, 86, .07);
    --ip-shadow-md: 0 12px 32px rgba(16, 42, 86, .10);
    --ip-shadow-lg: 0 22px 55px rgba(16, 42, 86, .14);
    --ip-gradient: linear-gradient(135deg, var(--ip-blue-600), var(--ip-blue-800));
    --ip-gradient-accent: linear-gradient(135deg, var(--ip-blue-600), var(--ip-blue-500) 62%, #2877ef);
    --ip-space-1: 4px;
    --ip-space-2: 8px;
    --ip-space-3: 12px;
    --ip-space-4: 16px;
    --ip-space-5: 20px;
    --ip-space-6: 24px;
    --ip-space-8: 32px;
}

body.tp-native-app {
    --tp-bg: var(--ip-canvas);
    --tp-surface: var(--ip-surface);
    --tp-surface-soft: var(--ip-blue-50);
    --tp-text: var(--ip-text);
    --tp-muted: var(--ip-muted);
    --tp-line: rgba(16, 42, 86, .11);
    --tp-blue: var(--ip-blue-600);
    --tp-green: var(--ip-green-500);
    --tp-orange: var(--ip-orange-500);
    --tp-shadow: var(--ip-shadow-lg);
    --tp-soft-shadow: var(--ip-shadow-sm);
}

body.tp-native-app .ip-card,
body.tp-native-app .tp-card {
    border: 1px solid var(--ip-line);
    border-radius: var(--ip-radius-lg);
    background: var(--ip-surface);
    box-shadow: var(--ip-shadow-md);
}

body.tp-native-app .ip-btn,
body.tp-native-app .tp-btn {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 18px;
    border: 1px solid var(--ip-line);
    border-radius: 14px;
    color: var(--ip-ink);
    background: var(--ip-surface);
    box-shadow: var(--ip-shadow-sm);
    font-weight: 800;
}

body.tp-native-app .ip-btn-primary,
body.tp-native-app .tp-btn.primary {
    border-color: transparent;
    color: #fff;
    background: var(--ip-gradient-accent);
    box-shadow: 0 12px 25px rgba(21, 87, 214, .22);
}

body.tp-native-app .ip-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: max-content;
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--ip-blue-700);
    background: var(--ip-blue-100);
    font-size: .75rem;
    font-weight: 800;
}

body.tp-native-app .ip-badge-success { color: var(--ip-green-600); background: var(--ip-green-50); }
body.tp-native-app .ip-badge-accent { color: var(--ip-orange-600); background: var(--ip-orange-50); }

body.tp-native-app .ip-field,
body.tp-native-app input:not([type="checkbox"]):not([type="radio"]),
body.tp-native-app select,
body.tp-native-app textarea {
    border-color: var(--ip-line);
    border-radius: 14px;
    background: var(--ip-surface);
    color: var(--ip-text);
}

body.tp-native-app .ip-icon {
    width: 44px;
    height: 44px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 14px;
    color: var(--ip-blue-600);
    background: var(--ip-blue-100);
}

body.tp-native-app .ip-icon img { width: 100%; height: 100%; object-fit: contain; }

@media (max-width: 640px) {
    body.tp-native-app { --ip-radius-lg: 18px; --ip-radius-xl: 24px; }
    body.tp-native-app .ip-btn, body.tp-native-app .tp-btn { min-height: 44px; padding-inline: 15px; }
}

@media (max-width: 640px) {
    body .tp-home .tp-appbar {
        position: sticky;
        inset: auto;
        top: 0;
    }
}

/* Step 2 user shell polish. Kept outside admin routes by app_config guard. */
body:not(.tp-admin-control):not(.tp-admin-login) .tp-action-icon img,
body:not(.tp-admin-control):not(.tp-admin-login) .tp-link-icon img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
}

body:not(.tp-admin-control):not(.tp-admin-login) .tp-action-icon img + i,
body:not(.tp-admin-control):not(.tp-admin-login) .tp-link-icon img + i {
    display: none;
}

body:not(.tp-admin-control):not(.tp-admin-login) .tp-action-card,
body:not(.tp-admin-control):not(.tp-admin-login) .tp-link-card {
    border-color: var(--ip-line, rgba(16,42,86,.12)) !important;
    background:
        linear-gradient(180deg, rgba(255,255,255,.98), rgba(246,249,253,.94)) !important;
    box-shadow: var(--ip-shadow-md, 0 12px 32px rgba(16,42,86,.10)) !important;
}

body:not(.tp-admin-control):not(.tp-admin-login) .tp-action-icon,
body:not(.tp-admin-control):not(.tp-admin-login) .tp-link-icon {
    padding: 0;
    overflow: hidden;
    background: #fff !important;
    box-shadow: var(--ip-shadow-sm, 0 4px 14px rgba(16,42,86,.07));
}
