/* ScanRSVP Custom Styles
   =====================
   Color palette uses CSS custom properties for easy theming.
   Change --color-brand and --color-brand-dark to rebrand the entire site.
*/

:root {
  /* Brand colors - change these to rebrand */
  --color-brand: #4f46e5;          /* indigo-600 */
  --color-brand-hover: #4338ca;    /* indigo-700 */
  --color-brand-dark: #7c3aed;     /* purple-600 (gradient end) */
  --color-brand-dark-hover: #6d28d9; /* purple-700 */
  --color-brand-light: #eef2ff;    /* indigo-50 */
  --color-brand-100: #e0e7ff;      /* indigo-100 */
  --color-brand-text: #4f46e5;     /* indigo-600 */

  /* Neutrals */
  --color-bg: #ffffff;
  --color-bg-subtle: #f8fafc;      /* slate-50 */
  --color-bg-muted: #f1f5f9;       /* slate-100 */
  --color-text: #0f172a;           /* slate-900 */
  --color-text-secondary: #475569; /* slate-600 */
  --color-text-muted: #64748b;     /* slate-500 */
  --color-border: #e2e8f0;         /* slate-200 */

  /* Feedback colors */
  --color-success: #16a34a;        /* green-600 */
  --color-success-light: #f0fdf4;  /* green-50 */
  --color-success-border: #bbf7d0; /* green-200 */
  --color-error: #dc2626;          /* red-600 */
  --color-error-light: #fef2f2;    /* red-50 */
  --color-error-border: #fecaca;   /* red-200 */
  --color-warning: #d97706;        /* amber-600 */
  --color-warning-light: #fffbeb;  /* amber-50 */

  /* Feature card accent colors */
  --color-purple-100: #f3e8ff;
  --color-purple-600: #9333ea;
  --color-green-100: #dcfce7;
  --color-green-600: #16a34a;
  --color-blue-100: #dbeafe;
  --color-blue-600: #2563eb;
  --color-orange-100: #ffedd5;
  --color-orange-600: #ea580c;
  --color-pink-100: #fce7f3;
  --color-pink-600: #db2777;
}

/* Brand gradient utility */
.bg-brand-gradient {
  background: linear-gradient(to bottom right, var(--color-brand), var(--color-brand-dark));
}

.bg-brand-gradient-r {
  background: linear-gradient(to right, var(--color-brand), var(--color-brand-dark));
}

.text-brand-gradient {
  background: linear-gradient(to right, var(--color-brand), var(--color-brand-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Button styles */
.btn-brand {
  background-color: var(--color-brand);
  color: white;
  font-weight: 500;
  padding: 0.625rem 1.5rem;
  border-radius: 0.5rem;
  transition: background-color 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
}
.btn-brand:hover {
  background-color: var(--color-brand-hover);
}

.btn-brand-lg {
  padding: 0.75rem 1.5rem;
  height: 3rem;
  font-size: 1rem;
}

.btn-ghost {
  background: transparent;
  color: var(--color-text-secondary);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  transition: color 0.15s ease;
  border: none;
  cursor: pointer;
}
.btn-ghost:hover {
  color: var(--color-brand);
}

.btn-white {
  background: white;
  color: var(--color-brand);
  font-weight: 600;
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  transition: background-color 0.15s ease;
  border: none;
  cursor: pointer;
}
.btn-white:hover {
  background: var(--color-bg-subtle);
}

/* Form input styles */
.input-field {
  width: 100%;
  height: 3rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: 0.5rem;
  font-size: 1rem;
  background: white;
  color: var(--color-text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.input-field:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}
.input-field::placeholder {
  color: var(--color-text-muted);
}

.textarea-field {
  width: 100%;
  min-height: 150px;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: 0.5rem;
  font-size: 1rem;
  background: white;
  color: var(--color-text);
  resize: vertical;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.textarea-field:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* OTP Input */
.otp-container {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}
.otp-input {
  width: 3rem;
  height: 3.5rem;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 600;
  border: 2px solid var(--color-border);
  border-radius: 0.5rem;
  background: white;
  transition: border-color 0.15s ease;
}
.otp-input:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* Card styles */
.card {
  background: white;
  border: 2px solid var(--color-border);
  border-radius: 0.75rem;
  padding: 2rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  border-color: var(--color-brand-100);
  box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1);
}

.card-elevated {
  background: white;
  border-radius: 1rem;
  padding: 2rem 3rem;
  box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1);
}

/* Alert / Flash message styles */
.alert {
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}
.alert-success {
  background: var(--color-success-light);
  border: 1px solid var(--color-success-border);
  color: #166534;
}
.alert-error {
  background: var(--color-error-light);
  border: 1px solid var(--color-error-border);
  color: #991b1b;
}
.alert-warning {
  background: var(--color-warning-light);
  border: 1px solid #fde68a;
  color: #92400e;
}
.alert-info {
  background: var(--color-brand-light);
  border: 1px solid var(--color-brand-100);
  color: #3730a3;
}

/* Accordion (for FAQs) */
.accordion-item {
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 1rem;
}
.accordion-item:last-child {
  border-bottom: none;
}
.accordion-trigger {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 1rem 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: color 0.15s ease;
}
.accordion-trigger:hover {
  color: var(--color-brand);
}
.accordion-trigger svg {
  transition: transform 0.2s ease;
  flex-shrink: 0;
}
.accordion-trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}
.accordion-content {
  display: none;
  padding: 0 0 1rem;
  color: var(--color-text-secondary);
  line-height: 1.7;
}
.accordion-content.open {
  display: block;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
}
.breadcrumbs a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.15s ease;
}
.breadcrumbs a:hover {
  color: white;
}
.breadcrumbs .current {
  color: white;
  font-weight: 500;
}
.breadcrumbs .separator {
  width: 1rem;
  height: 1rem;
}

/* Prose styles for legal/content pages */
.prose h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 2rem 0 0.75rem;
}
.prose h2:first-child {
  margin-top: 0;
}
.prose h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-text);
  margin: 1.5rem 0 0.5rem;
}
.prose p {
  color: var(--color-text-secondary);
  line-height: 1.75;
  margin-bottom: 1rem;
}
.prose ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}
.prose li {
  color: var(--color-text-secondary);
  line-height: 1.75;
  margin-bottom: 0.25rem;
}
.prose strong {
  color: var(--color-text);
  font-weight: 600;
}

/* Icon container utilities */
.icon-box {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.icon-box-sm {
  width: 3rem;
  height: 3rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Step circle for "How it works" */
.step-circle {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1);
}
.step-number {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.125rem;
  color: white;
  position: absolute;
  top: -0.5rem;
  right: -0.5rem;
}

/* Checkbox */
.checkbox-wrapper {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding-top: 0.5rem;
}
.checkbox-wrapper input[type="checkbox"] {
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.125rem;
  accent-color: var(--color-brand);
}
.checkbox-wrapper label {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* Mobile nav toggle */
.mobile-nav-toggle {
  display: none;
}
@media (max-width: 768px) {
  .mobile-nav-toggle {
    display: block;
  }
  .desktop-nav {
    display: none;
  }
  .mobile-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-bottom: 1px solid var(--color-border);
    padding: 1rem;
    gap: 0.5rem;
    z-index: 50;
  }
}

/* Logo icon */
.logo-icon {
  background: linear-gradient(to bottom right, var(--color-brand), var(--color-brand-dark));
  padding: 0.5rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Utility: visually hidden */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
