/* Terrace Interior — Masuk/Daftar & Akun Saya */
body.t-auth-page, body.t-acc-page { background: #f4f3f0; }
body.t-auth-page .t-content, body.t-acc-page .t-content { padding-top: 0; padding-bottom: 48px; }
body.t-auth-page .t-auth-intro, body.t-acc-page .t-auth-intro { display: none; }

/* ================= Masuk / Daftar ================= */
.ta { --ta-green: #4fae88; font-family: var(--t-font); color: var(--t-ink); max-width: 960px; margin: max(32px, 9vh) auto 0; display: grid; grid-template-columns: 1fr 440px; background: #fff; border-radius: 20px; overflow: hidden; box-shadow: 0 1px 2px rgba(17,17,17,.04); }
.ta *, .ta *::before, .ta *::after { box-sizing: border-box; }
.ta-hero { position: relative; background: var(--ta-green); padding: 72px 40px 48px; display: flex; flex-direction: column; justify-content: center; gap: 12px; min-height: 420px; }
.ta-back { position: absolute; top: 20px; left: 20px; z-index: 2; display: inline-flex; align-items: center; gap: 4px; padding: 7px 14px 7px 10px; border-radius: 999px; background: rgba(255,255,255,.28); color: #0b2a22; font: 500 13px/18px var(--t-font); transition: background .15s; }
.ta-back:hover { background: rgba(255,255,255,.45); text-decoration: none; }
.ta-back:focus-visible { outline: 2px solid #0b2a22; outline-offset: 2px; }
.ta-hero::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 220px; height: 220px; border-radius: 50%; background: rgba(255,255,255,.12); }
.ta-hello { margin: 0; font: 700 34px/42px var(--t-font); color: #0f1a16; position: relative; z-index: 1; }
.ta-sub { margin: 0; font: 400 16px/24px var(--t-font); color: #12332a; position: relative; z-index: 1; }
.ta-toast { position: absolute; top: 64px; left: 50%; transform: translateX(-50%); z-index: 3; width: max-content; max-width: calc(100% - 32px); margin: 0; padding: 12px 18px; border-radius: 10px; background: #c6f0df; color: #0b2a22; font: 600 14px/20px var(--t-font); box-shadow: 0 6px 18px rgba(0,0,0,.12); text-align: center; }
.ta-card { padding: 40px 36px; display: flex; align-items: center; }
.ta-view { width: 100%; display: grid; gap: 12px; }
.ta-view[hidden] { display: none; }
.ta-view h2 { margin: 0 0 8px; text-align: center; font: 700 24px/32px var(--t-font); }
.ta-desc, .ta-hint { margin: -4px 0 4px; text-align: center; font: 400 14px/20px var(--t-font); color: var(--t-muted); }
.ta-hint { text-align: left; margin: -4px 0 0; font-size: 13px; padding: 8px 12px; background: var(--t-warm); border-radius: var(--t-r-sm); }
.ta-field { position: relative; }
.ta-field input { width: 100%; height: 48px; padding: 0 14px; border: 1.5px solid var(--t-line); border-radius: var(--t-r-md); background: #fff; font: 400 15px/20px var(--t-font); color: var(--t-ink); }
.ta-field input::placeholder { color: #a3a09a; }
.ta-field input:focus { outline: none; border-color: var(--t-ink); }
.ta-field input[aria-invalid="true"] { border-color: var(--t-danger); }
.ta-pw input { padding-right: 52px; }
.ta-eye { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 0; background: none; color: #8d8a84; border-radius: var(--t-r-sm); cursor: pointer; }
.ta-eye:hover { color: var(--t-ink); }
.ta-eye:focus-visible { outline: 2px solid var(--t-em-text); }
.ta-eye .ta-eye-off, .ta-eye.is-on .ta-eye-on { display: none; }
.ta-eye.is-on .ta-eye-off { display: block; }
.ta-forgot { justify-self: end; margin-top: -4px; font: 600 13px/18px var(--t-font); color: var(--t-em-text); }
.ta-rules { list-style: none; margin: -2px 0 2px; padding: 0; display: grid; gap: 3px; font: 400 13px/18px var(--t-font); color: #8d8a84; }
.ta-rules li { display: flex; align-items: center; gap: 8px; }
.ta-rule-ico { width: 14px; height: 14px; flex: none; position: relative; }
.ta-rule-ico::before, .ta-rule-ico::after { content: ""; position: absolute; left: 6px; top: 1px; width: 1.75px; height: 12px; background: currentColor; border-radius: 1px; }
.ta-rule-ico::before { transform: rotate(45deg); }
.ta-rule-ico::after { transform: rotate(-45deg); }
.ta-rules:not(.is-touched) .ta-rule-ico::before { transform: none; left: 1px; top: 6px; width: 12px; height: 1.75px; }
.ta-rules:not(.is-touched) .ta-rule-ico::after { display: none; }
.ta-rules.is-touched li:not(.is-ok) { color: var(--t-danger); }
.ta-rules li.is-ok { color: var(--t-em-text); }
.ta-rules li.is-ok .ta-rule-ico::before { left: 1px; top: 6px; width: 5px; height: 1.75px; transform: rotate(45deg); }
.ta-rules li.is-ok .ta-rule-ico::after { left: 4px; top: 5px; width: 10px; height: 1.75px; transform: rotate(-45deg); }
.ta-err { margin: 0; font: 500 13px/18px var(--t-font); color: var(--t-danger); }
.ta-ok { margin: 0; padding: 10px 12px; border-radius: var(--t-r-sm); background: var(--t-em-tint); color: var(--t-em-text); font: 500 14px/20px var(--t-font); }
.ta-btn { min-height: 48px; border: 0; border-radius: var(--t-r-md); background: var(--ta-green); color: #0b2a22; font: 700 15px/20px var(--t-font); cursor: pointer; margin-top: 4px; }
.ta-btn:hover:not(:disabled) { background: #43a07b; }
.ta-btn:disabled { background: #dcdad5; color: #77746e; cursor: default; }
.ta-switch { margin: 8px 0 0; text-align: center; font: 400 14px/20px var(--t-font); }
.ta-switch a { font-weight: 700; color: var(--t-em-text); }
.ta-otp { display: flex; justify-content: center; gap: 8px; margin: 8px 0; }
.ta-otp input { width: 46px; height: 54px; padding: 0; border: 1.5px solid var(--t-line); border-radius: var(--t-r-md); text-align: center; font: 700 22px/1 var(--t-font); color: var(--t-ink); background: #fff; }
.ta-otp input:focus { outline: none; border-color: var(--t-ink); box-shadow: 0 0 0 3px rgba(17,17,17,.06); }
.ta-otp.is-full input { border-color: var(--ta-green); }
.ta-otp.is-bad input { border-color: var(--t-danger); animation: taShake .35s; }
@keyframes taShake { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }
.ta-resend { justify-self: center; min-height: 36px; padding: 0 10px; border: 0; background: none; color: var(--t-muted); font: 600 13px/18px var(--t-font); cursor: default; }
.ta-resend.is-ready { color: var(--t-em-text); cursor: pointer; }
.ta-resend.is-ready:hover { text-decoration: underline; }

@media (max-width: 900px) {
	body.t-auth-page .t-content > .t-wrap { padding-left: 0; padding-right: 0; }
	.ta { display: block; margin: 0; border-radius: 0; background: none; box-shadow: none; }
	.ta-hero { min-height: 0; padding: 72px 20px 56px; }
	.ta-back { top: 16px; left: 16px; }
	.ta-toast { top: 60px; }
	.ta-hello { font-size: 26px; line-height: 34px; }
	.ta-sub { font-size: 14px; line-height: 20px; }
	.ta-hero::after { width: 160px; height: 160px; right: -50px; bottom: -30px; }
	.ta-card { position: relative; margin-top: -28px; padding: 28px 20px calc(96px + env(safe-area-inset-bottom)); background: #fff; border-radius: 24px 24px 0 0; min-height: 60vh; align-items: flex-start; }
	.ta-otp input { width: 44px; height: 52px; }
}
@media (prefers-reduced-motion: reduce) { .ta-otp.is-bad input { animation: none; } }
.ta a { text-decoration: none; } .ta a:hover { text-decoration: underline; }

/* ================= Akun Saya ================= */
.tp { font-family: var(--t-font); color: var(--t-ink); display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; align-items: start; max-width: 1120px; margin: 24px auto 0; }
.tp *, .tp *::before, .tp *::after { box-sizing: border-box; }
.tp a { text-decoration: none; }
.tp-show-m { display: none !important; }
.tp-side { position: sticky; top: 24px; display: grid; gap: 12px; }
.tp-me { display: flex; align-items: center; gap: 14px; padding: 18px; background: #fff; border-radius: var(--t-r-lg); }
.tp-me-text { min-width: 0; display: grid; }
.tp-me-text strong { font: 700 17px/24px var(--t-font); overflow-wrap: anywhere; }
.tp-me-text span { font-size: 13px; color: var(--t-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tp-avatar-wrap { position: relative; flex: none; }
.tp-avatar { width: 64px; height: 64px; border-radius: 50%; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; background: var(--t-em-tint); color: var(--t-em-text); font: 700 22px/1 var(--t-font); flex: none; }
.tp-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tp-avatar.is-lg { width: 96px; height: 96px; font-size: 32px; }
.tp-avatar-edit { position: absolute; right: -2px; bottom: -2px; width: 26px; height: 26px; border-radius: 50%; background: var(--t-ink); color: #fff; display: inline-flex; align-items: center; justify-content: center; border: 2px solid #fff; }
.tp-nav { display: grid; background: #fff; border-radius: var(--t-r-lg); padding: 6px; }
.tp-nav a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 12px; border-radius: var(--t-r-md); color: var(--t-ink); font: 500 15px/20px var(--t-font); }
.tp-nav a span { flex: 1; }
.tp-nav a > .t-icon:first-child { color: var(--t-em-text); }
.tp-nav a > .t-icon:last-child { color: #b9b6b0; }
.tp-nav a:hover { background: var(--t-warm); }
.tp-nav a.is-on { background: var(--t-em-tint); font-weight: 700; }
.tp-nav .tp-logout { color: var(--t-danger); margin-top: 4px; border-top: 1px solid var(--t-line); border-radius: 0 0 var(--t-r-md) var(--t-r-md); }
.tp-nav .tp-logout > .t-icon:first-child { color: var(--t-danger); }

.tp-main { min-width: 0; display: grid; gap: 12px; }
.tp-head { display: flex; align-items: center; gap: 8px; }
.tp-head h1 { margin: 0; font: 700 24px/32px var(--t-font); }
.tp-notices:empty { display: none; }
.tp-stack { display: grid; gap: 12px; }
.tp-card { padding: 18px; }
.tp-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tp-muted { color: var(--t-muted); font-size: 13px; }
.tp-help { margin: 8px 0 0; font: 400 13px/19px var(--t-font); color: var(--t-muted); }
.tp-sec-note { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; background: var(--t-warm); border-radius: var(--t-r-sm); }
.tp-sec-note .t-icon { flex: none; color: var(--t-em-text); margin-top: 1px; }
.tp-msg { margin: 10px 0 0; padding: 8px 12px; border-radius: var(--t-r-sm); background: var(--t-em-tint); color: var(--t-em-text); font: 500 14px/20px var(--t-font); }
.tp-msg.is-bad { background: #fdf0ee; color: var(--t-danger); }
.tp-link { border: 0; background: none; padding: 6px 4px; color: var(--t-em-text); font: 700 14px/20px var(--t-font) !important; cursor: pointer; }
.tp-link:hover { text-decoration: underline; }
.tp-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 16px; border: 1.5px solid var(--t-line); border-radius: var(--t-r-md); background: #fff; color: var(--t-ink) !important; font: 700 14px/20px var(--t-font) !important; cursor: pointer; white-space: nowrap; }
.tp-btn:hover { border-color: var(--t-ink); }
.tp-btn-primary { background: var(--t-em); border-color: var(--t-em); color: var(--t-on-em, #0b2a22) !important; }
.tp-btn-primary:hover { background: var(--t-em-hover); border-color: var(--t-em-hover); }
.tp-btn-danger { color: var(--t-danger) !important; border-color: #f0c7c2; }
.tp-btn.is-confirm, .tp-photo-del.is-confirm { background: var(--t-danger); border-color: var(--t-danger); color: #fff !important; }
.tp-form { display: grid; gap: 12px; }
.tp-form .ta-field input, .tp .ta-field input { width: 100%; height: 46px; padding: 0 52px 0 12px; border: 1.5px solid var(--t-line); border-radius: var(--t-r-md); font: 400 15px/20px var(--t-font); }
.tp .ta-field input:focus { outline: none; border-color: var(--t-ink); }
.tp [aria-invalid="true"] { border-color: var(--t-danger) !important; }
.tp .ta-forgot { justify-self: end; margin-top: -6px; }
.tp-pw-form { max-width: 460px; }

/* Ubin pesanan */
.tp-tiles-wrap { background: #fff; border-radius: var(--t-r-lg); padding: 16px; }
.tp-tiles-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.tp-tiles-head a { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; font-weight: 600; color: var(--t-muted); }
.tp-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.tp-tile { display: grid; justify-items: center; gap: 6px; padding: 10px 4px; border-radius: var(--t-r-md); color: var(--t-ink); font: 500 13px/18px var(--t-font); text-align: center; }
.tp-tile:hover { background: var(--t-warm); }
.tp-tile-ico { position: relative; color: var(--t-em-text); }
.tp-tile-ico b { position: absolute; top: -8px; right: -12px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--t-danger); color: #fff; font: 700 11px/18px var(--t-font); }

/* Data akun */
.tp-photo { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.tp-photo-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tp-photo-actions .tp-help { flex-basis: 100%; margin: 0; }
.tp-row-form { display: flex; align-items: flex-end; gap: 10px; }
.tp-row-form .tco-f { flex: 1; }
.tp-rows { margin-top: 12px; border-top: 1px solid var(--t-line); }
.tp-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--t-line); }
.tp-row-l { display: block; font-size: 13px; color: var(--t-muted); }
.tp-row-v { font: 600 15px/22px var(--t-font); overflow-wrap: anywhere; }
.tp-row-v em { font-weight: 400; color: var(--t-muted); }
.tp-tag { display: inline-block; margin-left: 6px; padding: 0 8px; border-radius: 999px; background: #fff4d6; color: #8a5a00; font: 600 11px/18px var(--t-font); vertical-align: 2px; }
.tp-contact-sheet .ta-otp { margin: 4px 0; }

/* Alamat Saya */
.tp-addr { display: grid; gap: 12px; }
.tp-addr-list { display: grid; gap: 12px; }
.tp-addr-card { display: grid; gap: 2px; border: 1.5px solid transparent; }
.tp-addr-card.is-default { border-color: var(--t-em); }
.tp-addr-card p { margin: 0; font-size: 14px; line-height: 20px; }
.tp-addr-top { display: flex; gap: 6px; min-height: 0; }
.tp-addr-top:empty { display: none; }
.tp-addr-actions { display: flex; gap: 12px; margin-top: 6px; }
.tp-addr .tco-add { margin-top: 0; }
.tp-addr-text { margin: 4px 0 8px; font-size: 14px; line-height: 21px; }
.tp-empty { text-align: center; display: grid; justify-items: center; gap: 4px; padding: 32px 16px; color: var(--t-muted); }
.tp-empty p { margin: 0; }
.tp-empty strong { color: var(--t-ink); }
.tp-empty-btn { margin-top: 12px !important; display: inline-flex; align-items: center; text-decoration: none; }

/* Pesanan */
.tp-tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.tp-tabs::-webkit-scrollbar { display: none; }
.tp-tabs a { flex: none; min-height: 38px; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 999px; background: #fff; color: var(--t-ink); font: 600 14px/20px var(--t-font); border: 1.5px solid transparent; }
.tp-tabs a.is-on { background: var(--t-ink); color: #fff; }
.tp-orders { display: grid; gap: 12px; }
.tp-order { display: grid; gap: 12px; }
.tp-order-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.tp-order-top > div { display: grid; }
.tp-order-top strong { font: 700 16px/22px var(--t-font); }
.tp-order-body { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; }
.tp-order-body .tco-thumb { width: 64px; height: 64px; }
.tp-order-body p { margin: 0; }
.tp-order-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 12px; border-top: 1px solid var(--t-line); flex-wrap: wrap; }
.tp-order-foot strong { font: 700 16px/22px var(--t-font); }
.tp-order-btns { display: flex; gap: 8px; }
.tp-pager { display: flex; justify-content: center; align-items: center; gap: 12px; }
.tp-chip { display: inline-block; padding: 3px 10px; border-radius: 999px; font: 700 12px/18px var(--t-font); white-space: nowrap; }
.tp-chip.is-warn { background: #fff4d6; color: #8a5a00; }
.tp-chip.is-info { background: #e6effc; color: #1d4f91; }
.tp-chip.is-go { background: var(--t-em-tint); color: var(--t-em-text); }
.tp-chip.is-ok { background: #e7f4e4; color: #2e6b1f; }
.tp-chip.is-bad { background: #fdf0ee; color: var(--t-danger); }
.tp-mini-orders { list-style: none; margin: 8px 0 0; padding: 0; }
.tp-mini-orders a { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--t-line); color: var(--t-ink); font-size: 14px; }
.tp-mini-orders li:last-child a { border-bottom: 0; }

/* Progres pesanan */
.tp-steps { list-style: none; margin: 16px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); counter-reset: s; }
.tp-steps li { position: relative; display: grid; justify-items: center; text-align: center; gap: 4px; padding: 0 4px; }
.tp-steps li::before { content: ""; position: absolute; top: 13px; left: -50%; width: 100%; height: 3px; background: var(--t-line); z-index: 0; }
.tp-steps li:first-child::before { display: none; }
.tp-steps li.is-done::before, .tp-steps li.is-now::before { background: var(--t-em); }
.tp-step-dot { position: relative; z-index: 1; width: 28px; height: 28px; border-radius: 50%; background: #fff; border: 3px solid var(--t-line); display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.tp-steps li.is-done .tp-step-dot { background: var(--t-em); border-color: var(--t-em); color: #0b2a22; }
.tp-steps li.is-now .tp-step-dot { border-color: var(--t-em); box-shadow: 0 0 0 4px var(--t-em-tint); }
.tp-steps li.is-now .tp-step-dot::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--t-em); }
.tp-steps li.is-partial .tp-step-dot { border-color: #f2b63c; box-shadow: 0 0 0 4px #fff4d6; }
.tp-steps li.is-partial .tp-step-dot::after { background: #f2b63c; }
.tp-step-t { font: 600 13px/17px var(--t-font); }
.tp-steps li.is-todo .tp-step-t { color: var(--t-muted); font-weight: 500; }
.tp-step-d { font-size: 11px; line-height: 15px; color: var(--t-muted); }
.tp-pay-btn { display: flex !important; align-items: center; justify-content: center; margin-top: 16px !important; text-decoration: none; }
.tp-cancel-box { display: flex; gap: 10px; align-items: center; margin-top: 14px; padding: 12px 14px; border-radius: var(--t-r-md); background: #fdf0ee; color: var(--t-danger); }
.tp-cancel-box div { display: grid; }
.tp-cancel-box span { font-size: 13px; color: #8a4038; }
.tp-ship { margin-top: 16px; padding: 12px 14px; border-radius: var(--t-r-md); background: var(--t-warm); display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.tp-ship > div { display: grid; gap: 2px; }
.tp-ship strong { font: 700 15px/22px var(--t-font); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tp-ship-note { grid-column: 1 / -1; }
.tp-ship-note p { margin: 0; font-size: 14px; }
.tp-copy { display: inline-flex; align-items: center; gap: 4px; min-height: 30px; padding: 0 10px; border: 1px solid var(--t-line); border-radius: 999px; background: #fff; font: 600 12px/16px var(--t-font) !important; color: var(--t-ink); cursor: pointer; }
.tp-help-card { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tp-help-card .tp-help { flex-basis: 100%; margin: 0; }

@media (max-width: 900px) {
	body.t-acc-page .t-content > .t-wrap { padding-left: 0; padding-right: 0; }
	.tp { display: block; margin: 0; }
	.tp-show-m { display: revert !important; }
	.tp-hide-m { display: none !important; }
	.tp-side { position: static; gap: 8px; padding: 8px 0; }
	.tp:not([data-ep="dashboard"]) .tp-side { display: none; }
	.tp[data-ep="dashboard"] .tp-main .tp-head { display: none; }
	.tp-me, .tp-nav, .tp-tiles-wrap { border-radius: 0; }
	.tp-me { padding: 20px 16px; }
	.tp-nav { padding: 4px 8px; }
	.tp-main { gap: 8px; }
	.tp-head { position: sticky; top: 0; z-index: 20; padding: 6px 16px; background: #fff; border-bottom: 1px solid var(--t-line); }
	.tp-head h1 { font-size: 17px; line-height: 24px; }
	.tp-head .tc-back { margin-left: -10px; }
	.tp-notices { padding: 0 16px; }
	.tp-stack { gap: 8px; }
	.tp .tco-card { border-radius: 0; }
	.tp-2col { grid-template-columns: 1fr; gap: 8px; }
	.tp-tabs { padding: 8px 16px 0; }
	.tp-orders, .tp-addr { gap: 8px; }
	.tp-addr { padding: 0 0 8px; }
	.tp-addr .tco-add, .tp-addr > .tp-help { margin: 0 16px; width: auto; }
	.tp-addr .tco-add { background: #fff; }
	.tp-steps { grid-template-columns: 1fr; gap: 0; justify-items: stretch; }
	.tp-steps li { grid-template-columns: 28px 1fr; justify-items: start; text-align: left; column-gap: 12px; row-gap: 0; padding: 0 0 18px; }
	.tp-steps li::before { top: -18px; left: 12.5px; width: 3px; height: calc(100% - 10px); }
	.tp-step-dot { grid-row: span 2; }
	.tp-step-t { align-self: center; padding-top: 4px; }
	.tp-step-d { grid-column: 2; }
	.tp-ship { grid-template-columns: 1fr; }
	.tp-row-form { flex-direction: column; align-items: stretch; }
	.tp-order-foot { align-items: flex-start; }
}
