/* ========================================
   CARD COMPONENT STYLES
   ========================================
   Consolidated card styles from across the codebase.
   
   USAGE:
   - Import after tokens.css
   - Use .card as base class, add modifiers for variants
   
   CARD TYPES:
   - .card: Base card with dark background
   - .plan-card: Pricing plan cards
   - .feature-card: Feature showcase cards
   - .hub-card: Admin dashboard navigation cards
   - .action-card: Interactive action cards
   - .testimonial-card: Quote/testimonial cards
   
   MIGRATION NOTE:
   - Consolidates styles from styles.css, pricing-cinematic.css,
     features-cinematic.css, admin.css, pricing-cards.css
   - Uses tokens.css variables for consistency
*/

/* ==========================================
   BASE CARD
   ========================================== */
.card {
  position: relative;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-subtle);
  background: var(--surface-card);
  box-shadow: 0 0 0 1px var(--border-subtle);
  backdrop-filter: blur(6px);
  padding: var(--space-5);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* Card content elements */
.card .label {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.card .title {
  margin-top: var(--space-2);
  color: var(--text-secondary);
  font-weight: var(--font-semibold);
  font-size: var(--text-lg);
}

.card .body {
  margin-top: var(--space-2);
  color: var(--text-muted);
  font-size: var(--text-sm);
}

/* Card accent decorations */
.card .accent {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: var(--radius-xl);
}

.card .accent.left-bar {
  inset: 0 auto 0 0;
  width: 3px;
  background: color-mix(in srgb, var(--color-primary-hover) 92%, transparent);
  border-top-left-radius: var(--radius-xl);
  border-bottom-left-radius: var(--radius-xl);
  transition: width var(--transition-base);
}

.card:hover .accent.left-bar {
  width: 5px;
}

.card .accent.glow {
  opacity: 0;
  transition: opacity var(--transition-slow);
  background: radial-gradient(300px 120px at 20% 0%, rgba(234, 88, 12, 0.18), transparent);
}

.card:hover .accent.glow {
  opacity: 1;
}

/* ==========================================
   FEATURE CARD
   ========================================== */
.feature-card {
  background: linear-gradient(135deg, rgba(26, 26, 26, 0.9), rgba(10, 10, 10, 0.9));
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  height: 100%;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(255, 140, 66, 0.2);
  border-color: var(--color-primary);
}

/* Top accent bar animation */
.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s;
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-icon {
  font-size: var(--text-5xl);
  color: var(--color-primary);
  margin-bottom: var(--space-4);
  background: rgba(255, 140, 66, 0.1);
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--border-accent);
  box-shadow: 0 5px 15px rgba(255, 140, 66, 0.2);
  transition: all var(--transition-base);
}

.feature-card:hover .feature-icon {
  transform: scale(1.1);
  border-color: var(--color-primary);
  box-shadow: 0 8px 25px rgba(255, 140, 66, 0.4);
}

.feature-title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-3);
  color: var(--text-primary);
  font-weight: var(--font-semibold);
  position: relative;
  padding-bottom: var(--space-3);
}

.feature-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 2px;
  background: var(--color-primary);
}

.feature-description {
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-4);
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}

.feature-list li {
  position: relative;
  padding-left: var(--space-4);
  margin-bottom: var(--space-2);
  color: var(--text-muted);
}

.feature-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: var(--font-bold);
}

/* ==========================================
   PLAN CARD (Pricing)
   ========================================== */
.plan-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius-2xl);
  padding: var(--space-6);
  backdrop-filter: blur(12px);
  background:
    radial-gradient(160% 200% at 0% 0%, rgba(255, 106, 26, 0.22), transparent 65%),
    rgba(12, 16, 26, 0.82);
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.65);
  transition: 
    outline-width var(--transition-slow),
    transform var(--transition-slow),
    box-shadow var(--transition-slow),
    border-color var(--transition-slow),
    filter var(--transition-base);
  outline: 1px solid color-mix(in srgb, var(--border-medium) 60%, var(--color-primary-hover) 40%);
}

.plan-card:hover {
  outline-width: 2px;
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--color-primary-hover) 70%, var(--border-medium) 30%);
  box-shadow: 0 36px 90px rgba(0, 0, 0, 0.85);
}

