/*!
 * Copyright 2024 Adobe. All rights reserved.
 *
 * This file is licensed to you under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License. You may obtain a copy
 * of the License at <http://www.apache.org/licenses/LICENSE-2.0>
 *
 * Unless required by applicable law or agreed to in writing, software distributed under
 * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
 * OF ANY KIND, either express or implied. See the License for the specific language
 * governing permissions and limitations under the License.
 */

.spectrum-Card {
	--spectrum-card-border-color: var(--spectrum-gray-100);
	--spectrum-card-border-color-hover: var(--spectrum-gray-200);
	--spectrum-card-divider-color: var(--spectrum-gray-200);
	--spectrum-card-preview-background-color: var(--spectrum-gray-100);
	--spectrum-card-preview-background-color-hover: var(--spectrum-gray-200);
	--spectrum-card-background-color: var(--mod-card-background-color, var(--spectrum-background-layer-2-color));
	--spectrum-card-body-spacing: var(--mod-card-body-spacing, var(--spectrum-spacing-400));
	--spectrum-card-body-padding-block-start: var(--mod-card-body-padding-block-start, var(--spectrum-spacing-300));
	--spectrum-card-title-padding-right: var(--mod-card-title-padding-right, var(--spectrum-spacing-400));
	--spectrum-card-content-margin-top: var(--mod-card-content-margin-top, var(--spectrum-spacing-100));
	--spectrum-card-content-margin-bottom: var(--mod-card-content-margin-bottom, var(--spectrum-spacing-300));
	--spectrum-card-footer-padding-top: var(--mod-card-footer-padding-block-start, var(--spectrum-spacing-100));
	--spectrum-card-subtitle-padding-right: var(--mod-card-subtitle-padding-right, var(--spectrum-spacing-100));
	--spectrum-card-border-width: var(--mod-card-border-width, var(--spectrum-border-width-100));
	--spectrum-card-corner-radius: var(--mod-card-corner-radius, var(--spectrum-corner-radius-100));
	--spectrum-card-title-font-family: var(--mod-card-title-font-family, var(--spectrum-sans-font-family-stack));
	--spectrum-card-title-font-size: var(--mod-card-title-font-size, var(--spectrum-heading-size-xxs));
	--spectrum-card-title-font-weight: var(--mod-card-title-font-weight, var(--spectrum-heading-sans-serif-font-weight));
	--spectrum-card-title-font-style: var(--mod-card-title-font-style, var(--spectrum-heading-sans-serif-font-style));
	--spectrum-card-title-line-height: var(--mod-card-title-line-height, var(--spectrum-heading-line-height));
	--spectrum-card-title-font-color: var(--mod-card-title-font-color, var(--spectrum-heading-color));
	--spectrum-card-body-font-family: var(--mod-card-body-font-family, var(--spectrum-sans-font-family-stack));
	--spectrum-card-body-font-size: var(--mod-card-body-font-size, var(--spectrum-body-size-s));
	--spectrum-card-body-font-weight: var(--mod-card-body-font-weight, var(--spectrum-body-sans-serif-font-weight));
	--spectrum-card-body-font-style: var(--mod-card-body-font-style, var(--spectrum-body-sans-serif-font-style));
	--spectrum-card-body-line-height: var(--mod-card-body-line-height, var(--spectrum-body-line-height));
	--spectrum-card-body-font-color: var(--mod-card-body-font-color, var(--spectrum-body-color));
	--spectrum-card-actions-spacing: var(--mod-card-actions-spacing, var(--spectrum-spacing-300));
	--spectrum-card-actions-size: var(--mod-card-actions-size, var(--spectrum-card-selection-background-size));
	--spectrum-card-actions-border-radius: var(--mod-card-actions-border-radius, var(--spectrum-corner-radius-100));
	--spectrum-card-actions-background-color-rgb: var(--mod-card-actions-background-color-rgb, var(--spectrum-gray-100-rgb));
	--spectrum-card-actions-background-color-opacity: var(--mod-card-actions-background-color-opacity, var(--spectrum-card-selection-background-color-opacity));
	--spectrum-card-actions-drop-shadow-color: var(--mod-card-actions-drop-shadow-color, var(--spectrum-drop-shadow-color));
	--spectrum-card-actions-drop-shadow-x: var(--mod-card-actions-drop-shadow-x, var(--spectrum-drop-shadow-x));
	--spectrum-card-actions-drop-shadow-y: var(--mod-card-actions-drop-shadow-y, var(--spectrum-drop-shadow-y));
	--spectrum-card-actions-drop-shadow-blur: var(--mod-card-actions-drop-shadow-blur, var(--spectrum-drop-shadow-blur));
	--spectrum-card-focus-indicator-color: var(--mod-card-focus-indicator-color, var(--spectrum-focus-indicator-color));
	--spectrum-card-focus-indicator-width: var(--mod-card-focus-indicator-width, var(--spectrum-focus-indicator-thickness));
	--spectrum-card-selected-background-opacity: var(--mod-card-selected-background-opacity, 0.1);
	--spectrum-card-preview-border-width-selected: var(--mod-card-preview-border-width-selected, var(--spectrum-border-width-100));
	--spectrum-card-horizontal-body-padding: var(--mod-card-horizontal-body-padding, var(--spectrum-spacing-300));
	--spectrum-card-horizontal-preview-padding: var(--mod-card-horizontal-preview-padding, var(--spectrum-spacing-200));
}

