/* static/css/public.css: page content, contact form and capabilities carousel. */

.page-content { color: var(--gp-text); }
.page-content a { color: var(--gp-link); }
.page-content h1, .page-content h2, .page-content h3 { color: var(--gp-ink); line-height: 1.2; }

/* ---------- contact form ---------- */
.form-container { max-width: none; margin: 0; padding: 0; }

.form-row { display: flex; flex-direction: column; margin-bottom: 1rem; }
.form-row label { margin-bottom: 0.4rem; font-weight: bold; color: var(--gp-ink); }
.form-row input,
.form-row textarea {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 0.65rem 0.75rem;
  box-sizing: border-box;
  border: 1px solid #B7C2CE;
  border-radius: 4px;
  background: #FFFFFF;
  color: var(--gp-ink);
}
.form-row input:focus,
.form-row textarea:focus { outline: 2px solid var(--gp-blue); outline-offset: 1px; border-color: var(--gp-blue); }

.form-row--checkbox { flex-direction: row; align-items: flex-start; gap: 0.75rem; }
.form-row--checkbox input[type="checkbox"] { width: 20px; height: 20px; flex: 0 0 auto; margin: 0.2rem 0 0; order: -1; }
.form-row--checkbox label { margin: 0; font-weight: normal; color: var(--gp-text); }

.form-errors, .errorlist { color: #B42318; }
.alert-success { background: #E7F4EC; border: 1px solid #9BCBAE; color: #1E5631; padding: 0.8rem 1rem; border-radius: 6px; margin-bottom: 1rem; }

/* ---------- capabilities carousel (home page, on a grey band) ---------- */
.carousel { position: relative; display: flex; align-items: center; justify-content: center; }
.carousel-track { display: flex; overflow: hidden; scroll-behavior: smooth; width: 85%; }

.carousel-card {
  background: #FFFFFF;
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  width: 300px;
  margin: 0 12px;
  padding: 20px;
  flex-shrink: 0;
  box-sizing: border-box;
  transition: box-shadow 0.3s ease;
}
@media (min-width: 800px) { .carousel-card { width: 560px; } }
.carousel-card:hover { box-shadow: 0 6px 18px rgba(16, 23, 37, 0.10); }
.carousel-card h3 { color: var(--gp-ink); margin-top: 0; }

.carousel-btn {
  background: var(--gp-blue);
  border: none;
  color: white;
  font-size: 1.1em;
  border-radius: 50%;
  cursor: pointer;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 10px;
  transition: background 0.3s;
  line-height: 0;
  flex: 0 0 auto;
}
.carousel-btn:hover { background: var(--gp-blue-hover); }

.carousel-card img {
  width: 63%;
  height: auto;
  border-radius: 6px;
  margin: 0 auto 10px;
  display: block;
}
.carousel-card img.gp-still {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.carousel-card video {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  margin-bottom: 10px;
  display: block;
  background: #DDE4EB;
}

/* card text: 3 lines, then ellipsis */
.carousel-card p {
  --lh: 1.4rem;
  --lines: 3;
  margin: 0 0 10px;
  line-height: var(--lh);
  height: calc(var(--lh) * var(--lines));
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--lines);
  line-clamp: var(--lines);
}

@media (max-width: 800px) {
  .carousel-card p { --lines: 6; }
  .carousel {
    display: grid;
    width: 100%;
    grid-template-columns: auto 1fr auto;
    grid-template-areas: "track track track" "prev . next";
    row-gap: 8px;
    align-items: center;
  }
  .carousel-track { grid-area: track; width: 100%; }
  .carousel-btn.left  { grid-area: prev; justify-self: start; margin-left: 12px; }
  .carousel-btn.right { grid-area: next; justify-self: end; margin-right: 12px; }
}
