/* Telering Control Room — kerangka front end */
.tcr-app {
	--tcr-bg: #f3f5fb; --tcr-fg: #0f172a; --tcr-muted: #64748b; --tcr-surface: #ffffff; --tcr-line: #e2e8f0; --tcr-wm: rgba(15, 23, 42, .055); --tcr-accent: #4f46e5;
	box-sizing: border-box; color: var(--tcr-fg); background: var(--tcr-bg);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; line-height: 1.4;
}
.tcr-app *, .tcr-app *::before, .tcr-app *::after { box-sizing: border-box; }
.tcr-app[data-tcr-theme="dark"] { --tcr-bg: #0b1020; --tcr-fg: #e8ecf6; --tcr-muted: #94a3b8; --tcr-surface: #151b30; --tcr-line: #232b45; --tcr-wm: rgba(255, 255, 255, .06); --tcr-accent: #818cf8; color-scheme: dark; }
html[data-tcr-theme="dark"] { color-scheme: dark; }
html[data-tcr-theme="dark"] body.tcr-body { background: #0b1020; }
html[data-tcr-theme="light"] body.tcr-body { background: #f3f5fb; }
body.tcr-body { margin: 0; }
.tcr-standalone { min-height: 100vh; }
.tcr-app.tcr-fade, .tcr-app.tcr-fade * { transition: background-color .3s, color .3s, border-color .3s; }

/* Animasi lingkaran saat ganti tema (View Transitions) */
html.tcr-vt::view-transition-old(root), html.tcr-vt::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
html.tcr-vt::view-transition-old(root) { z-index: 1; }
html.tcr-vt::view-transition-new(root) { z-index: 2; }

.tcr-shell { display: flex; flex-direction: column; min-height: inherit; }
.tcr-head { display: flex; align-items: center; gap: 18px; padding: 14px 24px; flex-wrap: wrap; position: relative; z-index: 5; }
.tcr-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.tcr-logo { width: 42px; height: 42px; object-fit: contain; flex: none; }
.tcr-title { margin: 0; padding: 0; font-size: 20px; font-weight: 800; letter-spacing: -.01em; color: var(--tcr-fg); line-height: 1.15; }
.tcr-subtitle { margin: 2px 0 0; font-size: 13px; color: var(--tcr-muted); }
.tcr-tabs { display: flex; gap: 6px; flex-wrap: wrap; flex: 1; justify-content: center; min-width: 0; }
.tcr-tab { appearance: none; border: 1px solid var(--tcr-line); background: var(--tcr-surface); color: var(--tcr-fg); font: inherit; font-size: 14px; font-weight: 600; padding: 7px 16px; border-radius: 999px; cursor: pointer; transition: transform .15s, background .15s, color .15s, border-color .15s; }
.tcr-tab:hover { transform: translateY(-1px); border-color: var(--tcr-accent); }
.tcr-tab.is-active { background: var(--tcr-accent); border-color: var(--tcr-accent); color: #fff; }
.tcr-app[data-tcr-theme="dark"] .tcr-tab.is-active { color: #0b1020; }
.tcr-theme-btn { margin-left: auto; appearance: none; border: 1px solid var(--tcr-line); background: var(--tcr-surface); color: var(--tcr-fg); width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; padding: 0; transition: transform .2s; }
.tcr-theme-btn:hover { transform: rotate(18deg) scale(1.06); }
.tcr-theme-btn svg { display: block; }
.tcr-ic-moon { display: none; }
.tcr-app[data-tcr-theme="dark"] .tcr-ic-sun { display: none; }
.tcr-app[data-tcr-theme="dark"] .tcr-ic-moon { display: inline-grid; }
.tcr-ic-sun, .tcr-ic-moon { line-height: 0; }

.tcr-stage { position: relative; flex: 1; overflow: hidden; padding: 8px 12px 40px; min-height: 320px; }
.tcr-standalone .tcr-stage { min-height: calc(100vh - 72px); }
.tcr-watermark { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px 4%; pointer-events: none; user-select: none; -webkit-user-select: none; z-index: 0; text-align: center; }
.tcr-watermark span { font-size: 160px; font-weight: 900; line-height: .92; letter-spacing: -.03em; text-transform: uppercase; color: var(--tcr-wm); overflow-wrap: anywhere; max-width: 100%; }
.tcr-viewport { position: relative; z-index: 1; padding: 8px 0 0; }
.tcr-viewport.is-scroll { overflow-x: auto; }
.tcr-fit { margin: 0 auto; position: relative; }
.tcr-empty { position: relative; z-index: 1; text-align: center; color: var(--tcr-muted); padding: 60px 20px; font-size: 16px; }

.tcr-swap .tcr-watermark span { animation: tcr-wm .45s ease both; }
@keyframes tcr-wm { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
.tcr-pop { animation: tcr-pop .4s cubic-bezier(.2, .8, .3, 1.2) both; }
@keyframes tcr-pop { from { opacity: 0; scale: .9; } to { opacity: 1; scale: 1; } }
@media (prefers-reduced-motion: reduce) { .tcr-pop, .tcr-swap .tcr-watermark span { animation: none; } }

/* Akses ditolak */
.tcr-denied { max-width: 420px; margin: 18vh auto 0; text-align: center; padding: 32px; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: #0f172a; }
.tcr-denied h1 { font-size: 24px; margin: 14px 0 6px; }
.tcr-denied p { color: #64748b; margin: 0 0 20px; }
.tcr-denied-inline { margin: 20px auto; border: 1px solid #e2e8f0; border-radius: 16px; background: #fff; }
.tcr-denied-body { background: #f3f5fb; }
.tcr-btn { display: inline-block; background: #4f46e5; color: #fff; padding: 10px 22px; border-radius: 999px; text-decoration: none; font-weight: 600; }

@media (max-width: 640px) {
	.tcr-head { padding: 12px 14px; gap: 10px; }
	.tcr-tabs { order: 3; flex-basis: 100%; justify-content: flex-start; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; }
	.tcr-tab { white-space: nowrap; }
	.tcr-title { font-size: 17px; }
}

/* Tampil di dalam post/halaman lewat shortcode (fullscreen="no") */
.tcr-app:not(.tcr-standalone):not(.tcr-full) { border-radius: 20px; overflow: hidden; margin: 1.5em 0; border: 1px solid var(--tcr-line); }
.tcr-app:not(.tcr-standalone) .tcr-stage { min-height: 360px; }
.tcr-app:not(.tcr-standalone) .tcr-title { font-size: 18px; }
a.tcr-brand { text-decoration: none; color: inherit; }

/* Layar penuh: tanpa celah atas/bawah/samping, menutupi header & footer tema */
.tcr-app.tcr-full { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 99990; margin: 0; border: 0; border-radius: 0; overflow-x: hidden; overflow-y: auto; display: flex; flex-direction: column; -webkit-overflow-scrolling: touch; }
body.admin-bar .tcr-app.tcr-full { top: 32px; }
@media (max-width: 782px) { body.admin-bar .tcr-app.tcr-full { top: 46px; } }
.tcr-app.tcr-full .tcr-shell { flex: 1 0 auto; min-height: 100%; }
.tcr-app.tcr-full .tcr-stage { min-height: 0; flex: 1 0 auto; }
html.tcr-has-full, html.tcr-has-full body { overflow: hidden; }

/* Tooltip kartu */
.tcr-tip { position: fixed; z-index: 99999; display: none; max-width: min(340px, calc(100vw - 16px)); min-width: 120px; box-sizing: border-box; padding: 12px 14px 8px; border-radius: 14px; cursor: copy;
	background: var(--tcr-surface); color: var(--tcr-fg); border: 1px solid var(--tcr-line);
	box-shadow: 0 18px 40px -12px rgba(15, 23, 42, .35), 0 2px 8px rgba(15, 23, 42, .12);
	opacity: 0; transform: translateY(6px) scale(.97); transform-origin: var(--ax, 50%) 100%;
	transition: opacity .16s ease, transform .16s ease, left .14s ease, top .14s ease, border-color .2s; pointer-events: none; }
.tcr-tip.is-on { opacity: 1; transform: none; pointer-events: auto; }
.tcr-tip.tcr-tip-instant { transition: opacity .16s ease, transform .16s ease; }
.tcr-tip.is-below { transform-origin: var(--ax, 50%) 0; }
.tcr-tip::before { content: ""; position: absolute; left: 0; right: 0; bottom: -16px; height: 16px; }       /* jembatan agar kursor bisa pindah ke bubble */
.tcr-tip.is-below::before { bottom: auto; top: -16px; }
.tcr-tip::after { content: ""; position: absolute; left: calc(var(--ax, 50%) - 7px); bottom: -7px; width: 12px; height: 12px; background: var(--tcr-surface); border-right: 1px solid var(--tcr-line); border-bottom: 1px solid var(--tcr-line); transform: rotate(45deg); }
.tcr-tip.is-below::after { bottom: auto; top: -7px; transform: rotate(225deg); }
.tcr-tip-body { white-space: pre-wrap; overflow-wrap: anywhere; font: 14px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; max-height: 240px; overflow-y: auto; user-select: text; -webkit-user-select: text; }
.tcr-tip-foot { margin-top: 8px; padding-top: 6px; border-top: 1px dashed var(--tcr-line); font: 600 11px/1.2 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: var(--tcr-muted); text-align: right; letter-spacing: .02em; }
.tcr-tip.is-copied { border-color: #22c55e; }
.tcr-tip.is-copied .tcr-tip-foot { color: #16a34a; }
.tcr-app[data-tcr-theme="dark"] .tcr-tip.is-copied .tcr-tip-foot { color: #4ade80; }
@media (prefers-reduced-motion: reduce) { .tcr-tip { transition: opacity .01s; transform: none; } }

.tcr-tip.has-segs { cursor: default; }
.tcr-tip.has-segs:not(.has-multi) { cursor: copy; }
.tcr-tip.has-multi .tcr-copy { cursor: copy; border-radius: 5px; padding: 0 3px; margin: 0 -3px; background: color-mix(in srgb, var(--tcr-accent) 14%, transparent); transition: background .15s; }
.tcr-tip.has-multi .tcr-copy:hover { background: color-mix(in srgb, var(--tcr-accent) 30%, transparent); }
.tcr-tip .tcr-copy.is-copied { background: color-mix(in srgb, #22c55e 28%, transparent) !important; }

.tcr-loading { padding: 80px 20px; text-align: center; color: var(--tcr-muted); font-size: 15px; }
.tcr-app.tcr-full .tcr-loading { margin: auto; padding: 0; }
.tcr-app > .tcr-denied { color: var(--tcr-fg); }
.tcr-app > .tcr-denied.tcr-denied-inline { background: var(--tcr-surface); border-color: var(--tcr-line); }
.tcr-app > .tcr-denied p { color: var(--tcr-muted); }

/* Hyperlink di dalam tooltip */
.tcr-tip-link { color: var(--tcr-accent); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.tcr-tip-link:hover { text-decoration-thickness: 2px; }
.tcr-tip.no-copy { cursor: default; }
