/**
 * Saaremaa Peotelgid - Custom Theme Styles
 *
 * Supplements Tailwind CSS with additional custom styles.
 */

/* ========================================
   Base & Reset
   ======================================== */

html {
	scroll-behavior: smooth;
}

/* ========================================
   Animations
   ======================================== */

@keyframes fade-in-up {
	0% {
		opacity: 0;
		transform: translateY(20px);
	}
	100% {
		opacity: 1;
		transform: translateY(0);
	}
}

.animate-fade-in-up {
	animation: fade-in-up 0.8s ease-out forwards;
}

@keyframes bounce-check {
	0%, 100% {
		transform: scale(1);
	}
	50% {
		transform: scale(1.2);
	}
}

.animate-bounce-check {
	animation: bounce-check 0.5s ease-in-out;
}

/* ========================================
   Typography
   ======================================== */

.font-display {
	font-family: 'Montserrat', sans-serif;
}

.font-sans {
	font-family: 'Open Sans', sans-serif;
}

/* ========================================
   Line Clamp
   ======================================== */

.line-clamp-2 {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ========================================
   WooCommerce Overrides
   ======================================== */

/* Hide default WooCommerce styles we don't need */
.woocommerce .products .product,
ul.products .product {
	margin: 0 !important;
	padding: 0 !important;
	width: 100% !important;
	float: none !important;
}

.woocommerce ul.products,
ul.products {
	display: grid !important;
	grid-template-columns: repeat(1, 1fr) !important;
	gap: 1.5rem !important;
	padding: 0 !important;
	margin: 0 !important;
	list-style: none !important;
}

@media (min-width: 640px) {
	.woocommerce ul.products,
	ul.products {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

@media (min-width: 980px) {
	.woocommerce ul.products,
	ul.products {
		grid-template-columns: repeat(3, 1fr) !important;
	}
}

.woocommerce ul.products::before,
.woocommerce ul.products::after,
ul.products::before,
ul.products::after {
	display: none !important;
}

/* Product card add-to-cart button */
.sp-add-to-cart-wrap a,
.sp-add-to-cart-wrap button {
	display: block !important;
	width: 100% !important;
	text-align: center !important;
	background-color: #216e4b !important;
	color: #fff !important;
	border-radius: 0.5rem !important;
	padding: 0.75rem 1.5rem !important;
	font-weight: 700 !important;
	font-size: 0.875rem !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-family: 'Montserrat', sans-serif !important;
	transition: background-color 0.2s, transform 0.15s !important;
	border: none !important;
	cursor: pointer !important;
	box-shadow: 0 1px 3px rgba(0,0,0,0.08) !important;
	text-decoration: none !important;
}

.sp-add-to-cart-wrap a:hover,
.sp-add-to-cart-wrap button:hover {
	background-color: #1c4834 !important;
	transform: translateY(-1px) !important;
}

.sp-add-to-cart-wrap a.added::after {
	display: none !important;
}

.sp-add-to-cart-wrap .added_to_cart {
	display: none !important;
}

.sp-add-to-cart-wrap a.loading {
	opacity: 0.7 !important;
	pointer-events: none !important;
}

/* Override WooCommerce add-to-cart button */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce .button {
	background-color: #216e4b !important;
	color: #fff !important;
	border-radius: 0.5rem !important;
	padding: 0.75rem 1.5rem !important;
	font-weight: 700 !important;
	font-size: 0.875rem !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-family: 'Montserrat', sans-serif !important;
	transition: background-color 0.2s !important;
	border: none !important;
	text-align: center !important;
	display: inline-block !important;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce .button:hover {
	background-color: #1c4834 !important;
}

/* WooCommerce notices */
.woocommerce-message,
.woocommerce-info {
	border-top-color: #36ad73 !important;
}

.woocommerce-message::before,
.woocommerce-info::before {
	color: #36ad73 !important;
}

/* WooCommerce product page */
.woocommerce div.product div.images {
	border-radius: 1rem;
	overflow: hidden;
}

/* Cart page styling */
.woocommerce-cart .woocommerce table.cart {
	border-radius: 1rem;
	overflow: hidden;
	border: 1px solid #e5e7eb;
}

.woocommerce-cart .woocommerce table.cart th {
	background-color: #f9fafb;
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	text-transform: uppercase;
	font-size: 0.75rem;
	letter-spacing: 0.05em;
}

/* Checkout styling */
.woocommerce-checkout #payment {
	border-radius: 1rem;
	background: #fff;
	border: 1px solid #e5e7eb;
}

/* ========================================
   Custom Logo
   ======================================== */

.custom-logo-link img {
	max-height: 60px;
	width: auto;
}

/* ========================================
   Mobile Menu
   ======================================== */

#mobile-menu.is-active {
	display: block;
}

/* ========================================
   Prose (content area)
   ======================================== */

.prose h1,
.prose h2,
.prose h3,
.prose h4 {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	color: #111827;
}

.prose a {
	color: #216e4b;
	text-decoration: underline;
}

.prose a:hover {
	color: #1c4834;
}

.prose img {
	border-radius: 1rem;
}

.prose ul {
	list-style-type: disc;
}

.prose ol {
	list-style-type: decimal;
}

/* ========================================
   Cart & Checkout Styling
   ======================================== */

/* ---- Unified font system for cart & checkout ---- */
.woocommerce-cart,
.woocommerce-checkout,
.woocommerce-cart .wc-block-cart,
.woocommerce-checkout .wc-block-checkout,
.woocommerce-cart .woocommerce,
.woocommerce-checkout .woocommerce {
	font-family: 'Open Sans', sans-serif;
	font-size: 0.95rem;
	color: #374151;
}

.woocommerce-cart h1, .woocommerce-cart h2, .woocommerce-cart h3,
.woocommerce-checkout h1, .woocommerce-checkout h2, .woocommerce-checkout h3,
.woocommerce-cart .page-title,
.woocommerce-checkout .page-title {
	font-family: 'Montserrat', sans-serif !important;
}

/* Widen cart & checkout page body */
.woocommerce-cart article,
.woocommerce-checkout article {
	max-width: none !important;
}

/* ---- Cart: single-column stacked layout ---- */
.woocommerce-cart .wp-block-woocommerce-cart {
	max-width: 100%;
	margin-left: auto;
	margin-right: auto;
}

.woocommerce-cart .wp-block-woocommerce-cart-items-block,
.woocommerce-cart .wp-block-woocommerce-cart-totals-block {
	flex: 0 0 100% !important;
	max-width: 100% !important;
}

.woocommerce-cart .wc-block-cart {
	display: flex !important;
	flex-direction: column !important;
	gap: 0 !important;
}

.woocommerce-cart .wc-block-cart .wc-block-cart__main {
	background: #fff;
	border-radius: 1rem 1rem 0 0;
	border: 1px solid #e5e7eb;
	border-bottom: none;
	padding: 2rem;
	width: 100% !important;
	flex: none !important;
}

.woocommerce-cart .wc-block-cart .wc-block-cart__sidebar {
	background: linear-gradient(135deg, #f0fdf6 0%, #edfdf4 50%, #fdfbf6 100%);
	border-radius: 0 0 1rem 1rem;
	border: 1px solid #e5e7eb;
	border-top: 2px solid #216e4b;
	padding: 1.5rem 2rem;
	width: 100% !important;
	flex: none !important;
}

/* Sidebar inner: totals + button in a row */
.woocommerce-cart .wc-block-cart__sidebar .wc-block-cart__totals-title {
	display: none !important;
}

.woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-wrapper:last-of-type {
	border-bottom: none !important;
}

.woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	font-size: 1.1rem !important;
	color: #111827 !important;
}

.woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-footer-item .wc-block-components-totals-item__value,
.wc-block-components-totals-footer-item .wc-block-components-totals-item__value,
.wc-block-components-totals-footer-item .wc-block-components-totals-item__value *,
.wc-block-components-totals-footer-item .wc-block-formatted-money-amount {
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	font-size: 1.05rem !important;
	color: #111827 !important;
}

/* Checkout main & sidebar keep normal layout */
.woocommerce-checkout .wc-block-checkout .wc-block-checkout__main {
	background: #fff;
	border-radius: 1rem;
	border: 1px solid #e5e7eb;
	padding: 1.5rem;
}

.woocommerce-checkout .wc-block-checkout .wc-block-checkout__sidebar {
	background: #fff;
	border-radius: 1rem;
	border: 1px solid #e5e7eb;
	padding: 1.5rem;
}

/* Styled page titles for WC pages */
.woocommerce-cart .wp-block-woocommerce-cart h2,
.woocommerce-checkout .wp-block-woocommerce-checkout h2,
.page-title.wc-title {
	font-family: 'Montserrat', sans-serif;
	font-weight: 800;
	font-size: 2rem;
	color: #111827;
}

/* WooCommerce block buttons */
.wc-block-components-button,
.wc-block-cart__submit-button,
.wc-block-components-checkout-place-order-button {
	background-color: #216e4b !important;
	color: #fff !important;
	border-radius: 0.75rem !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-size: 0.95rem !important;
	border: none !important;
	padding: 1rem 2rem !important;
	transition: all 0.2s ease !important;
	box-shadow: 0 2px 8px rgba(33, 110, 75, 0.25) !important;
}

.wc-block-components-button:hover,
.wc-block-cart__submit-button:hover,
.wc-block-components-checkout-place-order-button:hover {
	background-color: #1c4834 !important;
	box-shadow: 0 4px 14px rgba(33, 110, 75, 0.35) !important;
	transform: translateY(-1px) !important;
}

/* Remove link button styling */
.wc-block-components-button--link {
	background-color: transparent !important;
	color: #216e4b !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	font-size: inherit !important;
	box-shadow: none !important;
	padding: 0 !important;
}

.wc-block-components-button--link:hover {
	background-color: transparent !important;
	color: #1c4834 !important;
	box-shadow: none !important;
	transform: none !important;
}

/* Cart & checkout text inputs */
.wc-block-components-text-input input,
.wc-block-components-textarea textarea {
	border-radius: 0.5rem !important;
	border-color: #d1d5db !important;
	font-family: 'Open Sans', sans-serif !important;
}

.wc-block-components-text-input input:focus,
.wc-block-components-textarea textarea:focus {
	border-color: #36ad73 !important;
	box-shadow: 0 0 0 1px #36ad73 !important;
}

/* Order summary heading */
.wc-block-components-order-summary .wc-block-components-order-summary__button {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
}

/* Quantity selector */
.wc-block-components-quantity-selector {
	border-radius: 0.5rem !important;
	border: 1px solid #d1d5db !important;
}

/* Hide subtotal row (only show total) */
.wc-block-components-totals-subtitle,
.wc-block-components-totals-item:not(.wc-block-components-totals-footer-item) {
	display: none !important;
}

/* Totals wrapper borders */
.wc-block-components-totals-wrapper {
	border-color: #e5e7eb !important;
}

/* Remove underline from checkout/proceed button */
.wc-block-cart__submit-button,
.wc-block-cart__submit-button a,
.wc-block-components-checkout-place-order-button {
	text-decoration: none !important;
}

/* Hide coupon block */
.wc-block-components-totals-coupon,
.wc-block-components-totals-coupon__content {
	display: none !important;
}

/* Cart table header labels (Toode, Kokku) in green */
.wc-block-cart-items .wc-block-cart-items__header span,
.wc-block-cart-items .wc-block-cart-items__header th {
	color: #216e4b !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-size: 0.8rem !important;
}

/* Cart product names: green, bold, no link */
.wc-block-components-product-name,
.wc-block-cart-item__product .wc-block-components-product-name {
	font-size: 1.05rem !important;
	font-weight: 700 !important;
	font-family: 'Montserrat', sans-serif !important;
	color: #216e4b !important;
	text-decoration: none !important;
	pointer-events: none !important;
	cursor: default !important;
}

/* Cart product prices */
.wc-block-components-product-price {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	color: #111827 !important;
}

/* Cart item subtle divider */
.wc-block-cart-items .wc-block-cart-items__row {
	border-bottom: 1px solid #f3f4f6 !important;
	padding-bottom: 1.25rem !important;
	margin-bottom: 1.25rem !important;
}

.wc-block-cart-items .wc-block-cart-items__row:last-child {
	border-bottom: none !important;
	margin-bottom: 0 !important;
	padding-bottom: 0 !important;
}

/* ========================================
   Checkout Page Styling
   ======================================== */

/* Hide order notes / additional information */
.wc-block-checkout__add-note,
.wc-block-components-checkout-step--additional-information,
.wp-block-woocommerce-checkout-order-note-block {
	display: none !important;
}

/* Hide payment methods section (no online payments) */
.wc-block-checkout__payment-method,
.wc-block-components-checkout-step--payment-method,
.wp-block-woocommerce-checkout-payment-block {
	display: none !important;
}

/* Terms & conditions: remove link, plain text */
.wc-block-checkout__terms a {
	pointer-events: none !important;
	text-decoration: none !important;
	color: inherit !important;
}

/* Checkout section headings smaller */
.wc-block-components-checkout-step__heading {
	font-family: 'Montserrat', sans-serif !important;
	font-size: 0.95rem !important;
	font-weight: 700 !important;
	color: #216e4b !important;
	text-transform: uppercase !important;
	letter-spacing: 0.03em !important;
}

/* Checkout step numbers */
.wc-block-components-checkout-step__container::before {
	color: #216e4b !important;
}

/* Place order / Kinnita tellimus button */
.wc-block-components-checkout-place-order-button {
	width: 100% !important;
	padding: 1.1rem 2rem !important;
	font-size: 1rem !important;
}

/* Return to cart link */
.wc-block-components-checkout-return-to-cart-button {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 600 !important;
	font-size: 0.85rem !important;
	color: #216e4b !important;
	text-decoration: none !important;
}

.wc-block-components-checkout-return-to-cart-button:hover {
	color: #1c4834 !important;
}

/* ========================================
   Custom Checkout Form
   ======================================== */

.sp-checkout-form {
	background: #fff;
	border-radius: 1rem;
	border: 1px solid #e5e7eb;
	padding: 2rem;
	margin-bottom: 2rem;
	font-family: 'Open Sans', sans-serif;
	font-size: 0.95rem;
	color: #374151;
}

.sp-checkout-section-title {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 0.95rem;
	color: #216e4b;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin: 0 0 1.25rem 0;
	padding-bottom: 0.75rem;
	border-bottom: 2px solid #f0fdf6;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.sp-checkout-section-title:not(:first-child) {
	margin-top: 2rem;
}

.sp-checkout-section-title i {
	font-size: 1rem;
	color: #36ad73;
}

.sp-checkout-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem 1.5rem;
}

@media (max-width: 640px) {
	.sp-checkout-grid {
		grid-template-columns: 1fr;
	}
}

.sp-field {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
}

.sp-field--full {
	grid-column: 1 / -1;
}

.sp-field label {
	font-family: 'Montserrat', sans-serif;
	font-weight: 600;
	font-size: 0.85rem;
	color: #374151;
}

.sp-field label .required {
	color: #ef4444;
}

.sp-field input,
.sp-field textarea,
.sp-field select {
	border: 1px solid #d1d5db;
	border-radius: 0.5rem;
	padding: 0.7rem 0.85rem;
	font-family: 'Open Sans', sans-serif;
	font-size: 0.95rem;
	color: #1f2937;
	transition: border-color 0.2s, box-shadow 0.2s;
	background: #fff;
	width: 100%;
	box-sizing: border-box;
}

.sp-field select {
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 0.85rem center;
	padding-right: 2.5rem;
	cursor: pointer;
}

.sp-field input:focus,
.sp-field textarea:focus,
.sp-field select:focus {
	outline: none;
	border-color: #36ad73;
	box-shadow: 0 0 0 3px rgba(54, 173, 115, 0.15);
}

.sp-field input::placeholder,
.sp-field textarea::placeholder {
	color: #9ca3af;
}

.sp-field--textarea {
	margin-top: 0.5rem;
}

.sp-field textarea {
	resize: vertical;
	min-height: 80px;
}

.sp-checkout-extras {
	margin-top: 1.25rem;
}

.sp-checkbox-label {
	display: flex;
	align-items: flex-start;
	gap: 0.5rem;
	font-family: 'Open Sans', sans-serif;
	font-size: 0.9rem;
	color: #374151;
	cursor: pointer;
}

.sp-checkbox-label input[type="checkbox"] {
	width: 18px;
	height: 18px;
	accent-color: #216e4b;
	margin-top: 2px;
	flex-shrink: 0;
}

.sp-checkbox-label .required {
	color: #ef4444;
}

/* PDF download button on thank-you page */
.sp-pdf-download {
	text-align: center;
	margin: 2rem 0;
}

.sp-pdf-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	background-color: #216e4b;
	color: #fff !important;
	padding: 0.9rem 2rem;
	border-radius: 0.75rem;
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 0.9rem;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	text-decoration: none !important;
	transition: all 0.2s;
	box-shadow: 0 2px 8px rgba(33, 110, 75, 0.25);
}

