/* =============================================================================
   SITE CHROME — shared by every page that uses the topbar / footer partials.
   Load before the page stylesheet.
   ============================================================================= */

/* ─── TOP BAR ──────────────────────────────────────────────────────────────── */
/* Tune the bar height here — it drives the bar, the body offset and the
   desktop nav offset together. */
:root {
  --topbar-h: 56px;
}

/* The bar is pinned to the viewport top and sits BEHIND the page (low z-index).
   body padding-top reserves its height so it peeks out at rest; on scroll the
   page sheet slides up and covers it. */
.site-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 0;
  display: flex;
  align-items: center;
  height: var(--topbar-h);
  padding-inline: var(--sp-1);
  background: transparent;
}

.divider {
  width: 1px;
  height: 24px;
  background: var(--primary-500);
}

.site-topbar__tagline {
  font-size: 14px;
  padding-right: 8px;
}

body {
  padding-top: var(--topbar-h);
}

/* Opaque sheet holding the whole page. Stacked above the fixed bar, so as the
   window scrolls it slides up and covers the bar (the page is "on" the bar). */
.page-scroll {
  position: relative;
  z-index: 1;
  background-color: #f1f1f3;
  /* Sticky footer: the sheet is at least one screen tall and <main> takes the slack,
     so on short pages the empty space sits above the footer, never below it. */
  display: flex;
  flex-direction: column;
  min-height: calc(100svh - var(--topbar-h));
}

.page-scroll > main {
  flex: 1 0 auto;
}

/* body::before (the page texture) is hidden behind the opaque sheet — re-apply
   the same texture on the sheet so content keeps its textured background. */
.page-scroll::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: url("../../assets/images/texture.webp");
  background-repeat: repeat;
  background-size: 150px;
  opacity: 0.5;
  pointer-events: none;
}

.site-topbar__brand {
  display: flex;
  align-items: center;
}

.site-topbar__logo-mark {
  height: 32px;
  width: auto;
}
.site-topbar__logo-type {
  height: 32px;
  width: auto;
  margin-right: -6px;
}

/* Tablet shows a centered 430px app shell — keep the fixed bar aligned to it
   instead of spanning the full viewport. */
@media (min-width: 768px) and (max-width: 899px) {
  .site-topbar {
    left: 50%;
    right: auto;
    width: 100%;
    max-width: var(--app-max-width);
    transform: translateX(-50%);
  }
}

/* ─── VALUES SCROLL ────────────────────────────────────────────────────────── */
.values-scroll {
  display: flex;
  flex-direction: row-reverse;
  gap: var(--sp-4);
  direction: ltr;
  overflow-x: auto;
  overflow-y: hidden;
  margin-inline: calc(-1 * var(--sp-4));
  padding: var(--sp-4) var(--sp-4) var(--sp-8);
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--sp-4);
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.values-scroll::-webkit-scrollbar {
  display: none;
}

.value-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--sp-1);
  flex: 0 0 250px;
  height: 360px;
  padding: var(--sp-4);
  direction: rtl;
  background-color: var(--primary-50);
  border-radius: var(--r-md);
  box-shadow: 0 2px 12px rgba(29, 32, 48, 0.08);
  scroll-snap-align: start;
}

.value-card__badge {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 64px;
  height: 64px;
  margin-bottom: var(--sp-4);
  flex-shrink: 0;
  background-image: url("/assets/images/badge-circle.webp");
  background-size: cover;
  background-position: center;
  opacity: 0.75;
}

/* ─── FOOTER ───────────────────────────────────────────────────────────────── */
.site-footer {
  background-color: #212752;
  color: #fff;
  padding-block: var(--sp-6);
}

.site-footer__inner {
  padding-inline: var(--sp-4);
  display: flex;
  flex-direction: column;
}

.site-footer__logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-3);
  flex-shrink: 0;
}

.site-footer__logo-mark {
  width: 64px;
}
.site-footer__logo-type {
  width: 72px;
  margin-top: -11px;
}

.site-footer__copy {
  flex: 1;
  text-align: right;
}

.site-footer__tagline {
  flex: 1;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.92);
}

.site-footer__launch {
  margin-top: var(--sp-6);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.75);
}

.site-footer__social {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--sp-4);
}

.site-footer__social-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
}

.site-footer__social-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-3);
}

.site-footer__social-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  color: rgba(255, 255, 255, 0.85);
  transition: color 250ms ease;
}

.site-footer__social-link:hover {
  color: #fff;
}

.site-footer__social-handle {
  font-size: 1.125rem;
}

.site-footer__social-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.site-footer__divider {
  width: 1px;
  height: 18px;
  background-color: #f8f8fb;
  flex-shrink: 0;
}
