/* V5 refinement — layout corrections and direct Services navigation. */
/* Preserve all existing V5 photographs, typography, content, and colors. */
*, *::before, *::after { box-sizing: border-box; }
main p, main li { text-wrap: pretty; }
main .wrap, .v2-card, .vx-pricing-preview { min-width: 0; }

/* Services dropdown: "Services" remains a link to the full overview;
   the chevron provides a direct submenu on desktop and mobile. */
nav.main .services-nav-item { position: relative; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; column-gap: 1px; flex-shrink: 0; }
nav.main .services-nav-item > a { grid-column: 1; grid-row: 1; }
nav.main .services-nav-item > .services-dropdown-toggle {
  grid-column: 2; grid-row: 1; background: transparent; border: 0;
  color: var(--gold); cursor: pointer; border-radius: 2px; min-width: 26px;
  min-height: 38px; display: inline-flex; align-items: center; justify-content: center;
  padding: 8px 4px; margin: 0;
}
nav.main .services-chevron { width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .16s ease; }
nav.main .services-nav-item.is-open .services-chevron { transform: translateY(2px) rotate(225deg); }
nav.main .services-submenu {
  position: absolute; z-index: 45; top: 100%; left: -12px;
  width: 292px; max-width: calc(100vw - 38px); background: #09243c;
  border: 1px solid rgba(209,171,93,.5); padding: 9px;
  box-shadow: 0 16px 40px rgba(0,0,0,.36);
  display: none; grid-template-columns: minmax(0,1fr); gap: 0;
}
nav.main .services-submenu a { display: block; padding: 12px 11px; margin: 0; font-size: .75rem; line-height: 1.45; letter-spacing: .04em; text-transform: none; white-space: normal; border-bottom: 1px solid rgba(201,165,94,.17); }
nav.main .services-submenu a:last-child { border-bottom: 0; }
nav.main .services-submenu a:hover, nav.main .services-submenu a:focus-visible { color: #edc76d; background: rgba(229,185,101,.08); }
nav.main .services-dropdown-toggle:focus-visible, nav.main .services-submenu a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
@media (min-width:901px) {
  nav.main .services-nav-item:hover .services-submenu,
  nav.main .services-nav-item:focus-within .services-submenu,
  nav.main .services-nav-item.is-open .services-submenu { display: grid; }
}
@media (max-width:900px) {
  nav.main .services-nav-item { width: 100%; flex: 0 0 auto; grid-template-columns: minmax(0,1fr) 46px; }
  nav.main .services-nav-item > a { display: block; min-width: 0; margin: 0; }
  nav.main .services-nav-item > .services-dropdown-toggle { min-height: 46px; min-width: 46px; border-bottom: 1px solid var(--line-soft); }
  nav.main .services-submenu { position: static; grid-column: 1 / -1; grid-row: 2; left: auto; top: auto; width: 100%; max-width: none; border: 0; border-left: 2px solid var(--gold); padding: 2px 8px 6px 14px; box-shadow: none; background: #0b2a44; }
  nav.main .services-nav-item.is-open .services-submenu { display: grid; }
  nav.main .services-submenu a { padding: 12px 7px; font-size: .83rem; letter-spacing: .015em; }
  nav.main .services-nav-item:not(.is-open) .services-submenu { display:none !important; }
}

/* Overview cards: remove inherited flex growth on *every* paragraph.
   Align the headers, descriptions, prices and action buttons on wide screens. */
.v5-service-overview .v2-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); align-items: stretch; gap: 20px; }
.v5-service-overview .v2-card { display: flex; flex-direction: column; min-width: 0; padding: 27px; overflow: hidden; }
.v5-service-overview .v2-card p { flex: none; }
.v5-service-overview .v2-card > .v2-kicker { margin: 0 0 17px; line-height: 1.5; min-height: 2em; }
.v5-service-overview .v2-card > h3 { margin: 0 0 13px; line-height: 1.22; font-size: clamp(1.22rem,1.75vw,1.5rem); }
.v5-service-overview .v2-card > h3 + p { margin: 0; line-height: 1.58; }
.v5-service-overview .v2-card .vx-pricing-preview { flex: none; margin-top: auto; padding-top: 22px; min-width:0; }
.v5-service-overview .v2-card .vx-price { margin: 5px 0 9px; align-items: baseline; row-gap: 4px; }
.v5-service-overview .v2-card .vx-price strong { white-space: nowrap; font-size: clamp(1.7rem,2.25vw,2rem); }
.v5-service-overview .v2-card .vx-price span { white-space: normal; }
.v5-service-overview .v2-card .vx-card-note { font-size: .86rem !important; line-height: 1.55 !important; margin: 0 !important; }
.v5-service-overview .v2-card .v2-actions { margin-top: 19px; width: 100%; display: grid; grid-template-columns: 1fr; gap: 9px; }
.v5-service-overview .v2-card .v2-actions .btn { width: 100%; min-height: 55px; padding: 13px 14px; }
.v5-service-overview .vx-price-note { max-width: none; margin-top: 21px; }
@media (min-width: 901px) {
  .v5-service-overview .v2-card > h3 { min-height: 3.1em; }
  .v5-service-overview .v2-card > h3 + p { min-height: 6.4em; }
  .v5-service-overview .v2-card .vx-pricing-preview { min-height: 157px; }
  .v5-service-overview .v2-card .vx-card-note { min-height: 3.3em; }
}
@media (min-width: 641px) and (max-width: 900px) {
  .v5-service-overview .v2-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 640px) {
  .v5-service-overview .v2-grid { grid-template-columns: minmax(0,1fr); gap: 15px; }
  .v5-service-overview .v2-card { padding: 21px 20px; }
  .v5-service-overview .v2-card > .v2-kicker { min-height: 0; margin-bottom: 12px; }
  .v5-service-overview .v2-card > h3 { min-height: 0; margin-bottom: 10px; }
  .v5-service-overview .v2-card > h3 + p { min-height: 0; }
  .v5-service-overview .v2-card .vx-pricing-preview { margin-top: 21px; min-height: 0; padding-top: 17px; }
  .v5-service-overview .v2-card .vx-card-note { min-height: 0; }
}

