/*
 * File: assets/css/request-quote.css
 * Purpose: Styles for the public combined quotation request page.
 */

:root {
  --rq-navy: #090e34;
  --rq-blue: #3758f9;
  --rq-blue-dark: #2446db;
  --rq-ink: #18223f;
  --rq-muted: #5e6980;
  --rq-border: #e2e8f5;
  --rq-soft: #f5f7ff;
  --rq-error: #b42318;
  --rq-error-border: #f9d2c9;
  --rq-error-bg: #fff0ed;
}

html {
  scroll-padding-top: 90px;
}

#rq-main {
  font-family: inherit;
  color: var(--rq-ink);
}

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

#rq-main p {
  line-height: 1.75;
}

#rq-main a,
#rq-main button {
  transition: background 0.18s ease, color 0.18s ease,
    border-color 0.18s ease, box-shadow 0.18s ease;
}

#rq-main a:focus-visible,
#rq-main button:focus-visible,
#rq-main input:focus-visible,
#rq-main select:focus-visible,
#rq-main textarea:focus-visible {
  outline: 3px solid #8aa0ff;
  outline-offset: 3px;
}

/* ---------- Hero ---------- */

.rq-hero {
  position: relative;
  overflow: hidden;
  padding: 168px 0 88px;
  background:
    radial-gradient(50% 70% at 92% 8%, rgba(55, 88, 249, 0.45), transparent 68%),
    radial-gradient(40% 60% at 4% 96%, rgba(55, 88, 249, 0.18), transparent 70%),
    linear-gradient(125deg, #090e34 12%, #14265e 78%, #243c83 100%);
  color: #ffffff;
}

.rq-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: 56px;
  align-items: center;
  max-width: 1120px;
  margin: 0 auto;
}

.rq-eyebrow {
  display: block;
  margin-bottom: 20px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: #adc1ff;
}

