:root {
  --t-orb-ink: #11110f;
  --t-orb-paper: #f7f4ec;
  --t-orb-orange: #ff5b35;
  --t-orb-acid: #d9ff43;
  --t-orb-blue: #8ad8ff;
  --t-orb-violet: #7357e8;
}

.t-orb,
.t-orb * {
  box-sizing: border-box;
}

.t-orb [hidden] {
  display: none !important;
}

.t-orb {
  position: relative;
  z-index: 2147483000;
  color: var(--t-orb-ink);
  font-family: "Be Vietnam Pro", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.45;
}

.t-orb-trigger {
  position: fixed;
  right: 22px;
  bottom: calc(22px + env(safe-area-inset-bottom, 0px));
  z-index: 4;
  width: 62px;
  height: 62px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: grab;
  isolation: isolate;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  transition:
    opacity 180ms ease,
    filter 180ms ease,
    transform 180ms cubic-bezier(0.2, 0.75, 0.2, 1);
}

.t-orb-trigger:active {
  cursor: grabbing;
}

.t-orb-is-dragging .t-orb-trigger {
  transition: none;
}

.t-orb-is-dragging .t-orb-trigger-hint {
  display: none;
}

.t-orb-trigger:hover,
.t-orb-trigger:focus-visible {
  filter: saturate(1.15);
  transform: translateY(-3px) scale(1.035);
}

.t-orb-trigger:focus-visible {
  outline: 3px solid var(--t-orb-blue);
  outline-offset: 4px;
}

.t-orb-trigger-visual {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(17, 17, 15, 0.82);
  border-radius: inherit;
  background:
    radial-gradient(circle at 32% 24%, rgba(255, 255, 255, 0.98), transparent 17%),
    radial-gradient(circle at 70% 76%, rgba(217, 255, 67, 0.9), transparent 30%),
    conic-gradient(
      from 205deg,
      var(--t-orb-violet),
      var(--t-orb-blue),
      var(--t-orb-acid),
      var(--t-orb-orange),
      var(--t-orb-violet)
    );
  box-shadow:
    0 12px 30px rgba(17, 17, 15, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    inset 0 -10px 18px rgba(17, 17, 15, 0.18);
}

.t-orb-trigger-visual::before {
  content: "";
  position: absolute;
  inset: 5px;
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: inherit;
  background: rgba(17, 17, 15, 0.78);
  box-shadow: inset 0 0 22px rgba(138, 216, 255, 0.22);
  backdrop-filter: blur(9px) saturate(1.25);
  -webkit-backdrop-filter: blur(9px) saturate(1.25);
}

.t-orb-trigger-visual::after {
  content: "";
  position: absolute;
  inset: -45%;
  background: conic-gradient(
    transparent 0 56%,
    rgba(255, 255, 255, 0.72) 62%,
    transparent 69%
  );
  animation: t-orb-scan 4.8s linear infinite;
}

.t-orb-mark {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  color: #fff;
  font-family: "Lora", Georgia, serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.06em;
  text-shadow: 0 1px 12px rgba(138, 216, 255, 0.9);
}

.t-orb-trigger-hint {
  position: absolute;
  right: calc(100% + 11px);
  top: 50%;
  width: max-content;
  padding: 8px 10px;
  border: 1px solid var(--t-orb-ink);
  background: var(--t-orb-acid);
  color: var(--t-orb-ink);
  box-shadow: 4px 4px 0 var(--t-orb-ink);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.12em;
  pointer-events: none;
  opacity: 0;
  transform: translate(6px, -50%);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
  white-space: nowrap;
}

.t-orb[data-side="left"] .t-orb-trigger-hint {
  right: auto;
  left: calc(100% + 11px);
  transform: translate(-6px, -50%);
}

.t-orb-trigger:hover .t-orb-trigger-hint,
.t-orb-trigger:focus-visible .t-orb-trigger-hint {
  opacity: 1;
  transform: translate(0, -50%);
}

.t-orb-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: rgba(17, 17, 15, 0.38);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: t-orb-fade-in 180ms ease both;
}

