/* ═══════════════════════════════════════════════════════════
   Crownzcom Limited · Awinyo Business Rules Form (Simplified)
   Palette: Navy #0B1F4B · Gold #C9A84C
   ═══════════════════════════════════════════════════════════ */

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

:root {
  --navy:       #0B1F4B;
  --navy-dark:  #07152f;
  --navy-mid:   #152d6b;
  --gold:       #C9A84C;
  --gold-light: #e8c96f;
  --gold-pale:  #faf5e8;
  --gold-dark:  #a07a2c;
  --white:      #FFFFFF;
  --off-white:  #F5F7FB;
  --border:     #dde3ef;
  --text:       #1a2540;
  --text-sub:   #4a5568;
  --text-light: #6b7280;
  --red:        #c0392b;
  --green:      #1a7a4a;
  --radius:     10px;
  --shadow:     0 2px 12px rgba(11,31,75,.09);
  --shadow-md:  0 4px 20px rgba(11,31,75,.13);
  --transition: all 0.2s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--off-white);
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
}

/* ── Header ── */
.site-header {
  background: var(--navy-dark);
  border-bottom: 3px solid var(--gold);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0,0,0,.25);
}

.header-inner {
  max-width: 860px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 11px;
}

.logo-crown {
  width: 36px;
  height: 36px;
  background: var(--gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy-dark);
  font-size: 16px;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--white);
}

.brand-tagline {
  font-size: 10.5px;
  color: var(--gold-light);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.client-pill {
  background: rgba(201,168,76,.18);
  border: 1px solid rgba(201,168,76,.35);
  color: var(--gold-light);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

/* ── Hero ── */
.hero-section {
  background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 60%, var(--navy-mid) 100%);
  padding: 52px 24px 44px;
  text-align: center;
}

.hero-inner {
  max-width: 640px;
  margin: 0 auto;
}

.hero-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(26px, 5vw, 40px);
  font-weight: 700;
  color: var(--white);
  line-height: 1.2;
  margin-bottom: 14px;
}

.hero-title .highlight { color: var(--gold-light); }

.hero-subtitle {
  font-size: 15px;
  color: rgba(255,255,255,.72);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.7;
}

.hero-subtitle strong { color: var(--white); }

/* ── Form Wrapper ── */
.form-wrapper {
  max-width: 760px;
  margin: 0 auto;
  padding: 36px 20px 60px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ── Sections ── */
.form-section {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.form-section:focus-within {
  box-shadow: var(--shadow-md);
}

.section-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(to right, var(--gold-pale), var(--white) 60%);
}

.section-icon {
  width: 38px;
  height: 38px;
  background: var(--navy);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}

.section-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 2px;
}

.section-desc {
  font-size: 13px;
  color: var(--text-sub);
}

