/* ==========================================================================
   Components - Buttons, Cards, Forms, Inputs
   ========================================================================== */

/* ==========================================================================
   BUTTONS
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  line-height: 1;
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius-lg);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Primary Button */
.btn-primary {
  background: var(--gradient-primary);
  color: var(--color-text-white);
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.5);
  color: var(--color-text-white);
}

.btn-primary:active {
  transform: translateY(0);
}

/* Secondary/Outline Button */
.btn-secondary {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn-secondary:hover {
  background: var(--color-primary);
  color: var(--color-text-white);
}

/* White Button (for dark backgrounds) */
.btn-white {
  background: var(--color-bg-white);
  color: var(--color-primary);
  border-color: var(--color-bg-white);
}

.btn-white:hover {
  background: var(--color-bg-light);
  color: var(--color-primary-dark);
}

/* Ghost Button */
.btn-ghost {
  background: transparent;
  color: var(--color-text-dark);
  border-color: transparent;
}

.btn-ghost:hover {
  background: var(--color-bg-light);
}

/* Button Sizes */
.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--font-size-sm);
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--font-size-lg);
}

.btn-xl {
  padding: var(--space-5) var(--space-10);
  font-size: var(--font-size-lg);
}

/* Button with icon */
.btn-icon {
  padding: var(--space-3);
}

.btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Loading state */
.btn-loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn-loading::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

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

/* ==========================================================================
   CARDS
   ========================================================================== */

.card {
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-card);
  transition: all var(--transition-base);
}

.card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-4px);
}

.card-flat {
  box-shadow: none;
  border: 1px solid var(--color-border);
}

.card-flat:hover {
  box-shadow: var(--shadow-md);
}

/* Glass Card */
.card-glass {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Feature Card */
.feature-card {
  text-align: center;
  padding: var(--space-8);
}

.feature-card .feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-6);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 182, 212, 0.1);
  border-radius: var(--radius-xl);
  color: var(--color-primary);
}

.feature-card .feature-icon svg {
  width: 32px;
  height: 32px;
}

.feature-card h3 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-3);
}

.feature-card p {
  font-size: var(--font-size-base);
  color: var(--color-text-medium);
  margin-bottom: 0;
}

/* Industry Card */
.industry-card {
  padding: var(--space-6);
  border: 1px solid var(--color-border-light);
  background: var(--color-bg-white);
}

.industry-card .industry-icon {
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-4);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 182, 212, 0.1);
  border-radius: var(--radius-lg);
  color: var(--color-primary);
}

.industry-card .industry-icon svg {
  width: 24px;
  height: 24px;
}

.industry-card h3 {
  font-size: var(--font-size-lg);
  margin-bottom: var(--space-2);
}

.industry-card .industry-examples {
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
  margin-bottom: var(--space-3);
}

.industry-card .industry-benefit {
  font-size: var(--font-size-sm);
  color: var(--color-primary-dark);
  font-weight: var(--font-weight-medium);
}

/* Highlighted Industry Card */
.industry-card-highlight {
  border: 2px solid var(--color-primary);
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.05) 0%, rgba(16, 185, 129, 0.05) 100%);
  position: relative;
}

.industry-card-highlight::before {
  content: 'Popular';
  position: absolute;
  top: -12px;
  right: var(--space-4);
  background: var(--gradient-primary);
  color: var(--color-text-white);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}

/* ==========================================================================
   FORMS
   ========================================================================== */

.form-group {
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  margin-bottom: var(--space-2);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-text-dark);
}

.form-label .required {
  color: #EF4444;
  margin-left: var(--space-1);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-size: var(--font-size-base);
  color: var(--color-text-dark);
  background: var(--color-bg-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
}

.form-input:hover,
.form-select:hover,
.form-textarea:hover {
  border-color: var(--color-text-light);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

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

.form-textarea {
  min-height: 120px;
  resize: vertical;
}

.form-select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--space-3) center;
  background-size: 20px;
  padding-right: var(--space-10);
}

/* Checkbox and Radio */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  cursor: pointer;
}

.form-check-input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  flex-shrink: 0;
  cursor: pointer;
  accent-color: var(--color-primary);
}

.form-check-label {
  font-size: var(--font-size-sm);
  color: var(--color-text-medium);
  cursor: pointer;
}

/* Radio Group */
.radio-group {
  display: flex;
  gap: var(--space-6);
  flex-wrap: wrap;
}

/* Form Error State */
.form-input.error,
.form-select.error,
.form-textarea.error {
  border-color: #EF4444;
}

.form-error {
  display: none;
  margin-top: var(--space-2);
  font-size: var(--font-size-sm);
  color: #EF4444;
}

.form-group.has-error .form-error {
  display: block;
}