.t-orb-panel {
  position: fixed;
  right: 24px;
  bottom: 104px;
  z-index: 3;
  width: min(486px, calc(100vw - 48px));
  max-height: min(720px, calc(100dvh - 132px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--t-orb-ink);
  border-radius: 25px;
  background:
    radial-gradient(circle at 92% 0, rgba(138, 216, 255, 0.5), transparent 27%),
    radial-gradient(circle at 0 32%, rgba(217, 255, 67, 0.3), transparent 29%),
    var(--t-orb-paper);
  box-shadow:
    11px 11px 0 var(--t-orb-ink),
    0 24px 70px rgba(17, 17, 15, 0.28);
  animation: t-orb-panel-in 230ms cubic-bezier(0.18, 0.82, 0.25, 1) both;
}

.t-orb[data-side="left"] .t-orb-panel {
  right: auto;
  left: 24px;
  box-shadow:
    -11px 11px 0 var(--t-orb-ink),
    0 24px 70px rgba(17, 17, 15, 0.28);
}

.t-orb-is-open .t-orb-trigger {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.82);
}

.t-orb-sheet-handle {
  display: none;
}

.t-orb-head {
  position: relative;
  width: 100%;
  max-width: none;
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 23px 24px 20px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  border: 0;
}

.t-orb-head > div {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 7px;
}

.t-orb-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #5b42cd;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.17em;
}

.t-orb-eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--t-orb-orange);
  box-shadow: 0 0 0 5px rgba(255, 91, 53, 0.13);
}

.t-orb-head h2 {
  margin: 0;
  padding: 1px 0 3px;
  color: var(--t-orb-ink);
  font-family: "Be Vietnam Pro", Arial, sans-serif;
  font-size: 22px;
  font-weight: 900;
  line-height: 1.22;
  letter-spacing: -0.04em;
}

.t-orb-head h2 em {
  color: var(--t-orb-orange);
  font-family: "Lora", Georgia, serif;
  font-weight: 600;
}

.t-orb-close {
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid var(--t-orb-ink);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.72);
  color: var(--t-orb-ink);
  cursor: pointer;
  font-size: 21px;
  line-height: 1;
  transition:
    background 150ms ease,
    color 150ms ease,
    transform 150ms ease;
}

.t-orb-close:hover,
.t-orb-close:focus-visible {
  background: var(--t-orb-ink);
  color: #fff;
  transform: rotate(5deg);
}

.t-orb-close:focus-visible,
.t-orb-search input:focus-visible,
.t-orb-clear:focus-visible,
.t-orb-filter:focus-visible,
.t-orb-topic:focus-visible,
.t-orb-more:focus-visible,
.t-orb-result:focus-visible {
  outline: 3px solid var(--t-orb-blue);
  outline-offset: 2px;
}

.t-orb-search-wrap {
  position: relative;
  z-index: 1;
  padding: 0 24px;
}

.t-orb-search {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
  border: 1px solid var(--t-orb-ink);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 5px 5px 0 var(--t-orb-violet);
  transition:
    box-shadow 160ms ease,
    transform 160ms ease;
}

.t-orb-search:focus-within {
  box-shadow: 6px 6px 0 var(--t-orb-acid);
  transform: translate(-1px, -1px);
}

.t-orb-search svg {
  flex: 0 0 auto;
  width: 19px;
  height: 19px;
  margin-left: 15px;
  stroke: currentColor;
}

.t-orb-search input {
  width: 100%;
  min-width: 0;
  height: 54px;
  padding: 0 10px 0 11px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--t-orb-ink);
  font-family: inherit;
  font-size: 13px;
  font-weight: 650;
}

.t-orb-search input::placeholder {
  color: #76736c;
  opacity: 1;
}

.t-orb-search input:focus-visible {
  outline: 0;
}

.t-orb-clear {
  flex: 0 0 auto;
  min-width: 34px;
  height: 34px;
  margin-right: 9px;
  padding: 0 8px;
  border: 0;
  border-radius: 9px;
  background: #e9e5dc;
  color: #56534d;
  cursor: pointer;
  font-size: 15px;
  font-weight: 800;
}

.t-orb-filters,
.t-orb-topics {
  position: relative;
  flex: 0 0 auto;
  width: 100%;
  min-height: 50px;
  padding: 14px 24px 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
}

.t-orb-topics {
  min-height: 44px;
  padding-top: 5px;
  padding-bottom: 7px;
}

.t-orb-filters::-webkit-scrollbar,
.t-orb-topics::-webkit-scrollbar {
  display: none;
}

.t-orb-filter,
.t-orb-topic {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(17, 17, 15, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.54);
  color: #525049;
  cursor: pointer;
  font-family: inherit;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.08em;
  white-space: nowrap;
  transition:
    background 140ms ease,
    border-color 140ms ease,
    color 140ms ease,
    transform 140ms ease;
}

.t-orb-filter:hover,
.t-orb-topic:hover {
  border-color: var(--t-orb-ink);
  transform: translateY(-1px);
}