.spectrum-Card.spectrum-Card--quiet {
	--mod-card-minimum-width: var(--mod-card-minimum-width-quiet);
	--mod-card-content-margin-top: var(--mod-card-content-margin-top-quiet, var(--spectrum-spacing-100));
}

.spectrum-Card.spectrum-Card--gallery {
	--spectrum-card-content-margin-top: var(--spectrum-spacing-100);
}

.spectrum-Card.is-drop-target, .spectrum-Card.is-selected {
	--spectrum-card-border-color: var(--mod-card-border-color-selected, var(--spectrum-blue-700));
}

.spectrum-Card {
	background-color: var(--spectrum-card-background-color);
	block-size: 100%;
	border: var(--spectrum-card-border-width) solid transparent;
	border-color: var(--mod-card-border-color, var(--spectrum-card-border-color));
	border-radius: var(--spectrum-card-corner-radius);
	box-sizing: border-box;
	display: inline-flex;
	flex-direction: column;
	min-inline-size: var(--mod-card-minimum-width, var(--spectrum-card-minimum-width));
	position: relative;
	-webkit-text-decoration: none;
	text-decoration: none;
}

.spectrum-Card:after, .spectrum-Card:before {
	block-size: 100%;
	content: "";
	inline-size: 100%;
	inset-block-start: 0;
	inset-inline-start: 0;
	position: absolute;
}

.spectrum-Card:after {
	border: 0 solid transparent;
	border-radius: var(--spectrum-card-corner-radius);
	inset-inline-end: 0;
	margin-block-start: calc(var(--spectrum-card-focus-indicator-width) * -1);
	margin-inline-start: calc(var(--spectrum-card-focus-indicator-width) * -1);
}

.spectrum-Card:focus-visible {
	outline: none;
}

.spectrum-Card:focus-visible:after {
	border-color: var(--spectrum-card-focus-indicator-color);
	border-width: var(--spectrum-card-focus-indicator-width);
}

.spectrum-Card:focus-visible .spectrum-Card-coverPhoto, .spectrum-Card:focus-visible .spectrum-Card-preview {
	border-start-end-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-focus-indicator-width));
	border-start-start-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-focus-indicator-width));
}

.spectrum-Card.is-selected:before {
	background-color: rgb(var(--mod-card-selected-background-color-rgb, var(--spectrum-card-selected-background-color-rgb)), var(--spectrum-card-selected-background-opacity));
}

.spectrum-Card.is-drop-target {
	--mod-card-background-color: var(--spectrum-background-base-color);
	box-shadow: 0 0 0 1px var(--spectrum-card-border-color);
}

.spectrum-Card.is-focused .spectrum-Card-actions, .spectrum-Card.is-focused .spectrum-Card-quickActions, .spectrum-Card.is-selected .spectrum-Card-actions, .spectrum-Card.is-selected .spectrum-Card-quickActions, .spectrum-Card:focus .spectrum-Card-actions, .spectrum-Card:focus .spectrum-Card-quickActions {
	opacity: 1;
	pointer-events: all;
	visibility: visible;
}

