/* ==========================================================================
   In Their Shoes — theme layer
   Only markup without a source equivalent, plus functional states.
   ========================================================================== */

/* ---------------------------------------------------------------- header */
.theme-header-nav {
	height: 5rem;
}

@media (min-width: 768px) {
	.theme-header-nav {
		height: 6rem;
	}
}

.site-header.is-large .theme-header-nav {
	height: 6rem;
}

@media (min-width: 768px) {
	.site-header.is-large .theme-header-nav {
		height: 9rem;
	}
}

.site-header .site-logo-img {
	height: calc(var(--logo-height, 64px) * 0.75);
	width: auto;
	display: block;
}

@media (min-width: 768px) {
	.site-header .site-logo-img {
		height: var(--logo-height, 64px);
	}
}

.site-header.is-large .site-logo-img {
	height: var(--logo-height, 64px);
}

@media (min-width: 768px) {
	.site-header.is-large .site-logo-img {
		height: calc(var(--logo-height, 64px) * 1.703125);
	}
}

.site-footer .site-logo-img {
	height: var(--logo-height, 64px);
	width: auto;
	display: block;
}

@media (min-width: 768px) {
	.site-footer .site-logo-img {
		height: calc(var(--logo-height, 64px) * 1.25);
	}
}

.site-logo-text {
	line-height: var(--logo-height, 64px);
	display: block;
}

.theme-nav-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.theme-nav-list a {
	display: inline-block;
	padding: 0.5rem 0.75rem;
	font-family: 'Karla', system-ui, -apple-system, sans-serif;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.5;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	text-decoration: none;
	color: hsl(var(--foreground) / 0.7);
	transition: color 0.15s ease;
}

.theme-nav-list a:hover,
.theme-nav-list a:focus-visible {
	color: hsl(var(--accent));
}

.theme-mobile-nav,
.theme-footer-nav {
	list-style: none;
	margin: 0;
	padding: 0;
}

.theme-mobile-nav a {
	display: block;
	width: 100%;
	padding: 0.75rem;
	text-align: left;
	font-family: 'Cormorant Garamond', Georgia, serif;
	font-size: 1.25rem;
	font-style: italic;
	font-weight: 500;
	line-height: 1.4;
	color: hsl(var(--foreground));
	text-decoration: none;
	transition: color 0.15s ease;
}

.theme-mobile-nav a:hover,
.theme-mobile-nav a:focus-visible {
	color: hsl(var(--accent));
}

.theme-footer-nav a {
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 0.875rem;
	line-height: 1.5;
	color: hsl(var(--primary-foreground) / 0.6);
	text-decoration: none;
	transition: color 0.15s ease;
}

.theme-footer-nav a:hover,
.theme-footer-nav a:focus-visible {
	color: hsl(var(--primary-foreground));
}

.theme-mobile-menu {
	top: 5rem;
}

@media (min-width: 768px) {
	.theme-mobile-menu {
		top: 6rem;
	}
}

.site-header.is-large + .theme-mobile-menu {
	top: 6rem;
}

@media (min-width: 768px) {
	.site-header.is-large + .theme-mobile-menu {
		top: 9rem;
	}
}

/* ----------------------------------------------------------- hero slides */
.theme-hero-slide {
	opacity: 0;
	transform: scale(1.015);
	transition: opacity 1.2s ease-in-out, transform 1.2s ease-in-out;
}

.theme-hero-slide.is-active {
	opacity: 1;
	transform: scale(1);
}

.theme-hero-bg {
	transform-origin: center center;
}

.theme-hero-content {
	will-change: transform, opacity;
}

.theme-hero-overlay {
	will-change: opacity;
}

/* --------------------------------------------------------- scroll reveals */
[data-reveal] {
	opacity: 0;
	transform: translateY(24px);
	transition: opacity 0.6s cubic-bezier(0.33, 0, 0.67, 1), transform 0.6s cubic-bezier(0.33, 0, 0.67, 1);
}

[data-reveal].is-revealed {
	opacity: 1;
	transform: none;
}

[data-reveal-delay="1"] {
	transition-delay: 0.08s;
}

[data-reveal-delay="2"] {
	transition-delay: 0.16s;
}

[data-reveal-delay="3"] {
	transition-delay: 0.24s;
}

[data-reveal-delay="4"] {
	transition-delay: 0.32s;
}

[data-reveal-delay="5"] {
	transition-delay: 0.4s;
}

body.is-customizer [data-reveal] {
	opacity: 1;
	transform: none;
}

@media (prefers-reduced-motion: reduce) {
	[data-reveal] {
		opacity: 1;
		transform: none;
		transition: none;
	}

	.theme-hero-slide {
		transform: none;
	}
}

/* ------------------------------------------------------ inside the book */
.theme-inside-image {
	opacity: 0;
	transition: opacity 0.4s ease-out;
}