.sp-pdf-btn:hover {
	background-color: #1c4834;
	box-shadow: 0 4px 14px rgba(33, 110, 75, 0.35);
	transform: translateY(-1px);
}

.sp-pdf-btn i {
	font-size: 1.1rem;
}

/* ========================================
   Classic WooCommerce Cart (shortcode)
   ======================================== */

.woocommerce table.shop_table {
	border: 1px solid #e5e7eb !important;
	border-radius: 1rem !important;
	overflow: hidden;
	border-collapse: separate !important;
}

.woocommerce table.shop_table th {
	background: transparent !important;
	color: #216e4b !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-size: 0.8rem !important;
	padding: 1rem !important;
	border: none !important;
	border-bottom: 1px solid #e5e7eb !important;
}

.woocommerce table.shop_table td {
	padding: 1rem !important;
	border-top: 1px solid #f3f4f6 !important;
	vertical-align: middle !important;
	font-family: 'Open Sans', sans-serif !important;
	font-size: 0.95rem !important;
}

.woocommerce table.shop_table .product-name a {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	font-size: 1.05rem !important;
	color: #216e4b !important;
	text-decoration: none !important;
	pointer-events: none !important;
}

.woocommerce table.shop_table .product-thumbnail img {
	border-radius: 0.5rem !important;
	width: 70px !important;
	height: 70px !important;
	object-fit: cover !important;
}