.spectrum-Card-quickActions {
	align-items: center;
	background-color: rgb(var(--spectrum-card-actions-background-color-rgb), var(--spectrum-card-actions-background-color-opacity));
	block-size: var(--spectrum-card-actions-size);
	border-radius: var(--spectrum-card-actions-border-radius);
	box-shadow: var(--spectrum-card-actions-drop-shadow-x) var(--spectrum-card-actions-drop-shadow-y) var(--spectrum-card-actions-drop-shadow-blur) var(--spectrum-card-actions-drop-shadow-color);
	box-sizing: border-box;
	display: inline-flex;
	inline-size: var(--spectrum-card-actions-size);
	inset-block-start: calc(var(--spectrum-card-actions-spacing) - var(--spectrum-card-border-width));
	inset-inline-start: calc(var(--spectrum-card-actions-spacing) - var(--spectrum-card-border-width));
	justify-content: center;
	pointer-events: auto;
	position: absolute;
	transition:
		transform var(--mod-overlay-animation-duration, var(--spectrum-animation-duration-100, 0.13s)) ease-in-out,
		opacity var(--mod-overlay-animation-duration, var(--spectrum-animation-duration-100, 0.13s)) ease-in-out,
		visibility 0s linear var(--mod-overlay-animation-duration, var(--spectrum-animation-duration-100, 0.13s));
	visibility: hidden;
}

.spectrum-Card-actions {
	inset-block-start: var(--spectrum-card-actions-spacing);
	inset-inline-end: var(--spectrum-card-actions-spacing);
}

.spectrum-Card-coverPhoto {
	align-items: center;
	background-color: var(--mod-card-preview-background-color, var(--spectrum-card-preview-background-color));
	background-position: 50%;
	background-size: cover;
	block-size: var(--mod-card-preview-minimum-height, var(--spectrum-card-preview-minimum-height));
	border-block-end-color: var(--mod-card-border-color, var(--spectrum-card-border-color));
	border-end-end-radius: 0;
	border-end-start-radius: 0;
	border-start-end-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-border-width));
	border-start-start-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-border-width));
	box-sizing: border-box;
	display: flex;
	justify-content: center;
	overflow: hidden;
	position: relative;
}

.spectrum-Card .spectrum-Divider {
	margin: 0;
}

.spectrum-Card-content {
	align-items: center;
	display: flex;
	margin-block-start: var(--spectrum-card-content-margin-top);
}

.spectrum-Card-body {
	padding-block-end: var(--mod-card-body-padding-block-end, calc(var(--spectrum-card-body-spacing) - var(--spectrum-card-border-width)));
	padding-block-start: var(--spectrum-card-body-padding-block-start);
	padding-inline-end: var(--mod-card-body-padding-inline-end, calc(var(--spectrum-card-body-spacing) - var(--spectrum-card-border-width)));
	padding-inline-start: var(--mod-card-body-padding-inline-start, calc(var(--spectrum-card-body-spacing) - var(--spectrum-card-border-width)));
}

.spectrum-Card-preview {
	align-items: center;
	border-end-end-radius: 0;
	border-end-start-radius: 0;
	border-start-end-radius: var(--spectrum-card-corner-radius);
	border-start-start-radius: var(--spectrum-card-corner-radius);
	color: var(--spectrum-card-body-font-color);
	display: flex;
	overflow: hidden;
}

.spectrum-Card-title {
	color: var(--spectrum-card-title-font-color);
	font-family: var(--spectrum-card-title-font-family);
	font-size: var(--spectrum-card-title-font-size);
	font-style: var(--spectrum-card-title-font-style);
	font-weight: var(--spectrum-card-title-font-weight);
	line-height: var(--spectrum-card-title-line-height);
	padding-inline-end: var(--spectrum-card-title-padding-right);
}

.spectrum-Card-subtitle {
	color: var(--spectrum-card-title-font-color);
	padding-inline-end: var(--spectrum-card-subtitle-padding-right);
	text-transform: none;
}

.spectrum-Card-subtitle + .spectrum-Card-description:before {
	content: "•";
	padding-inline-end: var(--spectrum-card-subtitle-padding-right);
}

.spectrum-Card-description {
	font-family: var(--spectrum-card-body-font-family);
	font-size: var(--spectrum-card-body-font-size);
	font-style: var(--spectrum-card-body-font-style);
	font-weight: var(--spectrum-card-body-font-weight);
}

.spectrum-Card-description, .spectrum-Card-footer {
	color: var(--spectrum-card-body-font-color);
	line-height: var(--spectrum-card-body-line-height);
}