/* Form Success State */
.form-success {
  text-align: center;
  padding: 3rem 2rem;
  background: linear-gradient(135deg, #ECFDF5 0%, #F0FDFA 100%);
  border-radius: var(--radius-2xl);
  border: 2px solid #10B981;
}

.form-success.hidden {
  display: none;
}

.success-icon {
  margin: 0 auto 1.5rem;
  animation: scaleIn 0.5s ease-out;
}

.form-success h3 {
  font-size: var(--font-size-3xl);
  color: var(--color-text-dark);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.form-success p {
  font-size: var(--font-size-lg);
  color: var(--color-text-medium);
  margin-bottom: 0.5rem;
}

.success-subtext {
  font-size: var(--font-size-base);
  color: var(--color-text-light);
}

@keyframes scaleIn {
  from {
    transform: scale(0);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Form Error States */
.error-message {
  color: #EF4444;
  font-size: 0.875rem;
  margin-top: 0.25rem;
  display: block;
}

.form-group input.error,
.form-group select.error,
.form-group textarea.error {
  border-color: #EF4444;
}

.form-error-alert {
  background-color: #FEE2E2;
  border: 1px solid #EF4444;
  color: #991B1B;
  padding: 1rem;
  border-radius: var(--radius-lg);
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
  display: none;
}

/* Form Privacy Text */
.form-privacy {
  font-size: var(--font-size-xs);
  color: var(--color-text-light);
  margin-top: var(--space-4);
}

.form-privacy a {
  color: var(--color-primary);
}

/* ==========================================================================
   VOLUME SLIDER
   ========================================================================== */

.slider-container {
  padding: var(--space-5);
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.05) 0%, rgba(16, 185, 129, 0.05) 100%);
  border-radius: var(--radius-xl);
  border: 2px solid rgba(6, 182, 212, 0.2);
  margin-top: var(--space-2);
}

.volume-slider {
  width: 100%;
  height: 8px;
  background: linear-gradient(to right, #e5e7eb 0%, var(--color-primary) 100%);
  border-radius: var(--radius-full);
  outline: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  background: var(--color-primary);
  border: 4px solid white;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.4);
  transition: all var(--transition-fast);
}

.volume-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 6px 16px rgba(6, 182, 212, 0.6);
}

.volume-slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  background: var(--color-primary);
  border: 4px solid white;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.4);
  transition: all var(--transition-fast);
}

.volume-slider::-moz-range-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 6px 16px rgba(6, 182, 212, 0.6);
}

.slider-labels {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-3);
  padding: 0 var(--space-1);
}

.slider-label {
  font-size: var(--font-size-xs);
  color: var(--color-text-light);
  font-weight: var(--font-weight-semibold);
  text-align: center;
  flex: 1;
}

.slider-value-display {
  margin-top: var(--space-4);
  padding: var(--space-3);
  background: var(--color-bg-white);
  border-radius: var(--radius-md);
  text-align: center;
}

.slider-value-display span {
  font-size: var(--font-size-lg);
  color: var(--color-primary);
  font-weight: var(--font-weight-bold);
}

/* Mobile slider adjustments */
@media (max-width: 767px) {
  .slider-labels {
    font-size: 0.65rem;
  }

  .slider-label {
    font-size: 0.65rem;
  }
}

/* ==========================================================================
   CHECKBOX GRID
   ========================================================================== */

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

@media (max-width: 768px) {
  .checkbox-grid {
    grid-template-columns: 1fr;
  }
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border: 2px solid #E5E7EB;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.checkbox-item:hover {
  border-color: #06B6D4;
  background: #F0FDFA;
}

.checkbox-item input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #06B6D4;
  cursor: pointer;
}

.checkbox-item input[type="checkbox"]:checked + .checkbox-label {
  font-weight: 600;
  color: #0891B2;
}

.checkbox-label {
  font-size: 14px;
  color: #374151;
  cursor: pointer;
}

/* ==========================================================================
   SATISFACTION METRICS GRID (Mobile Fix)
   ========================================================================== */

.satisfaction-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

@media (max-width: 768px) {
  .satisfaction-metrics-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
    text-align: center;
  }

  .satisfaction-metrics-grid > div {
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
  }
}

/* ==========================================================================
   ACCORDION
   ========================================================================== */

.accordion {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.accordion-item {
  border-bottom: 1px solid var(--color-border);
}

.accordion-item:last-child {
  border-bottom: none;
}

.accordion-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-6);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-dark);
  text-align: left;
  background: var(--color-bg-white);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.accordion-header:hover {
  background: var(--color-bg-light);
}

.accordion-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--color-text-light);
  transition: transform var(--transition-base);
}

.accordion-item.active .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base);
}

.accordion-body {
  padding: 0 var(--space-6) var(--space-5);
  color: var(--color-text-medium);
  line-height: var(--line-height-relaxed);
}

/* ==========================================================================
   STATS
   ========================================================================== */

.stat-card {
  text-align: center;
  padding: var(--space-6);
}

.stat-value {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-extrabold);
  color: var(--color-text-dark);
  margin-bottom: var(--space-2);
}

.stat-value.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-size: var(--font-size-sm);
  color: var(--color-text-medium);
}

/* ==========================================================================
   TRUST BADGES
   ========================================================================== */

.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: center;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--font-size-sm);
  color: var(--color-text-medium);
}

.trust-badge svg {
  width: 20px;
  height: 20px;
  color: var(--color-secondary);
}

/* ==========================================================================
   INTEGRATION LOGOS
   ========================================================================== */

.logo-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-8);
}

.logo-item {
  opacity: 0.6;
  transition: opacity var(--transition-fast);
  filter: grayscale(100%);
}

.logo-item:hover {
  opacity: 1;
  filter: grayscale(0%);
}

.logo-item img {
  height: 32px;
  width: auto;
}

/* ==========================================================================
   STEP / TIMELINE
   ========================================================================== */

.steps {
  display: grid;
  gap: var(--space-8);
}

.step {
  display: flex;
  gap: var(--space-6);
}

.step-number {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  color: var(--color-text-white);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  border-radius: var(--radius-full);
}

.step-content h3 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-2);
}

.step-content p {
  color: var(--color-text-medium);
  margin-bottom: 0;
}

/* ==========================================================================
   MARQUEE ITEMS - Dark Mode Hover
   ========================================================================== */

.marquee-item:hover {
  opacity: 1 !important;
}
