.tfsa-actions,
.tfsa-actions *,
.tfsa-drawer,
.tfsa-drawer * {
  box-sizing: border-box;
}

.tfsa-actions {
  --tfsa-accent: #1877f2;
  display: flex;
  align-items: center;
  gap: .65rem;
  position: relative;
  margin: 1.5rem 0;
  font-family: inherit;
  z-index: 20;
}

.tfsa-button,
.tfsa-menu-item {
  appearance: none !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  min-height: 2.65rem;
  margin: 0 !important;
  border: 1px solid #d8dee9 !important;
  border-radius: .8rem !important;
  background: #fff !important;
  color: #1d2433 !important;
  padding: .68rem .95rem !important;
  font: inherit !important;
  font-size: .92rem !important;
  font-weight: 650 !important;
  line-height: 1.1 !important;
  letter-spacing: normal !important;
  text-align: center !important;
  text-decoration: none !important;
  text-shadow: none !important;
  text-transform: none !important;
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, background-color .16s ease, color .16s ease, box-shadow .16s ease;
}

.tfsa-button:hover,
.tfsa-menu-item:hover {
  transform: translateY(-1px);
  border-color: var(--tfsa-accent) !important;
  background: #f7f9fc !important;
  color: #111827 !important;
  box-shadow: 0 7px 18px rgba(15, 23, 42, .1) !important;
}

.tfsa-button:focus:not(:focus-visible),
.tfsa-menu-item:focus:not(:focus-visible),
.tfsa-drawer button:focus:not(:focus-visible) {
  outline: 0 !important;
  box-shadow: none !important;
}

.tfsa-button:focus-visible,
.tfsa-menu-item:focus-visible {
  border-color: var(--tfsa-accent) !important;
  outline: 3px solid var(--tfsa-accent) !important;
  outline-offset: 2px !important;
  box-shadow: none !important;
}

.tfsa-button:disabled {
  opacity: .58;
  cursor: wait;
  transform: none;
}

.tfsa-actions .tfsa-like.is-liked,
.tfsa-actions .tfsa-like.is-liked:hover {
  border-color: var(--tfsa-accent) !important;
  background: var(--tfsa-accent) !important;
  color: #fff !important;
  box-shadow: 0 7px 20px color-mix(in srgb, var(--tfsa-accent) 30%, transparent) !important;
}

.tfsa-actions .tfsa-like.is-liked * {
  color: #fff !important;
  text-shadow: none !important;
}

.tfsa-icon {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 1.12rem;
  height: 1.12rem;
  color: currentColor !important;
}

.tfsa-icon svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.tfsa-icon svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tfsa-icon svg circle {
  fill: currentColor;
  stroke: none;
}

.tfsa-like.is-liked .tfsa-icon svg path {
  fill: currentColor;
  stroke: currentColor;
}

.tfsa-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.35rem;
  min-height: 1.35rem;
  padding: 0 .28rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, .07);
  color: inherit !important;
  font-size: .75rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.tfsa-like.is-liked .tfsa-count { background: rgba(255, 255, 255, .2); }
.tfsa-share-wrap { position: relative; }

.tfsa-menu {
  position: absolute;
  left: 0;
  top: calc(100% + .65rem);
  width: max-content;
  max-width: min(21rem, 88vw);
  padding: .55rem;
  border: 1px solid #e2e7ef;
  border-radius: 1rem;
  background: rgba(255, 255, 255, .98);
  color: #1d2433;
  box-shadow: 0 18px 45px rgba(15, 23, 42, .18);
  backdrop-filter: blur(16px);
  z-index: 100;
}

.tfsa-menu[hidden],
.tfsa-menu-item[hidden] { display: none !important; }

.tfsa-menu-item {
  justify-content: flex-start !important;
  width: 100%;
  border: 0 !important;
  border-radius: .7rem !important;
  background: transparent !important;
  line-height: 1.25 !important;
}

