/* ── TWiLabs Sticky Widget ── */

#tw-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 500;
  width: 248px;
  font-family: 'DM Sans', sans-serif;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
}

#tw-widget.tw-collapsed .tw-body { display: none; }

/* Body: stacks 2 cards above the pill */
.tw-body {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  order: -1;
}

/* ── Cards shared ── */
.tw-card {
  border-radius: 16px;
  padding: 16px;
  position: relative;
  overflow: hidden;
}

/* ── Card 1 — About (light) ── */
.tw-card-about {
  background: #fff;
  border: 1.5px solid #e0d8c8;
  box-shadow: 0 4px 18px rgba(0, 0, 0, .08);
  text-decoration: none;
  color: inherit;
  display: block;
  transition: border-color .15s, box-shadow .15s;
}
.tw-card-about:hover {
  border-color: #b0a898;
  box-shadow: 0 6px 22px rgba(0, 0, 0, .12);
}

/* Outline "TW" logo mark */
.tw-logo-mark {
  font-family: 'DM Serif Display', serif;
  font-size: 36px;
  color: transparent;
  -webkit-text-stroke: 2px #1a1a2e;
  line-height: 1;
  letter-spacing: -2px;
  margin-bottom: 10px;
  user-select: none;
}

.tw-card-brand {
  font-size: 13px;
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 4px;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.tw-card-by {
  font-size: 10px;
  font-weight: 400;
  color: #aaa;
  letter-spacing: .2px;
}
.tw-card-desc {
  font-size: 12px;
  color: #777;
  line-height: 1.6;
  margin-bottom: 10px;
}
.tw-card-link {
  font-size: 11.5px;
  font-weight: 700;
  color: #1a1a2e;
  text-decoration: none;
  letter-spacing: .2px;
}
.tw-card-link:hover { text-decoration: underline; }

/* Close button — top-right of about card */
.tw-close-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #f5f2ec;
  border: none;
  cursor: pointer;
  font-size: 11px;
  color: #999;
  line-height: 1;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, color .15s;
  font-family: inherit;
}
.tw-close-btn:hover { background: #ebe7df; color: #444; }

/* ── Card 2 — Coffee (dark) ── */
.tw-card-coffee {
  background: #1a1a2e;
  box-shadow: 0 4px 18px rgba(0, 0, 0, .18);
}

.tw-coffee-icon-lg {
  font-size: 30px;
  line-height: 1;
  margin-bottom: 8px;
}

.tw-coffee-heading {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 5px;
}

.tw-coffee-copy {
  font-size: 11.5px;
  color: rgba(255, 255, 255, .55);
  line-height: 1.65;
  margin-bottom: 13px;
}

.tw-coffee-btns {
  display: flex;
  gap: 7px;
}
.tw-coffee-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
  padding: 9px 10px;
  border-radius: 9px;
  transition: opacity .15s;
  font-family: inherit;
  letter-spacing: .1px;
}
.tw-coffee-link:hover { opacity: .85; }
.tw-btn-id     { background: #ffdd57; color: #1a1a1a; }
.tw-btn-global { background: #1a1a2e; color: #fff; }

/* ── Pill toggle ── */
.tw-pill {
  background: #1a1a2e;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 7px 14px 7px 11px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 14px rgba(0, 0, 0, .22);
  letter-spacing: .2px;
  transition: opacity .15s;
  white-space: nowrap;
}
.tw-pill:hover { opacity: .82; }
.tw-pill-icon { font-size: 14px; line-height: 1; }

/* ── Mobile ── */
@media (max-width: 640px) {
  #tw-widget { bottom: 14px; right: 14px; width: 232px; }
}
