/*
 * My9Iron Fitting Engine - brand-aligned styles.
 * Rewritten to match the site's actual black/red/white identity (matches
 * .hero, .btn-danger, .creator-tile border colors elsewhere in main.css)
 * instead of the original generic green placeholder theme.
 */

.my9iron-fitting {
  max-width: 680px;
  margin: 2rem auto;
  font-family: inherit;
}

.fitting-crawlable-intro {
  /* Present in the HTML for search/AI crawlers, visually hidden from human visitors -
     same technique as accessibility screen-reader-only text. Not cloaking - identical
     content either way, just not displayed since a wall of methodology text isn't what
     someone tapping through a fitting wants to see. */
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================================
   APP CONTAINER
   ============================================================ */
.fitting-app {
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 12px 32px rgba(16,42,67,0.10);
  border: 1px solid #e7e9ec;
}

/* ============================================================
   INTRO SCREEN - dark hero treatment, same visual language as the
   site's real .hero sections, instead of a plain bordered box.
   ============================================================ */
.fitting-intro-screen {
  text-align: center;
  padding: 3rem 2rem 2.5rem;
  background: #0B0F0A;
  color: #fff;
  position: relative;
}
.fitting-intro-screen:before {
  content: "GOLF FITTING LAB";
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: #FF0000;
  margin-bottom: 14px;
}
.fitting-intro-screen .fitting-title {
  margin: 0 0 0.75rem;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  color: #fff !important;
  letter-spacing: -0.01em;
}
.fitting-intro-screen .fitting-desc {
  color: rgba(255,255,255,0.78) !important;
  margin: 0 auto 1.75rem;
  max-width: 44ch;
  font-size: 15px;
  line-height: 1.6;
}

/* ============================================================
   BUTTONS - red primary, matching .btn-danger sitewide
   ============================================================ */
.fitting-start-btn,
.fitting-next-btn,
.fitting-retake-btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  border: none;
  background: #C8102E;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  font-size: 1rem;
  letter-spacing: 0.01em;
  transition: background 0.15s ease, transform 0.1s ease;
}
.fitting-start-btn:hover,
.fitting-next-btn:hover,
.fitting-retake-btn:hover { background: #a80d26; }
.fitting-start-btn:active,
.fitting-next-btn:active { transform: translateY(1px); }

.fitting-back-btn {
  display: inline-block;
  padding: 0.85rem 1.5rem;
  border-radius: 8px;
  background: transparent;
  color: #102a43;
  border: 1.5px solid #d8dce1;
  font-weight: 600;
  cursor: pointer;
  font-size: 1rem;
}
.fitting-back-btn:hover { border-color: #102a43; }

/* ============================================================
   PROGRESS BAR - red fill
   ============================================================ */
.fitting-progress {
  height: 6px;
  background: #e7e9ec;
  border-radius: 3px;
  margin-bottom: 1.75rem;
  overflow: hidden;
}
.fitting-progress-bar {
  height: 100%;
  background: #C8102E;
  width: 0%;
  transition: width 0.3s ease;
}

/* ============================================================
   QUESTION SCREEN
   ============================================================ */
.fitting-question-screen { padding: 2.25rem 2rem; }
.fitting-question-text { font-size: 1.25rem; font-weight: 700; color: #102a43; margin-bottom: 1rem; }
.fitting-question-hint { font-size: 13px; color: #52606d; margin: -8px 0 12px; }

.fitting-answers { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 1.75rem; }
.fitting-answer-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1.1rem;
  border: 1.5px solid #e7e9ec;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.12s ease, background 0.12s ease;
}
.fitting-answer-option:hover { border-color: #c8102e55; }
.fitting-answer-option:has(input:checked) {
  border-color: #C8102E;
  background: #fdf1f2;
}
.fitting-answer-option--multi { align-items: flex-start; }
.fitting-answer-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fitting-answer-check {
  width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid #ccc;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 1px;
}
.fitting-answer-option input:checked + .fitting-answer-check { background: #C8102E; border-color: #C8102E; }
.fitting-answer-option input:checked + .fitting-answer-check:after { content: "\2713"; color: #fff; font-size: 12px; }
.fitting-answer-text { display: flex; flex-direction: column; }
.fitting-answer-label { font-size: 15px; color: #102a43; }
.fitting-answer-sublabel { font-size: 12.5px; color: #52606d; margin-top: 2px; }
.fitting-answer-option:has(input:checked) .fitting-answer-label { color: #C8102E; font-weight: 700; }

.fitting-nav { display: flex; justify-content: space-between; }

.fitting-error-shake { animation: fitting-shake 0.3s; }
@keyframes fitting-shake {
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* ============================================================
   RESULTS SCREEN - Best Match card gets the strongest visual
   weight on the page, matching a "gold medal" identity
   ============================================================ */
.fitting-results-screen { padding: 2rem; }

.fitting-result-best {
  text-align: center;
  padding: 1.75rem 1.5rem;
  background: #fff;
  border-radius: 12px;
  border: 3px solid #C8102E;
  box-shadow: 0 14px 32px rgba(0,0,0,0.18);
  margin-bottom: 1.5rem;
}
.fitting-result-label {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
  color: #C8102E;
  font-weight: 800;
}
.fitting-result-name { margin: 0.35rem 0 0.5rem; font-size: 1.7rem; font-weight: 800; color: #102a43; }
.fitting-confidence { font-size: 1rem; margin-bottom: 1rem; }
.fitting-confidence-num { font-size: 1.9rem; font-weight: 800; color: #C8102E; }
.fitting-confidence--compact .fitting-confidence-num { font-size: 1.3rem; }
.fitting-confidence-sub { color: #52606d; font-size: 14px; max-width: 40ch; margin: 6px auto 0; }

.fitting-tier-tag {
  display: inline-block; font-size: 0.8rem; font-weight: 700; color: #C8102E;
  background: #fdf1f2; padding: 0.25rem 0.7rem; border-radius: 999px; margin-bottom: 0.5rem;
}
.fitting-price-label { font-size: 0.85rem; color: #52606d; margin-bottom: 0.5rem; }

/* Analysis / why-list */
.fitting-analysis { margin-top: 1.25rem; text-align: left; }
.fitting-analysis-heading { font-size: 1.1rem; font-weight: 800; color: #102a43; margin-bottom: 1rem; }
.fitting-analysis-block { margin-bottom: 1.5rem; }
.fitting-why-heading { font-size: 1rem; font-weight: 700; color: #102a43; margin-bottom: 0.4rem; }
.fitting-why-intro { color: #52606d; font-size: 14px; margin-bottom: 0.5rem; }

.fitting-why-list { list-style: none; padding: 0; margin: 0 0 1rem; text-align: left; }
.fitting-why-list .why-item { padding: 0.5rem 0; border-bottom: 1px solid #f0f1f3; font-size: 14.5px; color: #333; }
.fitting-why-list--loss .why-item--loss { color: #52606d; }
.fitting-why-list--notfor .why-item--notfor { color: #52606d; }

.fitting-section-divider { border: none; border-top: 1px solid #e7e9ec; margin: 32px 0; }

/* Runner-up / brand-comparison cards */
.fitting-result-card {
  padding: 1.5rem;
  background: #fdfdfd;
  border: 1.5px solid #e7e9ec;
  border-radius: 12px;
  text-align: left;
}
.fitting-runner-up-label {
  text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.8rem;
  color: #52606d; font-weight: 800; margin-bottom: 0.35rem;
}
.fitting-runner-up-name { font-size: 1.35rem; font-weight: 800; color: #102a43; margin: 0 0 0.35rem; }
.fitting-runner-up-score { color: #52606d; font-size: 14.5px; margin: 0.75rem 0 0.75rem; }
.fitting-brand-badge {
  display: inline-block; font-size: 11px; font-weight: 700; color: #C8102E;
  background: #fdf1f2; padding: 3px 9px; border-radius: 999px; margin-left: 6px; vertical-align: middle;
}

.fitting-notice-section { background: #f7f9fb; border-radius: 12px; padding: 1.25rem 1.5rem; }
.fitting-notice-intro { color: #52606d; font-size: 14px; margin-bottom: 0.5rem; }

.fitting-info-link { display: inline-block; font-size: 12.5px; color: #8a8f98; text-decoration: underline; margin-top: 8px; }

/* Purchase links */
.fitting-purchase-links { display: flex; gap: 0.5rem; justify-content: flex-start; flex-wrap: wrap; margin-top: 0.9rem; }
.fitting-result-best .fitting-purchase-links { justify-content: center; }
.fitting-purchase-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  background: #FFD814;
  border: 1px solid #FCD200;
  color: #0F1111;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 700;
}
.fitting-purchase-btn:hover { background: #F7CA00; }
.fitting-purchase-arrow { font-size: 1rem; line-height: 1; }

.fitting-affiliate-disclaimer {
  font-size: 12px;
  color: #fff;
  text-align: center;
  margin: 0 0 1.25rem;
  padding: 0.6rem 1rem;
  background: #0B0F0A;
  border-radius: 6px;
}

/* Full list / brand chips */
.fitting-full-list { margin-top: 1.5rem; }
.fitting-alt-intro { color: #52606d; font-size: 0.9rem; margin-bottom: 0.75rem; }
.fitting-full-list h3 { font-size: 1.1rem; margin-bottom: 0.4rem; color: #102a43; }
.fitting-brand-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.fitting-brand-chip {
  font-size: 13px; padding: 6px 14px; border-radius: 999px; border: 1.5px solid #e7e9ec;
  background: #fff; color: #52606d; cursor: pointer; font-weight: 600;
}
.fitting-brand-chip--active { border-color: #C8102E; background: #fdf1f2; color: #C8102E; }

.fitting-full-list-rows { display: flex; flex-direction: column; gap: 8px; }
.fitting-list-row { border: 1.5px solid #e7e9ec; border-radius: 10px; background: #fff; overflow: hidden; }
.fitting-list-row--open { border-color: #C8102E; }
.fitting-list-row-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; cursor: pointer; }
.fitting-list-row-name { font-size: 14px; font-weight: 700; color: #102a43; }
.fitting-list-row-brand { font-size: 12px; color: #52606d; }
.fitting-list-row-meta { display: flex; align-items: center; gap: 10px; }
.fitting-list-row-price { font-size: 12px; color: #52606d; }
.fitting-list-row-confidence { font-size: 14px; font-weight: 700; color: #C8102E; }
.fitting-list-row-chevron { font-style: normal; font-size: 12px; color: #8a8f98; transition: transform 0.15s ease; }
.fitting-list-row--open .fitting-list-row-chevron { transform: rotate(180deg); }
.fitting-list-row-why { display: none; padding: 0 16px 14px; border-top: 1px solid #f0f1f3; }
.fitting-list-row--open .fitting-list-row-why { display: block; }
.fitting-list-row-why .fitting-why-list { margin-top: 10px; }
.fitting-list-row-why .fitting-purchase-links { justify-content: flex-start; }

.fitting-retake-btn { display: block; margin: 1.75rem auto 0; background: transparent !important; color: #52606d !important; border: 1.5px solid #d8dce1; }
.fitting-retake-btn:hover { background: #f7f9fb !important; }

.fitting-no-match { text-align: center; padding: 2.5rem 2rem; color: #52606d; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 600px) {
  .fitting-intro-screen { padding: 2.25rem 1.25rem 1.75rem; }
  .fitting-question-screen { padding: 1.75rem 1.25rem; }
  .fitting-results-screen { padding: 1.25rem; }
  .fitting-result-name { font-size: 1.4rem; }
}
