/* ===== RESET & BASE ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --orange-primary: #FF6B00;
  --orange-light: #FF8C00;
  --orange-glow: rgba(255, 107, 0, 0.35);
  --orange-glow-soft: rgba(255, 107, 0, 0.15);
  --bg-deep: #0a0a0a;
  --bg-panel: #111111;
  --bg-card: #1a1a1a;
  --bg-input: #1e1e1e;
  --bg-hover: #222222;
  --text-primary: #f0f0f0;
  --text-secondary: #888888;
  --text-muted: #555555;
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-orange: rgba(255, 107, 0, 0.25);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --sidebar-width: 320px;
  --header-height: 82.5px;
  --input-height: 72px;
}

html, body {
  height: 100%;
  font-family: 'Share Tech', sans-serif;
  background: var(--bg-deep);
  color: var(--text-primary);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ===== LAYOUT ===== */
#app {
  display: flex;
  height: 100vh;
  height: 100dvh;
  width: 100%;
}

/* ===== SIDEBAR ===== */
#sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--bg-panel);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 20;
  transition: transform 0.3s ease;
}

.sidebar-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-height);
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.sidebar-logo-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background:transparent;
  display: block;
  object-fit: contain;
}

.sidebar-logo-text {
  font-size: 20px;
  letter-spacing: 2px;
  color: var(--text-primary);
  font-weight: normal;
}

.sidebar-logo-text span {
  color: var(--orange-primary);
}

.btn-add-webhook {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-orange);
  background: transparent;
  color: var(--orange-primary);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-family: 'Share Tech', sans-serif;
}

.btn-add-webhook:hover {
  background: rgba(255, 107, 0, 0.1);
  box-shadow: 0 0 15px var(--orange-glow-soft);
}

.sidebar-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
}

.sidebar-list::-webkit-scrollbar {
  width: 4px;
}

.sidebar-list::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar-list::-webkit-scrollbar-thumb {
  background: var(--text-muted);
  border-radius: 4px;
}

/* ===== WEBHOOK CARD ===== */
.webhook-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.webhook-card:hover {
  border-color: var(--border-orange);
  background: var(--bg-hover);
}

.webhook-card.active {
  border-color: var(--orange-primary);
  box-shadow: 0 0 20px var(--orange-glow-soft), inset 0 0 30px rgba(255, 107, 0, 0.03);
  animation: cardGlow 3s ease-in-out infinite;
}

@keyframes cardGlow {
  0%, 100% { box-shadow: 0 0 15px var(--orange-glow-soft), inset 0 0 30px rgba(255, 107, 0, 0.03); }
  50% { box-shadow: 0 0 25px var(--orange-glow), inset 0 0 30px rgba(255, 107, 0, 0.05); }
}

.webhook-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.webhook-name {
  font-size: 15px;
  color: var(--text-primary);
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

.webhook-card.active .webhook-name {
  color: var(--orange-primary);
  text-shadow: 0 0 10px var(--orange-glow-soft);
}

.webhook-card-actions {
  display: flex;
  gap: 4px;
}

.btn-icon {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: all 0.15s ease;
}

.btn-icon:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.btn-icon.delete:hover {
  color: #ff4444;
  background: rgba(255, 68, 68, 0.1);
}

.btn-icon img {
  width: 16px;
  height: 16px;
  object-fit: contain;
  vertical-align: middle;
  pointer-events: none;
  opacity: 0.6;
  transition: opacity 0.15s ease, filter 0.15s ease;
}

.btn-icon:hover img {
  opacity: 1;
}

.btn-icon img.visible {
  opacity: 1;
  filter: drop-shadow(0 0 2px var(--orange-glow));
}

.webhook-url-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

.webhook-url-display {
  flex: 1;
  font-family: 'Share Tech Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  background: var(--bg-deep);
  padding: 6px 10px;
  border-radius: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: 1px solid var(--border-subtle);
}

.btn-open-chat {
  width: 100%;
  padding: 8px 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-orange);
  background: transparent;
  color: var(--orange-primary);
  font-family: 'Share Tech', sans-serif;
  font-size: 13px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-open-chat:hover {
  background: rgba(255, 107, 0, 0.1);
  box-shadow: 0 0 15px var(--orange-glow-soft);
}

.webhook-card.active .btn-open-chat {
  background: linear-gradient(135deg, var(--orange-primary), var(--orange-light));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 0 20px var(--orange-glow-soft);
}

/* ===== SIDEBAR EMPTY STATE ===== */
.sidebar-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  text-align: center;
}

