/*
|--------------------------------------------------------------------------
| Contact pages — /contact + /service/contact
|--------------------------------------------------------------------------
| Shared `.cx-*` layer for the two overlay-form landing pages. Follows the
| models/vfs redesign language — compact editorial head (eyebrow → title
| with the red accent bar → one-line lead) over the flowing near-black
| column — but deliberately WITHOUT a tall hero: these pages stay short
| and functional. Layout: the form CTA card (glass recipe) beside slim
| contact tiles (call / email / visit / hours), then a mirrored two-card
| strip clarifying which of the two forms fits ("You're in the right
| place" vs. a link to the other page).
|
| The overlay itself is untouched — the CTA button opens it via
| data-overlay-open (src/js/form-overlay.js).
|
| The sitewide `*{}` reset forces font-weight/colour and h2/h3 get global
| uppercase + 1.2rem, so every text style below restates its own size /
| weight / colour / tracking.
*/

/* Flowing near-black page column (models/vfs recipe). */
.cx-flow {
    display: flow-root;
    /* Clears the fixed navbar, the same way .support-flow does for the other
       split-header pages. It used to live on .cx's padding-top, which only
       worked while the header was nested inside .cx. */
    padding-top: var(--nav-h, 3.3rem);
    /* The ground moved to src/styles/surfaces.css — see .support-flow, whose
       recipe this was a copy of. */
}

/* The footer's measure, so the body column starts on the same left edge as the
   .support-head--split lockup above it and the footer below: .footer-max caps
   content at 1600px and footer.css supplies the gutter (6rem, stepped below
   exactly as it steps). Expressed as padding rather than a max-width for the
   same reason page-head.css does — the section spans the viewport, so each
   side takes whichever is larger, the gutter or the slack outside the cap.
   Was width: min(100%, 72rem), which ran ~110px narrower than the header. */
.cx {
    width: 100%;
    margin: 0;
    /* No nav offset here any more — .cx-flow owns it now that the header sits
       above this section rather than inside it. This is just the gap under the
       lockup. */
    padding:
        0
        max(6rem, calc(50vw - 800px))
        clamp(3rem, 7vw, 5rem);
}

@media only screen and (min-width: 1600px) {
    .cx {
        padding-left: max(9rem, calc(50vw - 800px));
        padding-right: max(9rem, calc(50vw - 800px));
    }
}

@media only screen and (max-width: 1200px) {
    .cx {
        padding-left: 2rem;
        padding-right: 2rem;
    }
}

@media only screen and (max-width: 700px) {
    .cx {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }
}

/* Head lockup: shared partial includes/support-header.php styled by
   support-header.css (.support-head) — the old .cx__head layer is retired. */

/* ── Shared glass surface (models-detail --md-glass recipe, restated so
      these pages don't depend on models-detail.css being loaded) ── */
/* The project's card recipe, shared with .bl-card / .vt-card / .job-card /
   .pg-card: theme border and surface tokens and the 1rem radius. Was a
   three-stop diagonal gradient with a permanent 40px drop shadow, which sat
   heavier than every other card on the site and never reacted to a pointer. */
.cx-card {
    border: 1px solid var(--theme-border, rgba(255, 255, 255, 0.09));
    border-radius: var(--theme-radius-md, 1rem);
    background: var(--theme-surface-white-04, rgba(255, 255, 255, 0.04));
    transition:
        transform 220ms ease,
        border-color 220ms ease,
        box-shadow 220ms ease;
}

/* Only the ones that go somewhere lift — the plain information tiles should
   not imply a click they do not have. */
a.cx-card:hover,
a.cx-card:focus-visible,
.cx-card:has(.tv-cta):hover {
    transform: translateY(-3px);
    border-color: var(--theme-border-strong, rgba(255, 255, 255, 0.18));
    box-shadow: var(--theme-shadow-card, 0 14px 34px rgba(0, 0, 0, 0.34));
}

/* ── Main grid — form CTA card beside the contact tiles ── */
.cx__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: clamp(1rem, 1.6vw, 1.5rem);
    align-items: stretch;
}

/* Primary card — the form CTA */
.cx-primary {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.95rem;
    padding: clamp(1.5rem, 3vw, 2.25rem);
}

.cx-primary__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.9rem;
    height: 2.9rem;
    border: 1px solid var(--theme-accent-soft-border, rgba(170, 0, 0, 0.22));
    border-radius: 0.85rem;
    background: var(--theme-accent-soft, rgba(170, 0, 0, 0.12));
    color: var(--theme-text-accent-soft, #f0c7c7);
    font-size: 1.15rem;
}

