/* ==========================================================================
   Tushar Biswas — portfolio template
   Original design system (plum → pink brand) on a rail + feed + side-rail shell.
   Bootstrap 5 provides the grid/utilities; every branded piece is `tb-` prefixed.
   ========================================================================== */

/* ------------------------------------------------------------------ tokens */
:root {
  --bg: #ffffff;
  --bg-2: #f7f6f8;
  --bg-3: #f0edf2;
  --line: #e7e3ea;
  --line-2: #dad4de;
  --ink: #1b1520;
  --ink-2: #5b5364;
  --ink-3: #837a8c;
  --brand: #681d49;
  --brand-2: #de347f;
  --brand-soft: rgba(104, 29, 73, .09);
  --grad: linear-gradient(135deg, #681d49 0%, #de347f 100%);
  --grad-soft: linear-gradient(135deg, rgba(104, 29, 73, .12), rgba(222, 52, 127, .12));
  --ring: rgba(104, 29, 73, .22);
  --shadow: 0 1px 2px rgba(27, 21, 32, .05), 0 10px 28px -14px rgba(27, 21, 32, .22);
  --shadow-lg: 0 24px 60px -28px rgba(27, 21, 32, .35);

  --fs-xs: .75rem;
  --fs-sm: .875rem;
  --fs-base: 1rem;
  --fs-lg: 1.125rem;
  --fs-xl: 1.375rem;
  --fs-2xl: 1.75rem;
  --fs-3xl: 2.5rem;

  --font-sans: "Space Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  color-scheme: light;
}

[data-bs-theme="dark"] {
  --bg: #0c0a10;
  --bg-2: #141118;
  --bg-3: #1c1822;
  --line: #2a2531;
  --line-2: #3a3344;
  --ink: #f4f1f6;
  --ink-2: #b4acbe;
  --ink-3: #8e8699;
  --brand: #e879b0;
  --brand-2: #de347f;
  --brand-soft: rgba(222, 52, 127, .16);
  --grad: linear-gradient(135deg, #a83a72 0%, #de347f 100%);
  --grad-soft: linear-gradient(135deg, rgba(168, 58, 114, .22), rgba(222, 52, 127, .16));
  --ring: rgba(222, 52, 127, .35);
  --shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 14px 34px -18px rgba(0, 0, 0, .8);
  --shadow-lg: 0 30px 70px -30px rgba(0, 0, 0, .9);

  color-scheme: dark;
}

/* -------------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p { margin: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 2px; }

/* --------------------------------------------------------------- utilities */
.tb-ink2 { color: var(--ink-2); }
.tb-ink3 { color: var(--ink-3); }
.tb-mono { font-family: var(--font-mono); }
.tb-tab { font-variant-numeric: tabular-nums; }
.tb-grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.min-w-0 { min-width: 0; }
.flex-1 { flex: 1 1 0%; }
.tb-lead { font-size: var(--fs-lg); }
.tb-sm { font-size: var(--fs-sm); }

.tb-eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase; color: var(--brand-2);
}
.tb-eyebrow::before { content: ""; width: 1.75rem; height: 2px; border-radius: 2px; background: var(--grad); }

.tb-h2 { font-size: var(--fs-xl); font-weight: 700; letter-spacing: -.02em; }
.tb-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }

/* =============================================================== app shell */
.tb-shell { max-width: 100rem; margin-inline: auto; display: flex; }

.tb-main { flex: 1 1 auto; min-width: 0; padding-bottom: 5rem; }
@media (min-width: 768px) { .tb-main { border-inline: 1px solid var(--line); padding-bottom: 0; } }