.empty-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px dashed var(--border-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-bottom: 20px;
  color: var(--orange-primary);
  opacity: 0.6;
}

.empty-title {
  font-size: 16px;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}

.empty-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 24px;
}

.btn-add-first {
  padding: 10px 28px;
  border-radius: var(--radius-sm);
  border: none;
  background: linear-gradient(135deg, var(--orange-primary), var(--orange-light));
  color: #fff;
  font-family: 'Share Tech', sans-serif;
  font-size: 14px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 0 20px var(--orange-glow-soft);
}

.btn-add-first:hover {
  box-shadow: 0 0 30px var(--orange-glow);
  transform: translateY(-1px);
}

/* ===== SIDEBAR FOOTER ===== */
.sidebar-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-subtle);
  text-align: center;
}

.sidebar-footer-text {
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 1px;
}

.sidebar-count {
  color: var(--orange-primary);
}

/* ===== MAIN CHAT AREA ===== */
#main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-deep);
  min-width: 0;
  position: relative;
}

/* ===== CHAT HEADER ===== */
.chat-header {
  height: var(--header-height);
  min-height: var(--header-height);
  padding: 0 24px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-panel);
}

.chat-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-menu-toggle {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-primary);
  font-size: 18px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.btn-menu-toggle:hover {
  border-color: var(--border-orange);
  color: var(--orange-primary);
}

.chat-assistant-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--orange-primary);
  box-shadow: 0 0 10px var(--orange-glow);
  animation: indicatorPulse 2s ease-in-out infinite;
}

@keyframes indicatorPulse {
  0%, 100% { box-shadow: 0 0 8px var(--orange-glow-soft); }
  50% { box-shadow: 0 0 16px var(--orange-glow); }
}

.chat-assistant-name {
  font-size: 16px;
  letter-spacing: 1px;
}

.chat-header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-clear-chat {
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-secondary);
  font-family: 'Share Tech', sans-serif;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-clear-chat:hover {
  border-color: rgba(255, 68, 68, 0.3);
  color: #ff6666;
  background: rgba(255, 68, 68, 0.05);
}

.btn-docs {
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-secondary);
  font-family: 'Share Tech', sans-serif;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.btn-docs:hover {
  border-color: var(--border-orange);
  color: var(--orange-primary);
  background: rgba(255, 107, 0, 0.05);
}

/* ===== CHAT MESSAGES ===== */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.chat-messages-inner {
  width: 100%;
  max-width: 720px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.chat-messages::-webkit-scrollbar {
  width: 5px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--text-muted);
  border-radius: 4px;
}

/* ===== CHAT WELCOME ===== */
.chat-welcome {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
}

.chat-welcome-icon {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(255, 107, 0, 0.1), rgba(255, 140, 0, 0.05));
  border: 1px solid var(--border-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  margin-bottom: 24px;
  box-shadow: 0 0 40px var(--orange-glow-soft);
}

.chat-welcome-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.chat-welcome h2 {
  font-size: 22px;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: 1px;
  font-weight: normal;
}

.chat-welcome p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 400px;
}

/* ===== MESSAGE BUBBLES ===== */
.msg-row {
  display: flex;
  animation: msgFadeIn 0.3s ease forwards;
  opacity: 0;
}

@keyframes msgFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.msg-row.user {
  justify-content: flex-end;
}

.msg-row.assistant {
  justify-content: flex-start;
}

.msg-row > div {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  max-width: 80%;
}

.msg-row.user > div {
  flex-direction: row-reverse;
}

