/* Custom styles beyond Tailwind */

:root {
  --red: #B01C2E;
  --red-dark: #8B1524;
  --red-light: #D4253A;
  --black: #000000;
  --white: #FFFFFF;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-400: #9CA3AF;
  --gray-600: #4B5563;
  --gray-700: #374151;
  --gray-800: #1F2937;
  --gray-900: #111827;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Hero gradient overlay */
.hero-bg {
  background: linear-gradient(135deg, #000000 0%, #1a0a0d 50%, #2d0a10 100%);
}

/* Red accent line */
.red-accent {
  width: 60px;
  height: 4px;
  background-color: var(--red);
}

/* Section fade-in animation */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Form styling */
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--gray-300);
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  background-color: var(--white);
  color: var(--gray-900);
}

.form-input:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(176, 28, 46, 0.15);
}

.form-input::placeholder {
  color: var(--gray-400);
}

.form-input.error {
  border-color: var(--red);
  background-color: #FEF2F2;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 0.375rem;
}

.form-label .required {
  color: var(--red);
  margin-left: 2px;
}

.error-message {
  font-size: 0.8rem;
  color: var(--red);
  margin-top: 0.25rem;
  display: none;
}

.error-message.show {
  display: block;
}

/* CTA button pulse */
.btn-primary {
  background-color: var(--red);
  color: var(--white);
  font-weight: 700;
  padding: 1rem 2.5rem;
  border-radius: 0.5rem;
  font-size: 1.125rem;
  transition: background-color 0.2s, transform 0.1s, box-shadow 0.2s;
  border: none;
  cursor: pointer;
  display: inline-block;
  text-decoration: none;
}

.btn-primary:hover {
  background-color: var(--red-dark);
  box-shadow: 0 4px 14px rgba(176, 28, 46, 0.35);
}

.btn-primary:active {
  transform: scale(0.98);
}

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

/* FAQ accordion */
.faq-item {
  border-bottom: 1px solid var(--gray-200);
}

.faq-question {
  cursor: pointer;
  user-select: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 0;
  font-weight: 600;
  color: var(--gray-900);
  font-size: 1.0625rem;
}

.faq-question:hover {
  color: var(--red);
}

.faq-question .faq-icon {
  transition: transform 0.2s;
  font-size: 1.25rem;
  flex-shrink: 0;
  margin-left: 1rem;
}

.faq-question.open .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  color: var(--gray-600);
  line-height: 1.7;
}

.faq-answer.open {
  max-height: 400px;
  padding-bottom: 1.25rem;
}

/* Confirmation state */
.form-confirmation {
  text-align: center;
  padding: 3rem 1.5rem;
}

.form-confirmation .checkmark {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: #10B981;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.form-confirmation .checkmark svg {
  width: 40px;
  height: 40px;
  color: var(--white);
}

/* File upload area */
.file-upload-area {
  border: 2px dashed var(--gray-300);
  border-radius: 0.5rem;
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s;
}

.file-upload-area:hover {
  border-color: var(--red);
  background-color: #FEF2F2;
}

.file-upload-area.dragover {
  border-color: var(--red);
  background-color: #FEF2F2;
}

/* Spinner */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  vertical-align: middle;
  margin-right: 0.5rem;
}

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

/* Blockquote styling */
.ruling-quote {
  border-left: 4px solid var(--red);
  padding-left: 1.5rem;
  font-family: Georgia, "Times New Roman", serif;
  font-style: italic;
  color: var(--gray-700);
  font-size: 1.0625rem;
  line-height: 1.8;
  letter-spacing: 0.01em;
}

/* Mobile optimizations */
@media (max-width: 640px) {
  .btn-primary {
    width: 100%;
    text-align: center;
    padding: 1rem 1.5rem;
  }

  .ruling-quote {
    font-size: 1rem;
    padding-left: 1rem;
  }
}

/* Focus visible for accessibility */
*:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 2px;
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .faq-answer {
    transition: none;
  }
}
