/**
 * A.R.C Technology — Resilient Orbit CTA Sections
 * Navy cosmos with teal radial glow, bold display type, vibrant energy
 * v2 — .cta-section__inner often uses raw h2/p without BEM utilities; scope fixes contrast + buttons
 */

/* ===========================
   CTA SECTION — Primary
   Lighter navy than the footer so the two dark bands read as separate layers
   =========================== */
.cta-section {
    background: linear-gradient(135deg, var(--color-navy-light) 0%, var(--color-navy-muted) 100%);
    padding: clamp(5rem, 8vw, 8rem) 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Radial teal glow — center bloom */
.cta-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 50% 50%, rgba(0, 212, 255, 0.12) 0%, rgba(0, 212, 255, 0.04) 35%, transparent 70%);
    pointer-events: none;
}

/* Gradient top border — teal > coral > yellow */
.cta-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: var(--border-thick);
    background: linear-gradient(90deg, var(--color-teal), var(--color-coral), var(--color-yellow));
    pointer-events: none;
    z-index: 1;
}

.cta-section__inner {
    position: relative;
    z-index: 1;
    max-width: 720px;
    margin: 0 auto;
    padding: 0 var(--container-px);
}

/* Section label */
.cta-section__label {
    display: inline-block;
    font-family: var(--font-display);
    font-size: var(--fs-label);
    font-weight: var(--font-bold);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--color-teal);
    margin-bottom: var(--space-5);
}

.cta-section__label--yellow {
    color: var(--color-yellow);
}

.cta-section__title {
    font-family: var(--font-display);
    font-size: var(--fs-4xl);
    font-weight: var(--font-bold);
    letter-spacing: -0.025em;
    color: var(--color-white);
    margin-bottom: var(--space-5);
    line-height: var(--leading-tight);
}

.cta-section__text {
    font-family: var(--font-family);
    font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
    color: var(--color-text-on-dark-secondary);
    line-height: var(--leading-relaxed);
    margin-bottom: var(--space-10);
    max-width: 52ch;
    margin-left: auto;
    margin-right: auto;
}

/* Raw h2 / p (most service pages omit .cta-section__title / .cta-section__text) */
.cta-section:not(.cta-section--light) .cta-section__inner > h2 {
    font-family: var(--font-display);
    font-size: var(--fs-4xl);
    font-weight: var(--font-bold);
    letter-spacing: -0.025em;
    color: var(--color-white);
    margin: 0 0 var(--space-5);
    line-height: var(--leading-tight);
}

.cta-section:not(.cta-section--light) .cta-section__inner > p {
    font-family: var(--font-family);
    font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
    color: rgba(255, 255, 255, 0.88);
    line-height: var(--leading-relaxed);
    margin: 0 auto var(--space-10);
    max-width: 52ch;
}

.cta-section:not(.cta-section--light) .cta-section__inner > .section-label {
    margin-bottom: var(--space-5);
}

.cta-section:not(.cta-section--light) .cta-section__inner .section-label--light {
    color: var(--color-teal);
    text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
}

/* Primary CTA: btn--dark was same fill as navy — invert for visibility */
.cta-section:not(.cta-section--light) .cta-section__actions .btn--dark {
    background: var(--color-white);
    color: var(--color-navy);
    border-color: var(--color-white);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.cta-section:not(.cta-section--light) .cta-section__actions .btn--dark:hover {
    background: var(--color-teal);
    color: var(--color-navy);
    border-color: var(--color-teal);
    box-shadow: 0 8px 28px rgba(0, 212, 255, 0.4);
}

.cta-section:not(.cta-section--light) .cta-section__actions .btn--outline-white {
    border-width: 2px;
    border-color: rgba(255, 255, 255, 0.65);
    color: #fff;
}

.cta-section:not(.cta-section--light) .cta-section__actions .btn--outline-white:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
    color: #fff;
}

.cta-section--light .cta-section__inner > h2 {
    color: var(--color-navy);
    margin: 0 0 var(--space-5);
    line-height: var(--leading-tight);
}

.cta-section--light .cta-section__inner > p {
    color: var(--color-text-secondary);
    margin: 0 auto var(--space-10);
    max-width: 52ch;
}

.cta-section__actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    flex-wrap: wrap;
}

/* ===========================
   CTA SECTION VARIANTS
   =========================== */