.plan-card .badge {
  position: absolute;
  right: var(--space-4);
  top: -10px;
  background: var(--color-primary-hover);
  color: #000;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  box-shadow: 0 10px 30px -10px rgba(255, 106, 26, 0.5);
}

.plan-card h3 {
  font-weight: var(--font-semibold);
}

.plan-card p.note {
  margin-top: var(--space-1);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* Plan card variants */
.plan-card--free {
  outline-color: rgba(255, 255, 255, 0.65);
}

.plan-card--pro {
  outline-color: color-mix(in srgb, var(--color-primary-hover) 70%, white 30%);
}

.plan-card--enterprise {
  outline-color: color-mix(in srgb, #22d3ee 70%, white 30%);
}

/* Price grid inside plan cards */
.price-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-5);
}

.price-box {
  text-align: center;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(3, 4, 10, 0.65);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.35);
}

.price-box .label {
  font-size: var(--text-xs);
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.08em;
}

.price-box .value {
  margin-top: var(--space-2);
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
}

.price-box .cadence {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.price-box.outlined {
  outline: 1px solid var(--color-primary-hover);
}

/* Plan features list */
.plan-features {
  margin-top: var(--space-5);
  display: grid;
  gap: var(--space-3);
  list-style: none;
  padding: 0;
}

.plan-features li {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  font-size: var(--text-sm);
  color: rgba(229, 231, 235, 0.92);
}

.plan-features li .dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  margin-top: 3px;
  flex-shrink: 0;
}

/* Dot color variants */
.dot-white { background-color: #fff; }
.dot-accent { background-color: var(--color-primary-hover); }
.dot-secondary { background-color: #22d3ee; }

.plan-cta {
  margin-top: var(--space-5);
}

.plan-cta button {
  width: 100%;
  justify-content: center;
}

/* ==========================================
   HUB CARD (Admin Dashboard)
   ========================================== */
.hub-card {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--surface-card);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1), 0 8px 24px rgba(0, 0, 0, 0.4);
  transition: 
    transform var(--transition-fast),
    box-shadow var(--transition-fast),
    border-color var(--transition-fast);
}

.hub-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-primary-hover);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1), 0 12px 32px rgba(255, 107, 43, 0.2);
}

.hub-card-main {
  flex: 1;
  max-width: 85%;
}

.hub-card-title-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}

.hub-card-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-lg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 107, 43, 0.1);
  border: 1px solid rgba(255, 107, 43, 0.3);
  color: var(--color-primary-hover);
  font-size: var(--text-base);
}

.hub-card-title {
  font-weight: var(--font-semibold);
  font-size: var(--text-base);
  color: var(--text-primary);
}

.hub-card-text {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.5;
}

