/* ==========================================================================
   site-info.css — layout and components for the stepped Site Submission form
   Tetra Consulting. Hand-authored: nothing in the deploy pipeline generates
   this file, and tailwind.css must not be regenerated (it has been hand-edited
   — see .guidance-link, which now lives here instead).
   Loaded AFTER /tailwind.css so these rules win where they overlap.
   ========================================================================== */

:root {
  --tetra-teal: #187272;
  --tetra-teal-dark: #145f5f;
  --tetra-teal-tint: #f0f7f7;
  --tetra-teal-tint-2: #dfeceb;
  --tetra-indigo: #3c3c76;
  --tetra-ink: #111827;
  --tetra-ink-soft: #374151;
  --tetra-ink-muted: #6b7280;
  --tetra-rule: #e5e7eb;
  --tetra-rule-soft: #f3f4f6;
  --tetra-paper: #f9fafb;
  --tetra-amber-bg: #fffbeb;
  --tetra-amber-line: #fde68a;
  --tetra-amber-ink: #92400e;
  --tetra-red: #b91c1c;
  --tetra-red-bg: #fef2f2;
  --tetra-red-line: #fecaca;
  --si-rail: 288px;
}

/* --------------------------------------------------------------------------
   Shell
   -------------------------------------------------------------------------- */

.si-shell {
  display: flex;
  align-items: flex-start;
  min-height: 100vh;
  background: var(--tetra-paper);
}

.si-rail {
  width: var(--si-rail);
  flex: 0 0 var(--si-rail);
  align-self: stretch;
  background: linear-gradient(to bottom, var(--tetra-teal), var(--tetra-indigo));
  color: #fff;
  padding: 32px 24px;
  position: sticky;
  top: 0;
  max-height: 100vh;
  overflow-y: auto;
}

.si-rail-logo {
  width: 118px;
  height: auto;
  display: block;
  margin-bottom: 28px;
}

.si-rail-title {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 4px;
}

.si-rail-sub {
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.75);
  margin: 0 0 28px;
}

.si-main {
  flex: 1 1 auto;
  min-width: 0;
  padding: 40px 40px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.si-col {
  width: 100%;
  max-width: 760px;
}

/* --------------------------------------------------------------------------
   Step list (in the rail)
   -------------------------------------------------------------------------- */

.si-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.si-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 9px 10px;
  border-radius: 8px;
  border: 0;
  background: none;
  width: 100%;
  text-align: left;
  font: inherit;
  color: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    color 0.15s ease;
}

.si-step:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.si-step:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.si-step[aria-current="step"] {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.si-step-num {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  margin-top: 1px;
}

.si-step[aria-current="step"] .si-step-num {
  background: #fff;
  border-color: #fff;
  color: var(--tetra-teal);
}

.si-step[data-state="done"] .si-step-num {
  background: rgba(255, 255, 255, 0.9);
  border-color: transparent;
  color: var(--tetra-teal);
}

.si-step-label {
  font-size: 14px;
  line-height: 1.35;
  padding-top: 2px;
}

.si-step-note {
  display: block;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.55);
  margin-top: 1px;
}

.si-step[hidden] {
  display: none;
}

.si-rail-help {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 12px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.7);
}

.si-rail-help p {
  margin: 0;
}

.si-rail-help a {
  color: #fff;
  text-decoration: underline;
}

.si-rail-help a:hover {
  color: rgba(255, 255, 255, 0.8);
}

/* --------------------------------------------------------------------------
   Step header
   -------------------------------------------------------------------------- */

.si-step-head {
  margin-bottom: 28px;
}

.si-eyebrow {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--tetra-ink-muted);
  margin: 0 0 6px;
}

.si-h1 {
  font-size: 27px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: var(--tetra-ink);
  margin: 0 0 8px;
}

.si-lede {
  font-size: 15px;
  line-height: 1.55;
  color: var(--tetra-ink-soft);
  max-width: 46em;
  margin: 0;
}

/* --------------------------------------------------------------------------
   Panes and groups. Existing <section> cards are restyled in place: the card
   chrome is dropped in favour of whitespace and a single hairline.
   -------------------------------------------------------------------------- */

.si-pane {
  display: none;
}

.si-pane.is-active {
  display: block;
}

.si-shell .si-pane > section {
  background: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  margin: 0 0 40px;
  max-width: none;
}

.si-shell .si-pane > section:last-of-type {
  margin-bottom: 0;
}