/* ---- left rail ---- */
.tb-rail {
  display: none; flex-shrink: 0; position: sticky; top: 0; height: 100dvh;
  flex-direction: column; align-items: center; padding: .85rem .7rem 1.25rem;
  transition: width .22s;
}
@media (min-width: 768px) { .tb-rail { display: flex; width: 4.75rem; } }
@media (min-width: 1280px) {
  .tb-rail { width: 16rem; align-items: stretch; padding-inline: 1rem; }
  [data-sidebar="collapsed"] .tb-rail { width: 4.75rem; align-items: center; padding-inline: .7rem; }
}
.tb-rail__brand { display: flex; align-items: center; height: 4.25rem; flex-shrink: 0; }
@media (min-width: 1280px) { .tb-rail__brand { padding-inline: .35rem; } [data-sidebar="collapsed"] .tb-rail__brand { padding-inline: 0; } }
.tb-rail__word { display: none; font-size: var(--fs-lg); font-weight: 700; letter-spacing: -.02em; }
.tb-rail__word span { color: var(--brand-2); }
@media (min-width: 1280px) {
  .tb-rail__word { display: inline; }
  [data-sidebar="collapsed"] .tb-rail__word { display: none; }
}
.tb-rail__nav { display: none; margin-top: 1rem; }
@media (min-width: 768px) { .tb-rail__nav { display: flex; flex-direction: column; gap: .15rem; } }
.tb-rail__link {
  position: relative;
  display: flex; align-items: center; justify-content: center; gap: .8rem;
  padding: .6rem .55rem; border-radius: .8rem;
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink-2);
  transition: background .15s, color .15s;
}
.tb-rail__link i { font-size: 1.1rem; }
.tb-rail__label { display: none; }
.tb-rail__link:hover, .tb-rail__link.is-active { background: var(--bg-2); color: var(--ink); }
.tb-rail__link.is-active i { color: var(--brand-2); }
/* icon-only (compact rail + collapsed rail): centre the icon and show a tooltip */
.tb-rail__link::after {
  content: attr(data-label);
  position: absolute; left: calc(100% + .55rem); top: 50%;
  transform: translateY(-50%) translateX(-4px);
  padding: .3rem .55rem; border-radius: .5rem;
  background: var(--ink); color: var(--bg);
  font-size: var(--fs-xs); font-weight: 600; white-space: nowrap;
  opacity: 0; pointer-events: none; z-index: 60;
  transition: opacity .15s, transform .15s;
}
.tb-rail__link:hover::after { opacity: 1; transform: translateY(-50%) translateX(0); }
@media (min-width: 1280px) {
  .tb-rail__link { justify-content: flex-start; padding-inline: .65rem; }
  .tb-rail__label { display: inline; }
  .tb-rail__link::after { display: none; }
  [data-sidebar="collapsed"] .tb-rail__link { justify-content: center; padding-inline: .55rem; }
  [data-sidebar="collapsed"] .tb-rail__label { display: none; }
  [data-sidebar="collapsed"] .tb-rail__link::after { display: block; }
}
.tb-rail__actions { margin-top: auto; display: flex; flex-direction: column; align-items: center; gap: .75rem; flex-shrink: 0; padding-top: 1rem; }
@media (min-width: 1280px) { .tb-rail__actions { align-items: flex-start; padding-inline: .35rem; } [data-sidebar="collapsed"] .tb-rail__actions { align-items: center; padding-inline: 0; } }
.tb-rail__buttons { display: flex; flex-direction: column; gap: .5rem; }
@media (min-width: 1280px) {
  .tb-rail__buttons { flex-direction: row; }
  [data-sidebar="collapsed"] .tb-rail__buttons { flex-direction: column; }
}
.tb-rail__collapse { display: none; }
@media (min-width: 1280px) { .tb-rail__collapse { display: inline-flex; } }
.tb-rail__copy { display: none; font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); }
@media (min-width: 1280px) {
  .tb-rail__copy { display: block; }
  [data-sidebar="collapsed"] .tb-rail__copy { display: none; }
}

/* ---- right rail ---- */
.tb-rail-right { display: none; flex-shrink: 0; position: sticky; top: 0; min-height: 100dvh; align-self: flex-start; }
@media (min-width: 1024px) { .tb-rail-right { display: block; width: 19rem; } }
@media (min-width: 1280px) { .tb-rail-right { width: 21rem; } }
.tb-rail-right__body { padding: 1.5rem; display: flex; flex-direction: column; gap: 1.25rem; }

/* ---- mobile top bar ---- */
.tb-topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between;
  height: 3.5rem; padding-inline: 1rem;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(12px);
}
@media (min-width: 768px) { .tb-topbar { display: none; } }

/* ---- profile bar ---- */
.tb-profilebar {
  display: none; position: sticky; top: 0; z-index: 20;
  align-items: center; gap: .75rem;
  height: 4.25rem; padding-inline: 1.5rem;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
}
@media (min-width: 768px) { .tb-profilebar { display: flex; } }
@media (min-width: 1024px) { .tb-profilebar { padding-inline: 2rem; } }
.tb-profilebar__meta { min-width: 0; flex: 1; line-height: 1.2; }
.tb-profilebar__name { font-size: var(--fs-base); font-weight: 700; }
.tb-profilebar__sub { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); }

/* ---- page bar ---- */
.tb-pagebar {
  position: sticky; top: 3.5rem; z-index: 20;
  display: flex; align-items: center; gap: 1rem;
  height: 3.75rem; padding-inline: 1rem;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(12px);
}
@media (min-width: 640px) { .tb-pagebar { padding-inline: 1.5rem; } }
@media (min-width: 768px) { .tb-pagebar { top: 0; height: 4.25rem; } }
@media (min-width: 1024px) { .tb-pagebar { padding-inline: 2rem; } }
.tb-pagebar h1 { font-size: var(--fs-lg); font-weight: 700; letter-spacing: -.02em; }

