/* ============================================
   ITAfx Thank You Page + Upsell — Design System
   ============================================ */

/* --- CSS Variables (ITAfx Brand) --- */
:root {
  /* Colors */
  --bg-primary: #09090b;
  --bg-card: #1d1d1f;
  --bg-card-hover: #242426;
  --accent: #485aff;
  --accent-hover: #3b7ef8;
  --accent-light: #0c82fb;
  --text-primary: #ffffff;
  --text-secondary: #71717b;
  --text-muted: #52525b;
  --border: #262628;
  --border-light: #3a3a3c;
  --success: #22c55e;
  --success-bg: rgba(34, 197, 94, 0.1);
  --danger: #ef4444;
  --warning: #f59e0b;
  --gold: #fbbf24;

  /* Typography */
  --font-display: 'Fraunces', serif;
  --font-ui: 'Inter', sans-serif;

  /* Spacing */
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 15px;
  --radius-xl: 20px;

  /* Shadows */
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 0 30px rgba(72, 90, 255, 0.15);
}

/* --- Reset --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul, ol { list-style: none; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* --- Logo --- */
.logo {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.logo span {
  color: var(--accent);
}

/* --- Order Confirmation Bar --- */
.order-bar {
  background: var(--success-bg);
  border-bottom: 1px solid rgba(34, 197, 94, 0.2);
  padding: 12px 0;
  text-align: center;
}

.order-bar__content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  color: var(--success);
  font-weight: 500;
}

.order-bar__icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* --- Progress Bar --- */
.progress-bar {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}

.progress-bar__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.progress-step {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
}

.progress-step--completed {
  color: var(--success);
}

.progress-step--active {
  color: var(--accent);
}

.progress-step__number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  border: 2px solid var(--text-muted);
  flex-shrink: 0;
}

.progress-step--completed .progress-step__number {
  background: var(--success);
  border-color: var(--success);
  color: #fff;
}

.progress-step--active .progress-step__number {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.progress-step__connector {
  width: 40px;
  height: 2px;
  background: var(--border);
  margin: 0 8px;
  flex-shrink: 0;
}

.progress-step--completed + .progress-step__connector,
.progress-step__connector--done {
  background: var(--success);
}

/* --- Header --- */
.header {
  padding: 20px 0;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

/* --- Hero Section --- */
.hero {
  text-align: center;
  padding: 48px 0 32px;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--success-bg);
  color: var(--success);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 20px;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.hero__badge svg {
  width: 14px;
  height: 14px;
}

.hero__headline {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.027em;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.hero__headline em {
  font-style: normal;
  color: var(--accent);
}

.hero__subheadline {
  font-size: 17px;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.5;
}

/* --- Timer Section --- */
.timer-section {
  text-align: center;
  padding: 24px 0;
}

.timer-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.timer-display {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.05em;
}

.timer-display.timer--urgent {
  color: var(--danger);
  animation: timerPulse 1s ease-in-out infinite;
}

@keyframes timerPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.timer-note {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

.timer-expired {
  display: none;
  text-align: center;
  padding: 24px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-md);
  color: var(--danger);
  font-weight: 500;
}

.timer-expired.is-visible {
  display: block;
}

/* --- Benefits Section --- */
.benefits {
  padding: 32px 0;
}

.section-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  text-align: center;
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 500;
  text-align: center;
  margin-bottom: 28px;
  letter-spacing: -0.02em;
}

.benefits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.benefit-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: border-color 0.2s;
}

.benefit-card:hover {
  border-color: var(--border-light);
}

.benefit-card__icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(72, 90, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent);
}

.benefit-card__icon svg {
  width: 18px;
  height: 18px;
}

.benefit-card__title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.benefit-card__desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* --- Comparison Table --- */
.comparison {
  padding: 0 0 32px;
}

.comparison-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.comparison-table th,
.comparison-table td {
  padding: 12px 16px;
  text-align: left;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
}

.comparison-table th {
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.02);
}

.comparison-table th:last-child {
  color: var(--accent);
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table td:first-child {
  color: var(--text-secondary);
}

.comparison-check {
  color: var(--success);
  font-weight: 700;
}

.comparison-cross {
  color: var(--text-muted);
}

.comparison-highlight {
  background: rgba(72, 90, 255, 0.05);
}

/* --- Value Stack --- */
.value-stack {
  padding: 32px 0;
}

.value-stack__card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  position: relative;
  overflow: hidden;
}

.value-stack__card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
}

.value-stack__badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(72, 90, 255, 0.15);
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.value-stack__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.value-stack__item:last-of-type {
  border-bottom: none;
}

.value-stack__item-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.value-stack__item-name svg {
  width: 16px;
  height: 16px;
  color: var(--success);
  flex-shrink: 0;
}

.value-stack__item-value {
  font-size: 14px;
  color: var(--text-secondary);
  text-decoration: line-through;
}

.value-stack__total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0 0;
  margin-top: 8px;
  border-top: 2px solid var(--border);
}

.value-stack__total-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}

.value-stack__total-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-secondary);
  text-decoration: line-through;
}

/* --- Pricing --- */
.pricing {
  text-align: center;
  padding: 32px 0 24px;
}

.pricing__original {
  font-size: 18px;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-bottom: 4px;
}

.pricing__current {
  font-family: var(--font-display);
  font-size: 52px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.03em;
}

.pricing__current sup {
  font-size: 24px;
  top: -16px;
  position: relative;
}

.pricing__save {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(34, 197, 94, 0.1);
  color: var(--success);
  font-size: 13px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 100px;
  margin-top: 8px;
}