.rq-hero h1 {
  margin: 0;
  max-width: 720px;
  font-size: clamp(38px, 4.2vw, 60px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.045em;
  color: #ffffff;
}

.rq-hero h1 span {
  color: #9eb6ff;
}

.rq-hero-lead {
  max-width: 660px;
  margin: 24px 0 0;
  font-size: 18px;
  line-height: 1.75;
  color: #e1e7fc;
}

.rq-hero-support {
  display: inline-flex;
  align-items: center;
  margin: 24px 0 0;
  padding: 9px 15px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  color: #dce5ff;
}

.rq-hero-card {
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
}

.rq-hero-card h2 {
  margin: 0 0 18px;
  font-size: 23px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.025em;
  color: #ffffff;
}

.rq-hero-steps {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rq-hero-steps li {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  font-size: 14px;
  line-height: 1.6;
  color: #e3e9fc;
}

.rq-hero-steps b {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  font-size: 12px;
  font-weight: 800;
  color: #ffffff;
}

.rq-hero-card-note {
  margin: 22px 0 0;
  padding-top: 17px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 12.5px;
  line-height: 1.6;
  color: #c4d1f4;
}

/* ---------- Form section ---------- */

.rq-form-section {
  padding: 72px 0 88px;
  background: linear-gradient(180deg, #f5f7ff 0%, #ffffff 58%);
}

.rq-form-shell {
  max-width: 1000px;
  margin: 0 auto;
  padding: 40px 42px;
  border: 1px solid var(--rq-border);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 28px 70px -44px rgba(9, 14, 52, 0.5);
}

.rq-form-intro {
  max-width: 720px;
  margin-bottom: 26px;
}

.rq-overline {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--rq-blue);
}

.rq-form-intro h2 {
  margin: 0 0 10px;
  font-size: clamp(28px, 3vw, 36px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.035em;
  color: var(--rq-navy);
}

.rq-form-intro p {
  margin: 0;
  font-size: 14.5px;
  color: var(--rq-muted);
}

.rq-required {
  color: var(--rq-blue);
}

.rq-success {
  margin: 0 0 28px;
  padding: 26px 28px;
  border: 1px solid #bfe8d6;
  border-radius: 14px;
  background: #eefbf6;
  color: #22684c;
}

.rq-success[hidden] {
  display: none;
}

.rq-success-kicker {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #1b7a58;
}

.rq-success h2 {
  margin: 0 0 10px;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #185c43;
}

.rq-success p {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.65;
  color: #2c6d55;
}

.rq-success-reference {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #cbeadc;
  font-size: 14px;
}

.rq-success-reference strong {
  font-size: 17px;
  letter-spacing: 0.01em;
  color: #184d38;
}

.rq-success-note {
  margin-bottom: 0 !important;
  font-size: 12.5px !important;
  color: #4b7d6b !important;
}

.rq-hp {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- Fields ---------- */

.rq-fieldset {
  margin: 0 0 30px;
  padding: 0;
  border: 0;
}

.rq-fieldset legend {
  margin: 0 0 6px;
  padding: 0;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: var(--rq-navy);
}

.rq-section-help {
  margin: 0 0 14px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--rq-muted);
}

.rq-grid {
  display: grid;
  gap: 18px;
}

.rq-grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.rq-field {
  margin: 0;
}

.rq-field label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.45;
  color: #283454;
}

.rq-optional {
  margin-left: 4px;
  font-size: 11px;
  font-weight: 500;
  color: #8893a7;
}

.rq-field input,
.rq-field select,
.rq-field textarea {
  width: 100%;
  min-height: 47px;
  padding: 13px 14px;
  border: 1px solid #cdd6e9;
  border-radius: 9px;
  background: #ffffff;
  font: inherit;
  font-size: 14px;
  line-height: 1.45;
  color: #1c2a4d;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.rq-field textarea {
  min-height: 132px;
  resize: vertical;
}

.rq-field input::placeholder,
.rq-field textarea::placeholder {
  color: #8d98ab;
}

.rq-field input:focus,
.rq-field select:focus,
.rq-field textarea:focus {
  border-color: var(--rq-blue);
  box-shadow: 0 0 0 3px rgba(55, 88, 249, 0.12);
  outline: none;
}

.rq-field.has-error input,
.rq-field.has-error select,
.rq-field.has-error textarea {
  border-color: #d92d20;
  background: #fffafa;
}

.rq-hint {
  margin: 7px 0 0;
  font-size: 11.5px;
  line-height: 1.5;
  color: #7c879b;
}

.rq-hint.is-over-limit {
  color: var(--rq-error);
  font-weight: 700;
}

.rq-error {
  margin: 8px 0 0;
  padding: 9px 11px;
  border: 1px solid var(--rq-error-border);
  border-radius: 8px;
  background: var(--rq-error-bg);
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.5;
  color: var(--rq-error);
}

.rq-error[hidden] {
  display: none;
}

/* ---------- Service selection ---------- */

.rq-service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 2px;
}

.rq-service-option {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  min-height: 66px;
  padding: 14px 15px;
  border: 1px solid #dfe6f3;
  border-radius: 11px;
  background: #ffffff;
  cursor: pointer;
  user-select: none;
}

.rq-service-option:hover {
  border-color: #9fb3f7;
  background: #f8faff;
}

.rq-service-option:has(input:checked) {
  border-color: #5f7cf4;
  background: #eef2ff;
  box-shadow: inset 0 0 0 1px #5f7cf4;
}

.rq-service-option input {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  margin: 2px 0 0;
  accent-color: var(--rq-blue);
}

.rq-service-title {
  display: block;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.4;
  color: #233152;
}

.rq-service-desc {
  display: block;
  margin-top: 3px;
  font-size: 12.5px;
  line-height: 1.5;
  color: #64708a;
}

.rq-fieldset.has-error .rq-service-grid {
  padding: 6px;
  border: 1px solid var(--rq-error-border);
  border-radius: 11px;
  background: #fffafa;
}

/* ---------- Packaging EPR countries ---------- */

.rq-epr-panel {
  margin: 0 0 30px;
  padding: 22px;
  border: 1px solid #d9e2f8;
  border-radius: 14px;
  background: #f8faff;
}

.rq-epr-panel[hidden] {
  display: none;
}

.rq-epr-head h3 {
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
  color: var(--rq-navy);
}

.rq-epr-head p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--rq-muted);
}

.rq-country-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin: 15px 0;
}

.rq-text-button {
  padding: 3px 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 12.5px;
  font-weight: 800;
  color: var(--rq-blue);
  cursor: pointer;
}