/* ---- cover band ---- */
.tb-cover { position: relative; height: 8.5rem; overflow: hidden; background: var(--grad); }
@media (min-width: 640px) { .tb-cover { height: 12rem; } }
.tb-cover::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(60% 120% at 15% 10%, rgba(255, 255, 255, .35), transparent 60%),
    radial-gradient(50% 100% at 85% 90%, rgba(0, 0, 0, .28), transparent 60%),
    repeating-linear-gradient(115deg, rgba(255, 255, 255, .07) 0 2px, transparent 2px 22px);
}
.tb-cover__dot {
  position: absolute; border-radius: 9999px; background: rgba(255, 255, 255, .35);
  animation: tb-float var(--dur, 12s) ease-in-out infinite alternate;
}
@keyframes tb-float { from { transform: translateY(-6px); } to { transform: translateY(10px); } }

/* ================================================================ components */

/* buttons ---------------------------------------------------------------- */
.tb-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  border: 1px solid transparent; border-radius: .8rem;
  font-weight: 600; letter-spacing: -.01em; white-space: nowrap; cursor: pointer;
  transition: transform .18s, box-shadow .2s, background .2s, border-color .2s, color .2s;
}
.tb-btn:hover { transform: translateY(-2px); }
.tb-btn:active { transform: translateY(0); }

.tb-btn--primary { color: #fff; background: var(--grad); box-shadow: 0 10px 22px -12px var(--ring); }
.tb-btn--primary:hover { box-shadow: 0 16px 30px -12px var(--ring); }
.tb-btn--outline { color: var(--ink); background: var(--bg); border-color: var(--line-2); box-shadow: var(--shadow); }
.tb-btn--outline:hover { border-color: var(--brand-2); color: var(--brand-2); }
.tb-btn--ghost { color: var(--ink-2); background: transparent; border-color: var(--line); }
.tb-btn--ghost:hover { color: var(--ink); background: var(--bg-2); }

.tb-btn--sm { height: 2.1rem; padding-inline: .8rem; font-size: var(--fs-xs); }
.tb-btn--md { height: 2.5rem; padding-inline: 1.05rem; font-size: var(--fs-sm); }
.tb-btn--lg { height: 3rem; padding-inline: 1.4rem; font-size: var(--fs-base); }
.tb-btn--icon { width: 2.5rem; height: 2.5rem; padding: 0; }
.tb-btn--icon-sm { width: 2.25rem; height: 2.25rem; padding: 0; }
.tb-btn--icon-lg { width: 3rem; height: 3rem; padding: 0; }
.tb-btn--round { border-radius: 9999px; }

/* card / panel ----------------------------------------------------------- */
.tb-card {
  position: relative; border-radius: 1.25rem; border: 1px solid var(--line);
  background: var(--bg); box-shadow: var(--shadow);
  transition: transform .22s, box-shadow .22s, border-color .22s;
}
.tb-card--hover:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-2); }
.tb-card--accent::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; border-radius: 1.25rem 1.25rem 0 0;
  background: var(--grad); opacity: .9;
}
.tb-card--flush { box-shadow: none; background: var(--bg-2); }
.tb-pad { padding: 1.25rem; }
.tb-pad-lg { padding: 1.75rem; }
.tb-card__label { display: flex; align-items: center; gap: .5rem; font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .1em; color: var(--ink-3); }
.tb-card__label i { color: var(--brand-2); }
.tb-card__value { margin-top: .35rem; font-size: var(--fs-lg); font-weight: 700; letter-spacing: -.01em; }

/* glow panel (soft brand aura) ------------------------------------------ */
.tb-glow { position: relative; border-radius: 1.25rem; }
.tb-glow::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; z-index: 0;
  background: var(--grad); opacity: .28; filter: blur(16px);
  transition: opacity .3s;
}
.tb-glow:hover::before { opacity: .5; }
.tb-glow > * { position: relative; z-index: 1; }

/* card-raised (gradient border) ----------------------------------------- */
.tb-raised { position: relative; border-radius: 1.25rem; background: var(--bg); border: 1px solid var(--line); box-shadow: var(--shadow); }
.tb-raised--grad { border-color: transparent; background:
  linear-gradient(var(--bg), var(--bg)) padding-box,
  var(--grad) border-box; }

/* tag / pill / badge ---------------------------------------------------- */
.tb-tag {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .2rem .6rem; border-radius: .5rem;
  font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 500;
  color: var(--ink-2); background: var(--bg-2); border: 1px solid var(--line);
}
.tb-pill {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .3rem .75rem; border-radius: 9999px;
  font-size: var(--fs-sm); font-weight: 500;
  color: var(--ink); background: var(--bg); border: 1px solid var(--line);
  transition: border-color .18s, transform .18s;
}
.tb-pill:hover { border-color: var(--brand-2); transform: translateY(-1px); }
.tb-pill i { color: var(--brand-2); }
.tb-badge {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .35rem .8rem; border-radius: .65rem;
  font-size: var(--fs-sm); font-weight: 500;
  color: var(--ink); background: var(--bg-2); border: 1px solid var(--line);
}
.tb-badge i { color: var(--brand-2); font-size: 1rem; }

