/* ============================================================
   /contact — TriGem Solutions
   - Mobile-first; 768px and 1024px breakpoints
   ============================================================ */

/* ============================================================
   1. HERO
   ============================================================ */
.ct-hero {
    position: relative;
    padding: clamp(3rem, 7vw, 4.5rem) 0 clamp(2.5rem, 6vw, 3.5rem);
    background:
        radial-gradient(120% 80% at 50% 0%, #0E2A4D 0%, #061629 60%, #03101F 100%);
    color: #E8EEF7;
    overflow: hidden;
    isolation: isolate;
}
.ct-hero__bg { position: absolute; inset: 0; z-index: -1; overflow: hidden; }
.ct-hero__orb {
    position: absolute;
    width: clamp(260px, 38vw, 480px);
    aspect-ratio: 1;
    border-radius: 50%;
    filter: blur(90px);
    pointer-events: none;
}
.ct-hero__orb--primary { background: var(--color-primary-light); top: -100px; right: -80px; opacity: 0.45; }
.ct-hero__orb--accent  { background: var(--color-accent);        bottom: -120px; left: -60px; opacity: 0.30; }
.ct-hero__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(to right, rgba(160, 200, 255, 0.06) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(160, 200, 255, 0.06) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%);
            mask-image: radial-gradient(ellipse at center, black 0%, transparent 75%);
}
.ct-hero__inner {
    position: relative;
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(2rem, 5vw, 3rem);
    align-items: center;
}
@media (min-width: 1024px) {
    .ct-hero__inner { grid-template-columns: 1.4fr 1fr; }
}
.ct-hero__copy { max-width: 640px; }
.ct-hero__eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-accent-light);
    padding: 0.4rem 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-full);
    margin-bottom: 1rem;
}
.ct-hero__title {
    color: #FFFFFF;
    font-size: clamp(1.85rem, 3.5vw, 2.75rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 0.85rem;
}
.ct-hero__lede {
    color: #C7D2E1;
    font-size: var(--text-base);
    margin: 0;
    max-width: 60ch;
}

/* Brand mark styles live in global.css — see .brand-mark / .brand-mark--tilt-right */

/* ============================================================
   2. BODY — form column + sidebar
   ============================================================ */
.ct-body {
    padding: var(--section-pad-y) 0;
    background: var(--color-bg);
}
.ct-body__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: start;
}
@media (min-width: 900px) {
    .ct-body__inner { grid-template-columns: 1.5fr 1fr; gap: 2.5rem; }
}

/* ----- Form card ----- */
.ct-form-card {
    padding: clamp(1.5rem, 3vw, 2.25rem);
    background: var(--color-surface);
    border: 1px solid var(--color-divider);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}
.ct-form__heading {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--color-text);
    margin: 0 0 0.4rem;
}
.ct-form__sub {
    color: var(--color-text-muted);
    font-size: var(--text-sm);
    margin: 0 0 1.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--color-divider);
}
.ct-required { color: var(--color-accent); font-weight: 700; }
.ct-optional { color: var(--color-text-faint); font-weight: 400; font-size: 0.9em; }

/* Form rows + fields */
.ct-form { display: flex; flex-direction: column; gap: 1.1rem; }
.ct-form__row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.1rem;
}
@media (min-width: 640px) {
    .ct-form__row { grid-template-columns: repeat(2, 1fr); }
}

.ct-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.ct-field--inline {
    flex-direction: row;
    gap: 0.65rem;
    align-items: flex-start;
    padding: 0.85rem 0;
}
.ct-field--inline input[type="checkbox"] {
    flex-shrink: 0;
    width: 18px; height: 18px;
    margin-top: 0.15rem;
    accent-color: var(--color-primary);
    cursor: pointer;
}
.ct-field--inline label {
    font-size: var(--text-sm);
    color: var(--color-text);
    line-height: 1.5;
    cursor: pointer;
}
.ct-field--inline label a {
    color: var(--color-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
    font-weight: 600;
}

.ct-field label {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
}

.ct-field input[type="text"],
.ct-field input[type="email"],
.ct-field input[type="tel"],
.ct-field select,
.ct-field textarea {
    width: 100%;
    min-height: 44px;
    padding: 0.7rem 0.85rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    color: var(--color-text);
    font: inherit;
    font-size: var(--text-base);
    line-height: 1.4;
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}
[data-theme="dark"] .ct-field input,
[data-theme="dark"] .ct-field select,
[data-theme="dark"] .ct-field textarea {
    background: var(--color-surface-alt);
}

.ct-field textarea {
    min-height: 140px;
    resize: vertical;
    font-family: inherit;
}

.ct-field select {
    appearance: none;
    -webkit-appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, var(--color-text-muted) 50%),
        linear-gradient(135deg, var(--color-text-muted) 50%, transparent 50%);
    background-position:
        calc(100% - 18px) calc(50% - 2px),
        calc(100% - 13px) calc(50% - 2px);
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
    padding-right: 2.5rem;
}

