/* =====================================================
   RESET + VARIABLES
===================================================== */
:root {
  --bg: #ffffff;
  --surface: #f7f8fa;
  --border: #e0e4ea;
  --text-main: #252a31;
  --text-muted: #6f7783;
  --primary: #4f7cff;
  --success: #1dbe89;
  --danger: #e44335;
  --radius: 12px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text-main);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 15px;
  line-height: 1.6;
}

/* =====================================================
   GLOBAL ELEMENTS
===================================================== */
a {
  color: var(--primary);
  text-decoration: none;
}

h1, h2, h3 {
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
}

h1 {
  font-size: 2.2rem;
  line-height: 1.2;
}

h2 {
  font-size: 1.6rem;
}

h3 {
  font-size: 1.1rem;
}

p {
  margin: 0;
  color: var(--text-muted);
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
}

/* =====================================================
   LAYOUT
===================================================== */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  margin: 64px 0;
}

/* =====================================================
   HEADER
===================================================== */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0;
}

.logo {
  font-weight: 700;
  font-size: 1.1rem;
}

.nav a {
  margin-left: 24px;
  font-weight: 500;
  color: var(--text-main);
}

/* =====================================================
   BUTTONS
===================================================== */
.btn-primary {
  background: var(--primary);
  color: #ffffff;
  padding: 10px 16px;
  border-radius: 6px;
  font-weight: 600;
  display: inline-block;
  transition: opacity 0.2s ease;
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-lg {
  padding: 14px 22px;
  font-size: 15px;
}

.muted {
  color: rgba(255,255,255,0.75);
  font-size: 13px;
}

/* =====================================================
   HERO
===================================================== */
.hero {
  max-width: 720px;
}

.hero-subtitle {
  font-size: 1rem;
  margin-bottom: 28px;
}

.hero-actions {
  margin-top: 24px;
}

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

/* =====================================================
   TRUST SECTION
===================================================== */
.trust {
  background: var(--surface);
  padding: 48px 0;
  border-radius: var(--radius);
}

.trust-grid {
  display: grid;
  gap: 24px;
}

.trust-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

/* =====================================================
   HOW IT WORKS
===================================================== */
.how-grid {
  display: grid;
  gap: 24px;
}

.how-step {
  display: flex;
  align-items: center;
  gap: 12px;
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* =====================================================
   CTA
===================================================== */
.cta-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 48px 32px;
  text-align: center;
}

.cta-card p {
  margin: 12px 0 24px;
}

/* =====================================================
   FOOTER
===================================================== */
.footer {
  border-top: 1px solid var(--border);
  padding: 24px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}

.footer nav a {
  margin-left: 16px;
  color: var(--text-muted);
}

/* =====================================================
   CARD (GENERIC – USED EVERYWHERE)
===================================================== */
.card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

/* =====================================================
   ANALYZER / REWRITE UI
===================================================== */
.rewrite-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  margin: 10px 0;
}

.rewrite-card button {
  margin-top: 8px;
  background: var(--primary);
  color: white;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
}

/* =====================================================
   CONFIDENCE METER
===================================================== */
.confidence-bar {
  height: 6px;
  background: var(--border);
  margin: 6px 0;
  border-radius: 4px;
  overflow: hidden;
}

.confidence-fill {
  height: 100%;
  background: linear-gradient(
    90deg,
    #e44335,
    #ffeb3b,
    #1dbe89
  );
  transition: width 0.4s ease;
}

/* =====================================================
   SCORE ANIMATION
===================================================== */
#scoreAfter {
  font-size: 28px;
  color: var(--success);
  animation: pop 0.4s ease;
}

@keyframes pop {
  from { transform: scale(0.9); }
  to   { transform: scale(1.05); }
}

/* =====================================================
   BLUR / PAYWALL
===================================================== */
.blur {
  filter: blur(6px);
  cursor: pointer;
}

/* =====================================================
   RESPONSIVE
===================================================== */
@media (min-width: 768px) {
  h1 {
    font-size: 2.6rem;
  }

  .trust-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .how-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .hero {
    margin-top: 40px;
  }
}