.theme-inside-image.is-active {
	opacity: 1;
}

/* ------------------------------------------------------------- accordion */
.theme-accordion-content[hidden] {
	display: none;
}

.theme-accordion-trigger svg {
	transition: transform 0.2s ease;
}

.theme-accordion-trigger[data-state="open"] > svg {
	transform: rotate(90deg);
}

/* ----------------------------------------------------------- video modal */
.theme-modal-content {
	z-index: 60;
}

.theme-modal-overlay {
	z-index: 55;
}

.theme-modal-content iframe {
	display: block;
}

/* -------------------------------------------------------------- toasts */
.theme-toasts {
	position: fixed;
	right: 1rem;
	bottom: 1rem;
	z-index: 100;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	width: min(356px, calc(100vw - 2rem));
	pointer-events: none;
}

.theme-toast {
	background: hsl(var(--foreground));
	color: hsl(var(--background));
	border-radius: 0.5rem;
	padding: 1rem;
	box-shadow: 0 12px 30px hsl(var(--foreground) / 0.28);
	opacity: 0;
	transform: translateY(12px);
	transition: opacity 0.25s ease, transform 0.25s ease;
	pointer-events: auto;
}

.theme-toast.is-visible {
	opacity: 1;
	transform: none;
}

.theme-toast-title {
	margin: 0;
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.4;
}

.theme-toast-text {
	margin: 0.25rem 0 0;
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 0.8125rem;
	line-height: 1.5;
	opacity: 0.85;
}

/* ---------------------------------------------------------- cart drawer */
#theme-cart-overlay {
	position: fixed;
	inset: 0;
	z-index: 50;
	background: hsl(var(--foreground) / 0.2);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.4s cubic-bezier(0.33, 0, 0.67, 1), visibility 0.4s;
}

body.cart-open #theme-cart-overlay {
	opacity: 1;
	visibility: visible;
}

#theme-cart-drawer {
	opacity: 0;
	transform: translateY(20px);
	visibility: hidden;
	transition: opacity 0.4s cubic-bezier(0.33, 0, 0.67, 1), transform 0.4s cubic-bezier(0.33, 0, 0.67, 1), visibility 0.4s;
}

body.cart-open #theme-cart-drawer {
	opacity: 1;
	transform: none;
	visibility: visible;
}

#theme-cart-drawer.is-updating > * {
	opacity: 0.6;
	pointer-events: none;
}

.theme-cart-count:empty {
	display: none;
}

[data-cart-close] {
	cursor: pointer;
}

/* --------------------------------------------------------- product cards */
.theme-product-card {
	position: relative;
}

.theme-card-link {
	z-index: 2;
	pointer-events: auto;
}

.theme-quick-add {
	z-index: 3;
	pointer-events: auto;
}

.theme-product-card-wrap.hidden {
	display: none;
}

.theme-card-price .woocommerce-Price-amount,
.theme-product-price .woocommerce-Price-amount {
	color: inherit;
	font: inherit;
}

.theme-card-price .woocommerce-Price-currencySymbol {
	font-size: 0.75em;
	font-weight: 400;
	color: hsl(var(--foreground) / 0.55);
}

.theme-product-price del {
	opacity: 0.55;
	font-weight: 400;
	margin-right: 0.5rem;
}

.theme-product-price ins {
	text-decoration: none;
}

/* ------------------------------------------------------- product details */
.single-product .theme-product-layout,
.single-product .theme-product-gallery,
.single-product .theme-product-info {
	min-width: 0;
	max-width: 100%;
}

.single-product .theme-product-thumbnails {
	flex-wrap: wrap;
	max-width: 100%;
}

.single-product .theme-add-to-cart-area {
	display: flex;
	align-items: stretch;
	flex-wrap: wrap;
	gap: 1rem;
}

.single-product .theme-add-to-cart-area .single_add_to_cart_button {
	flex: 1 1 auto;
	min-width: 160px;
}

.single-product .woocommerce-product-details__short-description,
.single-product .woocommerce-variation-description,
.single-product .posted_in,
.theme-product-included {
	overflow-wrap: break-word;
	word-break: break-word;
}

.theme-product-thumb {
	width: 5rem;
	height: 6.25rem;
	overflow: hidden;
	border-radius: 0.5rem;
	border: 2px solid transparent;
	padding: 0;
	background: hsl(var(--muted));
	cursor: pointer;
}

.theme-product-thumb.is-active {
	border-color: hsl(var(--primary));
}

.theme-product-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

#product-main-img img {
	display: block;
	width: 100%;
}

.theme-product-included ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.theme-product-included li {
	display: flex;
	gap: 0.75rem;
	align-items: flex-start;
	line-height: inherit;
}