.ct-field input:focus,
.ct-field select:focus,
.ct-field textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(12, 85, 148, 0.15);
}
[data-theme="dark"] .ct-field input:focus,
[data-theme="dark"] .ct-field select:focus,
[data-theme="dark"] .ct-field textarea:focus {
    box-shadow: 0 0 0 3px rgba(63, 127, 186, 0.30);
}

.ct-field input:invalid:not(:placeholder-shown),
.ct-field textarea:invalid:not(:placeholder-shown) {
    border-color: var(--color-error);
}
.ct-field input:invalid:not(:placeholder-shown):focus,
.ct-field textarea:invalid:not(:placeholder-shown):focus {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

.ct-field__hint {
    margin: 0;
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

/* ----- Honeypot — present in DOM, invisible to humans, untouched by AT ----- */
.ct-honeypot {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

/* ----- Form actions ----- */
.ct-form__actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
    margin-top: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-divider);
}
@media (min-width: 640px) {
    .ct-form__actions {
        flex-direction: row;
        align-items: center;
        gap: 1.25rem;
    }
}
.ct-form__sla {
    margin: 0;
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

/* ============================================================
   2b. SIDEBAR
   ============================================================ */
.ct-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.ct-card {
    padding: 1.25rem 1.25rem 1.4rem;
    background: var(--color-surface);
    border: 1px solid var(--color-divider);
    border-radius: var(--radius-lg);
}
.ct-card__heading {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    color: var(--color-primary);
    margin: 0 0 0.85rem;
}

.ct-list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}
.ct-list li {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}
.ct-list__label {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    font-weight: 500;
}
.ct-list__value {
    font-size: var(--text-sm);
    color: var(--color-text);
    font-weight: 600;
    word-break: break-word;
}
.ct-list__value:hover { color: var(--color-primary); }
[data-theme="dark"] .ct-list__value:hover { color: var(--color-primary-light); }
.ct-list__address {
    font-size: var(--text-sm);
    color: var(--color-text);
    line-height: 1.5;
}

.ct-card--social { padding-bottom: 1.25rem; }
.ct-social {
    display: flex;
    gap: 0.5rem;
}
.ct-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px; height: 38px;
    background: var(--color-surface-alt);
    border: 1px solid var(--color-divider);
    border-radius: var(--radius-full);
    color: var(--color-text-muted);
    transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}
.ct-social a:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #FFFFFF;
    transform: translateY(-2px);
}

/* ============================================================
   3. TRUST STRIP
   ============================================================ */
.ct-trust {
    padding: clamp(2rem, 5vw, 3rem) 0 clamp(2.5rem, 6vw, 4rem);
    background: var(--color-surface-alt);
    border-top: 1px solid var(--color-divider);
}
.ct-trust__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}
@media (min-width: 768px) {
    .ct-trust__grid { grid-template-columns: repeat(3, 1fr); }
}
.ct-trust__item {
    padding: 1.25rem 1.25rem;
    background: var(--color-surface);
    border: 1px solid var(--color-divider);
    border-left: 3px solid var(--color-accent);
    border-radius: var(--radius-md);
}
.ct-trust__title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 0.4rem;
}
.ct-trust__blurb {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
    margin: 0;
    line-height: 1.55;
}
.ct-trust__blurb a {
    color: var(--color-primary);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* FAQ — extra breathing room before the trust strip */
.faq { margin-bottom: clamp(2rem, 5vw, 4rem); }

/* ============================================================
   Form states: flash banner, field errors, thank-you card
   ============================================================ */

.ct-form__flash {
    margin-bottom: 1.25rem;
    padding: 0.875rem 1rem;
    border-radius: var(--radius-md);
    background: color-mix(in srgb, var(--color-error) 8%, var(--color-surface));
    border: 1px solid color-mix(in srgb, var(--color-error) 25%, var(--color-divider));
    color: var(--color-error);
    font-size: var(--text-sm);
    font-weight: 500;
    line-height: 1.5;
}

.ct-field--error label { color: var(--color-error); }
.ct-field--error input,
.ct-field--error select,
.ct-field--error textarea {
    border-color: var(--color-error);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-error) 15%, transparent);
}
.ct-field__error {
    margin: 0.4rem 0 0;
    font-size: var(--text-xs);
    color: var(--color-error);
    font-weight: 500;
}

/* Thank-you card replaces the form on successful submission */
.ct-thanks {
    background: var(--color-surface);
    border: 1px solid var(--color-divider);
    border-radius: var(--radius-lg);
    padding: clamp(2rem, 5vw, 3rem);
    box-shadow: var(--shadow-sm);
    scroll-margin-top: 100px; /* so #ct-thanks anchor doesn't hide under sticky header */
}
.ct-thanks__eyebrow {
    margin: 0 0 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--color-accent);
}
.ct-thanks__heading {
    margin: 0 0 1rem;
    font-size: var(--text-xl);
    line-height: 1.2;
    color: var(--color-text);
    letter-spacing: -0.01em;
}
.ct-thanks__text {
    margin: 0 0 1rem;
    color: var(--color-text);
    line-height: 1.6;
    max-width: 56ch;
}
.ct-thanks__text--muted {
    color: var(--color-text-muted);
    font-size: var(--text-sm);
}
.ct-thanks__text a {
    color: var(--color-primary);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}
