/* Pure CSS (the CSP allows no scripts). Laptop layout (>= 900px wide) is
   meant to fit 1366x768 without scrolling; on phones the cards stack in
   reading order with Send last. */

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

:root {
  --accent: #007bff;
  --accent-dark: #0062cc;
  --text: #2b2f36;
  --muted: #6b7280;
  --line: #d0d4da;

  --why-bg: #eaf3ff;   --why-edge: #007bff;
  --info-bg: #e8f6ee;  --info-edge: #28a745;
  --fb-bg: #fff8ec;    --fb-edge: #f0a020;
  --opt-bg: #f3f0fb;   --opt-edge: #7c5cbf;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans', sans-serif;
  font-size: 15px;
  color: var(--text);
  background: #f5f6f8;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }
.wrap.wide { max-width: 1120px; }

/* Header */
.top { background: #fff; border-bottom: 1px solid #e3e5e8; }
.top .wrap { min-height: 46px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; padding-top: 10px; padding-bottom: 8px; }
.brand { font-size: 1.15rem; font-weight: 700; color: #222; letter-spacing: -0.01em; }
.brand:hover { color: var(--accent); text-decoration: none; }
.subtitle { color: var(--muted); font-size: 0.9rem; }

main { padding-top: 16px; padding-bottom: 24px; }

/* Cards */
.card {
  border-radius: 12px;
  border-top: 5px solid transparent;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  padding: 16px 20px;
  background: #fff;
}
.c-why      { background: var(--why-bg);  border-top-color: var(--why-edge); }
.c-info     { background: var(--info-bg); border-top-color: var(--info-edge); }
.c-feedback { background: var(--fb-bg);   border-top-color: var(--fb-edge); }
.c-optional { background: var(--opt-bg);  border-top-color: var(--opt-edge); }
.card.single { margin-top: 8px; padding: 24px; }

h1, h2 { margin: 0 0 8px; color: #1f2328; line-height: 1.25; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.15rem; }
.card p { margin: 0 0 8px; }
.card p:last-child { margin-bottom: 0; }
.h-note { font-size: 0.8rem; font-weight: 500; color: var(--opt-edge); background: #fff; border: 1px solid #d9cff0; border-radius: 999px; padding: 1px 9px; margin-left: 6px; vertical-align: 2px; }

.c-info ul { margin: 0; padding: 0; list-style: none; }
.c-info li { position: relative; padding-left: 24px; margin-bottom: 4px; }
.c-info li::before { content: "✓"; position: absolute; left: 2px; color: var(--info-edge); font-weight: 700; }

/* Layout */
.grid { display: grid; gap: 14px; }
.form { display: grid; gap: 14px; }

@media (min-width: 900px) {
  .grid { grid-template-columns: 1fr 1fr; }
  .form {
    grid-column: 1 / -1;
    grid-template-columns: 1.1fr 1fr;
    grid-template-rows: 1fr auto;
    grid-template-areas: "fb opt" "send opt";
  }
  .c-feedback { grid-area: fb; display: flex; flex-direction: column; }
  .c-optional { grid-area: opt; }
  .send { grid-area: send; }
  .c-feedback .grow { flex: 1; display: flex; flex-direction: column; margin-bottom: 0; }
  .c-feedback .grow textarea { flex: 1; }
}

/* Fields */
.field { margin-bottom: 10px; }
label { display: block; font-weight: 600; color: #1f2328; margin-bottom: 4px; font-size: 0.95rem; }
.hint { font-weight: 400; color: var(--muted); font-size: 0.85rem; }
.req { font-weight: 500; font-size: 0.75rem; color: #9a5b00; background: #fff; border: 1px solid #f3cf8e; border-radius: 999px; padding: 0 8px; margin-left: 4px; white-space: nowrap; }

input[type="text"], input[type="email"], textarea {
  width: 100%;
  font: inherit;
  color: inherit;
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
}
textarea { resize: vertical; min-height: 120px; }
::placeholder { color: #9aa1ab; }
input:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(0,123,255,0.18); }

.has-error input, .has-error textarea { border-color: #d9534f; }
.error { color: #c0392b; margin: 4px 0 0; font-size: 0.88rem; }
.alert { background: #fff; border-left: 4px solid #d9534f; border-radius: 6px; padding: 6px 10px; font-size: 0.92rem; }

.row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }

.checks { margin-top: 4px; }
.checks label { display: flex; gap: 9px; align-items: flex-start; font-weight: 400; margin-bottom: 4px; cursor: pointer; }
.checks input { margin-top: 0.3em; width: 17px; height: 17px; flex: none; accent-color: var(--opt-edge); }

/* Send */
.send { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; }
.send-note { color: var(--muted); font-size: 0.88rem; }

button, .button {
  display: inline-block;
  font: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 9px;
  padding: 12px 34px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,123,255,0.3);
}
button:hover, .button:hover { background: var(--accent-dark); text-decoration: none; }
button:focus-visible, .button:focus-visible { outline: 3px solid rgba(0,123,255,0.4); outline-offset: 2px; }

@media (max-width: 560px) {
  .row { grid-template-columns: 1fr; }
  .card { padding: 14px 16px; }
  h1 { font-size: 1.35rem; }
  .send button { width: 100%; }
}

/* Honeypot: off-screen rather than display:none, which some bots skip. */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