.cx-primary__title {
    margin: 0;
    font-size: clamp(1.35rem, 2vw, 1.6rem);
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: 0.01em;
    text-transform: none;
    color: var(--theme-text-strong, #ffffff);
}

.cx-primary__copy {
    margin: 0;
    max-width: 34rem;
    font-size: 0.98rem;
    font-weight: 300;
    line-height: 1.7;
    color: var(--theme-text-muted, #c4c6cc);
}

.cx-primary .tv-cta {
    margin-top: 0.35rem;
}

.cx-primary__meta {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: var(--theme-text-soft, #989ba3);
}

/* Contact tiles — slim icon + label/value rows */
.cx__tiles {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(0.7rem, 1vw, 0.9rem);
    align-content: stretch;
}

.cx-tile {
    display: flex;
    align-items: center;
    gap: 0.95rem;
    padding: 0.9rem 1.1rem;
    border-radius: 0.85rem;
    text-decoration: none;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease;
}

a.cx-tile:hover {
    transform: translateY(-3px);
    border-color: var(--theme-border-strong, rgba(255, 255, 255, 0.16));
    background: linear-gradient(
        160deg,
        rgba(255, 255, 255, 0.1) 0%,
        rgba(255, 255, 255, 0.04) 46%,
        rgba(255, 255, 255, 0.02) 100%
    );
}

a.cx-tile:focus-visible {
    outline: 2px solid var(--theme-accent, #aa0000);
    outline-offset: 2px;
}

.cx-tile__icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    height: 2.4rem;
    border: 1px solid var(--theme-border-soft, rgba(255, 255, 255, 0.08));
    border-radius: 0.7rem;
    background: var(--theme-surface-white-05, rgba(255, 255, 255, 0.05));
    color: var(--theme-text-muted, #c4c6cc);
    font-size: 0.95rem;
}

.cx-tile__body {
    display: grid;
    gap: 0.14rem;
    min-width: 0;
}

.cx-tile__label {
    font-size: 0.66rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--theme-text-soft, #989ba3);
}

.cx-tile__value {
    font-size: 0.98rem;
    font-weight: 500;
    line-height: 1.35;
    overflow-wrap: anywhere;
    color: var(--theme-text-main, #ececef);
}

.cx-tile__hint {
    font-size: 0.8rem;
    font-weight: 300;
    line-height: 1.45;
    color: var(--theme-text-soft, #989ba3);
}

/* ── "Which form?" strip — this page vs. the other one ── */
.cx__switch {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(1rem, 1.6vw, 1.5rem);
    margin-top: clamp(1rem, 1.6vw, 1.5rem);
}

.cx-switch {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.55rem;
    padding: clamp(1.15rem, 2vw, 1.5rem);
    text-decoration: none;
}

.cx-switch--this {
    border-color: var(--theme-accent-soft-border, rgba(170, 0, 0, 0.22));
}

a.cx-switch--other {
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease;
}

a.cx-switch--other:hover {
    transform: translateY(-4px);
    border-color: var(--theme-border-strong, rgba(255, 255, 255, 0.16));
    background: linear-gradient(
        160deg,
        rgba(255, 255, 255, 0.1) 0%,
        rgba(255, 255, 255, 0.04) 46%,
        rgba(255, 255, 255, 0.02) 100%
    );
}

a.cx-switch--other:focus-visible {
    outline: 2px solid var(--theme-accent, #aa0000);
    outline-offset: 2px;
}

.cx-switch__tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.32rem 0.62rem;
    border: 1px solid var(--theme-border, rgba(255, 255, 255, 0.1));
    border-radius: var(--theme-radius-pill, 999px);
    background: var(--theme-surface-white-045, rgba(255, 255, 255, 0.045));
    font-size: 0.64rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--theme-text-muted, #c4c6cc);
}

.cx-switch--this .cx-switch__tag {
    border-color: var(--theme-accent-soft-border, rgba(170, 0, 0, 0.22));
    background: var(--theme-accent-soft, rgba(170, 0, 0, 0.12));
    color: var(--theme-text-accent-soft, #f0c7c7);
}

.cx-switch__name {
    margin: 0.15rem 0 0;
    font-size: 1.08rem;
    font-weight: 550;
    line-height: 1.25;
    letter-spacing: 0.01em;
    text-transform: none;
    color: var(--theme-text-strong, #ffffff);
}

.cx-switch__desc {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 300;
    line-height: 1.65;
    color: var(--theme-text-muted, #c4c6cc);
}

.cx-switch__go {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin-top: 0.35rem;
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--theme-text-accent-soft, #f0c7c7);
}

.cx-switch__go i {
    font-size: 0.78rem;
    transition: transform 0.2s ease;
}

a.cx-switch--other:hover .cx-switch__go i {
    transform: translateX(4px);
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .cx__grid {
        grid-template-columns: 1fr;
    }

    .cx__tiles {
        grid-template-columns: 1fr 1fr;
    }

    .cx__switch {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .cx__tiles {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cx-tile,
    a.cx-switch--other,
    .cx-switch__go i {
        transition: none;
    }

    a.cx-tile:hover,
    a.cx-switch--other:hover {
        transform: none;
    }
}