.t-orb-filter[aria-selected="true"] {
  border-color: var(--t-orb-ink);
  background: var(--t-orb-ink);
  color: #fff;
}

.t-orb-topic[aria-pressed="true"] {
  border-color: var(--t-orb-ink);
  background: var(--t-orb-acid);
  color: var(--t-orb-ink);
}

.t-orb-results-head {
  padding: 17px 24px 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #68655e;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.t-orb-results-head span:last-child {
  color: #8a877f;
  letter-spacing: 0;
}

.t-orb-results-scroll {
  flex: 1 1 auto;
  min-height: 148px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: rgba(17, 17, 15, 0.28) transparent;
  scrollbar-width: thin;
}

.t-orb-results {
  padding: 0 17px 2px;
  display: grid;
  gap: 8px;
}

.t-orb-result {
  position: relative;
  min-width: 0;
  padding: 10px;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid transparent;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.68);
  color: var(--t-orb-ink);
  text-decoration: none;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease;
}

.t-orb-result:hover,
.t-orb-result:focus-visible,
.t-orb-result.is-key-active {
  border-color: var(--t-orb-ink);
  background: #fff;
  box-shadow: 4px 4px 0 var(--t-orb-acid);
  transform: translate(-1px, -1px);
}

.t-orb-result-media {
  position: relative;
  width: 64px;
  height: 64px;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 1px solid rgba(17, 17, 15, 0.28);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(115, 87, 232, 0.82), rgba(138, 216, 255, 0.82));
  color: #fff;
  font-family: "Lora", Georgia, serif;
  font-size: 19px;
  font-weight: 600;
}

.t-orb-result[data-group="product"] .t-orb-result-media {
  background: linear-gradient(135deg, var(--t-orb-orange), #ffb36c);
}

.t-orb-result[data-group="guide"] .t-orb-result-media {
  background: linear-gradient(135deg, #0d645f, var(--t-orb-blue));
}

.t-orb-result-media img {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: #fff;
}

.t-orb-result-copy {
  min-width: 0;
}

.t-orb-result-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #6a675f;
  font-size: 7px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.t-orb-result-meta i {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--t-orb-violet);
}

.t-orb-result[data-group="guide"] .t-orb-result-meta i {
  background: #0d7b74;
}

.t-orb-result[data-group="product"] .t-orb-result-meta i {
  background: var(--t-orb-orange);
}

.t-orb-result h3 {
  margin: 5px 0 3px;
  overflow: hidden;
  color: var(--t-orb-ink);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-family: "Be Vietnam Pro", Arial, sans-serif;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: -0.025em;
}

.t-orb-result p {
  margin: 0;
  overflow: hidden;
  color: #6b6861;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  font-size: 9px;
  line-height: 1.45;
}

.t-orb-result-side {
  min-width: 55px;
  display: grid;
  justify-items: end;
  gap: 5px;
  color: var(--t-orb-ink);
}

.t-orb-result-side strong {
  font-size: 9px;
  font-weight: 900;
  white-space: nowrap;
}

.t-orb-result-side span {
  color: var(--t-orb-orange);
  font-size: 16px;
  font-weight: 900;
  transition: transform 150ms ease;
}

.t-orb-result:hover .t-orb-result-side span,
.t-orb-result:focus-visible .t-orb-result-side span {
  transform: translateX(3px);
}

.t-orb-more {
  width: calc(100% - 34px);
  min-height: 42px;
  margin: 10px 17px 4px;
  border: 1px dashed rgba(17, 17, 15, 0.5);
  border-radius: 12px;
  background: transparent;
  color: var(--t-orb-ink);
  cursor: pointer;
  font-family: inherit;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.1em;
}

.t-orb-more:hover {
  border-style: solid;
  background: var(--t-orb-acid);
}

.t-orb-empty,
.t-orb-loading {
  margin: 2px 7px 8px;
  padding: 30px 22px;
  border: 1px dashed rgba(17, 17, 15, 0.35);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.46);
  text-align: center;
}

.t-orb-empty b,
.t-orb-loading b {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 900;
}

.t-orb-empty p,
.t-orb-loading p {
  margin: 0;
  color: #706d66;
  font-size: 10px;
  line-height: 1.6;
}

.t-orb-empty a {
  display: inline-flex;
  margin-top: 14px;
  padding-bottom: 3px;
  border-bottom: 2px solid var(--t-orb-orange);
  color: var(--t-orb-ink);
  font-size: 9px;
  font-weight: 900;
  text-decoration: none;
}