.rq-text-button:hover {
  color: var(--rq-blue-dark);
  text-decoration: underline;
}

.rq-country-count {
  margin-left: auto;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--rq-muted);
}

.rq-country-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  max-height: 302px;
  overflow-y: auto;
  padding: 2px;
}

.rq-country-option {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 42px;
  padding: 10px 11px;
  border: 1px solid #dee5f3;
  border-radius: 8px;
  background: #ffffff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  color: #35425f;
  cursor: pointer;
  user-select: none;
}

.rq-country-option:hover {
  border-color: #9fb3f7;
}

.rq-country-option:has(input:checked) {
  border-color: #5f7cf4;
  background: #eef2ff;
  color: #253fac;
}

.rq-country-option input {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: var(--rq-blue);
}

.rq-epr-panel.has-error {
  border-color: var(--rq-error-border);
  background: #fffafa;
}

/* ---------- Actions ---------- */

.rq-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  margin-top: 26px;
  padding-top: 26px;
  border-top: 1px solid #e8ecf5;
}

.rq-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 13px 24px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: var(--rq-blue);
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.4;
  color: #ffffff;
  cursor: pointer;
}

.rq-button:hover {
  background: var(--rq-blue-dark);
}

.rq-button:disabled {
  cursor: not-allowed;
  opacity: 0.65;
  transform: none;
}

.rq-actions-note {
  flex: 1 1 260px;
  margin: 0;
  font-size: 12.5px;
  line-height: 1.65;
  color: #6b7280;
}

.rq-actions-note a {
  color: var(--rq-blue);
  text-decoration: underline;
}

.rq-status {
  margin-top: 18px;
  padding: 13px 15px;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.6;
}

.rq-status[hidden] {
  display: none;
}

.rq-status--error {
  border: 1px solid var(--rq-error-border);
  background: var(--rq-error-bg);
  color: var(--rq-error);
}

.rq-noscript {
  margin: 16px 0 0;
  padding: 12px 14px;
  border: 1px solid #f0d58c;
  border-radius: 8px;
  background: #fff8e6;
  font-size: 13px;
  color: #6b4f00;
}

/* ---------- What happens next ---------- */

.rq-next {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  max-width: 1000px;
  margin: 28px auto 0;
}

.rq-next article {
  padding: 22px;
  border: 1px solid var(--rq-border);
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 18px 40px -36px rgba(9, 14, 52, 0.4);
}

.rq-next article > span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: #eef2ff;
  font-size: 15px;
  font-weight: 800;
  color: var(--rq-blue);
}

.rq-next h3 {
  margin: 0 0 7px;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.35;
  color: var(--rq-navy);
}

.rq-next p {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
  color: var(--rq-muted);
}

/* ---------- Responsive ---------- */

@media (max-width: 1024px) {
  .rq-hero-inner {
    gap: 34px;
  }

  .rq-country-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .rq-hero {
    padding: 140px 0 72px;
  }

  .rq-hero-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .rq-hero-card {
    max-width: 620px;
  }

  .rq-form-shell {
    padding: 32px 28px;
  }
}

@media (max-width: 760px) {
  .rq-grid-2,
  .rq-service-grid,
  .rq-next {
    grid-template-columns: minmax(0, 1fr);
  }

  .rq-form-section {
    padding: 56px 0 64px;
  }

  .rq-country-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rq-country-count {
    width: 100%;
    margin-left: 0;
  }

  .rq-actions .rq-button {
    width: 100%;
  }
}

@media (max-width: 520px) {
  .rq-hero {
    padding: 132px 0 62px;
  }

  .rq-hero h1 {
    font-size: 36px;
  }

  .rq-hero-lead {
    font-size: 16px;
  }

  .rq-hero-card {
    padding: 23px 20px;
  }

  .rq-form-shell {
    padding: 26px 18px;
    border-radius: 16px;
  }

  .rq-form-intro h2 {
    font-size: 27px;
  }

  .rq-service-option {
    padding: 13px 12px;
  }

  .rq-epr-panel {
    padding: 18px 14px;
  }

  .rq-country-option {
    padding: 9px;
    font-size: 12.5px;
  }

  .rq-next article {
    padding: 19px;
  }
}
