/* RoofRatesPro — оригинальный CSS, без копирования advertiser tailwind bundle. */

:root {
  --rr-primary: #ed7d31;
  --rr-primary-700: #d96b1f;
  --rr-secondary: #254798;
  --rr-dark: #0c1932;
  --rr-light: #ffffff;
  --rr-muted: #d6dce8;
  --rr-radius-pill: 9999px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

.rr-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Lato", Helvetica, Arial, sans-serif;
  color: var(--rr-light);
  background: var(--rr-dark);
}

.rr-main { flex: 1 0 auto; display: flex; flex-direction: column; }

/* HERO (step zip) */
.rr-hero {
  position: relative;
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
  background:
    linear-gradient(rgba(12,25,50,0.55), rgba(12,25,50,0.55)),
    url('/roofing/roof-hero.webp') center/cover no-repeat;
  min-height: 90vh;
}

.rr-hero h1 {
  font-size: clamp(1.85rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 1rem;
  max-width: 900px;
}

.rr-hero h4 {
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 500;
  margin: 0 0 2rem;
  color: #f3f7ff;
  max-width: 680px;
}

.rr-zip-row {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: 560px;
}

@media (min-width: 768px) {
  .rr-zip-row { flex-direction: row; }
}

.rr-input {
  width: 100%;
  border: 2px solid #d4d4d8;
  background: #fff;
  color: #111827;
  padding: 14px 24px;
  font-size: 1rem;
  text-align: center;
  border-radius: var(--rr-radius-pill);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.rr-input::placeholder { color: #9ca3af; }
.rr-input:focus { border-color: var(--rr-primary); box-shadow: 0 0 0 3px rgba(237,125,49,0.18); }

.rr-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background: var(--rr-primary);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  padding: 14px 28px;
  border-radius: var(--rr-radius-pill);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.25s, transform 0.05s;
}
.rr-btn:hover { background: var(--rr-primary-700); }
.rr-btn:active { transform: translateY(1px); }
.rr-btn:disabled { opacity: 0.65; cursor: wait; }

.rr-btn--narrow { max-width: 240px; }
.rr-btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,0.4); }
.rr-btn--ghost:hover { background: rgba(255,255,255,0.08); }

/* STEPS — общий контейнер на тёмном фоне */
.rr-step-wrap {
  background: linear-gradient(180deg, #15264b 0%, var(--rr-dark) 100%);
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}

.rr-step-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 16px 8px;
  gap: 14px;
}

.rr-lock {
  position: absolute;
  left: 16px;
  background: var(--rr-secondary);
  border-radius: 9999px;
  padding: 6px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rr-header-row {
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rr-logo {
  display: inline-flex;
  align-items: center;
  font-weight: 800;
  font-size: 1.25rem;
  color: #fff;
  letter-spacing: 0.02em;
}
.rr-logo span.rr-logo-mark {
  background: var(--rr-primary);
  color: #fff;
  padding: 4px 10px;
  border-radius: 8px;
  margin-right: 8px;
}

.rr-progress-rail {
  width: min(100%, 360px);
  height: 6px;
  background: rgba(255,255,255,0.15);
  border-radius: 999px;
  overflow: hidden;
}
.rr-progress-fill {
  height: 100%;
  background: var(--rr-secondary);
  transition: width 0.4s ease;
}

.rr-step {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 28px 20px;
}

.rr-step-inner {
  width: 100%;
  max-width: 720px;
  text-align: center;
}

.rr-step-icon {
  width: 64px;
  height: 64px;
  margin: 8px auto 16px;
}

.rr-step h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  font-weight: 700;
  margin: 0 0 1.4rem;
  line-height: 1.2;
}

.rr-step .rr-subtitle {
  font-size: 1rem;
  color: var(--rr-muted);
  margin: -1rem 0 1.25rem;
}

/* Choice grids */
.rr-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}

.rr-choice-card {
  position: relative;
  background: rgba(255,255,255,0.06);
  border: 2px solid rgba(255,255,255,0.18);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s, background 0.15s;
  color: #fff;
  font-weight: 600;
  padding: 18px 12px;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rr-choice-card:hover { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.35); }
.rr-choice-card.is-active { border-color: var(--rr-primary); background: rgba(237,125,49,0.18); }

.rr-roof-card { padding: 0; }
.rr-roof-card img {
  display: block;
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 12px;
}
@media (max-width: 600px) {
  .rr-roof-card img { height: 100px; }
}
.rr-roof-card .rr-roof-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.0) 30%, rgba(0,0,0,0.6) 100%);
}
.rr-roof-card .rr-roof-label {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  background: var(--rr-primary);
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 700;
  z-index: 2;
}

.rr-row-3 {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}
@media (min-width: 768px) { .rr-row-3 { flex-direction: row; } }

.rr-row-3 .rr-choice-card { flex: 1; }

/* Single inputs (email/name/phone/address) */
.rr-form-row { width: 100%; max-width: 520px; margin: 0 auto; }
.rr-form-row + .rr-form-row { margin-top: 12px; }

.rr-name-pair { display: flex; gap: 12px; flex-direction: column; }
@media (min-width: 600px) { .rr-name-pair { flex-direction: row; } }
.rr-name-pair > div { flex: 1; }

.rr-error {
  display: inline-block;
  margin-top: 8px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.85rem;
  background: #fee2e2;
  color: #991b1b;
}

.rr-disclaimer {
  margin-top: 18px;
  font-size: 0.78rem;
  color: var(--rr-muted);
  line-height: 1.45;
  max-width: 540px;
  text-align: center;
}
.rr-disclaimer a { color: #f6ad55; text-decoration: underline; }

.rr-next-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-top: 18px;
}

.rr-back {
  background: transparent;
  color: #fff;
  border: none;
  padding: 8px 14px;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  opacity: 0.85;
  margin-top: 16px;
}
.rr-back:hover { opacity: 1; }

/* FOOTER */
.rr-footer {
  background: #000;
  color: #fff;
  padding: 28px 16px;
}
.rr-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
}
@media (min-width: 900px) {
  .rr-footer-inner { flex-direction: row; justify-content: space-between; }
}
.rr-footer a {
  color: #cbd5e1;
  margin: 0 8px;
  text-decoration: none;
  font-size: 0.9rem;
}
.rr-footer a:hover { color: #fff; }
.rr-footer-copy { font-size: 0.85rem; color: #94a3b8; }
