/* ── proof.css ── */

/* Body / layout overrides */
body[data-tab="proof"] {
  background: #120c08;
}

/* ── Game wrap ─────────────────────────────────────────────────────────────── */
#pf-wrap {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  padding: 20px 16px 32px;
  box-sizing: border-box;
}

/* ── Shared section util ───────────────────────────────────────────────────── */
.pf-hide { display: none !important; }

.pf-center-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  text-align: center;
  padding: 24px 0;
}

/* ── Loading ──────────────────────────────────────────────────────────────── */
.pf-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(196,163,90,0.2);
  border-top-color: #C4A35A;
  border-radius: 50%;
  animation: pf-spin 0.9s linear infinite;
}

@keyframes pf-spin {
  to { transform: rotate(360deg); }
}

.pf-loading-text {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  color: rgba(196,163,90,0.65);
  margin: 0;
}

/* ── Error ─────────────────────────────────────────────────────────────────── */
.pf-error-icon {
  font-size: 2.5rem;
  margin: 0;
}

.pf-error-msg {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.6;
  margin: 0;
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */
.pf-btn {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  padding: 14px 36px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
}

.pf-btn:active { transform: scale(0.97); opacity: 0.85; }

.pf-btn-start {
  background: #C4202A;
  color: #fff;
  font-size: 1.1rem;
  padding: 16px 48px;
  letter-spacing: 0.03em;
}

.pf-btn-share {
  background: #C4A35A;
  color: #120c08;
  font-weight: 700;
}

/* ── Splash ────────────────────────────────────────────────────────────────── */
.pf-logo-wrap {
  margin-bottom: 8px;
}

.pf-logo {
  height: 52px;
  display: block;
}

.pf-splash-tagline {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: rgba(255,255,255,0.55);
  line-height: 1.6;
  margin: 0;
  max-width: 300px;
}

.pf-source-badge {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 0.82rem;
  color: rgba(196,163,90,0.7);
  border: 1px solid rgba(196,163,90,0.25);
  border-radius: 20px;
  padding: 6px 16px;
  max-width: 280px;
}

/* ── Timer bar ─────────────────────────────────────────────────────────────── */
.pf-timer-bar {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-bottom: 16px;
}

.pf-timer-label {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(196,163,90,0.5);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pf-timer {
  font-family: 'DM Sans', sans-serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: #F0C040;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  min-width: 5ch;
  text-align: right;
}

/* ── Passage card ──────────────────────────────────────────────────────────── */
.pf-passage-card {
  background: #FBF5E4;
  border-radius: 12px;
  padding: 24px 22px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.5);
}

.pf-passage {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.85;
  color: #1a100a;
  word-break: break-word;
}

/* ── Clickable words ───────────────────────────────────────────────────────── */
.pf-word {
  cursor: pointer;
  border-radius: 3px;
  padding: 0 1px;
  transition: background 0.1s;
}

.pf-word:hover {
  background: rgba(196,32,42,0.12);
}

/* Wrong click — red flash */
.pf-word.pf-penalty {
  background: rgba(220,38,38,0.35) !important;
  animation: pf-flash 0.4s ease-out forwards;
}

@keyframes pf-flash {
  0%   { background: rgba(220,38,38,0.55); }
  100% { background: rgba(220,38,38,0); }
}

/* Correct click — yellow highlight stays */
.pf-word.pf-correct {
  background: #FBBF24 !important;
  color: #120c08 !important;
  border-radius: 3px;
  animation: pf-correct-pop 0.3s ease-out;
}

@keyframes pf-correct-pop {
  0%   { transform: scale(1.12); }
  100% { transform: scale(1); }
}

/* ── Hint text ─────────────────────────────────────────────────────────────── */
.pf-hint {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.3);
  text-align: center;
  margin: 12px 0 0;
}

/* ── Result ────────────────────────────────────────────────────────────────── */
#pf-result {
  display: none;
  flex-direction: column;
  gap: 16px;
}

#pf-result:not(.pf-hide) {
  display: flex;
}

.pf-result-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.pf-result-logo {
  height: 36px;
}

.pf-result-time-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.pf-result-label {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  color: rgba(196,163,90,0.5);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pf-result-time {
  font-family: 'DM Sans', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: #F0C040;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

/* Result passage: non-interactive but highlighted */
.pf-result-passage-card {
  margin: 0;
}

.pf-result-passage {
  font-size: 0.95rem;
  line-height: 1.8;
}

mark.pf-highlight {
  background: #FBBF24;
  color: #120c08;
  padding: 0 2px;
  border-radius: 2px;
  font-style: normal;
  font-weight: 600;
}

.pf-result-source {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 0.82rem;
  color: rgba(196,163,90,0.65);
  text-align: center;
  margin: 0;
}

.pf-comeback {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.28);
  text-align: center;
  margin: 0;
}