.t-orb-loader {
  width: 30px;
  height: 30px;
  margin: 0 auto 12px;
  border: 4px solid rgba(17, 17, 15, 0.12);
  border-top-color: var(--t-orb-violet);
  border-right-color: var(--t-orb-orange);
  border-radius: 50%;
  animation: t-orb-spin 800ms linear infinite;
}

.t-orb-foot {
  width: 100%;
  max-width: none;
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 13px 24px calc(14px + env(safe-area-inset-bottom, 0px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid rgba(17, 17, 15, 0.12);
  background: rgba(247, 244, 236, 0.86);
  color: #77746d;
  font-size: 7px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.t-orb-foot span:last-child,
.t-orb-foot a {
  color: #524dbe;
}

.t-orb-foot a {
  padding-bottom: 2px;
  border-bottom: 1px solid currentColor;
  white-space: nowrap;
}

@keyframes t-orb-scan {
  to {
    transform: rotate(1turn);
  }
}

@keyframes t-orb-spin {
  to {
    transform: rotate(1turn);
  }
}

@keyframes t-orb-fade-in {
  from {
    opacity: 0;
  }
}

@keyframes t-orb-panel-in {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.97);
  }
}

@media (max-width: 650px) {
  body.t-orb-body-open {
    overflow: hidden;
    overscroll-behavior: none;
  }

  .t-orb-trigger {
    right: 16px;
    bottom: calc(17px + env(safe-area-inset-bottom, 0px));
    width: 57px;
    height: 57px;
  }

  .t-orb-mark {
    width: 36px;
    height: 36px;
    font-size: 17px;
  }

  .t-orb-trigger-hint {
    display: none;
  }

  .t-orb-backdrop {
    background: rgba(17, 17, 15, 0.54);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
  }

  .t-orb-panel,
  .t-orb[data-side="left"] .t-orb-panel {
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: min(86dvh, 760px);
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 26px 26px 0 0;
    box-shadow: 0 -12px 60px rgba(17, 17, 15, 0.35);
    animation-name: t-orb-sheet-in;
  }

  .t-orb-sheet-handle {
    width: 42px;
    height: 4px;
    margin: 9px auto 0;
    display: block;
    border-radius: 999px;
    background: rgba(17, 17, 15, 0.24);
  }

  .t-orb-head {
    padding: 14px 17px 17px;
  }

  .t-orb-head h2 {
    font-size: 20px;
    line-height: 1.24;
  }

  .t-orb-close {
    width: 36px;
    height: 36px;
  }

  .t-orb-search-wrap,
  .t-orb-filters,
  .t-orb-topics {
    padding-right: 17px;
    padding-left: 17px;
  }

  .t-orb-search input {
    height: 52px;
    font-size: 12px;
  }

  .t-orb-filters {
    min-height: 50px;
    padding-top: 14px;
    padding-bottom: 4px;
  }

  .t-orb-topics {
    min-height: 44px;
    padding-top: 5px;
    padding-bottom: 7px;
  }

  .t-orb-results-head {
    padding: 15px 17px 8px;
  }

  .t-orb-results {
    padding-right: 11px;
    padding-left: 11px;
  }

  .t-orb-result {
    grid-template-columns: 58px minmax(0, 1fr) auto;
    gap: 10px;
    padding: 9px;
  }

  .t-orb-result-media {
    width: 58px;
    height: 58px;
  }

  .t-orb-result h3 {
    font-size: 11px;
  }

  .t-orb-result p {
    display: none;
  }

  .t-orb-result-side {
    min-width: 44px;
  }

  .t-orb-result-side strong {
    max-width: 68px;
    overflow: hidden;
    font-size: 8px;
    text-overflow: ellipsis;
  }

  .t-orb-foot {
    padding-right: 17px;
    padding-left: 17px;
  }
}

@media (max-width: 350px) {
  .t-orb-head h2 {
    font-size: 18px;
  }

  .t-orb-filters {
    gap: 6px;
  }

  .t-orb-filter {
    padding-inline: 8px;
    font-size: 7px;
  }

  .t-orb-result {
    grid-template-columns: 52px minmax(0, 1fr) 34px;
    gap: 8px;
  }

  .t-orb-result-media {
    width: 52px;
    height: 52px;
  }

  .t-orb-result-side strong {
    display: none;
  }
}

@media (max-width: 620px) {
  .t-orb-foot > span:first-child {
    display: none;
  }
}

@keyframes t-orb-sheet-in {
  from {
    opacity: 0;
    transform: translateY(100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .t-orb *,
  .t-orb *::before,
  .t-orb *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media print {
  .t-orb {
    display: none !important;
  }
}
