/* ==============================================
   LAYERONE WEBSITE - Components
   Boutons, cards, inputs, etc.
   ============================================== */

/* ========== BOUTONS ========== */

/* Base */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  line-height: 1;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
  min-height: 48px;
}

.btn:hover {
  text-decoration: none;
}

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

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Primary */
.btn-primary {
  background: var(--accent-gradient);
  color: var(--text-white);
  box-shadow: var(--shadow-accent);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(140, 100, 240, 0.5);
  color: var(--text-white);
}

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

.btn-primary:disabled {
  background: var(--border-light);
  color: var(--text-muted);
  box-shadow: none;
}

/* Secondary */
.btn-secondary {
  background: var(--text-white);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}

.btn-secondary:hover {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

/* Ghost */
.btn-ghost {
  background: transparent;
  color: var(--accent-primary);
  padding: var(--space-md) var(--space-lg);
}

.btn-ghost:hover {
  background: rgba(140, 100, 240, 0.1);
}

/* Large */
.btn-lg {
  padding: var(--space-xl) var(--space-3xl);
  font-size: var(--text-lg);
  min-height: 56px;
}

/* Small */
.btn-sm {
  padding: var(--space-md) var(--space-lg);
  font-size: var(--text-md);
  min-height: 40px;
}

/* Full width */
.btn-block {
  width: 100%;
}

/* Icon dans bouton */
.btn svg,
.btn .icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

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

/* Glass Card (style login app) */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-top: 1px solid rgba(255, 255, 255, 0.8);
  border-left: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow:
    0 25px 50px rgba(0, 0, 0, 0.15),
    0 10px 20px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  overflow: hidden;
}

/* Card standard */
.card {
  background: var(--text-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  padding: var(--space-2xl);
  transition: all var(--transition-base);
}

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

/* Feature Card (subtle glass) */
.feature-card {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.6);
  padding: var(--space-3xl);
  text-align: center;
  transition: all var(--transition-base);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(140, 100, 240, 0.15);
  border-color: rgba(140, 100, 240, 0.3);
}

.feature-card .icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  background: linear-gradient(135deg, rgba(66, 133, 255, 0.15), rgba(140, 100, 240, 0.15), rgba(236, 72, 180, 0.1));
  border-radius: var(--radius-md);
  color: var(--accent-purple);
}

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

.feature-card p {
  color: var(--text-secondary);
  font-size: var(--text-md);
}

/* Pricing Card */
.pricing-card {
  background: var(--text-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  padding: var(--space-3xl);
  text-align: center;
  transition: all var(--transition-base);
  position: relative;
}

.pricing-card.featured {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 1px var(--accent-primary);
}

.pricing-card.featured::before {
  content: "Recommandé";
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-gradient);
  color: var(--text-white);
  padding: var(--space-xs) var(--space-lg);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
}

.pricing-card .price {
  font-size: var(--text-4xl);
  font-weight: var(--font-bold);
  color: var(--text-primary);
  margin: var(--space-xl) 0;
}

.pricing-card .price span {
  font-size: var(--text-lg);
  font-weight: var(--font-regular);
  color: var(--text-muted);
}

.pricing-card ul {
  list-style: none;
  padding: 0;
  margin: var(--space-2xl) 0;
  text-align: left;
}

.pricing-card li {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
  color: var(--text-secondary);
}

.pricing-card li::before {
  content: "✓";
  color: var(--success);
  font-weight: var(--font-bold);
}

.pricing-card li.disabled {
  color: var(--text-muted);
  text-decoration: line-through;
}

.pricing-card li.disabled::before {
  content: "✗";
  color: var(--text-muted);
}

/* ========== INPUTS ========== */

/* Input Group */
.input-group {
  margin-bottom: var(--space-xl);
}

/* Label */
.input-label {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-sm);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-label .required {
  color: var(--danger);
}

