// Copyright (c) 2017-2025, CKSource Holding sp. z o.o. All rights reserved.
// For licensing, see LICENSE.md.

@use 'helpers/color';
@use 'helpers/globals';
@use 'helpers/spacing';

nav.api-info-box.api-secondary-navigation{
	@include globals.u-responsive-narrow {
		padding: spacing.u-spacing( 2 ) spacing.u-spacing( 2 ) spacing.u-spacing( -3 );
		min-width: 12em;

		dt {
			border-bottom: 1px solid color.u-color( 'separator' )
		}

		dd {
			margin-right: spacing.u-spacing( -1 );
		  	margin-bottom: 0;
		}
	}

	@include globals.u-responsive-wide {
		dl {
			margin-bottom: 1.5 * globals.$u-footer-height;
		}
	}

	@include globals.u-responsive-wide-md {
		padding-left: spacing.u-spacing(4);
	}

	// Fix "no-breaking-space" as pseudoelement in the ToC for API (hierachy).
	code {
		&::after,
		&::before {
			content: '';
		}

		// Disable "active" dot for hover & current item.
		a {
			&::before {
				display: none;
			}
		}
	}

	dt {
		@include globals.u-micro-header;
		margin-bottom: .5em;

		&:first-child {
			padding-top: 0;
		}
	}

	ul {
		list-style: none;
		margin: 0 0 spacing.u-spacing( 1 ) spacing.u-spacing( 2 );
		padding: 0;

		code {
			background: none;
			padding: 0;
		}

		&.hierarchy-list {
			ul {
				li {
					&::before {
						content: url( ../img/list-nest.svg );
						height: 1em;
						width: 1em;
						display: inline-block;
						position: relative;
						top: -.3em;
					}
				}
			}

			& > li > ul {
				margin-left: 0;
			}
		}
	}
}
