/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

.typing-dots span {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin: 0 2px;
  background: #999;
  border-radius: 50%;
  animation: typing-bounce 1.4s infinite both;
}
.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing-bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

.step-option-btn {
  background-color: var(--bs-primary);
  color: #fff;
  border: 1px solid transparent;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, color 0.2s, border-color 0.2s;
  opacity: 0;
  transform: translateY(8px);
  animation: step-option-enter 0.3s ease forwards, pill-pulse 5s ease-in-out infinite;
  position: relative;
  overflow: hidden;
}

.step-option-btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.4) 50%, transparent 70%);
  animation: pill-glare 5s ease-in-out infinite;
  animation-delay: calc(var(--pill-index, 0) * 0.3s);
}

@keyframes pill-pulse {
  0%, 85%, 100% { scale: 1; }
  92% { scale: 1.03; }
}

@keyframes pill-glare {
  0%, 85% { left: -100%; }
  100% { left: 200%; }
}

.step-option-btn:hover {
  background: #fff;
  color: var(--bs-primary);
  border-color: var(--bs-primary);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

@keyframes step-option-enter {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.step-option-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.step-option-card {
  background: #fff;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 16px 8px 12px;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
  opacity: 0;
  transform: translateY(8px);
  animation: step-option-enter 0.3s ease forwards;
}

.step-option-card:hover {
  border-color: var(--bs-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.step-option-card img,
.step-option-card .material-icons {
  height: 64px;
  width: auto;
  display: block;
  margin: 0 auto 8px;
  font-size: 48px;
  color: var(--bs-primary);
}

.step-option-card .step-option-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #333;
  line-height: 1.2;
  display: block;
}

.chat-bubble {
  animation: 0.3s ease;
}

.chat-bubble-assistant {
  background-color: #f8f9fa;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  animation-name: bubble-slide-left;
}

.chat-bubble-user {
  animation-name: bubble-slide-right;
}

@keyframes bubble-slide-left {
  from { transform: translateX(-12px); }
  to   { transform: translateX(0); }
}

@keyframes bubble-slide-right {
  from { transform: translateX(12px) scale(1.05); }
  to   { transform: translateX(0) scale(1); }
}

.chat-messages-area {
  background: linear-gradient(180deg, #f0f4f8 0%, #ffffff 100%);
}

.chat-messages-area > * {
  transition: opacity 0.4s ease;
}

@keyframes input-glow {
  0% { outline: 3px solid rgba(var(--bs-primary-rgb), 0); outline-offset: 0; }
  50% { outline: 3px solid rgba(var(--bs-primary-rgb), 0.4); outline-offset: 2px; }
  100% { outline: 3px solid rgba(var(--bs-primary-rgb), 0); outline-offset: 0; }
}

.input-glow {
  animation: input-glow 0.8s ease-out;
  border-radius: var(--bs-border-radius);
}

[data-controller="treppenlifte-chat"] .input-group:focus-within,
[data-controller="chatbot-chat"] .input-group:focus-within {
  border-radius: var(--bs-border-radius);
  box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
}

[data-controller="treppenlifte-chat"] .form-control:focus,
[data-controller="chatbot-chat"] .form-control:focus {
  box-shadow: none;
}

@keyframes send-launch {
  0% { transform: scale(1) rotate(0deg); }
  40% { transform: scale(0.85) rotate(-15deg); }
  70% { transform: scale(1.15) rotate(5deg); }
  100% { transform: scale(1) rotate(0deg); }
}

.send-launch .bi-send {
  display: inline-block;
  animation: send-launch 0.4s ease-out;
}

.chatbot-sidebar {
  top: 1rem;
}

@media (min-width: 992px) {
  .chatbot-sidebar {
    margin-top: -200px;
  }
}

/* Icon picker */

.icon-picker-dropdown {
  position: absolute;
  z-index: 1050;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  padding: 6px;
  max-height: 220px;
  overflow-y: auto;
}

.icon-picker-item {
  background: none;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 4px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon-picker-item:hover {
  background: #f0f4ff;
  border-color: var(--bs-primary);
}

.icon-picker-item .material-icons {
  font-size: 20px;
  color: #333;
  pointer-events: none;
}

/* Landing page */

.landing-page {
  background: #0b0b0f;
  font-family: 'Space Grotesk', sans-serif;
  overflow: hidden;
}

.landing-headline {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 700;
  color: #f0f0f5;
  line-height: 1.2;
  animation: landing-fade-up 0.8s ease both;
}

.landing-highlight {
  background: linear-gradient(135deg, #6e57ff, #a78bfa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.landing-subtext {
  color: #8a8a9a;
  font-size: 1.1rem;
  margin-top: 1rem;
  animation: landing-fade-up 0.8s 0.2s ease both;
}

.landing-promo-wrapper {
  position: absolute;
  right: -160px;
  top: calc(100% + 50px);
  display: flex;
  align-items: flex-end;
  gap: 0.2rem;
  animation: landing-fade-up 0.8s 0.7s ease both;
}

.landing-promo-text {
  font-family: 'Caveat', cursive;
  color: #8a8a9a;
  font-size: 1.55rem;
  margin: 0;
  margin-left: 1rem;
  line-height: 1.3;
  text-align: left;
  white-space: nowrap;
  position: relative;
  top: 1.2rem;
}

.landing-arrow {
  flex-shrink: 0;
}

.landing-arrow path {
  stroke-dasharray: 200;
  stroke-dashoffset: 200;
  animation: landing-draw 1.2s 1s ease forwards;
}

.landing-form {
  animation: landing-fade-up 0.8s 0.5s ease both;
}

.landing-input-group {
  display: flex;
  gap: 0;
  max-width: 520px;
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 20px rgba(110, 87, 255, 0.15);
  transition: box-shadow 0.3s;
}

.landing-input-group:focus-within {
  box-shadow: 0 0 30px rgba(110, 87, 255, 0.35);
}

.landing-input {
  background: #16161d !important;
  border: 1px solid #2a2a3a !important;
  border-right: none !important;
  color: #f0f0f5 !important;
  font-size: 1.05rem;
  padding: 0.85rem 1.2rem;
  border-radius: 12px 0 0 12px !important;
}

.landing-input::placeholder {
  color: #555566;
}

.landing-input:focus {
  box-shadow: none !important;
  border-color: #6e57ff !important;
}

.landing-btn {
  background: linear-gradient(135deg, #6e57ff, #8b6fff);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.85rem 1.6rem;
  border: none;
  border-radius: 0 12px 12px 0;
  white-space: nowrap;
  transition: filter 0.2s;
}

.landing-btn:hover {
  filter: brightness(1.15);
  color: #fff;
}

@keyframes landing-fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes landing-draw {
  to { stroke-dashoffset: 0; }
}

/* Progress steps */

.progress-container {
  margin-top: 2rem;
}

.progress-step-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.progress-step {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #8a8a9a;
  font-size: 1.05rem;
  animation: landing-fade-up 0.4s ease both;
}

.progress-step-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.progress-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid #3a3a4a;
  border-top-color: #6e57ff;
  border-radius: 50%;
  display: none;
}

.progress-check {
  font-size: 24px;
  color: #22c55e;
  display: none;
  transform: scale(0);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.progress-step.active .progress-spinner {
  display: block;
  animation: progress-spin 0.8s linear infinite;
}

.progress-step.active .progress-step-label {
  color: #f0f0f5;
}

.progress-step.done .progress-check {
  display: block;
  transform: scale(1);
}

.progress-step.done .progress-step-label {
  color: #f0f0f5;
}

.progress-step.error .progress-spinner {
  display: none;
}

.progress-step.error .progress-step-label {
  color: #ef4444;
}

@keyframes progress-spin {
  to { transform: rotate(360deg); }
}

/* Blob overlay */

.blob-overlay {
  position: fixed;
  width: 200vmax;
  height: 200vmax;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  border-radius: 50%;
  background: linear-gradient(135deg, rgb(13, 110, 253), rgb(60, 150, 255));
  z-index: 9999;
  pointer-events: none;
  transform: scale(0);
}

.blob-overlay-active {
  animation: blob-transition 2.6s ease-in-out forwards;
}

@keyframes blob-transition {
  0%   { transform: scale(0); }
  30%  { transform: scale(1); }
  70%  { transform: scale(1); }
  100% { transform: scale(0); }
}