.tb-status {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .35rem .8rem; border-radius: 9999px;
  font-size: var(--fs-sm); font-weight: 600; color: var(--brand-2);
  background: var(--brand-soft); border: 1px solid var(--ring);
}
.tb-status::before { content: ""; width: .5rem; height: .5rem; border-radius: 9999px; background: var(--brand-2); animation: tb-pulse 1.6s ease-in-out infinite; }
@keyframes tb-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .4; transform: scale(.7); } }

/* avatar ----------------------------------------------------------------- */
.tb-avatar { border-radius: 9999px; object-fit: cover; border: 1px solid var(--line); }
.tb-avatar--sm { width: 2.25rem; height: 2.25rem; }

/* progress / meter ------------------------------------------------------- */
.tb-bar { height: .55rem; border-radius: 9999px; background: var(--bg-3); overflow: hidden; }
.tb-bar__fill { height: 100%; width: 0; border-radius: 9999px; background: var(--grad); transition: width 1.1s cubic-bezier(.22, 1, .36, 1); }
.tb-meter { display: flex; gap: .25rem; }
.tb-meter span { height: .4rem; flex: 1; border-radius: 9999px; background: var(--grad); }
.tb-meter span.is-empty { background: var(--bg-3); }

/* ================================================================ sections */
.tb-section { padding: 3rem 1.25rem; }
.tb-section--tight { padding-block: 2rem; }
@media (min-width: 640px) { .tb-section { padding-inline: 1.75rem; } }
@media (min-width: 1024px) { .tb-section { padding-inline: 2.25rem; } }

/* hero ------------------------------------------------------------------- */
.tb-hero { position: relative; padding: 0 1.25rem 2.5rem; text-align: center; }
@media (min-width: 640px) { .tb-hero { padding-inline: 1.75rem; } }
@media (min-width: 1024px) { .tb-hero { padding-inline: 2.25rem; } }
.tb-hero__photo-wrap { position: relative; width: 8.5rem; height: 8.5rem; margin: -3.5rem auto 0; }
.tb-hero__photo { width: 100%; height: 100%; border-radius: 9999px; object-fit: cover; border: 4px solid var(--bg); box-shadow: var(--shadow); }
.tb-hero__ring { position: absolute; inset: -14px; border-radius: 9999px; border: 1px dashed var(--line-2); animation: tb-spin 26s linear infinite; }
@keyframes tb-spin { to { transform: rotate(360deg); } }
.tb-hero h1 { margin-top: 1rem; font-size: var(--fs-2xl); font-weight: 700; letter-spacing: -.025em; }
.tb-hero__role { margin-top: .35rem; font-family: var(--font-mono); font-size: var(--fs-base); color: var(--ink-2); }
.tb-hero__role .tb-caret { color: var(--brand-2); animation: tb-blink 1s steps(1) infinite; }
@keyframes tb-blink { 50% { opacity: 0; } }
.tb-hero__desc { margin: .85rem auto 0; max-width: 34rem; font-size: var(--fs-lg); color: var(--ink-2); }
.tb-hero__meta { margin-top: 1rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .5rem 1.25rem; font-size: var(--fs-sm); color: var(--ink-2); }
.tb-hero__meta .tb-tag { border: 0; background: transparent; padding: 0; }
.tb-hero__stack { margin-top: 1.5rem; display: flex; flex-direction: column; gap: .5rem; align-items: center; }
.tb-hero__stack ul { display: flex; flex-wrap: wrap; gap: .4rem; justify-content: center; }
.tb-hero__cta { margin-top: 1.75rem; display: flex; flex-wrap: wrap; gap: .75rem; justify-content: center; }

