/* =============================================
   App Detail Pages — Shared Styles
   ============================================= */

/* Back Link */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  transition: var(--transition);
}
.back-link:hover {
  color: #fff;
}

/* App Hero */
.app-hero {
  padding: 140px 0 80px;
  text-align: center;
  color: #fff;
  position: relative;
}
.app-hero.vet        { background: linear-gradient(135deg, #1565C0 0%, #0D47A1 100%); }
.app-hero.reception   { background: linear-gradient(135deg, #00897B 0%, #00695C 100%); }
.app-hero.lab         { background: linear-gradient(135deg, #E65100 0%, #BF360C 100%); }
.app-hero.pharmacy    { background: linear-gradient(135deg, #7B1FA2 0%, #4A148C 100%); }
.app-hero.customer    { background: linear-gradient(135deg, #2E7D32 0%, #1B5E20 100%); }
.app-hero.owner       { background: linear-gradient(135deg, #F57F17 0%, #E65100 100%); }
.app-hero.admin       { background: linear-gradient(135deg, #546E7A 0%, #37474F 100%); }
.app-hero.super-admin { background: linear-gradient(135deg, #263238 0%, #1a1a2e 100%); }

.app-hero-content {
  max-width: 700px;
  margin: 0 auto;
}

.app-icon-large {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  line-height: 1;
}

.app-hero h1 {
  font-size: 2.8rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.app-hero-subtitle {
  font-size: 1.2rem;
  opacity: 0.9;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.app-hero-stats {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.app-hero-stats span {
  background: rgba(255, 255, 255, 0.15);
  padding: 0.5rem 1.25rem;
  border-radius: 100px;
  font-size: 0.9rem;
  font-weight: 500;
  backdrop-filter: blur(4px);
}

/* Workflow Section */
.workflow-steps {
  display: flex;
  flex-direction: column;
  gap: 5rem;
}

.workflow-step {
  display: flex;
  align-items: center;
  gap: 4rem;
}

.workflow-step.reverse {
  flex-direction: row-reverse;
}

.step-screenshot {
  flex: 1;
  min-width: 0;
  max-width: 50%;
}

.step-screenshot img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid #e5e7eb;
}

.step-info {
  flex: 1;
  min-width: 0;
}

.step-badge {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  padding: 0.3rem 0.85rem;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Color-specific step badges */
.app-hero.vet ~ .section .step-badge        { background: #1565C0; }
.app-hero.reception ~ .section .step-badge   { background: #00897B; }
.app-hero.lab ~ .section .step-badge         { background: #E65100; }
.app-hero.pharmacy ~ .section .step-badge    { background: #7B1FA2; }
.app-hero.customer ~ .section .step-badge    { background: #2E7D32; }
.app-hero.owner ~ .section .step-badge       { background: #F57F17; }
.app-hero.admin ~ .section .step-badge       { background: #546E7A; }
.app-hero.super-admin ~ .section .step-badge { background: #263238; }

.step-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.step-info p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #555;
}

/* Placeholder Screenshot */
.screenshot-coming-soon {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border: 2px dashed #dee2e6;
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
  color: #adb5bd;
  aspect-ratio: 16 / 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.screenshot-coming-soon svg {
  opacity: 0.4;
}

.screenshot-coming-soon span {
  font-size: 0.9rem;
  font-weight: 500;
}

/* App Features Grid */
.app-features {
  background: #f8f9fa;
}

.app-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  max-width: 900px;
  margin: 0 auto;
}

.app-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.app-feature-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.app-feature-item svg {
  flex-shrink: 0;
  color: var(--primary);
  margin-top: 2px;
}

.app-feature-item span {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.4;
  font-weight: 500;
}

/* App CTA Section */
.app-cta {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  text-align: center;
  padding: 80px 0;
}

.app-cta h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #fff;
}

.app-cta p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 2rem;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.app-cta .btn {
  background: #fff;
  color: var(--primary);
  font-weight: 700;
  border: none;
}

.app-cta .btn:hover {
  background: #f0f0f0;
  transform: translateY(-2px);
}

/* Feature Card Link (used on index.html) */
.feature-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
  margin-top: auto;
  padding-top: 1rem;
  transition: var(--transition);
}

.feature-card-link:hover {
  color: var(--primary-dark);
  gap: 0.6rem;
}

.feature-card-link svg {
  transition: var(--transition);
}

/* =============================================
   Class Aliases (variant names from page templates)
   ============================================= */

/* Step info aliases */
.step-content,
.workflow-content {
  flex: 1;
  min-width: 0;
}
.step-content h3,
.workflow-content h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
}
.step-content p,
.workflow-content p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #555;
}

/* Step number (div variant of step-badge) */
.step-number {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

/* Screenshot alias */
.workflow-screenshot {
  flex: 1;
  min-width: 0;
  max-width: 50%;
}

/* Hero aliases */
.app-subtitle { font-size: 1.2rem; opacity: 0.9; line-height: 1.6; margin-bottom: 2rem; }
.app-icon, .app-hero-icon { font-size: 3.5rem; margin-bottom: 1rem; line-height: 1; }
.app-stats { display: flex; justify-content: center; gap: 1.5rem; flex-wrap: wrap; }
.app-stats span { background: rgba(255,255,255,0.15); padding: 0.5rem 1.25rem; border-radius: 100px; font-size: 0.9rem; font-weight: 500; }
.app-stat { text-align: center; }
.app-stat strong { display: block; font-size: 1.1rem; margin-bottom: 0.25rem; }
.app-stat span { background: none !important; padding: 0 !important; font-size: 0.85rem; opacity: 0.8; }

/* Features grid aliases */
.features-grid-section { background: #f8f9fa; }
.features-grid-section .features-grid,
.features-grid-section .feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  max-width: 900px;
  margin: 0 auto;
}
.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}
.feature-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.feature-item svg {
  flex-shrink: 0;
  color: var(--primary);
  margin-top: 2px;
}
.feature-item span {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.4;
  font-weight: 500;
}

/* CTA alias */
.cta-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  text-align: center;
  padding: 80px 0;
}
.cta-section h2 { font-size: 2rem; font-weight: 700; margin-bottom: 1rem; color: #fff; }
.cta-section p { font-size: 1.1rem; opacity: 0.9; margin-bottom: 2rem; max-width: 500px; margin-left: auto; margin-right: auto; }
.cta-section .btn { background: #fff; color: var(--primary); font-weight: 700; border: none; }
.cta-section .btn:hover { background: #f0f0f0; transform: translateY(-2px); }

/* Workflow section alias */
.workflow-section { padding: 80px 0; }
.workflow-section .section-header { text-align: center; margin-bottom: 4rem; }
.workflow-section .section-header h2 { font-size: 2rem; font-weight: 700; margin-bottom: 1rem; }
.workflow-section .section-header p { font-size: 1.05rem; color: #555; max-width: 600px; margin: 0 auto; }

/* =============================================
   Responsive
   ============================================= */
@media (max-width: 1024px) {
  .app-features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .app-hero {
    padding: 120px 0 60px;
  }
  .app-hero h1 {
    font-size: 2rem;
  }
  .app-hero-subtitle, .app-subtitle {
    font-size: 1.05rem;
  }
  .app-hero-stats, .app-stats {
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
  }
  .workflow-steps {
    gap: 3rem;
  }
  .workflow-step,
  .workflow-step.reverse {
    flex-direction: column;
    gap: 1.5rem;
  }
  .step-screenshot, .workflow-screenshot {
    max-width: 100%;
  }
  .app-features-grid, .features-grid-section .features-grid {
    grid-template-columns: 1fr;
  }
  .app-cta, .cta-section {
    padding: 60px 0;
  }
  .app-cta h2, .cta-section h2 {
    font-size: 1.6rem;
  }
}

@media (max-width: 480px) {
  .app-hero h1 {
    font-size: 1.6rem;
  }
  .app-hero-subtitle {
    font-size: 0.95rem;
  }
  .step-info h3 {
    font-size: 1.25rem;
  }
}