.tfsa-menu-item:hover { background: #f1f5f9 !important; box-shadow: none !important; transform: none; }
.tfsa-facebook-mark { display: inline-grid; place-items: center; width: 1.45rem; height: 1.45rem; border-radius: 50%; background: #1877f2; color: #fff !important; font-weight: 800; }
.tfsa-hint { max-width: 18rem; margin: .45rem .55rem .25rem; color: #64748b; font-size: .76rem; line-height: 1.4; }
.tfsa-status { position: absolute; left: 0; top: 100%; padding-top: .35rem; color: #475569; font-size: .78rem; }
.tfsa--theme-fallback { max-width: 1200px; margin: 1.5rem auto; padding: 0 1rem; }

.tfsa-actions[class*="tfsa--floating-"] {
  position: fixed;
  margin: 0;
  padding: .45rem;
  border: 1px solid rgba(148, 163, 184, .35);
  border-radius: 1rem;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 14px 35px rgba(15, 23, 42, .18);
  backdrop-filter: blur(14px);
  z-index: 9990;
}

.tfsa--floating-left,
.tfsa--floating-right { top: 50%; transform: translateY(-50%); flex-direction: column; }
.tfsa--floating-left { left: .75rem; }
.tfsa--floating-right { right: .75rem; }
.tfsa--floating-top-left { top: calc(1rem + var(--wp-admin--admin-bar--height, 0px)); left: 1rem; }
.tfsa--floating-top-right { top: calc(1rem + var(--wp-admin--admin-bar--height, 0px)); right: 1rem; }
.tfsa--floating-bottom-left { bottom: 1rem; left: 1rem; }
.tfsa--floating-bottom-center { bottom: 1rem; left: 50%; transform: translateX(-50%); }
.tfsa--floating-bottom-right { right: 1rem; bottom: 1rem; }
.tfsa--floating-right .tfsa-menu,
.tfsa--floating-top-right .tfsa-menu,
.tfsa--floating-bottom-right .tfsa-menu { left: auto; right: 0; }
.tfsa--floating-bottom-left .tfsa-menu,
.tfsa--floating-bottom-center .tfsa-menu,
.tfsa--floating-bottom-right .tfsa-menu { top: auto; bottom: calc(100% + .65rem); }

.tfsa-actions[class*="tfsa--floating-"] .tfsa-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.tfsa-actions[class*="tfsa--floating-"] .tfsa-button {
  width: 2.7rem;
  min-width: 2.7rem;
  padding: .7rem !important;
  border-radius: .75rem !important;
}

.tfsa-actions[class*="tfsa--floating-"] .tfsa-count {
  position: absolute;
  top: -.3rem;
  right: -.3rem;
  border: 2px solid #fff;
  background: var(--tfsa-accent);
  color: #fff !important;
}

.tfsa-actions[class*="tfsa--floating-"] .tfsa-status { display: none; }

.tfsa-drawer {
  --tfsa-drawer-width: min(22rem, calc(100vw - 3.5rem));
  position: fixed;
  top: 50%;
  width: var(--tfsa-drawer-width);
  z-index: 9995;
  transition: transform .32s cubic-bezier(.22, 1, .36, 1);
}

.tfsa-drawer--left { left: 0; transform: translate(-100%, -50%); }
.tfsa-drawer--right { right: 0; transform: translate(100%, -50%); }
.tfsa-drawer.is-open { transform: translate(0, -50%); }

.tfsa-drawer-panel {
  position: relative;
  min-height: 10rem;
  padding: 1.25rem;
  border: 1px solid rgba(226, 232, 240, .95);
	background: #f8fafc;
  background:
    radial-gradient(circle at 0 0, color-mix(in srgb, var(--tfsa-accent) 10%, transparent), transparent 42%),
    linear-gradient(145deg, rgba(255, 255, 255, .99), rgba(247, 249, 252, .98));
  color: #172033;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .28);
  backdrop-filter: blur(18px);
}

.tfsa-drawer--left .tfsa-drawer-panel { border-left: 0; border-radius: 0 1.15rem 1.15rem 0; }
.tfsa-drawer--right .tfsa-drawer-panel { border-right: 0; border-radius: 1.15rem 0 0 1.15rem; }

.tfsa-drawer-heading {
  display: grid;
  grid-template-columns: 2.65rem minmax(0, 1fr);
  align-items: center;
  gap: .8rem;
  margin: 0 2.15rem 1.1rem 0;
}

.tfsa-drawer-brand {
  display: grid;
  place-items: center;
  width: 2.65rem;
  height: 2.65rem;
  border-radius: .85rem;
  background: var(--tfsa-accent);
  color: #fff !important;
  box-shadow: 0 8px 22px color-mix(in srgb, var(--tfsa-accent) 28%, transparent);
}

.tfsa-drawer-brand svg { width: 1.35rem; height: 1.35rem; }
.tfsa-drawer-brand circle { fill: currentColor; }
.tfsa-drawer-brand path { fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; }
.tfsa-drawer-title { display: block; overflow: hidden; color: #172033 !important; font-size: 1rem; font-weight: 750; line-height: 1.25; text-overflow: ellipsis; text-shadow: none !important; white-space: nowrap; }
.tfsa-drawer-subtitle { display: block; margin-top: .18rem; color: #64748b !important; font-size: .72rem; line-height: 1.3; text-shadow: none !important; }

.tfsa-drawer-tab {
  appearance: none !important;
  position: absolute;
  top: 50%;
  min-height: 3rem;
  margin: 0 !important;
  padding: .85rem .62rem !important;
  border: 0 !important;
  background: var(--tfsa-accent) !important;
  color: #fff !important;
  font: inherit !important;
  font-size: .85rem !important;
  font-weight: 700 !important;
  line-height: 1.15 !important;
  letter-spacing: .01em !important;
  text-shadow: none !important;
  text-transform: none !important;
  cursor: pointer;
  writing-mode: vertical-rl;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .25);
}

.tfsa-drawer--left .tfsa-drawer-tab { left: 100%; transform: translateY(-50%); border-radius: 0 .75rem .75rem 0 !important; }
.tfsa-drawer--right .tfsa-drawer-tab { right: 100%; transform: translateY(-50%) rotate(180deg); border-radius: 0 .75rem .75rem 0 !important; }
.tfsa-drawer-tab:hover { filter: brightness(1.08); }
.tfsa-drawer-tab:focus-visible { outline: 3px solid var(--tfsa-accent) !important; outline-offset: 3px !important; }
.tfsa-drawer-arrow { margin-bottom: .4rem; }
.tfsa-drawer.is-open .tfsa-drawer-tab { visibility: hidden; }

.tfsa-drawer-close {
  appearance: none !important;
  display: grid !important;
  place-items: center;
  position: absolute;
  top: .85rem;
  right: .85rem;
  width: 2.15rem;
  height: 2.15rem;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: .7rem !important;
  background: rgba(255, 255, 255, .76) !important;
  color: #64748b !important;
  cursor: pointer;
  transition: background-color .16s ease, color .16s ease, transform .16s ease;
}

.tfsa-drawer-close svg { width: 1rem; height: 1rem; }
.tfsa-drawer-close path { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.tfsa-drawer-close:hover { transform: rotate(4deg); background: #fff !important; color: #172033 !important; }
.tfsa-drawer-close:focus-visible { outline: 3px solid var(--tfsa-accent) !important; outline-offset: 2px !important; }

.tfsa--drawer-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: .65rem;
  width: 100%;
  margin: 0;
}

.tfsa--drawer-actions > .tfsa-button,
.tfsa--drawer-actions > .tfsa-share-wrap,
.tfsa--drawer-actions .tfsa-share-toggle { width: 100%; }
.tfsa--drawer-actions .tfsa-share-wrap { position: relative; }
.tfsa--drawer-actions.is-share-open .tfsa-share-wrap { grid-column: 1 / -1; }
.tfsa--drawer-actions .tfsa-status { grid-column: 1 / -1; }
.tfsa-drawer .tfsa-button { min-height: 2.85rem; border-radius: .8rem !important; }
.tfsa-drawer .tfsa-menu { position: static; width: 100%; max-width: none; margin-top: .65rem; transform: none; }
.tfsa-drawer .tfsa-status { position: static; width: 100%; padding: 0; }

@media (max-width: 700px) {
  .tfsa--floating-left,
  .tfsa--floating-right {
    left: 50%;
    right: auto;
    top: auto;
    bottom: .75rem;
    transform: translateX(-50%);
    flex-direction: row;
  }
  .tfsa-menu { position: fixed; left: 50% !important; right: auto !important; top: auto; bottom: 4.8rem; transform: translateX(-50%); }
  .tfsa-drawer .tfsa-menu { position: static; left: auto !important; right: auto !important; bottom: auto; transform: none; }
  .tfsa-actions:not([class*="tfsa--floating"]) .tfsa-label { font-size: .88rem; }
}

@media (max-width: 360px) {
  .tfsa-drawer { --tfsa-drawer-width: calc(100vw - 3.25rem); }
  .tfsa-drawer-panel { padding: 1rem; }
  .tfsa-drawer-heading { grid-template-columns: 2.35rem minmax(0, 1fr); gap: .65rem; margin-right: 2rem; }
  .tfsa-drawer-brand { width: 2.35rem; height: 2.35rem; }
  .tfsa--drawer-actions { grid-template-columns: 1fr; }
  .tfsa--drawer-actions.is-share-open .tfsa-share-wrap { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .tfsa-actions *,
  .tfsa-drawer { scroll-behavior: auto !important; transition: none !important; }
}