.tb-stats { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.5rem; margin-top: 1.75rem; }
.tb-stat { text-align: center; }
.tb-stat__num { font-size: var(--fs-2xl); font-weight: 700; letter-spacing: -.03em; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tb-stat__lbl { font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .12em; color: var(--ink-3); }
.tb-stat-sep { width: 1px; height: 2.5rem; background: var(--line); }

/* about ------------------------------------------------------------------ */
.tb-about { display: flex; flex-direction: column; gap: .85rem; font-size: var(--fs-base); line-height: 1.75; color: var(--ink-2); }
.tb-about .tb-more { display: none; }
.tb-about[data-expanded] .tb-more { display: block; }
.tb-about .tb-toggle { display: inline-flex; align-items: center; gap: .15rem; font-weight: 600; color: var(--brand-2); background: none; border: 0; padding: 0; cursor: pointer; }
.tb-about .tb-toggle:hover { text-decoration: underline; }
.tb-about .tb-toggle--less { display: none; }
.tb-about[data-expanded] .tb-toggle--more { display: none; }
.tb-about[data-expanded] .tb-toggle--less { display: inline-flex; }
.tb-about[data-expanded] p:focus { outline: none; }

.tb-facts { margin-top: 1.5rem; display: grid; gap: 1rem; }
@media (min-width: 640px) { .tb-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tb-facts .tb-span2 { grid-column: 1 / -1; }
.tb-clock__time { margin-top: 1rem; display: flex; align-items: flex-end; gap: .5rem; }
.tb-clock__digits { font-size: 2.25rem; line-height: 1; font-weight: 700; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.tb-clock__zone { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); padding-bottom: .25rem; }
.tb-clock__period {
  margin-top: .65rem;
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .3rem .7rem; border-radius: 9999px;
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink-2);
  background: var(--bg-2); border: 1px solid var(--line);
}
.tb-clock__period i { font-size: 1.05rem; line-height: 1; }
.tb-clock__period[data-period="day"] .tb-period-day { color: #f5a623; }
.tb-period-night { display: none; }
.tb-clock__period[data-period="night"] .tb-period-day { display: none; }
.tb-clock__period[data-period="night"] .tb-period-night { display: inline-block; color: #8b8ff5; }

/* stats grid inside about */
.tb-mini { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin-top: 1rem; }
@media (min-width: 480px) { .tb-mini { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tb-mini__card { padding: .9rem; border-radius: .9rem; background: var(--bg-2); border: 1px solid var(--line); text-align: center; }
.tb-mini__num { font-size: var(--fs-xl); font-weight: 700; letter-spacing: -.02em; }
.tb-mini__lbl { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); }

/* services --------------------------------------------------------------- */
.tb-svc { display: flex; flex-direction: column; height: 100%; padding: 1.35rem; }
.tb-svc__icon {
  display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: .9rem;
  font-size: 1.35rem; color: #fff; background: var(--grad); box-shadow: 0 10px 20px -12px var(--ring);
}
.tb-svc__num { position: absolute; top: 1.1rem; right: 1.25rem; font-family: var(--font-mono); font-size: var(--fs-sm); font-weight: 700; color: var(--ink-3); opacity: .5; }
.tb-svc__title { margin-top: 1rem; font-size: var(--fs-lg); font-weight: 700; }
.tb-svc__desc { margin-top: .5rem; font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.7; }

/* projects --------------------------------------------------------------- */
.tb-filters { display: flex; flex-wrap: wrap; gap: .5rem; }
.tb-filter {
  padding: .45rem .95rem; border-radius: 9999px; font-size: var(--fs-sm); font-weight: 600;
  color: var(--ink-2); background: var(--bg); border: 1px solid var(--line); cursor: pointer;
  transition: background .18s, color .18s, border-color .18s;
}
.tb-filter:hover { border-color: var(--brand-2); color: var(--brand-2); }
.tb-filter.is-active { color: #fff; background: var(--grad); border-color: transparent; }

.tb-proj-grid { display: grid; gap: 1.1rem; }
@media (min-width: 640px) { .tb-proj-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .tb-proj-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tb-proj[hidden] { display: none; }
.tb-proj { display: flex; }
.tb-proj > .tb-card { width: 100%; display: flex; flex-direction: column; }
.tb-proj__media { position: relative; overflow: hidden; border-radius: 1.25rem 1.25rem 0 0; background: var(--bg-2); }
.tb-proj__media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; transition: transform .5s; }
.tb-card--hover:hover .tb-proj__media img { transform: scale(1.05); }
.tb-proj__overlay {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: linear-gradient(180deg, rgba(27, 21, 32, 0) 40%, rgba(27, 21, 32, .65));
  opacity: 0; transition: opacity .25s;
}
.tb-proj__media:hover .tb-proj__overlay { opacity: 1; }
.tb-proj__link {
  display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 9999px;
  color: #fff; background: var(--grad); box-shadow: 0 10px 22px -10px rgba(0, 0, 0, .6);
  transform: translateY(8px); transition: transform .25s;
}
.tb-proj__media:hover .tb-proj__link { transform: translateY(0); }
.tb-proj__body { display: flex; flex-direction: column; flex: 1; padding: 1.1rem 1.2rem 1.3rem; }
.tb-proj__cat { font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--brand-2); }
.tb-proj__title { margin-top: .5rem; font-size: var(--fs-lg); font-weight: 700; line-height: 1.35; }
.tb-proj__desc { margin-top: .5rem; font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.7; }
.tb-proj-more { margin-top: 1.75rem; display: flex; justify-content: center; }

/* segmented project-type switcher */
.tb-seg { display: inline-flex; flex-wrap: wrap; gap: .3rem; padding: .3rem; background: var(--bg-2); border: 1px solid var(--line); border-radius: 999px; }
.tb-seg__btn { display: inline-flex; align-items: center; gap: .5rem; padding: .55rem 1rem; border: 0; border-radius: 999px; background: transparent; color: var(--ink-2); font-weight: 600; font-size: var(--fs-sm); cursor: pointer; transition: .25s; }
.tb-seg__btn:hover { color: var(--brand-2); }
.tb-seg__btn.is-active { color: #fff; background: var(--grad); }
.tb-seg__btn i { font-size: 1rem; }
.tb-seg__count { font-family: var(--font-mono); font-size: var(--fs-xs); opacity: .8; }

.tb-panel[hidden] { display: none; }

.tb-proj__top { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.tb-proj__badge { display: inline-flex; align-items: center; gap: .35rem; font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; padding: .25rem .6rem; border: 1px solid var(--line-2); border-radius: 999px; color: var(--ink-2); white-space: nowrap; }
.tb-proj__badge i { font-size: .9rem; }
.tb-proj__badge--envato { color: var(--brand-2); border-color: transparent; background: var(--grad-soft); }
.tb-proj__badge--envato i { color: var(--brand-2); }

.tb-proj__actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: auto; padding-top: 1rem; }

/* experience / timeline -------------------------------------------------- */
.tb-timeline { position: relative; padding-left: 1.6rem; }
.tb-timeline::before { content: ""; position: absolute; left: .45rem; top: .5rem; bottom: .5rem; width: 2px; background: linear-gradient(var(--brand), var(--brand-2)); opacity: .35; }
.tb-tl { position: relative; padding-bottom: 1.6rem; }
.tb-tl:last-child { padding-bottom: 0; }
.tb-tl__dot {
  position: absolute; left: -1.6rem; top: .25rem; display: grid; place-items: center;
  width: 1.6rem; height: 1.6rem; border-radius: 9999px; font-size: .7rem; color: #fff;
  background: var(--grad); box-shadow: 0 0 0 4px var(--bg);
}
.tb-tl__card { padding: 1.1rem 1.2rem; }
.tb-tl__date { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--brand-2); font-weight: 600; }
.tb-tl__role { margin-top: .3rem; font-size: var(--fs-lg); font-weight: 700; }
.tb-tl__company { margin-top: .2rem; font-size: var(--fs-sm); color: var(--ink-2); display: flex; align-items: center; gap: .4rem; }
.tb-tl__company i { color: var(--brand-2); }
.tb-tl__desc { margin-top: .6rem; font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.7; }
.tb-tl__tags { margin-top: .75rem; display: flex; flex-wrap: wrap; gap: .4rem; }

/* skills ----------------------------------------------------------------- */
.tb-skills { display: grid; gap: 2rem; }
@media (min-width: 992px) { .tb-skills { grid-template-columns: 1fr 1fr; align-items: start; } }
.tb-skill + .tb-skill { margin-top: 1.05rem; }
.tb-skill__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: .45rem; font-size: var(--fs-sm); font-weight: 600; }
.tb-skill__head i { color: var(--brand-2); margin-right: .4rem; }
.tb-skill__pct { font-family: var(--font-mono); color: var(--ink-3); }
.tb-badges { display: flex; flex-wrap: wrap; gap: .55rem; }

/* draggable physics skills ---------------------------------------------- */
.tb-physics { display: flex; flex-direction: column; gap: .75rem; }
.tb-physics__bar { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.tb-physics__hint {
  display: inline-flex; align-items: center; gap: .45rem;
  font-family: var(--font-mono); font-size: var(--fs-xs);
  text-transform: uppercase; letter-spacing: .12em; color: var(--ink-3);
}
.tb-physics__hint i { color: var(--brand-2); font-size: .95rem; }
.tb-physics__stage {
  position: relative; overflow: hidden;
  height: 21rem; padding: 1rem;
  display: flex; flex-wrap: wrap; align-content: flex-start; gap: .55rem;
  border-radius: 1.25rem; border: 1px solid var(--line);
  background-color: var(--bg-2);
  background-image: radial-gradient(circle at 1px 1px, var(--line-2) 1px, transparent 0);
  background-size: 22px 22px;
}
@media (min-width: 640px) { .tb-physics__stage { height: 26rem; } }

.tb-phys { position: relative; }
.tb-physics.is-live .tb-physics__stage { display: block; padding: 0; }
.tb-physics.is-live .tb-phys {
  position: absolute; top: 0; left: 0;
  will-change: transform; user-select: none; -webkit-user-select: none;
  cursor: grab; touch-action: none;
  transition: none;
}
.tb-physics.is-live .tb-phys:active { cursor: grabbing; }
.tb-physics.is-live .tb-phys:hover { border-color: var(--brand-2); }

/* testimonials ----------------------------------------------------------- */
.tb-testi-grid { display: grid; gap: 1.1rem; }
@media (min-width: 768px) { .tb-testi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tb-testi { position: relative; display: flex; flex-direction: column; height: 100%; padding: 1.4rem; }
.tb-testi__quote { font-size: 3rem; line-height: 1; font-weight: 700; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tb-testi__text { margin-top: .4rem; flex: 1; font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.75; }
.tb-testi__author { margin-top: 1.1rem; display: flex; align-items: center; gap: .7rem; }
.tb-testi__author img { width: 2.5rem; height: 2.5rem; border-radius: 9999px; object-fit: cover; border: 1px solid var(--line); }
.tb-testi__name { display: block; font-size: var(--fs-sm); font-weight: 700; }
.tb-testi__role { display: block; font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); }
.tb-stars { display: flex; gap: .15rem; color: #f5a623; font-size: .8rem; margin-top: .9rem; }

/* testimonials slider + video feedback ----------------------------------- */
.tb-slider__viewport { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -ms-overflow-style: none; border-radius: 1rem; }
.tb-slider__viewport::-webkit-scrollbar { display: none; }
.tb-slider__viewport:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 4px; }
.tb-slider__track { display: flex; gap: 1.1rem; }
.tb-slide { flex: 0 0 auto; height: auto; scroll-snap-align: start; width: 100%; }
@media (min-width: 768px) { .tb-slide { width: calc((100% - 1.1rem) / 2); } }
@media (min-width: 1024px) { .tb-slide { width: calc((100% - 2.2rem) / 3); } }
.tb-slider__controls { margin-top: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.tb-slider__dots { display: flex; align-items: center; gap: .5rem; }
.tb-slider__dot { width: .5rem; height: .5rem; padding: 0; border: 0; border-radius: 999px; background: var(--ink-3); opacity: .45; cursor: pointer; transition: width .2s, background .2s, opacity .2s; }
.tb-slider__dot:hover { background: var(--brand-2); opacity: 1; }
.tb-slider__dot.is-active { width: 1.4rem; background: var(--grad); opacity: 1; }
.tb-slider__nav { display: none; }
.tb-slider.is-scrollable .tb-slider__nav { display: inline-flex; }

.tb-video-grid { display: grid; gap: 1.1rem; }
@media (min-width: 768px) { .tb-video-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tb-video { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; padding: 0; border: 1px solid var(--line); border-radius: 1.1rem; overflow: hidden; background: var(--grad); cursor: pointer; text-align: left; transition: transform .2s, box-shadow .2s, border-color .2s; }
.tb-video:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--brand-2); }
.tb-video__poster { position: absolute; inset: 0; display: grid; place-items: center; opacity: .3; }
.tb-video__poster img { width: 5.5rem; height: 5.5rem; border-radius: 9999px; object-fit: cover; }
.tb-video__play { position: absolute; top: 40%; left: 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 9999px; background: rgba(255, 255, 255, .22); border: 1px solid rgba(255, 255, 255, .55); color: #fff; font-size: 1.35rem; backdrop-filter: blur(2px); transition: transform .2s, background .2s; }
.tb-video:hover .tb-video__play { transform: translate(-50%, -50%) scale(1.08); background: rgba(255, 255, 255, .34); }
.tb-video__play::before { content: ""; position: absolute; inset: -6px; border-radius: 9999px; border: 2px solid rgba(255, 255, 255, .45); animation: tb-pulse 2.4s ease-out infinite; }
.tb-video__meta { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; padding: 1.6rem 1rem .75rem; color: #fff; background: linear-gradient(to top, rgba(15, 10, 18, .85), transparent); }
.tb-video__name { font-size: var(--fs-sm); font-weight: 700; }
.tb-video__role { font-family: var(--font-mono); font-size: var(--fs-xs); opacity: .85; }
@keyframes tb-pulse { 0% { transform: scale(.9); opacity: .9; } 70% { transform: scale(1.35); opacity: 0; } 100% { transform: scale(1.35); opacity: 0; } }

.tb-video-frame { aspect-ratio: 16 / 9; border-radius: .8rem; overflow: hidden; background: #000; }
.tb-video-frame iframe { display: block; width: 100%; height: 100%; border: 0; }

/* contact ---------------------------------------------------------------- */
.tb-ct-grid { display: grid; gap: 1.5rem; }
@media (min-width: 992px) { .tb-ct-grid { grid-template-columns: 5fr 7fr; align-items: start; } }
.tb-ct-item { display: flex; align-items: center; gap: .9rem; padding: .9rem 1rem; border-radius: 1rem; border: 1px solid var(--line); background: var(--bg); transition: transform .2s, border-color .2s, box-shadow .2s; }
.tb-ct-item + .tb-ct-item { margin-top: .75rem; }
.tb-ct-item:hover { transform: translateY(-2px); border-color: var(--brand-2); box-shadow: var(--shadow); }
.tb-ct-item__icon { display: grid; place-items: center; width: 2.9rem; height: 2.9rem; flex: none; border-radius: .85rem; color: #fff; background: var(--grad); font-size: 1.1rem; }
.tb-ct-item__label { display: block; font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .1em; color: var(--ink-3); }
.tb-ct-item__value { display: block; font-size: var(--fs-sm); font-weight: 600; overflow-wrap: anywhere; }

.tb-field { margin-bottom: 1rem; }
.tb-field label { display: block; margin-bottom: .4rem; font-size: var(--fs-sm); font-weight: 600; }
.tb-input {
  width: 100%; padding: .75rem .9rem; border-radius: .8rem;
  background: var(--bg); color: var(--ink);
  border: 1px solid var(--line-2); font-size: var(--fs-sm);
  transition: border-color .18s, box-shadow .18s;
}
.tb-input::placeholder { color: var(--ink-3); }
.tb-input:focus { outline: 0; border-color: var(--brand-2); box-shadow: 0 0 0 3px var(--brand-soft); }
.tb-input.is-invalid { border-color: #e5484d; box-shadow: 0 0 0 3px rgba(229, 72, 77, .15); }
textarea.tb-input { resize: vertical; min-height: 8rem; }
.tb-err { display: none; margin-top: .35rem; font-size: var(--fs-xs); color: #e5484d; }
.tb-field.has-error .tb-err { display: block; }
.tb-form-ok { display: none; margin-top: 1rem; padding: .85rem 1rem; border-radius: .8rem; font-size: var(--fs-sm); color: var(--brand-2); background: var(--brand-soft); border: 1px solid var(--ring); }
.tb-form-ok.is-shown { display: flex; align-items: center; gap: .5rem; }

/* footer ----------------------------------------------------------------- */
.tb-footer { margin-inline: 1.25rem; padding: 2.25rem 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; align-items: center; gap: 1rem; }
@media (min-width: 640px) { .tb-footer { margin-inline: 1.75rem; } }
@media (min-width: 1024px) { .tb-footer { margin-inline: 2.25rem; } }
.tb-footer__socials { display: flex; gap: 1rem; }
.tb-footer__socials a { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 9999px; border: 1px solid var(--line); color: var(--ink-2); font-size: 1.05rem; transition: transform .18s, color .18s, border-color .18s; }
.tb-footer__socials a:hover { transform: translateY(-2px); color: var(--brand-2); border-color: var(--brand-2); }
.tb-footer__copy { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); }

/* right-rail widgets ----------------------------------------------------- */
.tb-widget { padding: 1.1rem; }
.tb-widget__title { display: flex; align-items: center; gap: .5rem; margin-bottom: .75rem; font-size: var(--fs-base); font-weight: 700; }
.tb-widget__title i { color: var(--brand-2); }
.tb-find { display: flex; flex-direction: column; gap: .15rem; }
.tb-find a { display: flex; align-items: center; gap: .75rem; padding: .5rem; border-radius: .8rem; transition: background .15s; }
.tb-find a:hover { background: var(--bg-2); }
.tb-find__icon { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; flex: none; border-radius: .65rem; border: 1px solid var(--line); color: var(--brand-2); }
.tb-find__label { display: block; font-size: var(--fs-sm); font-weight: 600; }
.tb-find__handle { display: block; font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* logo ------------------------------------------------------------------- */
.tb-logo {
  display: inline-grid; place-items: center; width: 2.25rem; height: 2.25rem; flex: none;
  border-radius: .7rem; background: var(--grad); color: #fff;
  font-weight: 700; font-size: 1rem; letter-spacing: -.02em;
  box-shadow: 0 8px 18px -10px var(--ring); transition: transform .2s;
}
.tb-logo-wrap:hover .tb-logo { transform: rotate(-5deg) scale(1.03); }

/* ================================================================= drawers */
.tb-drawer { width: min(20rem, 86vw) !important; background: var(--bg) !important; color: var(--ink) !important; border: 0 !important; box-shadow: var(--shadow-lg); }
.tb-drawer .offcanvas-body { padding: 1rem 1.1rem 1.4rem; display: flex; flex-direction: column; }
.tb-drawer__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.tb-drawer__nav { display: flex; flex-direction: column; gap: .15rem; }
.tb-drawer__nav a { display: flex; align-items: center; gap: .7rem; padding: .7rem .75rem; border-radius: .8rem; font-weight: 600; color: var(--ink-2); }
.tb-drawer__nav a:hover { background: var(--bg-2); color: var(--ink); }
.tb-drawer__nav a i { color: var(--brand-2); }
.tb-drawer__foot { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.offcanvas-backdrop.show { background-color: #1b152073; backdrop-filter: blur(6px); opacity: 1; }
.offcanvas-backdrop { background-color: transparent; }

/* modal ------------------------------------------------------------------ */
.tb-modal { border: 1px solid var(--line); border-radius: 1.25rem; background: var(--bg); color: var(--ink); overflow: hidden; }
.modal-backdrop.show { background-color: #1b152080; backdrop-filter: blur(6px); opacity: 1; }

/* icon toggling ---------------------------------------------------------- */
.tb-i-moon { display: none !important; }
[data-bs-theme="dark"] .tb-i-moon { display: inline-block !important; }
[data-bs-theme="dark"] .tb-i-sun { display: none !important; }

.tb-i-sound-off { display: none !important; }
[data-sound="off"] .tb-i-sound-off { display: inline-block !important; }
[data-sound="off"] .tb-i-sound-on { display: none !important; }

/* reveal on scroll ------------------------------------------------------- */
.tb-reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.tb-reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
  .tb-reveal { opacity: 1; transform: none; }
}