.theme-product-included li::before {
	content: '';
	width: 0.375rem;
	height: 0.375rem;
	border-radius: 9999px;
	background: hsl(var(--primary));
	margin-top: 0.5rem;
	flex: 0 0 auto;
}

.theme-product-included p {
	margin-bottom: 0.75rem;
}

.theme-qty-input {
	-moz-appearance: textfield;
	appearance: textfield;
	width: 3rem;
	padding-left: 0;
	padding-right: 0;
	text-align: center;
}

.theme-qty-input::-webkit-outer-spin-button,
.theme-qty-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

/* --------------------------------------------- add to cart button states */
.single_add_to_cart_button.button:disabled,
.single_add_to_cart_button.button.disabled,
.add_to_cart_button.button:disabled,
.add_to_cart_button.button.disabled {
	cursor: not-allowed !important;
	opacity: 0.4 !important;
	pointer-events: none !important;
}

.single_add_to_cart_button.button:disabled:hover,
.single_add_to_cart_button.button.disabled:hover,
.add_to_cart_button.button:disabled:hover,
.add_to_cart_button.button.disabled:hover {
	opacity: 0.4 !important;
}

.ajax_add_to_cart.theme-btn-loading {
	opacity: 0.6 !important;
	pointer-events: none !important;
	cursor: wait !important;
}

.single-product .single_add_to_cart_button.loading::after,
.ajax_add_to_cart.loading::after {
	display: none !important;
}

.woocommerce-page a.added_to_cart.wc-forward,
.single-product a.added_to_cart.wc-forward,
body a.added_to_cart.wc-forward {
	display: none !important;
}

/* ------------------------------------------------------ variations table */
.single-product .variations tbody,
.single-product .variations tbody tr,
.single-product .variations tbody td {
	display: block;
	width: 100%;
}

.single-product .variations tbody td.label {
	padding-bottom: 0.25rem;
}

.single-product .variations tbody td.value {
	padding-top: 0;
}

.single-product .variations select {
	width: 100%;
	padding: 0.75rem 1rem;
	border: 1px solid hsl(var(--border));
	border-radius: 0.375rem;
	background: hsl(var(--background));
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 1rem;
	color: hsl(var(--foreground));
}

.single-product .variations label {
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: hsl(var(--foreground) / 0.7);
}

/* -------------------------------------------------------------- notices */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce-noreviews {
	list-style: none;
	padding: 1rem 1.25rem;
	margin-bottom: 1rem;
	border: 1px solid hsl(var(--border));
	border-radius: 0.75rem;
	background: hsl(var(--card));
	color: hsl(var(--foreground));
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 0.95rem;
	line-height: 1.6;
}

.woocommerce-error {
	border-color: hsl(var(--destructive));
}

.single-product .woocommerce-message,
.single-product .woocommerce-info {
	display: none;
}

#theme-cart-drawer .woocommerce-message {
	display: none;
}

/* ------------------------------------------------------------- checkout */
body.woocommerce-checkout .site-main {
	padding-bottom: 4rem;
}

body.woocommerce-checkout .page-title {
	margin-bottom: 2rem;
}

body.woocommerce-checkout .entry-content,
body.woocommerce-cart .entry-content,
body.woocommerce-account .entry-content,
body.theme-thankyou-page .entry-content {
	max-width: 100%;
}

body.woocommerce-checkout .wc-block-checkout {
	display: block;
}

body.woocommerce-checkout .wc-block-checkout__main,
body.woocommerce-checkout .wc-block-checkout__sidebar {
	min-width: 0;
	width: 100%;
	max-width: none;
}

@media (min-width: 768px) {
	body.woocommerce-checkout .wc-block-components-sidebar-layout {
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 2rem;
		align-items: start;
	}
}

body.woocommerce-checkout .wc-block-components-sidebar-layout > * {
	min-width: 0;
}

body.woocommerce-checkout .wc-block-components-notice-banner,
body.woocommerce-checkout .wc-block-components-notices {
	grid-column: 1 / -1;
}

body.woocommerce-checkout .wc-block-checkout__sidebar {
	background-color: hsl(var(--card));
	border: 1px solid hsl(var(--border));
	border-radius: 1rem;
	padding: 2rem;
}

body.woocommerce-checkout .wc-block-components-text-input input,
body.woocommerce-checkout .wc-block-components-select select,
body.woocommerce-checkout .wc-blocks-components-select__select,
body.woocommerce-checkout .wc-block-components-textarea textarea,
body.woocommerce-checkout .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input {
	width: 100% !important;
	max-width: none !important;
	font-family: 'Karla', system-ui, -apple-system, sans-serif !important;
	font-size: 1rem !important;
	color: hsl(var(--foreground)) !important;
	background-color: hsl(var(--background)) !important;
	border: 1px solid hsl(var(--border)) !important;
	border-radius: 0.375rem !important;
}