.si-shell .si-pane > section > h2 {
  font-size: 17px;
  font-weight: 600;
  color: var(--tetra-ink);
  letter-spacing: -0.005em;
  margin: 0 0 4px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--tetra-rule);
}

.si-shell .si-pane > section > h2 + * {
  margin-top: 20px;
}

/* Conditional service sections keep a tint so it is clear they were added
   because of the requested service. */
.si-shell .si-pane > section.si-service {
  background: var(--tetra-teal-tint);
  border-radius: 10px;
  padding: 24px;
}

.si-shell .si-pane > section.si-service > h2 {
  border-bottom-color: var(--tetra-teal-tint-2);
}

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

.si-shell label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--tetra-ink);
  line-height: 1.4;
  margin-bottom: 5px;
}

.si-shell input[type="text"],
.si-shell input[type="number"],
.si-shell input[type="date"],
.si-shell input[type="email"],
.si-shell input[type="tel"],
.si-shell select,
.si-shell textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  font-size: 15px;
  color: var(--tetra-ink);
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  box-shadow: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.si-shell textarea {
  min-height: 96px;
  line-height: 1.5;
  resize: vertical;
}

.si-shell select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236b7280' stroke-width='1.6'%3E%3Cpath d='M6 8l4 4 4-4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 18px 18px;
  padding-right: 36px;
}

.si-shell input:focus,
.si-shell select:focus,
.si-shell textarea:focus {
  outline: none;
  border-color: var(--tetra-teal);
  box-shadow: 0 0 0 3px rgba(24, 114, 114, 0.18);
}

.si-shell input.border-red-500,
.si-shell select.border-red-500,
.si-shell textarea.border-red-500 {
  border-color: #dc2626;
  background: #fffafa;
}

.si-shell input[readonly],
.si-shell input:disabled,
.si-shell select:disabled,
.si-shell textarea:disabled {
  background: var(--tetra-rule-soft);
  color: var(--tetra-ink-soft);
  cursor: not-allowed;
}

/* Two-column field grid on wide viewports */
.si-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 24px;
}

.si-grid > .si-wide,
.si-grid > .md\:col-span-2 {
  grid-column: 1 / -1;
}

/* --------------------------------------------------------------------------
   Read-only value rows (address, requested service, subtypes)
   -------------------------------------------------------------------------- */

.si-readonly {
  display: grid;
  grid-template-columns: minmax(0, 200px) minmax(0, 1fr);
  gap: 10px 24px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid var(--tetra-rule);
  border-radius: 10px;
  font-size: 15px;
}

.si-readonly dt {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--tetra-ink-muted);
  padding-top: 2px;
}

.si-readonly dd {
  margin: 0;
  color: var(--tetra-ink);
}

/* --------------------------------------------------------------------------
   Guidance: bucket A inline hints, bucket B expandable panels,
   bucket C statutory links. Replaces .guidance-link, which was hand-inserted
   into the generated tailwind.css and is reproduced here.
   -------------------------------------------------------------------------- */

.si-hint {
  display: block;
  font-size: 13px;
  line-height: 1.5;
  color: var(--tetra-ink-muted);
  margin: 5px 0 0;
  max-width: 52em;
}

.si-hint a,
.si-help-body a {
  color: var(--tetra-teal);
  text-decoration: underline;
}

.si-hint a:hover,
.si-help-body a:hover {
  color: var(--tetra-teal-dark);
}

.si-help {
  margin-top: 6px;
}

.si-help > summary {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 500;
  color: var(--tetra-teal);
  cursor: pointer;
  list-style: none;
  padding: 2px 0;
}

.si-help > summary::-webkit-details-marker {
  display: none;
}

.si-help > summary:hover {
  color: var(--tetra-teal-dark);
  text-decoration: underline;
}

.si-help > summary:focus-visible {
  outline: 2px solid var(--tetra-teal);
  outline-offset: 2px;
  border-radius: 3px;
}

.si-help > summary::before {
  content: "";
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  background: currentColor;
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
  transform: rotate(0deg);
  transition: transform 0.15s ease;
}

.si-help[open] > summary::before {
  transform: rotate(90deg);
}

.si-help-body {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--tetra-ink-soft);
  background: var(--tetra-teal-tint);
  border-radius: 8px;
  padding: 14px 16px;
  margin-top: 8px;
  max-width: 52em;
}

.si-help-body p {
  margin: 0 0 8px;
}

.si-help-body p:last-child {
  margin-bottom: 0;
}