/* Input Field */
.input-field {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  width: 100%;
  padding: var(--space-md) var(--space-lg);
  background: var(--background-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.input-field:focus-within {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(102, 153, 255, 0.15);
}

.input-field .icon {
  color: var(--text-muted);
  flex-shrink: 0;
}

.input-field input,
.input-field textarea {
  flex: 1;
  width: 100%;
  font-size: var(--text-lg);
  color: var(--text-primary);
  background: transparent;
}

.input-field input::placeholder,
.input-field textarea::placeholder {
  color: var(--text-placeholder);
}

/* Select */
.input-field select {
  flex: 1;
  width: 100%;
  font-size: var(--text-lg);
  color: var(--text-primary);
  background: transparent;
  border: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

/* Textarea */
.input-field.textarea {
  align-items: flex-start;
  padding-top: var(--space-md);
}

.input-field textarea {
  min-height: 120px;
}

/* Input Error */
.input-field.error {
  border-color: var(--danger);
}

.input-error {
  margin-top: var(--space-sm);
  font-size: var(--text-sm);
  color: var(--danger);
}

/* ========== BADGES ========== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-md);
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  border-radius: var(--radius-full);
}

.badge-primary {
  background: rgba(102, 153, 255, 0.15);
  color: var(--accent-primary);
}

.badge-success {
  background: rgba(0, 170, 68, 0.15);
  color: var(--success);
}

.badge-warning {
  background: rgba(255, 136, 0, 0.15);
  color: var(--warning);
}

.badge-danger {
  background: rgba(221, 0, 0, 0.15);
  color: var(--danger);
}

/* ========== ALERTS ========== */
.alert {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-lg);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-lg);
}

.alert-info {
  background: rgba(102, 153, 255, 0.1);
  border: 1px solid rgba(102, 153, 255, 0.3);
  color: var(--accent-primary);
}

.alert-success {
  background: rgba(0, 170, 68, 0.1);
  border: 1px solid rgba(0, 170, 68, 0.3);
  color: var(--success);
}

.alert-warning {
  background: rgba(255, 136, 0, 0.1);
  border: 1px solid rgba(255, 136, 0, 0.3);
  color: var(--warning);
}

.alert-error {
  background: rgba(221, 0, 0, 0.1);
  border: 1px solid rgba(221, 0, 0, 0.3);
  color: var(--danger);
}

/* ========== DIVIDER ========== */
.divider {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  margin: var(--space-2xl) 0;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border-light);
}

.divider span {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-muted);
}

/* ========== STORE BADGES ========== */
.store-badges {
  display: flex;
  gap: var(--space-lg);
  justify-content: center;
  flex-wrap: wrap;
}

.store-badge {
  display: block;
  height: 48px;
  transition: transform var(--transition-fast);
}

.store-badge:hover {
  transform: scale(1.05);
}

.store-badge img {
  height: 100%;
  width: auto;
}

/* ========== TESTIMONIAL ========== */
.testimonial {
  background: var(--text-white);
  border-radius: var(--radius-lg);
  padding: var(--space-3xl);
  border: 1px solid var(--border-light);
  position: relative;
}

.testimonial::before {
  content: """;
  position: absolute;
  top: var(--space-lg);
  left: var(--space-2xl);
  font-size: 4rem;
  color: var(--accent-primary);
  opacity: 0.2;
  line-height: 1;
}

.testimonial blockquote {
  font-size: var(--text-xl);
  font-style: italic;
  color: var(--text-primary);
  margin-bottom: var(--space-xl);
}

.testimonial cite {
  display: block;
  font-style: normal;
  font-size: var(--text-md);
  color: var(--text-secondary);
}

.testimonial cite strong {
  display: block;
  color: var(--text-primary);
}

/* ========== ACCORDION / FAQ ========== */
.accordion {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

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

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

.accordion-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-lg) var(--space-xl);
  background: transparent;
  border: none;
  font-size: var(--text-lg);
  font-weight: var(--font-medium);
  color: var(--text-primary);
  text-align: left;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.accordion-trigger:hover {
  background: var(--background-section);
}

.accordion-trigger::after {
  content: "+";
  font-size: var(--text-xl);
  color: var(--text-muted);
  transition: transform var(--transition-fast);
}

.accordion-item.active .accordion-trigger::after {
  transform: rotate(45deg);
}

.accordion-content {
  display: none;
  padding: 0 var(--space-xl) var(--space-xl);
  color: var(--text-secondary);
}

.accordion-item.active .accordion-content {
  display: block;
}

/* ========== LOADING SPINNER ========== */
.spinner {
  width: 24px;
  height: 24px;
  border: 2px solid var(--border-light);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ========== CHECKMARK LIST ========== */
.check-list {
  list-style: none;
  padding: 0;
}

.check-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-sm) 0;
}

.check-list li::before {
  content: "✓";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: rgba(0, 170, 68, 0.15);
  color: var(--success);
  border-radius: 50%;
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  flex-shrink: 0;
  margin-top: 2px;
}
