/**
 * H2O Chat Widget v7.5 — Premium UI
 * Extracted from monolith inline styles.
 * @package H2O_Chat_AI
 * @since   2.0.0
 */

/* ============================================================
   RADU — H2O CHAT WIDGET v7.5 (Premium UI)
   ============================================================ */
:root {
  --r-orange: #F26B22;
  --r-orange-dark: #D85A15;
  --r-orange-deep: #C04D0E;
  --r-orange-light: #FFF3EC;
  --r-orange-glow: rgba(242, 107, 34, 0.25);
  --r-orange-subtle: #FEF0E7;
  --r-bg: #FFFFFF;
  --r-surface: #F6F7F9;
  --r-surface-warm: #FDFAF7;
  --r-border: #E4E5EA;
  --r-border-light: #EEEEF2;
  --r-text: #1A1D24;
  --r-text-secondary: #5A6172;
  --r-text-muted: #969DAB;
  --r-success: #22C55E;
  --r-success-bg: #ECFDF5;
  --r-info: #3B82F6;
  --r-warning: #F59E0B;
  --r-danger: #EF4444;
  --r-radius: 22px;
  --r-radius-md: 16px;
  --r-radius-sm: 12px;
  --r-radius-xs: 8px;
  --r-shadow-widget: 0 25px 60px -12px rgba(0,0,0,0.15), 0 0 0 1px rgba(0,0,0,0.03);
  --r-shadow-trigger: 0 8px 28px rgba(242,107,34,0.35), 0 2px 8px rgba(242,107,34,0.15);
  --r-shadow-trigger-hover: 0 12px 36px rgba(242,107,34,0.45), 0 4px 12px rgba(242,107,34,0.2);
  --r-shadow-card: 0 1px 3px rgba(0,0,0,0.04), 0 0 0 1px rgba(0,0,0,0.03);
  --r-shadow-card-hover: 0 8px 24px rgba(242,107,34,0.1), 0 0 0 1px rgba(242,107,34,0.12);
  --r-width: 400px;
  --r-height: 660px;
  --r-font-display: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --r-font-body: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Scoped reset */
.radu-widget, .radu-widget * {
  margin: 0; padding: 0; box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.radu-widget { font-family: var(--r-font-body); }

/* === TRIGGER BUTTON === */
.radu-trigger {
  position: fixed; bottom: 24px; right: 24px; z-index: 99998;
  display: flex; align-items: flex-end; flex-direction: column; gap: 12px;
  -webkit-tap-highlight-color: transparent;
}
.radu-trigger-btn {
  width: 62px; height: 62px; border-radius: 18px;
  background: linear-gradient(145deg, #F57C3A 0%, #F26B22 40%, #D85A15 100%);
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--r-shadow-trigger);
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative; z-index: 2;
}
.radu-trigger-btn:hover {
  transform: scale(1.08) translateY(-3px);
  box-shadow: var(--r-shadow-trigger-hover);
}
.radu-trigger-btn:active { transform: scale(0.94); }
.radu-trigger-btn svg {
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s;
}
.radu-trigger-btn .radu-icon-close {
  position: absolute; opacity: 0; transform: rotate(-90deg) scale(0.5);
}
.radu-trigger-btn.is-open .radu-icon-chat {
  opacity: 0; transform: rotate(90deg) scale(0.5);
}
.radu-trigger-btn.is-open .radu-icon-close {
  opacity: 1; transform: rotate(0) scale(1);
}

/* Badge — hidden by default, shown on unread messages */
.radu-trigger-badge {
  position: absolute; top: -3px; right: -3px; width: 18px; height: 18px;
  background: #FF3B30; border-radius: 50%; border: 2.5px solid #fff; z-index: 3;
  display: none;
}
.radu-trigger-badge.has-unread {
  display: block;
  animation: radu-badgePop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), radu-badgePulse 2s 0.4s infinite;
}
.radu-trigger-btn.is-open .radu-trigger-badge { display: none; }
@keyframes radu-badgePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,59,48,0.4); }
  50% { box-shadow: 0 0 0 6px rgba(255,59,48,0); }
}
@keyframes radu-badgePop {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

/* Proactive bubble */
.radu-proactive {
  position: absolute; bottom: 74px; right: 0;
  background: var(--r-bg); border-radius: 16px 16px 4px 16px;
  padding: 12px 16px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.1), 0 0 0 1px rgba(0,0,0,0.03);
  width: max-content; max-width: min(320px, calc(100vw - 90px));
  font-size: 0.84rem; color: var(--r-text); line-height: 1.5;
  opacity: 0; transform: translateY(10px) scale(0.92);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); pointer-events: none;
}
.radu-proactive.is-visible {
  opacity: 1; transform: translateY(0) scale(1); pointer-events: auto;
}
.radu-proactive-close {
  position: absolute; top: 8px; right: 10px; background: none; border: none;
  cursor: pointer; color: var(--r-text-muted); font-size: 1.1rem; line-height: 1;
  padding: 2px 4px; border-radius: 4px; transition: background 0.15s;
}
.radu-proactive-close:hover { background: var(--r-surface); }
.radu-proactive-tag {
  display: inline-flex; align-items: center; gap: 5px;
  font-weight: 600; color: var(--r-orange); font-size: 0.7rem;
  letter-spacing: 0.04em; margin-bottom: 3px;
  font-family: var(--r-font-display); text-transform: uppercase;
}
.radu-proactive-tag::before {
  content: ''; width: 6px; height: 6px; background: var(--r-success); border-radius: 50%;
}