.spectrum-Card-footer {
	border-block-start: var(--spectrum-card-border-width) solid var(--mod-card-divider-color, var(--spectrum-card-divider-color));
	margin-block-start: var(--mod-card-footer-margin-block-start, calc((var(--spectrum-card-body-spacing) - var(--spectrum-card-content-margin-bottom)) * -1));
	margin-inline-end: var(--mod-card-footer-margin-inline-end, var(--spectrum-card-body-spacing));
	margin-inline-start: var(--mod-card-footer-margin-inline-start, var(--spectrum-card-body-spacing));
	padding-block-end: var(--mod-card-footer-padding-block-end, calc(var(--spectrum-card-body-spacing) - var(--spectrum-card-border-width)));
	padding-block-start: var(--spectrum-card-footer-padding-top);
}

.spectrum-Card-header {
	align-items: center;
	display: flex;
	justify-content: space-between;
}

.spectrum-Card-actionButton {
	z-index: 1;
}

.spectrum-Card--quiet .spectrum-Card-preview {
	border: var(--spectrum-card-focus-indicator-width) solid transparent;
}

.spectrum-Card--quiet.is-focused:after, .spectrum-Card--quiet:focus:after {
	border-width: 0;
}

.spectrum-Card--quiet.is-focused .spectrum-Card-preview:after, .spectrum-Card--quiet:focus .spectrum-Card-preview:after {
	border-color: var(--spectrum-card-focus-indicator-color);
}

.spectrum-Card--quiet.is-selected .spectrum-Card-preview {
	border: var(--spectrum-card-preview-border-width-selected) solid;
	border-color: var(--spectrum-card-border-color);
}

.spectrum-Card--gallery, .spectrum-Card--quiet {
	--mod-card-border-color-hover: transparent;
	background-color: initial;
	border-color: transparent;
	border-radius: 0;
	border-width: 0;
	overflow: visible;
}

.spectrum-Card--gallery:before, .spectrum-Card--quiet:before {
	display: none;
}

.spectrum-Card--gallery .spectrum-Card-preview, .spectrum-Card--quiet .spectrum-Card-preview {
	background-color: var(--mod-card-preview-background-color, var(--mod-card-background-color, var(--spectrum-card-preview-background-color)));
	border-radius: var(--spectrum-card-corner-radius);
	box-sizing: border-box;
	flex: 1;
	inline-size: 100%;
	margin: 0 auto;
	min-block-size: var(--mod-card-preview-minimum-height, var(--spectrum-card-preview-minimum-height));
	overflow: visible;
	position: relative;
	transition: background-color var(--mod-card-animation-duration, var(--mod-animation-duration-100, var(--spectrum-animation-duration-100)));
}

.spectrum-Card--gallery .spectrum-Card-preview:before, .spectrum-Card--quiet .spectrum-Card-preview:before {
	block-size: 100%;
	content: "";
	inline-size: 100%;
	inset-block-start: 0;
	inset-inline-start: 0;
	position: absolute;
}

.spectrum-Card--gallery .spectrum-Card-preview:after, .spectrum-Card--quiet .spectrum-Card-preview:after {
	block-size: 100%;
	border: 0 solid transparent;
	border-radius: calc(var(--spectrum-card-corner-radius) + var(--spectrum-card-focus-indicator-width));
	content: "";
	inline-size: 100%;
	inset-block-start: 0;
	inset-inline-end: 0;
	inset-inline-start: 0;
	margin-block-start: calc(var(--spectrum-card-focus-indicator-width) * -1);
	margin-inline-start: calc(var(--spectrum-card-focus-indicator-width) * -1);
	position: absolute;
}

.spectrum-Card--gallery.is-drop-target, .spectrum-Card--quiet.is-drop-target {
	background-color: initial;
	border-color: transparent;
	box-shadow: none;
}

.spectrum-Card--gallery.is-drop-target .spectrum-Card-preview, .spectrum-Card--quiet.is-drop-target .spectrum-Card-preview {
	background-color: var(--mod-card-preview-background-color, var(--mod-card-background-color, var(--spectrum-card-preview-background-color)));
	transition: none;
}

.spectrum-Card--gallery.is-drop-target .spectrum-Card-preview:before, .spectrum-Card--quiet.is-drop-target .spectrum-Card-preview:before {
	border-color: var(--spectrum-card-focus-indicator-color);
	box-shadow: 0 0 0 1px var(--spectrum-card-focus-indicator-color);
}

.spectrum-Card--gallery.is-selected .spectrum-Card-preview:before, .spectrum-Card--quiet.is-selected .spectrum-Card-preview:before {
	background-color: rgb(var(--mod-card-selected-background-color-rgb, var(--spectrum-card-selected-background-color-rgb)), var(--mod-card-selected-background-opacity, var(--spectrum-card-selected-background-opacity)));
}

