/*
 * SMM Homepage interaction refinements.
 * Loaded only on the front page.
 */

/* Homepage standard-card numbers: stronger normal visibility. */
.smm-homepage .card-num {
	color: #a8b6c5;
	transition: color .25s ease;
}

/* Shared linked-card interaction: standard cards + Why SMM attribute cards. */
.smm-homepage .smm-home-linked-card {
	position: relative;
	z-index: 1;
	border-bottom: 3px solid transparent;
	transition:
		transform .25s ease,
		box-shadow .25s ease,
		background-color .25s ease,
		border-color .25s ease;
}

.smm-homepage .smm-home-linked-card:hover,
.smm-homepage .smm-home-linked-card:focus-visible {
	z-index: 2;
	transform: translateY(-4px);
	background: #dfeefa;
	box-shadow: 0 12px 30px rgba(16, 43, 73, .22);
	border-bottom-color: var(--red, #d32f2f);
}

/* Linked standard-card number becomes more prominent on interaction. */
.smm-homepage .card.smm-home-linked-card:hover .card-num,
.smm-homepage .card.smm-home-linked-card:focus-visible .card-num {
	color: #6b829a;
}

/* Preserve right-side card images while matching the stronger hover background. */
.smm-homepage .card.has-image.smm-home-linked-card:hover::after,
.smm-homepage .card.has-image.smm-home-linked-card:focus-visible::after {
	background: linear-gradient(
		to right,
		#dfeefa 0%,
		rgba(223, 238, 250, 1) 15%,
		rgba(223, 238, 250, .84) 35%,
		rgba(223, 238, 250, .32) 62%,
		rgba(223, 238, 250, 0) 100%
	);
}

/* Consistent keyboard focus on linked cards. */
.smm-homepage .smm-home-linked-card:focus-visible {
	outline: 3px solid rgba(26, 107, 196, .35);
	outline-offset: 3px;
}

/*
 * Final CTA link: retain the established red-button appearance while adding
 * the same interaction language (lift + stronger shadow).
 */
.smm-homepage .smm-home-linked-action {
	position: relative;
	z-index: 1;
	transition:
		transform .25s ease,
		box-shadow .25s ease,
		background-color .25s ease;
}

.smm-homepage .smm-home-linked-action:hover,
.smm-homepage .smm-home-linked-action:focus-visible {
	z-index: 2;
	transform: translateY(-4px);
	box-shadow: 0 12px 30px rgba(16, 43, 73, .22);
}

.smm-homepage .smm-home-linked-action:focus-visible {
	outline: 3px solid rgba(26, 107, 196, .35);
	outline-offset: 3px;
}

/*
 * Homepage final CTA — permanent closing-band treatment.
 * Mirrors the Level-One hero visual language in reverse:
 * navy closing band with the red rule at the top.
 */
.smm-homepage > div > section:last-of-type {
    background: #142d4c !important;
    border-top: 4px solid var(--red, #d32f2f) !important;
    border-bottom: 0 !important;
    padding-top: 58px !important;
    padding-bottom: 54px !important;
}

.smm-homepage > div > section:last-of-type .container {
    position: relative;
}

.smm-homepage > div > section:last-of-type .eyebrow {
    color: #a9c8e8 !important;
}

.smm-homepage > div > section:last-of-type .sec-title {
    color: #ffffff !important;
    max-width: 820px;
}

.smm-homepage > div > section:last-of-type .sec-desc {
    color: #d7e2ee !important;
    max-width: 700px;
}

.smm-homepage > div > section:last-of-type .hero-btns {
    margin-top: 26px;
}

.smm-homepage > div > section:last-of-type .btn-red {
    box-shadow: 0 8px 22px rgba(0, 0, 0, .18);
}

.smm-homepage > div > section:last-of-type .btn-red:hover,
.smm-homepage > div > section:last-of-type .btn-red:focus-visible {
    box-shadow: 0 12px 30px rgba(0, 0, 0, .28);
}

html[data-theme="dark"] .smm-homepage > div > section:last-of-type {
    background: #10263f !important;
    border-top-color: var(--red, #d32f2f) !important;
}

html[data-theme="dark"] .smm-homepage > div > section:last-of-type .eyebrow {
    color: #a9c8e8 !important;
}

html[data-theme="dark"] .smm-homepage > div > section:last-of-type .sec-title {
    color: #ffffff !important;
}

html[data-theme="dark"] .smm-homepage > div > section:last-of-type .sec-desc {
    color: #d7e2ee !important;
}

@media (max-width: 768px) {
    .smm-homepage > div > section:last-of-type {
        padding-top: 48px !important;
        padding-bottom: 44px !important;
    }

    .smm-homepage > div > section:last-of-type .hero-btns {
        margin-top: 22px;
    }
}


/*
 * Homepage image-backed cards.
 * Match the approved Level-One treatment at all responsive widths:
 * 50% image area, 65% text measure, and a softer fade in light/dark mode.
 */
.smm-homepage .card.has-image::before {
    width: 50%;
}

.smm-homepage .card.has-image::after {
    width: 50%;
    background: linear-gradient(
        to right,
        var(--white) 0%,
        rgba(255, 255, 255, 1) 8%,
        rgba(255, 255, 255, .78) 28%,
        rgba(255, 255, 255, .42) 48%,
        rgba(255, 255, 255, .12) 68%,
        rgba(255, 255, 255, 0) 100%
    );
}

.smm-homepage .card.has-image .card-num,
.smm-homepage .card.has-image .card-title,
.smm-homepage .card.has-image .card-desc {
    max-width: 65%;
}

.smm-homepage .card.has-image:hover::after,
.smm-homepage .card.has-image.smm-home-linked-card:focus-visible::after {
    background: linear-gradient(
        to right,
        var(--blue-light) 0%,
        rgba(232, 242, 251, 1) 8%,
        rgba(232, 242, 251, .74) 28%,
        rgba(232, 242, 251, .36) 48%,
        rgba(232, 242, 251, .10) 68%,
        rgba(232, 242, 251, 0) 100%
    );
}

html[data-theme="dark"] .smm-homepage .card.has-image::after {
    background: linear-gradient(
        to right,
        rgba(23, 35, 47, 1) 0%,
        rgba(23, 35, 47, 1) 8%,
        rgba(23, 35, 47, .78) 28%,
        rgba(23, 35, 47, .42) 48%,
        rgba(23, 35, 47, .12) 68%,
        rgba(23, 35, 47, 0) 100%
    );
}

html[data-theme="dark"] .smm-homepage .card.has-image:hover::after,
html[data-theme="dark"] .smm-homepage .card.has-image.smm-home-linked-card:focus-visible::after {
    background: linear-gradient(
        to right,
        #1d384f 0%,
        rgba(29, 56, 79, 1) 8%,
        rgba(29, 56, 79, .76) 28%,
        rgba(29, 56, 79, .40) 48%,
        rgba(29, 56, 79, .10) 68%,
        rgba(29, 56, 79, 0) 100%
    );
}

/*
 * Homepage light-mode readability.
 * Uses the finalized body-copy standard established on Level One and Level Two.
 * Hero copy and the dark closing CTA band retain their dedicated treatments.
 */
html:not([data-theme="dark"]) .smm-homepage .sec-desc,
html:not([data-theme="dark"]) .smm-homepage .card-desc,
html:not([data-theme="dark"]) .smm-homepage .info-card p {
    color: #29435E !important;
    font-weight: 400;
}

/* Preserve the dedicated final CTA-band treatment. */
html:not([data-theme="dark"]) .smm-homepage > div > section:last-of-type .sec-desc {
    color: #d7e2ee !important;
}

/*
 * Homepage Business Areas — test treatment for non-image cards.
 * The border uses the exact stop positions of the approved image-card fade.
 * Its visibility is the inverse of that image-cover opacity: effectively
 * transparent on the left and progressively more defined toward the right.
 * No typography, background, shadow, radius, spacing or hover behavior changes.
 */
.smm-homepage .smm-home-business .card:not(.has-image)::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid transparent;
    border-radius: inherit;
    background: linear-gradient(
        to right,
        rgba(100, 123, 146, 0) 0%,
        rgba(100, 123, 146, 0) 8%,
        rgba(100, 123, 146, .22) 28%,
        rgba(100, 123, 146, .58) 48%,
        rgba(100, 123, 146, .88) 68%,
        rgba(100, 123, 146, 1) 100%
    ) border-box;
    -webkit-mask:
        linear-gradient(#fff 0 0) padding-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#fff 0 0) padding-box,
        linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
    z-index: 3;
}

html[data-theme="dark"] .smm-homepage .smm-home-business .card:not(.has-image)::after {
    background: linear-gradient(
        to right,
        rgba(111, 137, 162, 0) 0%,
        rgba(111, 137, 162, 0) 8%,
        rgba(111, 137, 162, .22) 28%,
        rgba(111, 137, 162, .58) 48%,
        rgba(111, 137, 162, .88) 68%,
        rgba(111, 137, 162, 1) 100%
    ) border-box;
}