.woocommerce table.shop_table .product-price,
.woocommerce table.shop_table .product-subtotal {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	color: #111827 !important;
}

/* Cart totals */
.woocommerce .cart_totals {
	background: linear-gradient(135deg, #f0fdf6 0%, #edfdf4 50%, #fdfbf6 100%);
	border-radius: 1rem;
	border: 1px solid #e5e7eb;
	border-top: 2px solid #216e4b;
	padding: 1.5rem 2rem;
	width: 100% !important;
	float: none !important;
}

.woocommerce .cart_totals h2 {
	display: none !important;
}

/* Hide subtotal row in classic cart (only show total) */
.woocommerce .cart_totals .cart-subtotal {
	display: none !important;
}

.woocommerce .cart_totals table {
	border: none !important;
}

.woocommerce .cart_totals table th {
	background: transparent !important;
	color: #111827 !important;
	font-size: 1rem !important;
	text-transform: none !important;
}

.woocommerce .cart_totals table td {
	border: none !important;
}

.woocommerce .cart_totals .order-total td {
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	font-size: 1.15rem !important;
	color: #111827 !important;
}

.woocommerce .cart_totals .wc-proceed-to-checkout a.checkout-button {
	display: block !important;
	width: 100% !important;
	text-align: center !important;
	margin-top: 1rem !important;
	padding: 1rem 2rem !important;
	font-size: 0.95rem !important;
	border-radius: 0.75rem !important;
	box-shadow: 0 2px 8px rgba(33, 110, 75, 0.25) !important;
}

/* Quantity input in classic cart */
.woocommerce .quantity .qty {
	border: 1px solid #d1d5db !important;
	border-radius: 0.5rem !important;
	padding: 0.5rem !important;
	width: 60px !important;
	text-align: center !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 600 !important;
}

/* Remove item button */
.woocommerce table.shop_table .product-remove a {
	color: #ef4444 !important;
	font-size: 1.2rem !important;
}

/* Update cart button */
.woocommerce table.shop_table + .actions button[name="update_cart"] {
	float: right !important;
}

/* Hide coupon form in classic cart */
.woocommerce-cart .woocommerce .coupon {
	display: none !important;
}

/* ========================================
   Classic WooCommerce Checkout (shortcode)
   ======================================== */

/* Hide default billing/shipping (we use custom fields) */
.woocommerce-checkout .woocommerce-billing-fields,
.woocommerce-checkout .woocommerce-shipping-fields,
.woocommerce-checkout .woocommerce-additional-fields {
	display: none !important;
}

/* Hide payment methods list but show the Place Order button */
.woocommerce-checkout #payment .payment_methods {
	display: none !important;
}

