@use "../../1-helpers/functions";

[data-archive="default"][data-layout="simple"] {

	article {
		display: flex;
		gap: var(--card-inner-spacing, 30px);

		@include functions.media-breakpoint-down (sm) {
			flex-direction: column;
		}

		> .ct-media-container {
			@include functions.media-breakpoint-up (md) {
				max-width: var(--card-media-max-width, 40%);
				flex-shrink: 0;
				margin-inline-end: 0;

				&:not(.boundless-image) {
					align-self: center;
				}
			}
		}

		.card-content {
			flex: 1;
			
			@include functions.media-breakpoint-up (md) {
				align-self: center;
			}
		}
	}

	// apply spacing and border only when slider is not enabled
	> article {
		border-bottom: var(--card-border, none);
		padding-bottom: var(--grid-columns-gap, 30px);

		&:not(:last-child) {
			margin-bottom: var(--grid-columns-gap, 30px);
		}
	}


	// boxed card type
	&[data-cards="boxed"] {

		.entry-card .boundless-image {

			@include functions.media-breakpoint-up (md) {
				width: 100%;
				margin-bottom: calc(var(--card-inner-spacing, 30px) * -1);
			}
		}
	}
}