/* Accordion Styles - Based on Figma Design Spec (AMS_Page5) */

/* Main Heading */
.onboarding-main-heading {
  color: #fff;
  text-align: center;
  font-family: Inter, sans-serif;
  font-size: 44px;
  font-style: normal;
  font-weight: 700;
  line-height: 94%; /* 41.36px */
  letter-spacing: -0.88px;
  margin: 30px auto 20px;
  padding: 0 20px;
  max-width: 900px;
}

/* Accordion Root Container */
.registration-accordion {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 20px 20px 40px 20px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* Accordion Item - Base Styles */
.accordion-item {
  border-radius: 5px;
  transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

/* Expanded State */
.accordion-item[data-state='open'] {
  background-color: #132f49;
  border: 1px solid #38bdf8;
  min-height: 248px;
}

/* Collapsed State */
.accordion-item[data-state='closed'] {
  background-color: #111d31;
  border: 1px solid #565964;
  min-height: 96px;
}

/* Accordion Header */
.accordion-header {
  position: relative;
}

/* Accordion Trigger - Expanded */
.accordion-item[data-state='open'] .accordion-trigger {
  cursor: default;
  padding: 18px 27px;
  display: flex;
  align-items: flex-start;
  gap: 37px;
  width: 100%;
  background: transparent;
  border: none;
  text-align: left;
}

/* Accordion Trigger - Collapsed */
.accordion-item[data-state='closed'] .accordion-trigger {
  cursor: pointer;
  padding: 22px 27px;
  display: flex;
  align-items: center;
  gap: 21px;
  width: 100%;
  background: transparent;
  border: none;
  text-align: left;
}

.accordion-item[data-state='closed'] .accordion-trigger:hover {
  background-color: rgba(56, 189, 248, 0.05);
}

/* Number Badge */
.number-badge {
  flex-shrink: 0;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #38bdf8 0%, #6cd2ff 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: Inter, sans-serif;
  font-weight: 700;
  font-size: 28px;
  line-height: 1;
  color: #ffffff;
}

/* Trigger Content Container */
.trigger-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Step Indicator (e.g., "Step 1 of 3:") */
.step-indicator {
  font-family: Inter, sans-serif;
  font-weight: 400;
  font-size: 15px;
  line-height: 1.3;
  font-style: italic;
  color: #38bdf8;
}

/* Hidden in collapsed state */
.accordion-item[data-state='closed'] .step-indicator {
  display: none;
}

/* Section Title */
.section-title {
  font-family: Inter, sans-serif;
  font-weight: 700;
  font-size: 28px;
  line-height: 1;
  color: #ffffff;
  margin: 0;
}

/* Description - visible in both expanded and collapsed states */
.section-description {
  font-family: Inter, sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.3;
  color: #ffffff;
  margin: 0;
}

/* Smaller text in collapsed state */
.accordion-item[data-state='closed'] .section-description {
  font-size: 14px;
  opacity: 0.8;
}

/* Chevron Icon Container */
.chevron-container {
  position: absolute;
  right: 27px;
  top: 18px;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion-item[data-state='open'] .chevron-container {
  transform: rotate(180deg);
}

.chevron-icon {
  width: 18px;
  height: 9px;
  color: #38bdf8;
}

/* Accordion Content */
.accordion-content {
  padding: 20px 40px 40px 40px;
  color: #ffffff;
}

.accordion-item[data-state='closed'] .accordion-content {
  display: none;
}

/* Radix UI data-state animation overrides */
.accordion-content[data-state='open'] {
  animation: fadeIn 200ms ease-out;
}

.accordion-content[data-state='closed'] {
  animation: fadeOut 200ms ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

/* Form Elements in Accordion Content */
.accordion-content input[type='text'],
.accordion-content input[type='email'],
.accordion-content input[type='tel'] {
  background: #ffffff;
  border: 1px solid #008bff;
  border-radius: 5px;
  padding: 12px;
  font-family: Inter, sans-serif;
  font-weight: 700;
  font-size: 16px;
  line-height: 1.3;
  color: rgba(2, 6, 24, 0.64);
}

/* Add spacing between form sections */
.accordion-content > div {
  margin-bottom: 24px;
}

.accordion-content > div:last-child {
  margin-bottom: 0;
}

.accordion-content input[type='text']:focus,
.accordion-content input[type='email']:focus,
.accordion-content input[type='tel']:focus {
  outline: none;
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

.accordion-content input[type='text']:disabled,
.accordion-content input[type='email']:disabled,
.accordion-content input[type='tel']:disabled {
  background: rgba(255, 255, 255, 0.5);
  cursor: not-allowed;
}

/* Helper/Validation Text */
.helper-text {
  font-family: Inter, sans-serif;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.3;
  font-style: italic;
  color: rgba(255, 255, 255, 0.78);
  margin-top: 7px;
}

/* Error Text */
.error-text {
  color: #ff6b6b;
  font-weight: 500;
}

/* Success Text */
.success-text {
  color: #6cd2ff;
  font-weight: 500;
}

/* Buttons */
.accordion-content button {
  font-family: Inter, sans-serif;
  font-weight: 600;
  font-size: 16px;
  border-radius: 5px;
  padding: 12px 24px;
  cursor: pointer;
  transition: all 200ms;
}

.accordion-content button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Primary Button */
.btn-primary {
  background: #38bdf8;
  color: #0f172a;
  border: none;
}

.btn-primary:hover:not(:disabled) {
  background: #6cd2ff;
}

.btn-primary:disabled {
  background: #94a3b8;
  color: #475569;
  opacity: 1;
}

/* Secondary Button */
.btn-secondary {
  background: #565964;
  color: #ffffff;
  border: none;
}

.btn-secondary:hover:not(:disabled) {
  background: #6f7380;
}

/* Responsive Design */
@media (max-width: 960px) {
  .registration-accordion {
    width: calc(100% - 40px);
    margin: 0 20px;
  }
}

@media (max-width: 640px) {
  .accordion-item[data-state='open'] {
    min-height: auto;
  }

  .number-badge {
    width: 40px;
    height: 40px;
    font-size: 22px;
  }

  .section-title {
    font-size: 22px;
  }

  .section-description {
    font-size: 14px;
  }

  .accordion-content {
    padding: 0 20px 20px 20px;
  }
}