.woocommerce-checkout #payment {
	background: transparent !important;
	border: none !important;
	border-radius: 0 !important;
	padding: 0 !important;
}

.woocommerce-checkout #payment .form-row.place-order {
	padding: 0 !important;
}

/* Hide privacy policy text and payment notice */
.woocommerce-checkout .woocommerce-privacy-policy-text,
.woocommerce-checkout .woocommerce-terms-and-conditions-wrapper,
.woocommerce-checkout .wc-block-checkout__terms,
.woocommerce-checkout .woocommerce-info {
	display: none !important;
}

/* Show our custom checkout form above order review */
.woocommerce-checkout .sp-checkout-form {
	display: block;
}

/* Payment method radio cards */
.sp-radio-card:has(input:checked) {
	border-color: #216e4b !important;
	background: #f0fdf6 !important;
}
.sp-radio-card:hover {
	border-color: #36ad73 !important;
	background: #fafffe !important;
}

/* Hide "Sinu tellimus" / "Your order" heading */
.woocommerce-checkout #order_review_heading {
	display: none !important;
}

/* Order review table - simplified */
.woocommerce-checkout .woocommerce-checkout-review-order-table {
	border: 1px solid #e5e7eb !important;
	border-radius: 1rem !important;
	overflow: hidden;
	border-collapse: collapse !important;
	margin-bottom: 1.5rem !important;
	width: 100% !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table thead th {
	background: transparent !important;
	color: #216e4b !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-size: 0.8rem !important;
	padding: 1rem 1.25rem !important;
	border: none !important;
	border-bottom: 1px solid #e5e7eb !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tbody td {
	padding: 0.9rem 1.25rem !important;
	border: none !important;
	border-bottom: 1px solid #f3f4f6 !important;
	font-family: 'Open Sans', sans-serif !important;
	font-size: 0.95rem !important;
	vertical-align: middle !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tbody .cart_item:last-child td {
	border-bottom: 1px solid #e5e7eb !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tbody .product-name {
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	color: #374151 !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tbody .product-total {
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	color: #374151 !important;
	text-align: right !important;
}

/* Hide cart-subtotal row, show only order-total */
.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .cart-subtotal {
	display: none !important;
}

/* Fee row (pikendusjuhe etc.) — match product row styling */
.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .fee th,
.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .fee td {
	padding: 0.9rem 1.25rem !important;
	border: none !important;
	border-bottom: 1px solid #f3f4f6 !important;
	background: transparent !important;
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	font-size: 0.95rem !important;
	color: #374151 !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	vertical-align: middle !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .fee td {
	text-align: right !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .order-total th,
.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .order-total td {
	padding: 1rem 1.25rem !important;
	border: none !important;
	background: #f9fafb !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .order-total th {
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	font-size: 0.9rem !important;
	color: #374151 !important;
	text-transform: uppercase !important;
}

.woocommerce-checkout .woocommerce-checkout-review-order-table tfoot .order-total td {
	font-family: 'Open Sans', sans-serif !important;
	font-weight: 400 !important;
	font-size: 1.1rem !important;
	color: #111827 !important;
	text-align: right !important;
}

/* Place order button in classic checkout */
.woocommerce-checkout #place_order {
	display: block !important;
	width: 100% !important;
	background-color: #216e4b !important;
	color: #fff !important;
	border-radius: 0.75rem !important;
	font-family: 'Montserrat', sans-serif !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	font-size: 1rem !important;
	padding: 1.1rem 2rem !important;
	border: none !important;
	cursor: pointer !important;
	transition: all 0.2s !important;
	box-shadow: 0 2px 8px rgba(33, 110, 75, 0.25) !important;
	margin-top: 1rem !important;
}

.woocommerce-checkout #place_order:hover {
	background-color: #1c4834 !important;
	box-shadow: 0 4px 14px rgba(33, 110, 75, 0.35) !important;
}

/* WooCommerce notices */
.woocommerce-checkout .woocommerce-NoticeGroup .woocommerce-error,
.woocommerce .woocommerce-error {
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-left: 4px solid #ef4444;
	border-radius: 0.5rem;
	padding: 1rem 1.25rem;
	margin-bottom: 1rem;
	list-style: none;
	font-family: 'Open Sans', sans-serif;
	font-size: 0.9rem;
	color: #991b1b;
}

/* Fix error notice icon overlap */
.woocommerce-error li,
.woocommerce-checkout .woocommerce-error li {
	padding-left: 1.5rem !important;
	position: relative;
	list-style: none !important;
}

.woocommerce-error::before,
.woocommerce-checkout .woocommerce-error::before {
	position: relative !important;
	display: inline-block !important;
	float: left !important;
	margin-right: 0.5rem !important;
	top: 0 !important;
	left: 0 !important;
}

.woocommerce-error,
.woocommerce-checkout .woocommerce-NoticeGroup .woocommerce-error {
	display: flex !important;
	flex-direction: column !important;
	gap: 0.25rem !important;
	padding-left: 2.5rem !important;
	position: relative !important;
}

.woocommerce-error::before {
	position: absolute !important;
	left: 1rem !important;
	top: 1rem !important;
	float: none !important;
	margin: 0 !important;
}

/* WooCommerce success notice */
.woocommerce-message {
	font-family: 'Open Sans', sans-serif !important;
	font-size: 0.95rem !important;
}

/* Thank-you page styling */
.woocommerce-order-received .woocommerce-thankyou-order-received {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.5rem;
	color: #216e4b;
	text-align: center;
	padding: 2rem;
	background: #f0fdf6;
	border-radius: 1rem;
	border: 1px solid #d4f9e4;
	margin-bottom: 2rem;
}

/* Thank-you page order details */
.woocommerce-order-received .woocommerce-order-details {
	background: #fff;
	border-radius: 1rem;
	border: 1px solid #e5e7eb;
	padding: 1.5rem 2rem;
}

/* Remove double border on table inside order-details wrapper */
.woocommerce-order-received .woocommerce-order-details table.shop_table {
	border: none !important;
	border-radius: 0 !important;
	border-collapse: collapse !important;
	border-spacing: 0 !important;
}

.woocommerce-order-received .woocommerce-order-details table.shop_table th {
	border-bottom: 1px solid #e5e7eb !important;
	border-top: none !important;
}

.woocommerce-order-received .woocommerce-order-details table.shop_table td {
	border-top: 1px solid #f3f4f6 !important;
	border-bottom: none !important;
}

/* ========================================
   Legal Pages (Privacy, Terms)
   ======================================== */

.page-template-default .entry-content,
.privacy-policy .entry-content,
body.page .entry-content {
	font-family: 'Open Sans', sans-serif;
	font-size: 1rem;
	line-height: 1.8;
	color: #374151;
	max-width: 800px;
	margin: 0 auto;
}

body.page .entry-content h2 {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.35rem;
	color: #216e4b;
	margin-top: 2.5rem;
	margin-bottom: 0.75rem;
	padding-bottom: 0.5rem;
	border-bottom: 2px solid #f0fdf6;
}

body.page .entry-content h2:first-child {
	margin-top: 0;
}

body.page .entry-content h3 {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.1rem;
	color: #1f2937;
	margin-top: 2rem;
	margin-bottom: 0.5rem;
}

body.page .entry-content p {
	margin-bottom: 1rem;
}

body.page .entry-content ul,
body.page .entry-content ol {
	margin-bottom: 1.25rem;
	padding-left: 1.5rem;
}

body.page .entry-content ul {
	list-style-type: disc;
}

body.page .entry-content ol {
	list-style-type: decimal;
}

body.page .entry-content li {
	margin-bottom: 0.4rem;
	padding-left: 0.25rem;
	line-height: 1.7;
}

body.page .entry-content strong {
	font-weight: 700;
	color: #1f2937;
}

body.page .entry-content em {
	color: #6b7280;
	font-size: 0.9rem;
}

body.page .entry-content a {
	color: #216e4b;
	text-decoration: underline;
}

/* ========================================
   Header Navigation Responsive
   ======================================== */

@media (min-width: 980px) and (max-width: 1100px) {
	header nav a,
	header nav .menu-item a {
		font-size: 0.7rem !important;
		letter-spacing: 0.02em !important;
	}
}

@media (min-width: 1100px) and (max-width: 1280px) {
	header nav a,
	header nav .menu-item a {
		font-size: 0.75rem !important;
	}
}

body.page .entry-content a:hover {
	color: #1c4834;
}

/* ========================================
   Category Archive: Container & Layout
   ======================================== */

/* Central container – same max-width as the front-page sections */
.sp-products-container {
	max-width: 1280px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 1rem;
	padding-right: 1rem;
}

@media (min-width: 640px) {
	.sp-products-container {
		padding-left: 1.5rem;
		padding-right: 1.5rem;
	}
}

@media (min-width: 1024px) {
	.sp-products-container {
		padding-left: 2rem;
		padding-right: 2rem;
	}
}

/* Hero section minimum height */
.sp-category-hero {
	min-height: 320px;
}

@media (min-width: 768px) {
	.sp-category-hero {
		min-height: 380px;
	}
}

/* Subcategory groups (e.g. Mööbel page) */
.sp-subcategory-group {
	margin-bottom: 2.5rem;
}

.sp-subcategory-group:last-child {
	margin-bottom: 0;
}

.sp-subcategory-title {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.35rem;
	color: #216e4b;
	padding-bottom: 0.75rem;
	margin-bottom: 1rem;
	border-bottom: 2px solid #d1fae5;
}

/* Cross-sell suggestions section */
.sp-cross-sells-divider {
	height: 2px;
	background: linear-gradient(to right, transparent, #d1fae5, transparent);
	margin-bottom: 2rem;
}

.sp-cross-sells-title {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.5rem;
	color: #216e4b;
	text-align: center;
	margin-bottom: 1.5rem;
}

.sp-cross-sells-title i {
	margin-right: 0.5rem;
	color: #36ad73;
}

/* Long description section styling */
.sp-long-description {
	font-family: 'Open Sans', sans-serif;
	font-size: 1rem;
	line-height: 1.8;
	color: #374151;
}

.sp-long-description h2 {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.35rem;
	color: #216e4b;
	margin-top: 2rem;
	margin-bottom: 0.75rem;
	padding-bottom: 0.5rem;
	border-bottom: 2px solid #f0fdf6;
}

.sp-long-description h2:first-child {
	margin-top: 0;
}

.sp-long-description h3 {
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1.1rem;
	color: #1f2937;
	margin-top: 1.5rem;
	margin-bottom: 0.5rem;
}

.sp-long-description p {
	margin-bottom: 1rem;
}

.sp-long-description ul {
	list-style-type: disc;
	padding-left: 1.5rem;
	margin-bottom: 1rem;
}

.sp-long-description li {
	margin-bottom: 0.4rem;
	line-height: 1.7;
}

.sp-long-description a {
	color: #216e4b;
	text-decoration: underline;
}

.sp-long-description a:hover {
	color: #1c4834;
}

.sp-long-description strong {
	font-weight: 700;
	color: #1f2937;
}

/* ========================================
   Cart Toast Notification
   ======================================== */

/* Hide default WooCommerce "added to cart" notice on archive pages */
.tax-product_cat .woocommerce-message,
.post-type-archive-product .woocommerce-message {
	display: none !important;
}

#sp-toast-container {
	position: fixed;
	top: 100px;
	right: 20px;
	z-index: 99999;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	pointer-events: none;
}

.sp-toast {
	pointer-events: all;
	display: flex;
	align-items: center;
	gap: 0.75rem;
	background: #fff;
	border: 1px solid #e5e7eb;
	border-left: 4px solid #216e4b;
	border-radius: 0.75rem;
	padding: 1rem 1.25rem;
	box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.05);
	max-width: 360px;
	min-width: 280px;
	font-family: 'Open Sans', sans-serif;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sp-toast-enter {
	opacity: 0;
	transform: translateX(100%) scale(0.95);
}

.sp-toast-visible {
	opacity: 1;
	transform: translateX(0) scale(1);
}

.sp-toast-exit {
	opacity: 0;
	transform: translateX(40px) scale(0.95);
}

.sp-toast-icon {
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	background: #f0fdf6;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #216e4b;
	font-size: 0.85rem;
}

.sp-toast-body {
	flex: 1;
	min-width: 0;
}

.sp-toast-msg {
	display: block;
	font-size: 0.85rem;
	color: #374151;
	line-height: 1.4;
}

.sp-toast-msg strong {
	font-weight: 700;
	color: #111827;
}

.sp-toast-link {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	font-size: 0.8rem;
	font-weight: 600;
	color: #216e4b;
	text-decoration: none;
	margin-top: 0.25rem;
}

.sp-toast-link:hover {
	color: #1c4834;
	text-decoration: underline;
}

.sp-toast-link i {
	font-size: 0.65rem;
	transition: transform 0.2s;
}

.sp-toast-link:hover i {
	transform: translateX(2px);
}

.sp-toast-close {
	flex-shrink: 0;
	background: none;
	border: none;
	color: #9ca3af;
	cursor: pointer;
	padding: 0.25rem;
	font-size: 0.85rem;
	line-height: 1;
	transition: color 0.2s;
}

.sp-toast-close:hover {
	color: #374151;
}

/* Mobile toast */
@media (max-width: 480px) {
	#sp-toast-container {
		left: 12px;
		right: 12px;
		top: 90px;
	}
	.sp-toast {
		max-width: none;
		min-width: 0;
	}
}