body.woocommerce-checkout .wc-block-components-text-input input:focus,
body.woocommerce-checkout .wc-block-components-select select:focus,
body.woocommerce-checkout .wc-block-components-textarea textarea:focus {
	border-color: hsl(var(--accent)) !important;
	box-shadow: 0 0 0 2px hsl(var(--accent) / 0.2) !important;
	outline: none !important;
}

body.woocommerce-checkout .wc-block-checkout__sidebar h2,
body.woocommerce-checkout .wc-block-components-title,
body.woocommerce-checkout .wc-block-components-checkout-step__title {
	font-family: 'Cormorant Garamond', Georgia, serif;
	font-weight: 500;
	letter-spacing: -0.01em;
	color: hsl(var(--foreground));
}

body.woocommerce-checkout .wc-block-components-button,
body.woocommerce-checkout .wc-block-components-checkout-place-order-button,
body.woocommerce-cart .wc-block-components-button {
	background-color: hsl(var(--primary)) !important;
	color: hsl(var(--primary-foreground)) !important;
	border-radius: 0.5rem !important;
	font-family: 'Karla', system-ui, sans-serif !important;
	font-size: 11px !important;
	font-weight: 700 !important;
	letter-spacing: 0.18em !important;
	text-transform: uppercase !important;
}

body.woocommerce-checkout .wc-block-components-checkout-place-order-button {
	padding: 1rem 2rem !important;
}

body.woocommerce-checkout .wc-block-cart-items__row,
body.woocommerce-cart .wc-block-cart-items__row {
	border-color: hsl(var(--border));
}

/* --------------------------------------------------- cart / account pages */
body.woocommerce-cart .wc-block-cart__main,
body.woocommerce-cart .wc-block-cart__sidebar {
	min-width: 0;
}

body.woocommerce-cart .wc-block-cart__sidebar {
	background-color: hsl(var(--card));
	border: 1px solid hsl(var(--border));
	border-radius: 1rem;
	padding: 2rem;
}

/* ------------------------------------------------------------ thank you */
body.theme-thankyou-page {
	overflow-x: hidden;
}

body.theme-thankyou-page .woocommerce-order {
	font-family: 'Karla', system-ui, sans-serif;
	color: hsl(var(--foreground));
}

body.theme-thankyou-page .woocommerce-order h2,
body.theme-thankyou-page .woocommerce-order-details__title,
body.theme-thankyou-page .woocommerce-column__title {
	font-family: 'Cormorant Garamond', Georgia, serif;
	font-weight: 500;
	font-size: 1.5rem;
	padding: 0 0 1rem 0;
	color: hsl(var(--foreground));
}

body.theme-thankyou-page .woocommerce-order-overview {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	list-style: none;
	margin: 0 0 2rem;
	padding: 1.5rem;
	border: 1px solid hsl(var(--border));
	border-radius: 1rem;
	background: hsl(var(--card));
}

body.theme-thankyou-page .woocommerce-order-overview li {
	margin: 0;
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	color: hsl(var(--foreground) / 0.6);
}

body.theme-thankyou-page .woocommerce-order-overview li strong {
	display: block;
	margin-top: 0.35rem;
	font-size: 1rem;
	letter-spacing: 0;
	text-transform: none;
	color: hsl(var(--foreground));
}

body.theme-thankyou-page .woocommerce-order-details table {
	width: 100%;
	table-layout: fixed;
	border-collapse: collapse;
}

body.theme-thankyou-page .woocommerce-order-details th,
body.theme-thankyou-page .woocommerce-order-details td {
	padding: 0.75rem 0;
	border-bottom: 1px solid hsl(var(--border));
	font-size: 0.95rem;
	text-align: left;
}

body.theme-thankyou-page .woocommerce-order-details tfoot th {
	text-align: left;
}

body.theme-thankyou-page .woocommerce-order-details tfoot td {
	text-align: right;
}

body.theme-thankyou-page .woocommerce-customer-details {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

body.theme-thankyou-page .woocommerce-customer-details address {
	max-width: 480px;
	overflow-wrap: break-word;
	font-style: normal;
	line-height: 1.7;
}

body.theme-thankyou-page .woocommerce-order-downloads {
	margin-top: 2rem;
}

/* -------------------------------------------------------------- blocks */
.entry-content > *:first-child {
	margin-top: 0;
}

.theme-page-main .entry-content p {
	font-family: 'Karla', system-ui, sans-serif;
	font-size: 17px;
	line-height: 1.75;
	color: hsl(var(--foreground) / 0.8);
}

.theme-page-main .entry-content a {
	color: hsl(var(--accent));
	text-decoration: underline;
	text-underline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
	#theme-cart-drawer,
	#theme-cart-overlay,
	.theme-toast {
		transition: none;
	}
}