/* Hub icon color variants */
.hub-card-icon--purple { background: rgba(168, 85, 247, 0.1); border-color: rgba(168, 85, 247, 0.3); color: #a855f7; }
.hub-card-icon--blue { background: rgba(59, 130, 246, 0.1); border-color: rgba(59, 130, 246, 0.3); color: #3b82f6; }
.hub-card-icon--green { background: rgba(34, 197, 94, 0.1); border-color: rgba(34, 197, 94, 0.3); color: #22c55e; }
.hub-card-icon--orange { background: rgba(255, 107, 43, 0.1); border-color: rgba(255, 107, 43, 0.3); color: var(--color-primary-hover); }
.hub-card-icon--cyan { background: rgba(14, 165, 233, 0.1); border-color: rgba(14, 165, 233, 0.3); color: #0ea5e9; }
.hub-card-icon--yellow { background: rgba(245, 158, 11, 0.1); border-color: rgba(245, 158, 11, 0.3); color: #f59e0b; }
.hub-card-icon--pink { background: rgba(236, 72, 153, 0.1); border-color: rgba(236, 72, 153, 0.3); color: #ec4899; }
.hub-card-icon--slate { background: rgba(148, 163, 184, 0.1); border-color: rgba(148, 163, 184, 0.3); color: #94a3b8; }
.hub-card-icon--red { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.3); color: #ef4444; }

/* Hub grid layout */
.hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-4);
}

/* ==========================================
   ACTION CARD (Pricing page CTAs)
   ========================================== */
.action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-5);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  text-decoration: none;
  transition: all var(--transition-slow);
  color: var(--text-secondary);
  min-height: 180px;
}

.action-card:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-4px);
  border-color: var(--border-strong);
}

.action-card .icon {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
  color: var(--text-muted);
  transition: color var(--transition-slow);
}

.action-card h4 {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  margin: 0 0 var(--space-2) 0;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.action-card p {
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin: 0;
  line-height: 1.4;
}

/* Action card accent colors */
.action-card.accent-orange:hover { border-color: var(--color-primary-hover); box-shadow: 0 8px 24px rgba(255, 106, 26, 0.15); }
.action-card.accent-orange:hover .icon { color: var(--color-primary-hover); }

.action-card.accent-cyan:hover { border-color: #22d3ee; box-shadow: 0 8px 24px rgba(34, 211, 238, 0.15); }
.action-card.accent-cyan:hover .icon { color: #22d3ee; }

.action-card.accent-purple:hover { border-color: #a78bfa; box-shadow: 0 8px 24px rgba(167, 139, 250, 0.15); }
.action-card.accent-purple:hover .icon { color: #a78bfa; }

.action-card.accent-green:hover { border-color: #34d399; box-shadow: 0 8px 24px rgba(52, 211, 153, 0.15); }
.action-card.accent-green:hover .icon { color: #34d399; }

.action-card.accent-gray:hover { border-color: #e5e7eb; box-shadow: 0 8px 24px rgba(229, 231, 235, 0.1); }
.action-card.accent-gray:hover .icon { color: #e5e7eb; }

/* Form inside action card */
.action-card.form-card {
  cursor: default;
}

.action-card.form-card:hover {
  transform: none;
  border-color: var(--border-medium);
  box-shadow: none;
}

.action-card.form-card:hover .icon {
  color: #34d399;
}

/* Action grid layout */
.action-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-8);
  width: 100%;
}

/* ==========================================
   TESTIMONIAL CARD
   ========================================== */
.testimonial-card {
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  transition: all var(--transition-base);
  position: relative;
  box-shadow: var(--shadow-lg);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.testimonial-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(255, 140, 66, 0.2);
  border-color: var(--color-primary);
}

.testimonial-text {
  position: relative;
  font-style: italic;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-4);
  z-index: 1;
  padding: 0 var(--space-2);
}

.testimonial-text::before {
  content: '\201C';
  position: absolute;
  top: -30px;
  left: -10px;
  font-size: 5rem;
  color: var(--color-primary);
  opacity: 0.2;
  font-family: Georgia, serif;
  line-height: 1;
  z-index: -1;
}

.testimonial-author {
  font-weight: var(--font-bold);
  color: var(--text-primary);
  margin-bottom: var(--space-1);
  font-size: var(--text-lg);
}

.testimonial-title {
  color: var(--color-primary);
  font-size: var(--text-sm);
}

/* ==========================================
   PRICING CARD (Legacy)
   ========================================== */
.pricing-card {
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  text-align: center;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.pricing-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(255, 140, 66, 0.2);
}

.pricing-card.featured {
  transform: scale(1.05);
  border-color: var(--color-primary);
  box-shadow: 0 10px 30px rgba(255, 140, 66, 0.3);
  z-index: 2;
}

.pricing-card.featured:hover {
  transform: translateY(-10px) scale(1.05);
}

.popular-badge {
  position: absolute;
  top: 0;
  right: 0;
  background: var(--color-primary);
  color: white;
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  padding: var(--space-2) var(--space-3);
  border-radius: 0 var(--radius-lg) 0 var(--radius-lg);
  letter-spacing: 1px;
}

/* ==========================================
   SOLUTION CARD
   ========================================== */
.solution-card {
  border-radius: var(--radius-xl);
  padding: var(--space-5);
  backdrop-filter: blur(6px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-medium);
  outline: 1px solid var(--border-strong);
}

/* ==========================================
   CARD GRIDS
   ========================================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-6);
  padding: var(--space-2);
  margin-top: var(--space-5);
}

.pricing-grid,
.pricing-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-6);
  margin-top: var(--space-8);
  padding: var(--space-3);
}

.testimonials-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-6);
  margin-top: var(--space-8);
  padding: var(--space-3);
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 640px) {
  .action-grid {
    grid-template-columns: 1fr;
    gap: var(--space-3);
    margin-top: var(--space-5);
  }

  .action-card {
    min-height: auto;
    padding: var(--space-4);
  }
  
  .hub-grid {
    grid-template-columns: 1fr;
  }
  
  .price-grid {
    grid-template-columns: 1fr;
  }
}