.pricing__note {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 8px;
}

/* --- Social Proof --- */
.social-proof {
  padding: 32px 0;
}

.testimonials {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
}

.testimonial-card__header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.testimonial-card__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  color: #fff;
  flex-shrink: 0;
}

.testimonial-card__name {
  font-size: 14px;
  font-weight: 600;
}

.testimonial-card__role {
  font-size: 12px;
  color: var(--text-secondary);
}

.testimonial-card__stars {
  color: var(--gold);
  font-size: 14px;
  margin-left: auto;
  display: flex;
  gap: 1px;
}

.testimonial-card__text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  font-style: italic;
}

.trust-badges {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}

.trust-badge__icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: rgba(72, 90, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.trust-badge__icon svg {
  width: 16px;
  height: 16px;
}

.trust-badge__value {
  color: var(--text-primary);
  font-weight: 700;
}

/* --- CTA Section --- */
.cta-section {
  padding: 32px 0;
  text-align: center;
}

.cta-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  max-width: 480px;
  padding: 18px 32px;
  background: var(--accent);
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  border-radius: var(--radius-lg);
  transition: all 0.2s;
  box-shadow: 0 4px 20px rgba(72, 90, 255, 0.3);
  position: relative;
  overflow: hidden;
}

.cta-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(72, 90, 255, 0.4);
}

.cta-primary:active {
  transform: translateY(0);
}

.cta-primary svg {
  width: 20px;
  height: 20px;
}

.cta-limited {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--warning);
  margin-bottom: 12px;
  animation: limitedPulse 2s ease-in-out infinite;
}

@keyframes limitedPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.cta-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 12px;
}

.cta-trigger svg {
  width: 14px;
  height: 14px;
}

/* --- Guarantee --- */
.guarantee {
  text-align: center;
  padding: 24px 0;
}

.guarantee__card {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 24px;
}

.guarantee__icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--success);
  flex-shrink: 0;
}

.guarantee__icon svg {
  width: 20px;
  height: 20px;
}

.guarantee__text {
  text-align: left;
}

.guarantee__title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.guarantee__desc {
  font-size: 12px;
  color: var(--text-secondary);
}

/* --- Decline Link --- */
.decline {
  text-align: center;
  padding: 24px 0 48px;
}

.decline__link {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.2s;
  cursor: pointer;
}

.decline__link:hover {
  color: var(--text-secondary);
}

/* --- Thank You Final Page --- */
.thankyou-hero {
  text-align: center;
  padding: 60px 0 40px;
}

.thankyou-hero__icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--success-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: var(--success);
}

.thankyou-hero__icon svg {
  width: 36px;
  height: 36px;
}

.thankyou-hero__title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 500;
  letter-spacing: -0.027em;
  margin-bottom: 12px;
}

.thankyou-hero__subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto;
}

/* --- Order Summary Card --- */
.order-summary {
  padding: 0 0 40px;
}

.order-summary__card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.order-summary__title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.order-summary__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 14px;
}

.order-summary__row--label {
  color: var(--text-secondary);
}

.order-summary__row--total {
  border-top: 1px solid var(--border);
  margin-top: 8px;
  padding-top: 16px;
  font-weight: 700;
  font-size: 16px;
}

/* --- Next Steps --- */
.next-steps {
  padding: 0 0 40px;
}

.next-steps__card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.next-steps__title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 20px;
}

.next-steps__list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.next-step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.next-step__number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(72, 90, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  flex-shrink: 0;
}

.next-step__content {
  flex: 1;
}

.next-step__title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.next-step__desc {
  font-size: 13px;
  color: var(--text-secondary);
}

/* --- Dashboard Button --- */
.dashboard-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-lg);
  transition: all 0.2s;
}

.dashboard-btn:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

/* --- Footer --- */
.footer {
  text-align: center;
  padding: 32px 0;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.footer__text {
  font-size: 12px;
  color: var(--text-muted);
}

/* ============================================
   Responsive Design
   ============================================ */

/* Mobile small (320px) */
@media (max-width: 374px) {
  .hero__headline { font-size: 24px; }
  .hero__subheadline { font-size: 15px; }
  .timer-display { font-size: 36px; }
  .pricing__current { font-size: 40px; }
  .benefits-grid { grid-template-columns: 1fr; }
  .progress-step__label { display: none; }
  .trust-badges { flex-direction: column; align-items: center; }
}

/* Mobile (375-767px) */
@media (max-width: 767px) {
  .container { padding: 0 16px; }
  .hero { padding: 36px 0 24px; }
  .hero__headline { font-size: 26px; }
  .benefits-grid { grid-template-columns: 1fr; }
  .comparison-table th,
  .comparison-table td { padding: 10px 12px; font-size: 12px; }
  .value-stack__card { padding: 24px; }
  .pricing__current { font-size: 44px; }
  .cta-primary { font-size: 15px; padding: 16px 24px; }
  .trust-badges { gap: 16px; }
  .guarantee__card { flex-direction: column; text-align: center; padding: 20px; }
  .guarantee__text { text-align: center; }
}

/* Tablet (768-1023px) */
@media (min-width: 768px) {
  .hero__headline { font-size: 36px; }
  .testimonials { flex-direction: row; }
  .testimonial-card { flex: 1; }
}

/* Desktop (1024+) */
@media (min-width: 1024px) {
  .container { max-width: 800px; }
  .hero__headline { font-size: 40px; }
  .hero { padding: 56px 0 36px; }
}