/* ========================================
   Product Card Slider
   ======================================== */

.sp-card-slider {
	position: relative;
	cursor: pointer;
}

.sp-card-slide {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0;
	transition: opacity 0.35s ease;
	pointer-events: none;
}

.sp-card-slide.active {
	opacity: 1;
	position: relative;
	pointer-events: auto;
}

/* Prev/Next arrows */
.sp-card-prev,
.sp-card-next {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.85);
	border: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #374151;
	font-size: 14px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
	opacity: 0.7;
	transition: opacity 0.2s, background 0.2s, transform 0.2s;
}

.sp-card-prev { left: 8px; }
.sp-card-next { right: 8px; }

.sp-card-prev:hover,
.sp-card-next:hover {
	background: #fff;
	opacity: 1;
	transform: translateY(-50%) scale(1.08);
}

/* Dots */
.sp-card-dots {
	position: absolute;
	bottom: 8px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 10;
	display: flex;
	gap: 5px;
}

.sp-card-dots span {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.5);
	cursor: pointer;
	transition: background 0.2s, transform 0.2s;
}

.sp-card-dots span.active {
	background: #fff;
	transform: scale(1.2);
	box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Lightbox
   ======================================== */

.sp-lightbox {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 99999;
	display: none;
	align-items: center;
	justify-content: center;
}

.sp-lightbox.active {
	display: flex;
}

.sp-lightbox-overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.85);
}