.si-help-body ul {
  margin: 0 0 8px;
  padding-left: 18px;
  list-style: disc;
}

.si-help-body li {
  margin-bottom: 3px;
}

/* Retained from tailwind.css, where it had been hand-inserted into
   @layer utilities and would be lost on any regeneration. */
.guidance-link {
  color: #667675;
  opacity: 0.8;
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.guidance-link:hover {
  color: var(--tetra-teal);
  opacity: 0.7;
}

/* --------------------------------------------------------------------------
   Checkbox and radio groups
   -------------------------------------------------------------------------- */

.si-shell fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}

.si-shell legend {
  font-size: 14px;
  font-weight: 500;
  color: var(--tetra-ink);
  padding: 0;
  margin-bottom: 8px;
}

.si-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 8px 20px;
}

.si-shell .si-options label,
.si-shell .si-opt {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.45;
  color: var(--tetra-ink-soft);
  margin: 0;
  padding: 5px 0;
  cursor: pointer;
  min-height: 32px;
}

.si-shell .si-options input[type="checkbox"],
.si-shell .si-options input[type="radio"],
.si-shell .si-opt input {
  flex: 0 0 17px;
  width: 17px;
  height: 17px;
  margin: 2px 0 0;
  accent-color: var(--tetra-teal);
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Notices
   -------------------------------------------------------------------------- */

.si-note {
  display: flex;
  gap: 10px;
  font-size: 13.5px;
  line-height: 1.55;
  border-radius: 8px;
  padding: 12px 14px;
  margin: 0 0 24px;
}

.si-note-info {
  background: var(--tetra-teal-tint);
  color: var(--tetra-ink-soft);
}

.si-note-warn {
  background: var(--tetra-amber-bg);
  border: 1px solid var(--tetra-amber-line);
  color: var(--tetra-amber-ink);
}

.si-note-error {
  background: var(--tetra-red-bg);
  border: 1px solid var(--tetra-red-line);
  color: var(--tetra-red);
}

.si-note p {
  margin: 0;
}

.si-note-title {
  font-weight: 600;
  margin-bottom: 3px;
}

.si-note ul {
  list-style: disc;
  margin: 6px 0 0;
  padding-left: 18px;
}

.si-note li {
  margin-bottom: 2px;
}

.si-note li button {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Footer navigation
   -------------------------------------------------------------------------- */

.si-footer {
  position: sticky;
  bottom: 0;
  background: var(--tetra-paper);
  border-top: 1px solid var(--tetra-rule);
  margin-top: 40px;
  padding: 16px 0 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.si-footer-spacer {
  flex: 1 1 auto;
}

.si-progress {
  font-size: 13px;
  color: var(--tetra-ink-muted);
}

.si-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 22px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.si-btn:focus-visible {
  outline: 2px solid var(--tetra-teal);
  outline-offset: 2px;
}

.si-btn-primary {
  background: var(--tetra-teal);
  color: #fff;
  font-weight: 600;
}

.si-btn-primary:hover {
  background: var(--tetra-teal-dark);
}

.si-btn-primary:active {
  background: #114f4f;
}

.si-btn-secondary {
  background: #fff;
  border-color: #d1d5db;
  color: var(--tetra-ink-soft);
}

.si-btn-secondary:hover {
  background: var(--tetra-rule-soft);
  border-color: #9ca3af;
}

.si-btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}

/* --------------------------------------------------------------------------
   Mobile. Deliberately minimal for this release — the rail collapses to a
   compact progress bar so nothing is unreachable on a phone. A full mobile
   pass is a separate piece of work.
   -------------------------------------------------------------------------- */

@media (max-width: 900px) {
  .si-shell {
    flex-direction: column;
  }

  .si-rail {
    width: 100%;
    flex: none;
    position: static;
    max-height: none;
    padding: 18px 20px;
  }

  .si-rail-logo {
    width: 92px;
    margin-bottom: 14px;
  }

  .si-rail-sub,
  .si-rail-help {
    display: none;
  }

  .si-steps {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
  }

  .si-step {
    width: auto;
    padding: 6px 10px;
  }

  .si-step-label,
  .si-step-note {
    display: none;
  }

  .si-main {
    padding: 24px 20px 0;
  }

  .si-grid,
  .si-readonly {
    grid-template-columns: minmax(0, 1fr);
  }

  .si-readonly dt {
    text-transform: none;
    letter-spacing: 0;
    font-size: 12.5px;
  }

  .si-h1 {
    font-size: 23px;
  }
}