.msg-bubble {
  padding: 10px 16px;
  border-radius: var(--radius-md);
  font-size: 14px;
  line-height: 1.6;
  word-wrap: break-word;
  white-space: pre-wrap;
  position: relative;
}

.msg-row.user .msg-bubble {
  background: linear-gradient(135deg, var(--orange-primary), var(--orange-light));
  color: #fff;
  border-bottom-right-radius: 4px;
  box-shadow: 0 4px 20px rgba(255, 107, 0, 0.2);
}

.msg-row.assistant .msg-bubble {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-bottom-left-radius: 4px;
}

.msg-time {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  white-space: nowrap;
  flex-shrink: 0;
  padding-bottom: 2px;
}

.msg-row.user .msg-time {
  color: rgba(255, 255, 255, 0.4);
}

/* Typing indicator */
.typing-indicator {
  display: flex;
  gap: 5px;
  padding: 4px 0;
}

.typing-indicator span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  animation: typingBounce 1.2s ease-in-out infinite;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.15s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.3s; }

@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-6px); opacity: 1; }
}

/* ===== CHAT INPUT BAR ===== */
.chat-input-bar {
  padding: 16px 24px;
}

.chat-input-wrapper {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 6px 6px 6px 18px;
  transition: all 0.25s ease;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
}

.chat-input-wrapper:focus-within {
  border-color: var(--orange-primary);
  box-shadow: 0 0 20px var(--orange-glow-soft), 0 0 20px rgba(255, 106, 0, 0.329);
}

.chat-input-wrapper textarea {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-family: 'Share Tech', sans-serif;
  font-size: 15px;
  letter-spacing: 0.3px;
  resize: none;
  height: 24px;
  max-height: 200px;
  margin: 9px 0;
  line-height: 20px;
  overflow-y: auto;
}

.chat-input-wrapper textarea::placeholder {
  color: var(--text-muted);
}

.btn-send {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  border: none;
  background: linear-gradient(135deg, var(--orange-primary), var(--orange-light));
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-send:hover {
  box-shadow: 0 0 25px var(--orange-glow);
  transform: scale(1.04);
}

.btn-send:active {
  transform: scale(0.96);
}

.btn-send:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ===== NO WEBHOOK SELECTED STATE (LANDING) ===== */
.no-webhook-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 40px 24px;
}

.landing-logo {
  width: 72px;
  height: 72px;
  margin-bottom: 16px;
  filter: drop-shadow(0 0 15px var(--orange-glow-soft));
  animation: logoFloat 4s ease-in-out infinite;
}

@keyframes logoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); filter: drop-shadow(0 0 20px var(--orange-glow)); }
}

.landing-title {
  font-size: 32px;
  letter-spacing: 3px;
  color: var(--text-primary);
  margin-bottom: 16px;
  text-align: center;
  font-weight: normal;
}

.landing-title span {
  color: var(--orange-primary);
}

.landing-desc {
  font-size: 14.5px;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
  margin-bottom: 35px;
  max-width: 480px;
}

.landing-uses {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 40px;
}

.use-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.use-item:hover {
  border-color: var(--orange-primary);
  transform: translateY(-2px);
  box-shadow: 0 0 12px var(--orange-glow-soft);
}

