/* Loaded last on every page: reviews block, mobile fit fixes and a more compact mobile layout. */

/* ---------- Reviews & ratings ---------- */
.rv { display: grid; gap: 16px; align-items: start; }
.rv-score { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; display: grid; gap: 16px; }
.rv-score__top { display: flex; align-items: center; gap: 14px; }
.rv-score__value { font-family: var(--font-display); font-size: 3.2rem; font-weight: 800; line-height: 1; color: var(--ink); }
.rv-score__top small { display: block; margin-top: 4px; font-size: .8rem; color: var(--ink-3); }
.rv-stars { position: relative; display: inline-block; align-self: flex-start; width: max-content; font-size: 1rem; line-height: 1; letter-spacing: 2px; color: var(--ph-2); white-space: nowrap; }
.rv-stars__on { position: absolute; inset: 0 auto 0 0; overflow: hidden; color: #f5a524; }
.rv-stars--lg { font-size: 1.35rem; }
.rv-score__bars { display: grid; gap: 6px; }
.rv-bar { display: grid; grid-template-columns: 28px 1fr 36px; align-items: center; gap: 8px; font-size: .78rem; color: var(--ink-2); }
.rv-bar i { height: 7px; border-radius: 99px; background: var(--tint); overflow: hidden; }
.rv-bar i b { display: block; height: 100%; border-radius: 99px; background: #f5a524; }
.rv-bar em { font-style: normal; text-align: right; font-weight: 700; color: var(--ink); }
.rv-score__meters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.rv-meter { text-align: center; padding: 8px 4px; border-radius: var(--radius-sm); background: var(--accent-tint); }
.rv-meter b { display: block; font-family: var(--font-display); font-size: 1.1rem; color: var(--accent); }
.rv-meter span { font-size: .72rem; color: var(--ink-2); }
.rv-list { display: grid; gap: 12px; }
.rv-card { display: flex; flex-direction: column; gap: 10px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); min-width: 0; }
.rv-card__head { display: flex; align-items: center; gap: 10px; }
.rv-card__head strong { display: block; font-family: var(--font-display); font-size: .95rem; color: var(--ink); }
.rv-card__avatar { flex: 0 0 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); font-family: var(--font-display); font-weight: 800; }
.rv-card__place { display: inline-flex; align-items: center; gap: 4px; font-size: .78rem; color: var(--ink-3); }
.rv-card__place svg { width: 13px; height: 13px; flex: 0 0 auto; color: var(--accent); }
.rv-card__text { margin: 0; font-size: .92rem; line-height: 1.55; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.rv-card__foot { margin-top: auto; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: .76rem; color: var(--ink-3); }
.rv-card__foot a { color: var(--accent); font-weight: 700; }
.rv-card__foot time { margin-left: auto; white-space: nowrap; }
@media (min-width: 900px) {
  .rv { grid-template-columns: minmax(280px, 1fr) 2.4fr; gap: 20px; }
  .rv-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 600px) and (max-width: 899px) { .rv-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Mobile fit fixes ---------- */
@media (max-width: 899px) {
  /* Section menus and swipe rows keep the side margin */
  .subnav__track { padding-inline: var(--gutter); scroll-padding-inline: var(--gutter); }
  .scroller, .formats, .fmt__row { scroll-padding-inline: var(--gutter); }
  /* Odd item counts: the last card spans the row instead of standing alone */
  .models > .model:last-child:nth-child(odd),
  .acc-items > .acc-item:last-child:nth-child(odd) { grid-column: 1 / -1; display: grid; grid-template-columns: 42% 1fr; column-gap: 14px; align-items: center; }
  .models > .model:last-child:nth-child(odd) > :first-child,
  .acc-items > .acc-item:last-child:nth-child(odd) > img { grid-row: span 4; margin: 0; }
  /* Reviews: one swipe row of cards */
  .rv-list { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter); margin-inline: calc(-1 * var(--gutter)); padding: 2px var(--gutter) 6px; scrollbar-width: none; }
  .rv-list::-webkit-scrollbar { display: none; }
  .rv-list { align-items: flex-start; }
  .rv-list > .rv-card { flex: 0 0 82%; scroll-snap-align: start; }
  .rv-card--rating .rv-card__foot { margin-top: 4px; }
}

/* ---------- Compact mobile ---------- */
@media (max-width: 599px) {
  .section { padding: 30px 0; }
  .section__head { margin-bottom: 16px; }
  .section__head h2, h2 { font-size: clamp(1.3rem, 5.6vw, 1.6rem); line-height: 1.18; }
  .kicker { margin-bottom: 6px; font-size: .7rem; }
  p { line-height: 1.55; }
  /* Page headers */
  .h2hero { padding: 18px 0 16px; }
  .h2hero__inner { gap: 14px; }
  .h2hero h1 { font-size: clamp(2rem, 9.6vw, 2.5rem); }
  .h2hero__lead, .phero .lead { font-size: .96rem; }
  .phero { padding: 18px 0 22px; }
  .phero h1 { font-size: clamp(1.7rem, 7.6vw, 2.1rem); }
  .phero__cta, .h2hero__cta { gap: 8px; }
  .phero__media { max-height: 220px; }
  /* Buttons */
  .btn--lg { min-height: 48px; font-size: .95rem; padding: 0 20px; }
  .btn { min-height: 44px; }
  /* Cards */
  .bcard__img { height: 150px; }
  .bcard__body, .svc__item, .industry, .value, .plan, .kb, .work, .solution__body { padding: 14px; }
  .svc, .bento, .industries, .values, .plans, .works { gap: 10px; }
  .faq details summary { padding-block: 13px; font-size: .93rem; }
  .keyspecs b { font-size: .9rem; }
  .keyspecs div { padding: 8px 10px; }
  .mats span, .chips-wrap a { font-size: .8rem; }
  .rv-score { padding: 16px; }
  .rv-score__value { font-size: 2.6rem; }
  /* Footer */
  .footer { padding-top: 32px; }
}

/* ---------- Home "What we build": the four processes side by side on every screen ---------- */
.bento { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.bento > .bcard:not(.bcard--dark):not(.bcard--accent) { grid-column: span 1; }
.bento > .bcard--dark, .bento > .bcard--accent { grid-column: span 2; }
@media (max-width: 899px) {
  .bento { gap: 10px; }
  .bento > .bcard:not(.bcard--dark):not(.bcard--accent) { min-height: 0; border-radius: 16px; }
  .bento .bcard__img { flex: 0 0 auto; min-height: 0; height: 120px; }
  .bento .bcard__img img { max-height: 110px; padding: 10px; }
  .bento .bcard__body { padding: 12px; gap: 4px; }
  .bento .bcard h3 { font-size: 1rem; }
  .bento .bcard p { font-size: .8rem; }
  .bento .bcard__meta span { font-size: .64rem; padding: 3px 7px; }
}
/* Phones: compact tiles, picture and name only */
@media (max-width: 599px) {
  .bento { gap: 8px; }
  .bento > .bcard:not(.bcard--dark):not(.bcard--accent) { border-radius: 14px; }
  .bento .bcard__img { height: 74px; }
  .bento .bcard__img img { max-height: 70px; padding: 6px; }
  .bento .bcard__body { padding: 8px 4px 10px; text-align: center; }
  .bento .bcard__num, .bento .bcard:not(.bcard--dark):not(.bcard--accent) p, .bento .bcard__meta { display: none; }
  .bento .bcard:not(.bcard--dark):not(.bcard--accent) h3 { font-size: .74rem; line-height: 1.2; }
  .bento > .bcard--dark, .bento > .bcard--accent { grid-column: 1 / -1; }
}

/* ---------- Logo: horizontal mark + name, readable at header size ---------- */
.appbar .brand { background: transparent; border: 0; padding: 0; box-shadow: none; }
.appbar .brand::after, .appbar .brand::before { display: none; }
.appbar .brand__logo { height: 42px; width: auto; max-width: 56vw; object-fit: contain; }
.drawer__head .brand__logo { height: 34px; width: auto; }
.footer .brand__logo { height: 44px; width: auto; }
@media (max-width: 599px) {
  .appbar .brand__logo { height: 38px; }
  .footer .brand__logo { height: 38px; }
}
@media (min-width: 1200px) { .appbar .brand__logo { height: 48px; } }
:root[data-theme="dark"] .appbar .brand { background: transparent; }

/* Keep homepage machine cutouts inside compact image wells. */
.bento .bcard__img img { width: 100%; height: 100%; max-height: 100%; min-height: 0; padding: 0; object-fit: contain; }