/* === BACKDROP === */
.radu-backdrop {
  position: fixed; inset: 0; z-index: 99997;
  background: rgba(0, 0, 0, 0.3);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.radu-backdrop.is-visible { opacity: 1; pointer-events: auto; }
@media (min-width: 481px) {
  .radu-backdrop { background: rgba(0,0,0,0.15); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
}

/* === CHAT WINDOW === */
.radu-window {
  position: fixed; bottom: 100px; right: 24px;
  width: var(--r-width); height: var(--r-height);
  max-height: calc(100vh - 120px); max-width: calc(100vw - 32px);
  background: var(--r-bg); border-radius: var(--r-radius);
  box-shadow: var(--r-shadow-widget); border: 1px solid rgba(0,0,0,0.04);
  display: flex; flex-direction: column; overflow: hidden; z-index: 99999;
  opacity: 0; transform: translateY(20px) scale(0.95); pointer-events: none;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.radu-window.is-open {
  opacity: 1; transform: translateY(0) scale(1); pointer-events: auto;
}

/* --- HEADER --- */
.radu-header {
  background: linear-gradient(140deg, #F57C3A 0%, #F26B22 35%, #D85A15 65%, #C04D0E 100%);
  padding: 0; flex-shrink: 0; position: relative; overflow: hidden;
}
.radu-header::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 15% 30%, rgba(255,255,255,0.15) 0%, transparent 50%),
    radial-gradient(circle at 85% 70%, rgba(0,0,0,0.1) 0%, transparent 40%);
  pointer-events: none;
}
.radu-header::after {
  content: ''; position: absolute; inset: 0; opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0L40 20L20 40L0 20Z' fill='%23fff' fill-opacity='1'/%3E%3C/svg%3E");
  background-size: 22px 22px; pointer-events: none;
}
.radu-header-inner {
  position: relative; z-index: 1;
  padding: 16px 16px 16px 18px;
  display: flex; align-items: center; gap: 12px;
}
.radu-avatar {
  width: 42px; height: 42px; border-radius: 13px;
  background: rgba(255,255,255,0.18);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-size: 1.2rem;
  border: 1.5px solid rgba(255,255,255,0.2);
}
.radu-avatar svg { filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15)); }
.radu-header-info { flex: 1; min-width: 0; }
.radu-header-name {
  color: #fff; font-weight: 700; font-size: 0.95rem; line-height: 1.2;
  font-family: var(--r-font-display);
  text-shadow: 0 1px 3px rgba(0,0,0,0.12);
}
.radu-header-status {
  color: rgba(255,255,255,0.8); font-size: 0.68rem;
  display: flex; align-items: center; gap: 6px; margin-top: 3px; font-weight: 400;
}
.radu-status-dot {
  width: 7px; height: 7px; background: #6EE7B7; border-radius: 50%;
  box-shadow: 0 0 8px rgba(110,231,183,0.6);
  animation: radu-statusPulse 2.5s infinite;
}
@keyframes radu-statusPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