.use-icon {
  background: var(--bg-deep);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.use-icon img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.use-text {
  text-align: left;
}

.use-text strong {
  display: block;
  font-size: 14px;
  color: var(--text-primary);
  margin-bottom: 4px;
  font-weight: normal;
  letter-spacing: 0.5px;
}

.use-text p {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.landing-action-info {
  font-size: 13.5px;
  color: var(--orange-primary);
  border: 1px dashed var(--border-orange);
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.5px;
  background: var(--orange-glow-soft);
  animation: actionPulse 2s infinite;
  text-align: center;
}

@keyframes actionPulse {
  0%, 100% { opacity: 0.85; box-shadow: 0 0 10px rgba(255, 107, 0, 0.05); }
  50% { opacity: 1; box-shadow: 0 0 20px var(--orange-glow-soft); }
}

/* ===== MODAL OVERLAY ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s ease;
}

.modal-overlay.visible {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-panel);
  border: 1px solid var(--border-orange);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 420px;
  max-width: 90vw;
  box-shadow: 0 0 60px var(--orange-glow-soft), 0 20px 60px rgba(0,0,0,0.5);
  transform: translateY(20px) scale(0.97);
  transition: transform 0.25s ease;
}

.modal-overlay.visible .modal {
  transform: translateY(0) scale(1);
}

.modal-title {
  font-size: 18px;
  letter-spacing: 1px;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.modal-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  letter-spacing: 1px;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.form-input {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: 'Share Tech', sans-serif;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus {
  border-color: var(--orange-primary);
  box-shadow: 0 0 12px var(--orange-glow-soft);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 28px;
}

.btn-modal {
  flex: 1;
  padding: 10px 0;
  border-radius: var(--radius-sm);
  border: none;
  font-family: 'Share Tech', sans-serif;
  font-size: 14px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-modal.cancel {
  background: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
}

.btn-modal.cancel:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.btn-modal.save {
  background: linear-gradient(135deg, var(--orange-primary), var(--orange-light));
  color: #fff;
  box-shadow: 0 0 15px var(--orange-glow-soft);
}

.btn-modal.save:hover {
  box-shadow: 0 0 25px var(--orange-glow);
}

/* ===== MOBILE SIDEBAR OVERLAY ===== */
.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 15;
}

/* ===== ERROR TOAST ===== */
.toast {
  position: absolute;
  top: 76px;
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  background: var(--bg-card);
  border: 1px solid rgba(255, 68, 68, 0.3);
  color: #ff6666;
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-family: 'Share Tech', sans-serif;
  font-size: 13px;
  letter-spacing: 0.5px;
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s ease;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}

.toast.visible {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.toast.success {
  border-color: rgba(0, 200, 100, 0.3);
  color: #4cde80;
}

/* ===== CONFIRM DIALOG ===== */
.confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: 110;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
}

.confirm-overlay.visible {
  opacity: 1;
  visibility: visible;
}

.confirm-box {
  background: var(--bg-panel);
  border: 1px solid rgba(255, 68, 68, 0.2);
  border-radius: var(--radius-md);
  padding: 28px;
  width: 360px;
  max-width: 90vw;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.confirm-box h3 {
  font-size: 16px;
  font-weight: normal;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.confirm-box p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.confirm-box .modal-actions {
  margin-top: 0;
}

.btn-modal.danger {
  background: #cc3333;
  color: #fff;
}

.btn-modal.danger:hover {
  background: #dd4444;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  :root {
    --sidebar-width: 290px;
  }

  #sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    transform: translateX(-100%);
    z-index: 30;
    box-shadow: 10px 0 40px rgba(0,0,0,0.5);
  }

  #sidebar.open {
    transform: translateX(0);
  }

  .sidebar-backdrop.active {
    display: block;
  }

  .btn-menu-toggle {
    display: flex;
  }

  .msg-bubble {
    max-width: 85%;
  }

  .chat-input-wrapper textarea {
    max-height: 100px;
  }

  .chat-input-wrapper textarea,
  .form-input {
    font-size: 16px;
  }
}

@media (max-width: 480px) {
  .chat-messages {
    padding: 16px;
  }

  .chat-input-bar {
    padding: 12px 16px;
  }

  .chat-header {
    padding: 0 16px;
  }
}

/* ===== RATING STARS (FEEDBACK MODAL) ===== */
.rating-container {
  display: flex;
  flex-direction: row-reverse;
  justify-content: center;
  gap: 10px;
  margin: 10px 0;
}

.rating-container input {
  display: none;
}

.rating-container label {
  font-size: 28px;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s ease, transform 0.15s ease, text-shadow 0.15s ease;
}

.rating-container label:hover,
.rating-container label:hover ~ label,
.rating-container input:checked ~ label {
  color: var(--orange-primary);
  text-shadow: 0 0 10px var(--orange-glow);
  transform: scale(1.1);
}

.rating-container label:active {
  transform: scale(0.9);
}