.sp-lightbox-content {
	position: relative;
	z-index: 1;
	max-width: 90vw;
	max-height: 90vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.sp-lightbox-img {
	max-width: 90vw;
	max-height: 80vh;
	object-fit: contain;
	border-radius: 0.5rem;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.sp-lightbox-close {
	position: fixed;
	top: 20px;
	right: 24px;
	background: none;
	border: none;
	color: #fff;
	font-size: 2.5rem;
	cursor: pointer;
	line-height: 1;
	z-index: 10;
	opacity: 0.7;
	transition: opacity 0.2s;
}

.sp-lightbox-close:hover {
	opacity: 1;
}

.sp-lightbox-prev,
.sp-lightbox-next {
	position: fixed;
	top: 50%;
	transform: translateY(-50%);
	background: rgba(255, 255, 255, 0.15);
	border: none;
	color: #fff;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	cursor: pointer;
	font-size: 20px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s;
	z-index: 10;
}

.sp-lightbox-prev { left: 20px; }
.sp-lightbox-next { right: 20px; }

.sp-lightbox-prev:hover,
.sp-lightbox-next:hover {
	background: rgba(255, 255, 255, 0.3);
}

.sp-lightbox-info {
	position: fixed;
	bottom: 20px;
	left: 50%;
	transform: translateX(-50%);
	color: #fff;
	text-align: center;
	font-family: 'Open Sans', sans-serif;
	z-index: 10;
}

.sp-lightbox-name {
	display: block;
	font-family: 'Montserrat', sans-serif;
	font-weight: 700;
	font-size: 1rem;
	margin-bottom: 4px;
}

.sp-lightbox-counter {
	font-size: 0.85rem;
	opacity: 0.7;
}

/* ========================================
   Cart Mobile: horizontal scroll for table
   ======================================== */

@media (max-width: 768px) {
	.woocommerce-cart article {
		max-width: 100% !important;
		padding-left: 0.5rem !important;
		padding-right: 0.5rem !important;
	}

	.woocommerce-cart .woocommerce {
		overflow-x: auto !important;
		-webkit-overflow-scrolling: touch !important;
	}

	.woocommerce-cart table.shop_table {
		min-width: 500px !important;
	}

	.woocommerce-cart .cart_totals {
		width: 100% !important;
		float: none !important;
		min-width: 0 !important;
	}

	.woocommerce-cart .wc-proceed-to-checkout a.checkout-button {
		width: 100% !important;
		text-align: center !important;
	}
}