.radu-header-close {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all 0.2s; flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.radu-header-close:hover { background: rgba(255,255,255,0.25); }
.radu-header-close:active { transform: scale(0.9); }
.radu-header-close:focus-visible {
  outline: 2px solid rgba(255,255,255,0.6);
  outline-offset: 2px;
}

/* --- MESSAGES --- */
.radu-messages {
  flex: 1; overflow-y: auto;
  padding: 18px 14px 12px;
  display: flex; flex-direction: column; gap: 6px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: var(--r-surface-warm);
  background-image: linear-gradient(to bottom, rgba(254,240,231,0.4) 0%, transparent 100px);
}
.radu-messages::-webkit-scrollbar { width: 3px; }
.radu-messages::-webkit-scrollbar-track { background: transparent; }
.radu-messages::-webkit-scrollbar-thumb { background: var(--r-border); border-radius: 3px; }

.radu-msg {
  max-width: 88%;
  animation: radu-msgIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes radu-msgIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
.radu-msg-bot { align-self: flex-start; }
.radu-msg-user { align-self: flex-end; }

/* Bubbles */
.radu-bubble {
  padding: 11px 15px; font-size: 0.86rem;
  line-height: 1.55; word-break: break-word;
}
.radu-msg-bot .radu-bubble {
  background: var(--r-bg); color: var(--r-text);
  border-radius: 4px 18px 18px 18px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05), 0 0 0 1px rgba(0,0,0,0.03);
}
.radu-msg-user .radu-bubble {
  background: linear-gradient(145deg, #F57C3A 0%, #F26B22 40%, #E05A14 100%);
  color: #fff;
  border-radius: 18px 18px 4px 18px;
  box-shadow: 0 2px 10px rgba(242,107,34,0.2);
}
.radu-bubble strong { font-weight: 600; color: var(--r-text); }
.radu-msg-user .radu-bubble strong { color: #fff; }
.radu-bubble a {
  color: var(--r-orange-dark); text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: rgba(242,107,34,0.3); font-weight: 500;
  transition: text-decoration-color 0.2s;
}
.radu-bubble a:hover { text-decoration-color: var(--r-orange); }
.radu-msg-user .radu-bubble a {
  color: rgba(255,255,255,0.95);
  text-decoration-color: rgba(255,255,255,0.4);
}

/* Quick actions */
.radu-actions {
  display: flex; flex-wrap: wrap; gap: 7px; padding: 10px 0 14px;
  animation: radu-msgIn 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.radu-action-btn {
  background: var(--r-bg); border: 1.5px solid var(--r-border);
  color: var(--r-text);
  border-radius: 100px; padding: 9px 18px;
  font-size: 0.82rem; font-weight: 500;
  cursor: pointer; transition: all 0.2s ease; white-space: nowrap;
  font-family: var(--r-font-body); line-height: 1.3;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
  -webkit-tap-highlight-color: transparent;
}
.radu-action-btn:hover {
  border-color: var(--r-orange); color: var(--r-orange);
  background: var(--r-orange-light);
  box-shadow: 0 3px 12px rgba(242,107,34,0.1);
  transform: translateY(-1px);
}
.radu-action-btn:active { transform: scale(0.96); }
.radu-action-btn:focus-visible {
  outline: 2px solid var(--r-orange);
  outline-offset: 2px;
}
.radu-action-btn--primary {
  background: var(--r-orange-light);
  border-color: rgba(242,107,34,0.3); color: var(--r-orange);
  font-weight: 600;
  animation: radu-primary-attention 2.5s ease-in-out infinite;
}
@keyframes radu-primary-attention {
  0%, 100% { box-shadow: 0 1px 2px rgba(0,0,0,0.03); }
  50% { box-shadow: 0 2px 14px rgba(242,107,34,0.18); }
}
.radu-action-btn--primary:hover { background: var(--r-orange); color: #fff; animation: none; }
.radu-action-btn--home {
  border: none;
  color: var(--r-text-muted);
  font-weight: 500;
  font-size: 0.74rem;
  background: transparent;
  padding: 6px 14px;
  opacity: 0.7;
  width: 100%;
  justify-content: center;
  display: flex;
}
.radu-action-btn--home:hover {
  color: var(--r-orange);
  background: var(--r-orange-light); opacity: 1;
}

/* Quick reply chips — smaller, pill-shaped, subtle */
.radu-chips {
  display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 0 10px;
  animation: radu-msgIn 0.2s ease;
}
.radu-chip {
  display: inline-flex; align-items: center;
  padding: 6px 14px;
  border-radius: 100px;
  border: 1px solid rgba(242,107,34,0.25);
  background: rgba(242,107,34,0.06);
  color: var(--r-orange);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
  line-height: 1.3;
}
.radu-chip:hover {
  background: var(--r-orange);
  color: #fff;
  border-color: var(--r-orange);
  transform: translateY(-1px);
}
.radu-chip:active { transform: scale(0.96); }

/* Product cards */
.radu-products {
  display: flex; flex-direction: column; gap: 6px;
  padding: 6px 0;
  animation: radu-msgIn 0.3s ease;
}
.radu-product-card {
  background: var(--r-bg); border-radius: var(--r-radius-sm);
  padding: 0; display: flex; gap: 0; align-items: stretch;
  transition: all 0.2s ease;
  color: var(--r-text); box-shadow: var(--r-shadow-card);
  overflow: hidden; position: relative;
  border: 1px solid var(--r-border-light);
}
.radu-product-card:hover {
  box-shadow: var(--r-shadow-card-hover);
  border-color: rgba(242,107,34,0.15);
  transform: translateY(-2px);
}
.radu-product-card:active {
  transform: scale(0.98);
  transition-duration: 0.1s;
}
.radu-product-img-wrap {
  width: 82px; min-height: 82px; flex-shrink: 0;
  background: var(--r-surface); position: relative;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.radu-product-img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.3s ease;
}
/* Image zoom on link hover handled by .radu-product-link:hover rule */
.radu-product-img-ph {
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--r-orange-light) 0%, #fff4ec 100%);
  display: none; align-items: center; justify-content: center;
  font-size: 0.6rem; font-weight: 800; color: var(--r-orange);
  font-family: var(--r-font-display); letter-spacing: 0.05em;
}
.radu-product-info {
  flex: 1; min-width: 0; padding: 10px 14px;
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
}
.radu-product-name {
  font-size: 0.82rem; font-weight: 600;
  overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  line-height: 1.35; font-family: var(--r-font-display);
}
.radu-product-meta {
  font-size: 0.72rem; color: var(--r-text-secondary); margin-top: 1px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.radu-product-price {
  font-weight: 700; color: var(--r-orange); font-size: 0.92rem;
  white-space: nowrap; font-family: var(--r-font-display);
}
.radu-product-old-price {
  text-decoration: line-through; color: var(--r-text-muted);
  font-size: 0.72rem; font-weight: 400;
}
.radu-sale-badge {
  display: inline-flex; align-items: center;
  font-size: 0.6rem; font-weight: 700; padding: 2px 7px;
  border-radius: 6px; text-transform: uppercase; letter-spacing: 0.04em;
  background: #FDE8E8; color: var(--r-danger);
}
.radu-stock-badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 0.6rem; font-weight: 600; padding: 2px 8px;
  border-radius: 6px;
  background: var(--r-success-bg); color: var(--r-success);
  text-transform: uppercase; letter-spacing: 0.03em;
}
.radu-stock-badge::before {
  content: ''; width: 5px; height: 5px;
  background: currentColor; border-radius: 50%;
}

/* Contact cards */
.radu-contact-grid {
  display: flex; flex-direction: column; gap: 8px;
  padding: 6px 0 10px;
  animation: radu-msgIn 0.3s ease;
}
.radu-contact-card {
  background: var(--r-bg); border-radius: var(--r-radius-sm);
  padding: 14px 16px; display: flex; align-items: center; gap: 14px;
  cursor: pointer; text-decoration: none; color: var(--r-text);
  box-shadow: var(--r-shadow-card); transition: all 0.2s;
  border: 1px solid transparent;
}
.radu-contact-card:hover {
  box-shadow: var(--r-shadow-card-hover);
  border-color: var(--r-orange); transform: translateY(-1px);
}
.radu-contact-card__icon {
  width: 42px; height: 42px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.radu-contact-card__icon--phone { background: linear-gradient(135deg, #93C5FD 0%, #60A5FA 100%); }
.radu-contact-card__icon--email { background: linear-gradient(135deg, #FDE68A 0%, #FCD34D 100%); }
.radu-contact-card__text { flex: 1; }
.radu-contact-card__label {
  font-size: 0.84rem; font-weight: 600; color: var(--r-text);
  font-family: var(--r-font-display); line-height: 1.3;
}
.radu-contact-card__sub {
  font-size: 0.72rem; color: var(--r-text-secondary); margin-top: 1px;
}
.radu-contact-card__arrow {
  color: var(--r-text-muted); flex-shrink: 0;
  transition: transform 0.2s, color 0.2s;
}
.radu-contact-card:hover .radu-contact-card__arrow {
  color: var(--r-orange); transform: translateX(3px);
}

/* Typing indicator */
.radu-typing {
  display: flex; align-items: center; gap: 4px;
  padding: 12px 18px; background: var(--r-bg);
  border-radius: 4px 18px 18px 18px; width: fit-content;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05), 0 0 0 1px rgba(0,0,0,0.03);
  align-self: flex-start;
  animation: radu-msgIn 0.2s ease;
}
.radu-typing-dot {
  width: 7px; height: 7px; background: var(--r-orange);
  border-radius: 50%; opacity: 0.4;
  animation: radu-bounce 1.4s infinite ease-in-out;
}
.radu-typing-dot:nth-child(2) { animation-delay: 0.16s; }
.radu-typing-dot:nth-child(3) { animation-delay: 0.32s; }
@keyframes radu-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-5px); opacity: 1; }
}

/* Input bar */
.radu-input-bar {
  padding: 10px 14px 12px; border-top: 1px solid var(--r-border-light);
  display: flex; gap: 10px; align-items: center;
  flex-shrink: 0; background: var(--r-bg);
  max-width: 100%; overflow: hidden;
}
.radu-input-wrap { flex: 1; position: relative; min-width: 0; }
.radu-input {
  width: 100%; border: 1.5px solid var(--r-border); border-radius: 100px;
  padding: 11px 18px; font-size: 0.92rem; font-family: var(--r-font-body);
  color: var(--r-text); outline: none; transition: all 0.2s;
  background: var(--r-surface);
  -webkit-appearance: none; appearance: none;
}
.radu-input:focus {
  border-color: var(--r-orange); background: var(--r-bg);
  box-shadow: 0 0 0 3px rgba(242,107,34,0.15);
}
.radu-input:focus-visible {
  outline: none;
}
.radu-input::placeholder { color: var(--r-text-muted); }
.radu-send-btn {
  width: 44px; height: 44px; border-radius: 50%;
  background: linear-gradient(145deg, #F57C3A 0%, #F26B22 40%, #E05A14 100%);
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s; flex-shrink: 0;
  box-shadow: 0 3px 10px rgba(242,107,34,0.2);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.radu-send-btn:hover {
  transform: translateY(-1px); box-shadow: 0 5px 16px rgba(242,107,34,0.3);
}
.radu-send-btn:active { transform: scale(0.92); }
.radu-send-btn:disabled { opacity: 0.35; cursor: not-allowed; transform: none; }
.radu-send-btn:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
  box-shadow: 0 3px 10px rgba(242,107,34,0.2), 0 0 0 5px rgba(242,107,34,0.12);
}

/* Footer */
.radu-footer {
  text-align: center; padding: 7px 14px; font-size: 0.6rem;
  color: var(--r-text-muted); flex-shrink: 0; background: var(--r-bg);
  font-weight: 400; letter-spacing: 0.01em; line-height: 1.5;
}
.radu-footer a { color: var(--r-orange); text-decoration: none; font-weight: 600; }

/* Body scroll lock */
html.radu-scroll-locked,
html.radu-scroll-locked body {
  overflow: hidden !important; position: relative; height: 100%;
}

/* === MOBILE — bottom sheet === */
@media (max-width: 480px) {
  .radu-window {
    bottom: 0; right: 0; left: 0;
    width: 100vw; max-width: 100vw;
    height: calc(var(--r-vh, 1vh) * 85); max-height: calc(var(--r-vh, 1vh) * 100);
    border-radius: 20px 20px 0 0; border: none;
    transform: translateY(100%) scale(1); opacity: 1;
    box-shadow: 0 -8px 40px rgba(0,0,0,0.12);
  }
  .radu-window.is-open {
    transform: translateY(0) scale(1); opacity: 1;
  }
  .radu-window.keyboard-open {
    height: calc(var(--r-vh, 1vh) * 100);
    max-height: calc(var(--r-vh, 1vh) * 100);
    border-radius: 0;
  }
  .radu-drag-handle {
    display: block;
    width: 36px; height: 4px;
    background: rgba(255,255,255,0.35); border-radius: 2px;
    margin: 8px auto 0; position: relative; z-index: 2;
  }
.radu-trigger { bottom: 135px; right: 16px; }
  .radu-trigger-btn { width: 56px; height: 56px; border-radius: 16px; }
  .radu-header-inner { padding-top: max(12px, env(safe-area-inset-top)); }
  .radu-footer { padding-bottom: max(7px, env(safe-area-inset-bottom)); font-size: 0.56rem; }
  .radu-window.keyboard-open .radu-footer { display: none; }
  .radu-input-bar { padding: 8px 10px; padding-bottom: max(10px, env(safe-area-inset-bottom)); gap: 8px; }
  .radu-window.keyboard-open .radu-input-bar { padding-bottom: 6px; }
  .radu-input { padding: 10px 16px; font-size: 1rem; }
  .radu-send-btn { width: 44px; height: 44px; min-width: 44px; }
  .radu-send-btn svg { width: 18px; height: 18px; }
  .radu-messages { padding: 16px 12px 10px; gap: 5px; }
  .radu-action-btn { padding: 10px 16px; font-size: 0.84rem; }
  .radu-chip { padding: 8px 16px; font-size: 0.82rem; }
  /* Smooth animations on mobile */
  .radu-msg, .radu-actions, .radu-products, .radu-product-card, .radu-chips { animation-duration: 0.25s !important; }
}

/* Hide drag handle on desktop */
.radu-drag-handle { display: none; }

/* === PRODUCT CARD LAYOUT — link + ATC button === */
.radu-product-card {
  display: flex; align-items: stretch; gap: 0;
}
.radu-product-link {
  display: flex; gap: 0; align-items: stretch;
  flex: 1; min-width: 0;
  text-decoration: none; color: var(--r-text);
}
.radu-product-link:hover .radu-product-img { transform: scale(1.05); }

/* === ADD-TO-CART BUTTON === */
.radu-atc-btn {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  padding: 0 16px; min-width: 56px;
  background: linear-gradient(160deg, #FF8A3D 0%, #F26B22 50%, #E55D12 100%);
  color: #fff;
  border: none;
  font-size: 0.68rem; font-weight: 700; font-family: var(--r-font-display);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none; white-space: nowrap;
  letter-spacing: 0.03em; text-transform: uppercase;
  position: relative; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
}
.radu-atc-btn::after {
  content: '';
  position: absolute; top: 0; left: -120%;
  width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.3) 50%, transparent 100%);
  animation: radu-shimmer 3.5s ease-in-out infinite;
  pointer-events: none;
  transform: skewX(-15deg);
}
@keyframes radu-shimmer {
  0% { left: -120%; }
  35%, 100% { left: 120%; }
}
.radu-atc-btn:hover {
  background: linear-gradient(160deg, #FFA05C 0%, #FF7A2E 50%, #F26B22 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 4px 20px rgba(242,107,34,0.35);
  transform: scale(1.03);
}
.radu-atc-btn:active { transform: scale(0.96); }
.radu-atc-icon { flex-shrink: 0; position: relative; z-index: 1; filter: drop-shadow(0 1px 1px rgba(0,0,0,0.1)); }
.radu-atc-btn > span { position: relative; z-index: 1; text-shadow: 0 1px 2px rgba(0,0,0,0.1); }

/* ATC states */
.radu-atc-btn--loading {
  background: linear-gradient(160deg, #B0B7C3 0%, #969DAB 100%);
  pointer-events: none;
}
.radu-atc-btn--loading::after { animation: none; }
.radu-atc-btn--success {
  background: linear-gradient(160deg, #34D399 0%, #16A34A 100%);
  pointer-events: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 3px 12px rgba(34,197,94,0.25);
}
.radu-atc-btn--success::after { animation: none; }
.radu-atc-btn--view-cart {
  background: linear-gradient(160deg, #FF8A3D 0%, #F26B22 50%, #E55D12 100%);
  pointer-events: auto; cursor: pointer;
  animation: radu-cart-glow 2s ease-in-out infinite;
}
.radu-atc-btn--view-cart::after {
  animation: radu-shimmer 2.5s ease-in-out infinite;
}
.radu-atc-btn--view-cart:hover {
  animation: none;
  box-shadow: 0 4px 24px rgba(242,107,34,0.5);
  transform: scale(1.05);
}
@keyframes radu-cart-glow {
  0%, 100% { box-shadow: 0 2px 8px rgba(242,107,34,0.2); }
  50% { box-shadow: 0 4px 20px rgba(242,107,34,0.45), 0 0 0 3px rgba(242,107,34,0.08); }
}
.radu-atc-btn--error {
  background: linear-gradient(160deg, #EF4444 0%, #DC2626 100%);
  pointer-events: none;
}
.radu-atc-btn--error::after { animation: none; }
.radu-atc-btn--link {
  background: var(--r-surface); color: var(--r-text-secondary);
  font-weight: 600; text-transform: none; box-shadow: none;
}
.radu-atc-btn--link::after { display: none; }
.radu-atc-btn--link:hover {
  background: var(--r-orange-light); color: var(--r-orange);
  box-shadow: none; transform: none;
}

/* ATC spinner */
.radu-atc-spinner {
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: radu-spin 0.6s linear infinite;
  position: relative; z-index: 1;
}
@keyframes radu-spin { to { transform: rotate(360deg); } }

/* === STOCK URGENCY BADGES === */
.radu-stock-badge--urgent {
  background: #FEE2E2; color: var(--r-danger);
  animation: radu-urgency-pulse 2s ease-in-out infinite;
}
.radu-stock-badge--urgent::before { background: var(--r-danger); }
.radu-stock-badge--low {
  background: #FEF3C7; color: #D97706;
}
.radu-stock-badge--low::before { background: #D97706; }
@keyframes radu-urgency-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* === SHIPPING NUDGE BANNER === */
.radu-shipping-nudge {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; margin: 4px 0;
  background: linear-gradient(135deg, #FFF7ED 0%, #FFEDD5 100%);
  border-radius: var(--r-radius-xs);
  border: 1px solid rgba(242,107,34,0.12);
  animation: radu-msgIn 0.3s ease;
}
.radu-shipping-nudge__text {
  font-size: 0.78rem; font-weight: 600;
  color: var(--r-orange-dark);
  font-family: var(--r-font-display);
  line-height: 1.4;
}
.radu-shipping-nudge--free {
  background: linear-gradient(135deg, #ECFDF5 0%, #D1FAE5 100%);
  border-color: rgba(34,197,94,0.15);
}
.radu-shipping-nudge--free .radu-shipping-nudge__text {
  color: #16A34A;
}

/* === MOBILE OVERRIDES === */
@media (max-width: 480px) {
  .radu-atc-btn {
    padding: 0 12px; min-width: 48px;
    font-size: 0; /* Icon-only on mobile */
  }
  .radu-atc-btn .radu-atc-icon { display: block; width: 18px; height: 18px; }
  .radu-atc-btn > span { display: none; }
  .radu-atc-btn--success,
  .radu-atc-btn--loading,
  .radu-atc-btn--error {
    font-size: 0.6rem;
  }
  .radu-atc-btn--success > span,
  .radu-atc-btn--loading > span,
  .radu-atc-btn--error > span { display: inline; }
  .radu-atc-btn--view-cart { font-size: 0.6rem; padding: 0 10px; }
  .radu-atc-btn--view-cart > span { display: inline; }
  .radu-atc-btn--link { font-size: 0.64rem; }
  .radu-atc-btn--link > span { display: inline; }
  .radu-shipping-nudge { padding: 8px 12px; }
  .radu-shipping-nudge__text { font-size: 0.72rem; }
  .radu-stock-badge--urgent { animation: none; }
}