/* Deeper glow variant */
.cta-section--glow::before {
    background:
        radial-gradient(ellipse 50% 40% at 50% 60%, rgba(0, 212, 255, 0.18) 0%, transparent 60%),
        radial-gradient(ellipse 30% 30% at 30% 40%, rgba(255, 107, 107, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse 30% 30% at 70% 40%, rgba(255, 214, 10, 0.05) 0%, transparent 50%);
}

/* Light variant */
.cta-section--light {
    background: var(--color-off-white);
}

.cta-section--light::before {
    background:
        radial-gradient(ellipse 60% 50% at 50% 50%, rgba(0, 212, 255, 0.06) 0%, transparent 60%);
}

.cta-section--light::after {
    background: linear-gradient(90deg, var(--color-teal), var(--color-coral), var(--color-yellow));
}

.cta-section--light .cta-section__title {
    color: var(--color-navy);
}

.cta-section--light .cta-section__text {
    color: var(--color-text-secondary);
}

.cta-section--light .cta-section__label {
    color: var(--color-on-light-teal);
}

/* ===========================
   INLINE CTA BANNER — Card-style
   =========================== */
.cta-banner {
    background: var(--color-white);
    border: var(--border-thick) solid var(--color-navy);
    border-radius: var(--radius-xl);
    padding: var(--space-8) var(--space-10);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-6);
    flex-wrap: wrap;
    position: relative;
    transition: box-shadow var(--transition-base) var(--ease-bounce),
                transform var(--transition-base) var(--ease-bounce);
}

.cta-banner:hover {
    box-shadow: var(--shadow-brutal);
    transform: translateY(-2px);
}

.cta-banner__text h3 {
    font-family: var(--font-display);
    font-size: var(--fs-xl);
    font-weight: var(--font-bold);
    color: var(--color-navy);
    margin-bottom: var(--space-2);
}

.cta-banner__text p {
    font-family: var(--font-family);
    font-size: var(--fs-sm);
    color: var(--color-text-secondary);
    margin: 0;
    line-height: var(--leading-normal);
}

/* Dark banner variant */
.cta-banner--dark {
    background: var(--color-navy);
    border-color: var(--color-teal);
}

.cta-banner--dark .cta-banner__text h3 {
    color: var(--color-white);
}

.cta-banner--dark .cta-banner__text p {
    color: var(--color-text-on-dark-secondary);
}

.cta-banner--dark:hover {
    box-shadow: var(--shadow-teal);
}

/* ===========================
   AI HIGHLIGHT — 2-column feature block
   =========================== */
.ai-highlight {
    background: var(--color-navy);
    padding: clamp(5rem, 8vw, 8rem) 0;
    position: relative;
    overflow: hidden;
}

/* Gradient top border */
.ai-highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: var(--border-thick);
    background: linear-gradient(90deg, var(--color-teal), var(--color-coral), var(--color-yellow));
    z-index: 1;
}

/* Subtle radial glow */
.ai-highlight::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 75% 50%, rgba(0, 212, 255, 0.08) 0%, transparent 55%);
    pointer-events: none;
}

.ai-highlight__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
    position: relative;
    z-index: 1;
}

.ai-highlight__content {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
}

.ai-highlight__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--color-teal-subtle);
    border: var(--border-medium) solid var(--color-teal);
    border-radius: var(--radius-full);
    font-family: var(--font-display);
    font-size: var(--fs-label);
    font-weight: var(--font-bold);
    color: var(--color-teal);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    width: fit-content;
}

.ai-highlight__title {
    font-family: var(--font-display);
    font-size: var(--fs-3xl);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    letter-spacing: -0.025em;
    color: var(--color-white);
}

.ai-highlight__text {
    font-family: var(--font-family);
    font-size: var(--fs-lg);
    color: var(--color-text-on-dark-secondary);
    line-height: var(--leading-relaxed);
}

/* Feature list */
.ai-highlight__features {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ai-highlight__features li {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    font-family: var(--font-family);
    font-size: var(--fs-sm);
    color: var(--color-text-on-dark-secondary);
    line-height: var(--leading-normal);
}

.ai-highlight__features li::before {
    content: '';
    display: block;
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    background: var(--color-teal);
    margin-top: 0.4em;
}

.ai-highlight__visual {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ai-highlight__graphic {
    width: 100%;
    max-width: 420px;
    aspect-ratio: 1;
    background: var(--color-navy-light);
    border: var(--border-thick) solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-2xl);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.ai-highlight__graphic::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 50% 50%, rgba(0, 212, 255, 0.08) 0%, transparent 70%);
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 767px) {
    .ai-highlight__inner {
        grid-template-columns: 1fr;
    }

    .ai-highlight__visual {
        display: none;
    }

    .cta-banner {
        flex-direction: column;
        text-align: center;
        padding: var(--space-6) var(--space-6);
    }
}

@media (prefers-reduced-motion: reduce) {
    .cta-banner {
        transition: none;
    }
}