/* About Us: every achievement gets a number above a readable label.
   Avoid the old breakpoint that forced two tiny internal columns per statistic. */
.about-grid .stats.v5-figures { display:grid; grid-template-columns: repeat(2,minmax(0,1fr)); width:100%; max-width:100%; }
.about-grid .stats.v5-figures .stat,
.about-grid .stats.v5-figures .stat:nth-child(odd),
.about-grid .stats.v5-figures .stat:nth-child(n+3) {
  min-width:0; min-height:172px; padding: 23px 20px;
  display:flex; flex-direction:column; align-items:flex-start; justify-content:center;
  gap: 12px; grid-template-columns: none; border-top:0;
  border-left: 1px solid var(--line-soft);
}
.about-grid .stats.v5-figures .stat:nth-child(odd) { border-left:0; }
.about-grid .stats.v5-figures .stat:nth-child(n+3) { border-top:1px solid var(--line-soft); }
.about-grid .stats.v5-figures .stat b { display:block; max-width:100%; font-size:clamp(1.8rem,2.85vw,2.6rem); line-height:1.1; letter-spacing:-.025em; white-space:nowrap; overflow-wrap:normal; }
.about-grid .stats.v5-figures .stat:last-child b { font-size:clamp(1.45rem,2.3vw,1.95rem); letter-spacing:-.03em; }
.about-grid .stats.v5-figures .stat b small { font-size:.63em; vertical-align:baseline; letter-spacing:0; }
.about-grid .stats.v5-figures .stat span { display:block; max-width:100%; font-size:.89rem; line-height:1.48; }
@media (max-width: 640px) {
  .about-grid .stats.v5-figures .stat,
  .about-grid .stats.v5-figures .stat:nth-child(odd),
  .about-grid .stats.v5-figures .stat:nth-child(n+3) { padding: 18px 15px; min-height:152px; gap:9px; }
  .about-grid .stats.v5-figures .stat b { font-size:clamp(1.8rem,7vw,2.4rem); }
  .about-grid .stats.v5-figures .stat:last-child b { font-size:clamp(1.34rem,5.3vw,1.65rem); }
  .about-grid .stats.v5-figures .stat span { font-size:.82rem; line-height:1.45; }
}
@media (max-width: 360px) {
  .about-grid .stats.v5-figures { grid-template-columns:minmax(0,1fr); }
  .about-grid .stats.v5-figures .stat,
  .about-grid .stats.v5-figures .stat:nth-child(odd),
  .about-grid .stats.v5-figures .stat:nth-child(n+3) { min-height:110px; border-left:0; border-top:1px solid var(--line-soft); }
  .about-grid .stats.v5-figures .stat:first-child { border-top:0; }
}

/* Method consultation: both actions inside the same panel, aligned and contained. */
.vx-consult { max-width: 100%; min-width:0; }
.vx-consult-actions { display: flex; flex-wrap: wrap; align-items:center; gap: 12px; margin-top:18px; }
.vx-consult .vx-consult-actions .btn { min-height: 50px; margin:0; }
@media(max-width: 540px) {
 .vx-consult-actions { flex-direction:column; align-items:stretch; }
 .vx-consult .vx-consult-actions .btn { width:100%; }
}

/* Prevent accidental overflow in multi-column sections and unnatural hard wraps. */
.v2-grid > *, .vx-pricing-grid > *, .market-grid > *, .offer-grid > *, .about-grid > * { min-width:0; }
.vx-price-note, .vx-consult p { text-wrap:pretty; }
@media (prefers-reduced-motion: reduce) { nav.main .services-chevron { transition:none; } }
