/* Rislix concept 08c: Contact page. Loaded after styles.css and pages.css. Classes are prefixed ct-. */

.ct-hero { padding-bottom: clamp(56px, 7vw, 96px); }

.ct-main { padding-top: clamp(48px, 6vw, 88px); }
.ct-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(28px, 5vw, 72px); align-items: start; }

/* ---------- form panel ---------- */
.ct-panel {
  background: #fff; border-radius: 18px; padding: clamp(22px, 4vw, 48px);
  box-shadow: 0 0 0 1px rgba(16, 32, 48, .08), 0 40px 80px -48px rgba(16, 32, 48, .4);
}
.ct-h { font-family: var(--display); font-weight: 500; font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.12; letter-spacing: -.02em; }
.ct-intro { margin-top: 8px; color: var(--ink-d-soft); }
.ct-form { display: grid; gap: 26px; }
.ct-form[hidden], .ct-summary[hidden] { display: none; }
.ct-form > .ct-h + .ct-intro { margin-top: -18px; }

.ct-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 20px; }
.ct-field { display: flex; flex-direction: column; min-width: 0; }
.ct-field label, .ct-group legend { font-weight: 600; font-size: 1rem; line-height: 1.35; color: var(--ink-d); }
.ct-opt { font-weight: 400; color: var(--ink-d-soft); }
.ct-help { margin-top: 2px; font-size: .9375rem; color: var(--ink-d-soft); line-height: 1.45; }
.ct-field input, .ct-field textarea {
  margin-top: 8px; width: 100%; min-height: 48px; padding: 11px 14px;
  font: inherit; font-size: 1rem; color: var(--ink-d); background: #fff;
  border: 1px solid #74818E; border-radius: 10px;
  transition: border-color .2s, box-shadow .2s;
}
.ct-field textarea { resize: vertical; min-height: 128px; line-height: 1.5; }
.ct-field input:hover, .ct-field textarea:hover { border-color: var(--ink-d-soft); }
.ct-field input:focus, .ct-field textarea:focus { outline: none; border-color: var(--verd-d); box-shadow: 0 0 0 3px rgba(23, 114, 93, .25); }
.ct-field input:focus-visible, .ct-field textarea:focus-visible { outline: 3px solid var(--verd-d); outline-offset: 1px; box-shadow: none; }
.ct-field input[aria-invalid="true"], .ct-field textarea[aria-invalid="true"] { border: 2px solid #9E2F28; padding: 10px 13px; }

.ct-err { margin-top: 6px; font-size: .9375rem; font-weight: 600; color: #9E2F28; line-height: 1.4; display: flex; gap: 8px; align-items: flex-start; }
.ct-err:empty { display: none; }
.ct-err::before { content: ""; flex: none; width: 16px; height: 16px; margin-top: 3px; border-radius: 50%; background: #9E2F28 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 4v5' stroke='%23fff' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='8' cy='11.8' r='1.2' fill='%23fff'/%3E%3C/svg%3E") center / 100% no-repeat; }

/* ---------- error summary ---------- */
.ct-summary { padding: 18px 20px; border-radius: 10px; background: #FBEDEB; border-left: 4px solid #9E2F28; }
.ct-summary:focus { outline: 3px solid #9E2F28; outline-offset: 3px; }
.ct-summary h3 { font-family: var(--display); font-weight: 600; font-size: 1.125rem; color: #7E241F; }
.ct-summary ul { margin-top: 8px; display: grid; gap: 4px; }
.ct-summary a { color: #7E241F; font-weight: 600; text-underline-offset: 3px; display: inline-block; padding: 4px 0; }
.js .ct-summary:not([hidden]) { animation: ctShake .4s var(--ease-out); }
@keyframes ctShake { 0%, 100% { transform: none; } 25% { transform: translateX(-4px); } 60% { transform: translateX(3px); } }

/* ---------- submit ---------- */
.ct-submit { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; padding-top: 4px; }

/* ---------- confirmation ---------- */
.ct-done { display: grid; justify-items: start; gap: 14px; }
.ct-done[hidden] { display: none; }
.ct-done > p { color: var(--ink-d-soft); max-width: 52ch; }
.ct-done .ct-h:focus { outline: none; }
.ct-done .ct-h:focus-visible { outline: 3px solid var(--verd-d); outline-offset: 4px; }
.ct-env { width: 132px; height: auto; margin-bottom: 4px; overflow: visible; }
.ct-env-back { fill: #DCE6E0; stroke: var(--ink-d); stroke-width: 2; }
.ct-env-letter rect { fill: #fff; stroke: var(--ink-d); stroke-width: 2; }
.ct-env-letter path { stroke: rgba(16, 32, 48, .35); stroke-width: 3; stroke-linecap: round; }
.ct-env-letter { transform: translateY(34px); }
.ct-env-front { fill: #EAF0EB; stroke: var(--ink-d); stroke-width: 2; stroke-linejoin: round; }
.ct-env-flap { fill: #F3F6F1; stroke: var(--ink-d); stroke-width: 2; stroke-linejoin: round; transform-box: fill-box; transform-origin: 50% 0; }
.ct-env-badge circle { fill: var(--verd-d); }
.ct-env-badge path { fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.ct-env-badge { transform-box: fill-box; transform-origin: center; }

.ct-done.is-on .ct-env-letter { animation: ctLetter 1.5s var(--ease) both; }
.ct-done.is-on .ct-env-flap { animation: ctFlap .5s var(--ease-out) 1.45s both; }
.ct-done.is-on .ct-env-badge { animation: ctBadge .5s var(--ease-out) 1.85s both; }
.ct-done.is-on .ct-env-badge path { animation: ctTick .45s var(--ease-out) 2.15s both; }
.ct-done.is-on .ct-env { animation: ctLift .7s var(--ease-out) 1.9s both; }
@keyframes ctLetter { 0% { transform: translateY(-12px); opacity: 0; } 30%, 55% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(34px); opacity: 1; } }
@keyframes ctFlap { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes ctBadge { from { transform: scale(0); } 70% { transform: scale(1.12); } to { transform: scale(1); } }
@keyframes ctTick { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes ctLift { 0% { transform: none; } 50% { transform: translateY(-5px); } 100% { transform: none; } }
.ct-link { min-height: 44px; padding: 8px 6px; border: 0; background: none; font-weight: 600; color: var(--ink-d); text-decoration: underline; text-underline-offset: 3px; }
.ct-panel :focus-visible { outline-color: var(--verd-d); }

/* ---------- side column ---------- */
.ct-side { position: sticky; top: calc(var(--head-h) + 28px); display: grid; gap: 0; }
.ct-h3 { font-family: var(--display); font-weight: 600; font-size: 1.25rem; line-height: 1.2; }
.ct-ways { margin-top: 14px; display: grid; }
.ct-ways > div { padding: 12px 0; border-top: 1px solid var(--line-d); }
.ct-ways > div:last-child { border-bottom: 1px solid var(--line-d); }
.ct-ways dt { font-size: .875rem; color: var(--ink-d-soft); }
.ct-ways dd a { display: inline-flex; align-items: center; min-height: 44px; font-family: var(--display); font-size: 1.1875rem; font-weight: 600; color: var(--ink-d); text-decoration-thickness: 1px; text-underline-offset: 4px; overflow-wrap: anywhere; }
.ct-ways dd a:hover { color: var(--verd-d); }
.ct-next-title { margin-top: 40px; }

/* ---------- old-site content blocks, in 8c's tokens ---------- */
.ct-eyebrow { margin-bottom: 10px; font-weight: 600; font-size: .9375rem; color: var(--verd-d); }
.ct-req { color: #9E2F28; font-weight: 600; }
.ct-status { padding: 16px 18px; border-radius: 10px; background: #FBEDEB; border-left: 4px solid #9E2F28; color: #7E241F; font-weight: 600; }
.ct-status[hidden] { display: none; }
.ct-status:focus { outline: 3px solid #9E2F28; outline-offset: 3px; }
.ct-status a { color: inherit; text-underline-offset: 3px; }
.ct-hours { margin-top: 14px; display: grid; }
.ct-hours > div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-top: 1px solid var(--line-d); }
.ct-hours > div:last-child { border-bottom: 1px solid var(--line-d); }
.ct-hours dt { color: var(--ink-d-soft); }
.ct-hours dd { font-weight: 600; text-align: right; }
.ct-note { margin-top: 12px; font-size: .9375rem; color: var(--verd-d); font-weight: 600; }
.ct-free { margin-top: 36px; padding: 22px 22px 18px; border-radius: 14px; background: var(--night); color: var(--ink-l); }
.ct-free p { margin-top: 8px; font-size: .9375rem; color: var(--ink-l-soft); }
.ct-free a { display: inline-flex; align-items: center; min-height: 44px; margin-top: 6px; font-family: var(--display); font-weight: 600; font-size: 1.125rem; color: var(--lantern); text-underline-offset: 4px; text-decoration-thickness: 1px; }
.ct-free :focus-visible { outline-color: var(--lantern); }

.ct-urgent { padding: clamp(64px, 8vw, 104px) 0; }
.ct-urgent-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.ct-urgent .sec-head { margin-bottom: 0; }

/* R-Trax sub-menu, interim until the shared navbar is stamped into SHELL:HEADER */
.nav-dd { position: relative; }
.nav ul.nav-sub { display: none; }
@media (min-width: 1121px) {
  .nav ul.nav-sub {
    position: absolute; top: 100%; left: -14px; z-index: 5; min-width: 200px;
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px;
    background: var(--night-2); color: var(--ink-l); border: 1px solid var(--line-l); border-radius: 12px;
    box-shadow: 0 24px 48px -24px rgba(0, 0, 0, .6);
  }
  .nav .nav-dd:hover > ul.nav-sub, .nav .nav-dd:focus-within > ul.nav-sub { display: flex; }
  .nav-sub a:not(.btn) { display: block; padding: 8px 10px; border-radius: 8px; }
  .nav-sub a:not(.btn):hover { background: rgba(234, 240, 244, .08); }
}
@media (max-width: 1120px) {
  .nav ul.nav-sub { display: block; position: static; padding: 0 0 0 16px; transform: none; opacity: 1; visibility: visible; border: 0; background: none; }
}

@media (max-width: 900px) {
  .ct-grid { grid-template-columns: minmax(0, 1fr); }
  .ct-side { position: static; }
}
@media (max-width: 600px) {
  .ct-row { grid-template-columns: minmax(0, 1fr); }
  .ct-submit .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .ct-done.is-on .ct-env-letter, .ct-done.is-on .ct-env-flap, .ct-done.is-on .ct-env-badge,
  .ct-done.is-on .ct-env-badge path, .ct-done.is-on .ct-env, .js .ct-summary:not([hidden]) { animation: none; }
}
