/*
 * Responsive styling for the Excel AutoFit article.
 *
 * This stylesheet is intentionally scoped to .excel-sheet-autofit-page. It
 * works with the shared legacy stylesheet and cannot change another page's
 * content, header, forms, or footer.
 */

body.excel-sheet-autofit-page,
.excel-sheet-autofit-page *,
.excel-sheet-autofit-page *::before,
.excel-sheet-autofit-page *::after {
	box-sizing: border-box;
}

body.excel-sheet-autofit-page {
	min-width: 0;
	max-width: 100%;
	overflow-x: hidden;
	background: #fff;
	color: #434950;
	font-family: 'Maven Pro', Arial, Helvetica, sans-serif;
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

.excel-sheet-autofit-page .skip-link {
	position: absolute;
	top: 8px;
	left: 8px;
	z-index: 3000;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
	background: #343a41;
	color: #fff;
}

.excel-sheet-autofit-page .skip-link:focus {
	width: auto;
	height: auto;
	padding: 10px 14px;
	margin: 0;
	overflow: visible;
	clip: auto;
	white-space: normal;
	text-decoration: none;
}

/* The shared header reveals this button at the tablet/mobile breakpoint. */
.excel-sheet-autofit-page .menu-toggle {
	display: none !important;
}

.excel-sheet-autofit-page .excel-autofit-main {
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
	background: #fff;
}

.excel-sheet-autofit-page .excel-autofit-article {
	width: calc(100% - 40px);
	max-width: 900px;
	margin: 0 auto;
	padding: 30px 0 48px;
}

.excel-sheet-autofit-page .article-breadcrumb {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 10px;
	margin: 0 0 20px;
	color: #6b7278;
	font-size: 14px;
	line-height: 1.4;
}

.excel-sheet-autofit-page .article-breadcrumb a {
	color: #6cc195 !important;
	font-weight: 700;
	text-decoration: none;
}

.excel-sheet-autofit-page .article-breadcrumb a:hover,
.excel-sheet-autofit-page .article-breadcrumb a:focus {
	color: #343a41 !important;
	text-decoration: underline;
}

.excel-sheet-autofit-page .article-header {
	position: static;
	margin: 0;
	padding: 0 0 24px;
	border-bottom: 1px solid #e5e5e5;
	text-align: left;
}

.excel-sheet-autofit-page .article-eyebrow {
	margin: 0 0 8px;
	color: #6cc195;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 1.3px;
	line-height: 1.3;
	text-transform: uppercase;
}

.excel-sheet-autofit-page .article-header h1 {
	float: none;
	width: auto;
	margin: 0 0 12px;
	padding: 0;
	color: #343a41;
	font-family: 'Maven Pro', Arial, Helvetica, sans-serif;
	font-size: clamp(30px, 5vw, 46px);
	font-weight: 700;
	letter-spacing: -1.3px;
	line-height: 1.08;
	text-align: left;
}

.excel-sheet-autofit-page .article-header h1 span,
.excel-sheet-autofit-page .section-heading h2 span {
	color: #6cc195;
}

.excel-sheet-autofit-page .article-lead {
	max-width: 760px;
	margin: 0;
	color: #666d73;
	font-size: 18px;
	line-height: 1.55;
}

.excel-sheet-autofit-page .article-facts {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 1px;
	margin: 24px 0;
	border: 1px solid #dfe3e5;
	border-radius: 2px;
	background: #dfe3e5;
	overflow: hidden;
}

.excel-sheet-autofit-page .article-facts > div {
	min-width: 0;
	padding: 13px 15px;
	background: #f8faf9;
}

.excel-sheet-autofit-page .article-facts span,
.excel-sheet-autofit-page .article-facts strong {
	display: block;
}

.excel-sheet-autofit-page .article-facts span {
	margin-bottom: 3px;
	color: #6b7278;
	font-size: 12px;
	letter-spacing: .6px;
	text-transform: uppercase;
}

.excel-sheet-autofit-page .article-facts strong {
	color: #343a41;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.3;
}

.excel-sheet-autofit-page .autofit-overview {
	margin: 0 0 24px;
	padding: 24px 26px 26px;
	border: 1px solid #dfe3e5;
	border-radius: 2px;
	background: #f8faf9;
	box-shadow: 0 2px 8px rgba(52, 58, 65, .05);
}

.excel-sheet-autofit-page .section-heading {
	display: flex;
	align-items: baseline;
	gap: 12px;
	margin: 0 0 16px;
	padding-bottom: 12px;
	border-bottom: 1px solid #e5e5e5;
}

.excel-sheet-autofit-page .section-heading--steps {
	margin-bottom: 18px;
}

.excel-sheet-autofit-page .section-kicker {
	flex: 0 0 auto;
	margin: 0;
	color: #6cc195;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 1px;
	text-transform: uppercase;
}

.excel-sheet-autofit-page .section-heading h2 {
	margin: 0;
	color: #343a41;
	font-family: 'Maven Pro', Arial, Helvetica, sans-serif;
	font-size: clamp(22px, 3vw, 29px);
	font-weight: 700;
	letter-spacing: -.6px;
	line-height: 1.2;
}

.excel-sheet-autofit-page .autofit-overview > p,
.excel-sheet-autofit-page .step-body > p,
.excel-sheet-autofit-page .save-note {
	margin: 0;
	color: #434950;
	font-size: 16px;
	line-height: 1.6;
}

.excel-sheet-autofit-page .autofit-overview > p + p,
.excel-sheet-autofit-page .step-body > p + p {
	margin-top: 14px;
}

.excel-sheet-autofit-page .article-note,
.excel-sheet-autofit-page .save-note {
	padding: 12px 14px;
	border-left: 4px solid #6cc195;
	background: #eef8f2;
}

.excel-sheet-autofit-page .article-note strong,
.excel-sheet-autofit-page .save-note strong,
.excel-sheet-autofit-page .completion-note strong {
	color: #343a41;
	font-weight: 700;
}

.excel-sheet-autofit-page .autofit-instructions {
	margin: 0;
}

.excel-sheet-autofit-page .autofit-steps {
	display: grid;
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.excel-sheet-autofit-page .autofit-step {
	display: grid;
	grid-template-columns: 32px minmax(0, 1fr);
	gap: 14px;
	align-items: start;
	min-width: 0;
	margin: 0;
	padding: 22px 24px;
	border: 1px solid #dfe3e5;
	border-radius: 2px;
	background: #fff;
	box-shadow: 0 2px 8px rgba(52, 58, 65, .06);
}

.excel-sheet-autofit-page .step-number {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	margin-top: 1px;
	border-radius: 50%;
	background: #6cc195;
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
}

.excel-sheet-autofit-page .step-body {
	min-width: 0;
}

.excel-sheet-autofit-page .step-body h3 {
	margin: 0 0 14px;
	color: #343a41;
	font-family: 'Maven Pro', Arial, Helvetica, sans-serif;
	font-size: clamp(20px, 2.5vw, 27px);
	font-weight: 700;
	letter-spacing: -.5px;
	line-height: 1.18;
}

.excel-sheet-autofit-page .step-body strong {
	color: #343a41;
	font-weight: 700;
}

.excel-sheet-autofit-page .instruction-list {
	margin: 14px 0 18px;
	padding: 0 0 0 25px;
	color: #434950;
	font-size: 16px;
	line-height: 1.6;
}

.excel-sheet-autofit-page .instruction-list li {
	margin: 0 0 8px;
	padding-left: 3px;
}

.excel-sheet-autofit-page kbd,
.excel-sheet-autofit-page code {
	border-radius: 2px;
	font-family: Consolas, Monaco, monospace;
}

.excel-sheet-autofit-page kbd {
	display: inline-block;
	padding: 2px 6px;
	border: 1px solid #cfd5d8;
	border-bottom-width: 2px;
	background: #f8faf9;
	color: #343a41;
	font-size: .9em;
	line-height: 1.2;
}

.excel-sheet-autofit-page .code-card {
	width: 100%;
	min-width: 0;
	margin: 16px 0 0;
	border: 1px solid #4b535a;
	border-radius: 2px;
	background: #343a41;
	overflow: hidden;
}

.excel-sheet-autofit-page .code-card--line {
	margin-top: 12px;
}

.excel-sheet-autofit-page .code-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	min-width: 0;
	padding: 8px 10px 8px 14px;
	border-bottom: 1px solid #4b535a;
	color: #dfe8e3;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .5px;
	text-transform: uppercase;
}

.excel-sheet-autofit-page .copy-code {
	flex: 0 0 auto;
	min-height: 44px;
	padding: 8px 13px;
	border: 1px solid #6cc195;
	border-radius: 2px;
	-webkit-appearance: none;
	appearance: none;
	background: #6cc195;
	color: #343a41;
	font: 700 13px/1.2 'Maven Pro', Arial, sans-serif;
	cursor: pointer;
}

.excel-sheet-autofit-page .copy-code:hover,
.excel-sheet-autofit-page .copy-code:focus {
	border-color: #fff;
	background: #fff;
	outline: none;
}

.excel-sheet-autofit-page .copy-code:focus-visible {
	outline: 2px solid #f90;
	outline-offset: 2px;
}

/* Override the legacy global pre styling and keep long code inside its card. */
.excel-sheet-autofit-page .code-card pre {
	max-width: 100%;
	margin: 0;
	padding: 16px 14px;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	background: #343a41;
	color: #f5f7f6;
	font: 400 16px/1.55 Consolas, Monaco, monospace;
	white-space: pre;
}

.excel-sheet-autofit-page .code-card code {
	padding: 0;
	background: transparent;
	color: inherit;
	font: inherit;
}

.excel-sheet-autofit-page .copy-status {
	display: block;
	min-height: 18px;
	padding: 0 14px 7px;
	color: #9fdbb9;
	font-size: 12px;
}

.excel-sheet-autofit-page .save-note {
	margin: 18px 0 0;
}

.excel-sheet-autofit-page .completion-note {
	margin: 22px 0 0;
	padding: 16px 18px;
	border-left: 4px solid #6cc195;
	background: #eef8f2;
	color: #434950;
	font-size: 15px;
	line-height: 1.55;
}

/* Partner logos and footer follow the current KB/index treatment. */
.excel-sheet-autofit-page .excel-autofit-partner-strip {
	width: 100%;
	max-width: 962px;
	margin: 0 auto;
	border-top: 1px solid #e5e5e5;
}

.excel-sheet-autofit-page .excel-autofit-partner-logos {
	display: flex;
	align-items: center;
	justify-content: space-around;
	gap: 22px;
	min-width: 0;
	padding: 18px 20px 12px;
}

.excel-sheet-autofit-page .excel-autofit-partner-logos img {
	display: block;
	width: auto;
	max-width: 22%;
	height: auto;
	max-height: 56px;
	padding: 0 !important;
	object-fit: contain;
}

.excel-sheet-autofit-page .footer-main {
	width: 100%;
	max-width: 962px;
	margin: 0 auto;
	background: #343a41 !important;
}

.excel-sheet-autofit-page .footer-main footer {
	width: 100%;
	padding: 18px 20px 20px;
	background: #343a41 !important;
}

.excel-sheet-autofit-page .footer-inner {
	overflow: visible;
}

.excel-sheet-autofit-page .footer-menu {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 8px 30px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.excel-sheet-autofit-page .footer-menu li {
	padding: 0 !important;
}

.excel-sheet-autofit-page .footer-menu a {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	color: #fff !important;
	font-size: 14px;
	text-decoration: none !important;
}

.excel-sheet-autofit-page .footer-menu a:hover,
.excel-sheet-autofit-page .footer-menu a:focus {
	color: #6cc195 !important;
}

.excel-sheet-autofit-page .footertext-bot {
	padding-top: 8px;
	color: #a1a4a8;
	font-size: 12px;
	line-height: 1.5;
}

.excel-sheet-autofit-page .footertext-bot .copyright-link {
	color: transparent !important;
}

.excel-sheet-autofit-page #spacer-footer-bottom {
	display: none;
}

@media screen and (max-width: 1023px) {
	.excel-sheet-autofit-page .excel-autofit-article {
		width: calc(100% - 32px);
		padding-top: 24px;
	}

	.excel-sheet-autofit-page .autofit-step {
		gap: 13px;
		padding: 20px;
	}

	.excel-sheet-autofit-page .autofit-overview {
		padding: 22px 20px 22px;
	}

	.excel-sheet-autofit-page .excel-autofit-partner-logos {
		gap: 16px;
		padding-right: 16px;
		padding-left: 16px;
	}
}

@media screen and (max-width: 680px) {
	.excel-sheet-autofit-page .excel-autofit-article {
		width: calc(100% - 24px);
		padding-top: 20px;
		padding-bottom: 32px;
	}

	.excel-sheet-autofit-page .article-breadcrumb {
		margin-bottom: 15px;
		font-size: 13px;
	}

	.excel-sheet-autofit-page .article-header {
		padding-bottom: 20px;
	}

	.excel-sheet-autofit-page .article-lead {
		font-size: 16px;
	}

	.excel-sheet-autofit-page .article-facts {
		grid-template-columns: minmax(0, 1fr);
		margin: 18px 0;
	}

	.excel-sheet-autofit-page .autofit-overview {
		margin-bottom: 16px;
		padding: 18px 16px 20px;
	}

	.excel-sheet-autofit-page .section-heading {
		align-items: flex-start;
		gap: 9px;
		margin-bottom: 14px;
	}

	.excel-sheet-autofit-page .section-heading h2 {
		font-size: 23px;
	}

	.excel-sheet-autofit-page .autofit-overview > p,
	.excel-sheet-autofit-page .step-body > p,
	.excel-sheet-autofit-page .save-note,
	.excel-sheet-autofit-page .instruction-list {
		font-size: 15px;
	}

	.excel-sheet-autofit-page .autofit-step {
		padding: 18px 16px 20px;
	}

	.excel-sheet-autofit-page .step-number {
		width: 30px;
		height: 30px;
	}

	.excel-sheet-autofit-page .step-body h3 {
		font-size: 22px;
	}

	.excel-sheet-autofit-page .instruction-list {
		padding-left: 22px;
	}

	.excel-sheet-autofit-page .code-toolbar {
		align-items: flex-start;
		padding-left: 11px;
	}

	.excel-sheet-autofit-page .code-card pre {
		padding: 14px 11px;
		font-size: 14px;
	}

	.excel-sheet-autofit-page .completion-note {
		margin-top: 16px;
		padding: 13px 14px;
		font-size: 14px;
	}

	.excel-sheet-autofit-page .excel-autofit-partner-logos {
		flex-wrap: wrap;
		justify-content: center;
		gap: 14px 20px;
	}

	.excel-sheet-autofit-page .excel-autofit-partner-logos img {
		width: calc(50% - 20px);
		max-width: 160px;
		max-height: 50px;
	}

	.excel-sheet-autofit-page .footer-main footer {
		padding-right: 16px;
		padding-left: 16px;
	}
}

@media screen and (max-width: 380px) {
	.excel-sheet-autofit-page .excel-autofit-article {
		width: calc(100% - 16px);
	}

	.excel-sheet-autofit-page .autofit-step,
	.excel-sheet-autofit-page .autofit-overview {
		padding-right: 13px;
		padding-left: 13px;
	}

	.excel-sheet-autofit-page .footer-menu {
		gap: 8px;
	}
}