.spectrum-Card--gallery .spectrum-Card-body, .spectrum-Card--quiet .spectrum-Card-body {
	margin-block-start: var(--spectrum-card-content-margin-top);
	padding: 0;
}

.spectrum-Card--gallery .spectrum-Card-footer, .spectrum-Card--quiet .spectrum-Card-footer {
	margin-inline-end: 0;
	margin-inline-start: 0;
}

.spectrum-Card--horizontal {
	flex-direction: row;
}

@media (hover: hover) {
	.spectrum-Card:hover {
		--mod-card-border-color: var(--mod-card-border-color-hover, var(--spectrum-card-border-color-hover));
	}
	.spectrum-Card:hover .spectrum-Card-actions, .spectrum-Card:hover .spectrum-Card-quickActions {
		opacity: 1;
		pointer-events: all;
		visibility: visible;
	}
	.spectrum-Card--gallery:hover .spectrum-Card-preview, .spectrum-Card--quiet:hover .spectrum-Card-preview {
		background-color: var(--mod-card-preview-background-color-hover, var(--mod-card-background-color-hover, var(--spectrum-card-preview-background-color-hover)));
	}
	.spectrum-Card--horizontal:hover .spectrum-Card-preview {
		border-color: var(--mod-card-border-color-hover, var(--spectrum-card-border-color-hover));
	}
}

.spectrum-Card--horizontal .spectrum-Card-preview {
	align-items: center;
	background-color: var(--mod-card-preview-background-color, var(--spectrum-card-preview-background-color));
	border-color: var(--mod-card-border-color, var(--spectrum-card-border-color));
	border-end-end-radius: 0;
	border-end-start-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-border-width));
	border-start-end-radius: 0;
	border-start-start-radius: calc(var(--spectrum-card-corner-radius) - var(--spectrum-card-border-width));
	display: flex;
	flex-shrink: 0;
	justify-content: center;
	min-block-size: 0;
	padding: var(--spectrum-card-horizontal-preview-padding);
}

.spectrum-Card--horizontal .spectrum-Card-content, .spectrum-Card--horizontal .spectrum-Card-header {
	block-size: auto;
	margin-block-start: 0;
}

.spectrum-Card--horizontal .spectrum-Card-content {
	margin-block-end: 0;
}

.spectrum-Card--horizontal .spectrum-Card-title {
	padding-inline-end: 0;
}

.spectrum-Card--horizontal .spectrum-Card-body {
	display: flex;
	flex-direction: column;
	flex-shrink: 0;
	justify-content: center;
	padding-block: 0;
	padding-inline: var(--spectrum-card-horizontal-body-padding);
}

.spectrum-Card--gallery {
	min-inline-size: 0;
}

.spectrum-Card--gallery .spectrum-Card-preview {
	border-radius: 0;
	padding: 0;
}

:root {
  --mod-card-body-padding-block-start: 0.5em;
  --mod-card-body-padding-block-end: 0.5em;
  --mod-card-content-margin-top: 0;
  --mod-card-content-margin-bottom: 0;
  --mod-card-footer-margin-block-start: 0.5em;
  --mod-card-footer-padding-block-end: 0.5em;
  --card-grid-card-width: 25vw;
  --mod-card-background-color: var(--surface-1);
  --mod-card-border-color: var(--surface-2);
  --mod-card-divider-color: var(--surface-2);
}

.cardgrid {
  display: grid;
  grid-auto-columns: 1fr;
  grid-auto-flow: column;
  grid-template-rows: 1fr;
  place-content: space-around;
  place-items: center;
}

div.spectrum-Card {
  height: 35vh;
  max-width: var(--card-grid-card-width);
}

div.spectrum-Card-preview {
  justify-content: center;
  max-width: var(--card-grid-card-width);
  min-height: var(--mod-card-preview-minimum-height);
}

.spectrum-Asset {
  height: 100%;
  max-width: var(--card-grid-card-width);
  width: 100%;
}

img.spectrum-Asset-image {
  display: block;
  height: 100%;
  margin: 0 auto;
  max-width: var(--card-grid-card-width);
  -o-object-fit: contain;
     object-fit: contain; /* Scales image to fit while maintaining aspect ratio */
  -o-object-position: center;
     object-position: center; /* Centers the image within the container */
}

div.spectrum-Card-header.centered {
  justify-content: center;
}

dl {
  -moz-column-count: 2;
       column-count: 2;
  margin-block: 0;
}