/* ── Fields container ── */
.fields {
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* ── Individual field ── */
.field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

label {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}

.req { color: var(--red); }

.note, .hint {
  font-weight: 400;
  color: var(--text-light);
  font-size: 12.5px;
}

/* Sub-label explanatory text beneath a question label */
.label-sub {
  display: block;
  font-weight: 400;
  font-size: 13px;
  color: var(--text-sub);
  margin-top: 4px;
  line-height: 1.55;
  padding: 6px 10px;
  background: var(--gold-pale);
  border-left: 3px solid var(--gold);
  border-radius: 0 4px 4px 0;
}

/* Small note beneath an input */
.field-note {
  font-size: 12px;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 2px;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 9px 13px;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  color: var(--text);
  background: var(--white);
  transition: var(--transition);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(11,31,75,.1);
}

input:hover, select:hover, textarea:hover {
  border-color: var(--gold-dark);
}

input.invalid, select.invalid, textarea.invalid {
  border-color: var(--red) !important;
  background: #fff6f6;
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='7' viewBox='0 0 11 7'%3E%3Cpath fill='%230B1F4B' d='M5.5 7L0 0h11z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  padding-right: 34px;
  cursor: pointer;
}

textarea {
  resize: vertical;
  min-height: 90px;
}

input::placeholder, textarea::placeholder { color: #b0b8cc; font-weight: 400; }

/* ── Radio & Checkbox groups ── */
.radio-group,
.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 2px;
}

.radio-group.inline {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.radio-item,
.check-item {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 14px;
  font-weight: 400;
  color: var(--text);
  cursor: pointer;
  padding: 8px 12px;
  border: 1.5px solid transparent;
  border-radius: 6px;
  transition: var(--transition);
  line-height: 1.5;
}

.radio-item:hover,
.check-item:hover {
  background: var(--gold-pale);
  border-color: var(--gold-light);
}

.radio-item input,
.check-item input {
  width: 16px;
  height: 16px;
  min-width: 16px;
  accent-color: var(--navy);
  margin-top: 2px;
  cursor: pointer;
}

.radio-item.invalid,
.check-item.invalid {
  border-color: var(--red);
  background: #fff6f6;
}

/* ── Declaration box ── */
.declaration-box {
  background: var(--gold-pale);
  border: 1px solid rgba(201,168,76,.45);
  border-left: 4px solid var(--gold);
  border-radius: 6px;
  padding: 14px 18px;
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.65;
}

.declaration-box strong { color: var(--navy); }

/* ── Submit button ── */
.btn-submit {
  width: 100%;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 14px 24px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  letter-spacing: 0.02em;
  transition: var(--transition);
  border-bottom: 3px solid var(--gold-dark);
}

.btn-submit:hover {
  background: linear-gradient(135deg, var(--navy-mid) 0%, var(--navy) 100%);
  box-shadow: 0 5px 20px rgba(11,31,75,.28);
  transform: translateY(-1px);
}

.btn-submit:active { transform: translateY(0); }

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* ── Success ── */
.success-banner {
  background: var(--white);
  border: 1px solid #b2dfcc;
  border-left: 5px solid var(--green);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

.success-inner {
  padding: 44px 32px;
  text-align: center;
}

.success-icon {
  font-size: 52px;
  color: var(--green);
  margin-bottom: 16px;
}

.success-inner h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 26px;
  color: var(--navy);
  margin-bottom: 12px;
}

.success-inner p {
  font-size: 15px;
  color: var(--text-sub);
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.7;
}

.success-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 20px;
  background: var(--gold-pale);
  border: 1px solid var(--gold-light);
  padding: 9px 20px;
  border-radius: 30px;
  font-size: 14px;
  color: var(--navy);
  font-weight: 600;
  text-decoration: none;
}

.success-link:hover { background: #f0e4bb; }

/* ── Error ── */
.error-banner {
  background: #fff5f5;
  border: 1px solid #fca5a5;
  border-left: 4px solid var(--red);
  border-radius: 6px;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--red);
  font-size: 14px;
  font-weight: 500;
}

/* ── Footer ── */
.site-footer {
  background: var(--navy-dark);
  border-top: 3px solid var(--gold);
  padding: 16px 24px;
}

.footer-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: rgba(255,255,255,.5);
}

.logo-crown-sm { color: var(--gold); font-size: 13px; }
.footer-inner strong { color: rgba(255,255,255,.75); }

/* ── Shake animation ── */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-4px); }
  40%, 80% { transform: translateX(4px); }
}
.shake { animation: shake 0.35s ease; }

/* ── Fade-in for sections ── */
.form-section {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.45s ease, transform 0.45s ease, box-shadow 0.2s;
}
.form-section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .row-2 { grid-template-columns: 1fr; }

  .fields { padding: 16px 18px 20px; }

  .section-header { padding: 14px 18px; }

  .radio-group.inline { flex-direction: column; gap: 6px; }

  .hero-section { padding: 36px 16px 30px; }

  .header-inner { gap: 8px; }

  .success-inner { padding: 32px 20px; }
}
