/*
 * The single product page — Sprint 3 Phase C.
 *
 * WHAT THIS FILE IS FOR. Since the shop opened, a product page was drawn by Elementor Pro's
 * template #288: a 50/50 Elementor section with Pro's own widgets. `includes/product.php` now
 * renders the same content from the child theme, and this stylesheet arranges it in the 4B
 * language the rest of the shop already speaks — the same tokens, the same card radius, the same
 * button, the same type.
 *
 * IT DEFINES NO NEW TOKENS AND NO NEW BUTTON. The wrapper carries `.irkn-land`, so the design
 * tokens on `.irkn-land` (--irkn-blue, --irkn-ink, --irkn-line, the radii and shadows) and the
 * shared `.irkn-btn` rules in `assets/landing.css` apply here exactly as they do on the landing
 * page, the search results and the catalogue.
 *
 * Non-negotiable rules, the same ones the rest of the design is held to:
 *   - no horizontal scrolling at 360, 768 or 1440
 *   - no tap target under 44px (the add-to-cart button is 48px)
 *   - the call accent #e8590c is used for the "call us" action ONLY
 *   - exactly one <h1> on the page, and it is the product's name
 */

/*
 * OceanWP's content area already supplies the page gutter, so the grey band and the vertical
 * padding the landing sections use are removed here — the same correction `assets/search.css`
 * makes for the catalogue pages, for the same reason (otherwise the content is indented twice).
 */
.irkn-prod {
	background: transparent;
	padding: 0;
	margin: 0 0 40px;
}

.irkn-prod .irkn-land__wrap {
	padding: 0;
}

/* ---------- the two columns ---------- */

.irkn-prod__grid {
	display: grid;
	grid-template-columns: minmax(0, 48%) minmax(0, 1fr);
	gap: clamp(20px, 3.5vw, 48px);
	align-items: start;
	margin-bottom: clamp(24px, 3.5vw, 44px);
}

.irkn-prod__media,
.irkn-prod__sum {
	min-width: 0;
}

/* ---------- the gallery ---------- */

.irkn-prod__media .woocommerce-product-gallery {
	background: #fff;
	border: 1px solid var(--irkn-line);
	border-radius: var(--irkn-r-lg);
	padding: clamp(10px, 1.6vw, 18px);
	box-shadow: var(--irkn-sh);
}

.irkn-prod__media .woocommerce-product-gallery__wrapper {
	margin: 0;
}

.irkn-prod__media img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: calc(var(--irkn-r-lg) - 8px);
}

/* Thumbnails, when a product has more than one picture. 44px minimum target. */
.irkn-prod__media .flex-control-thumbs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 10px 0 0;
	padding: 0;
	list-style: none;
}

.irkn-prod__media .flex-control-thumbs li {
	width: 64px;
	margin: 0;
}

.irkn-prod__media .flex-control-thumbs img {
	border: 2px solid transparent;
	border-radius: 10px;
	cursor: pointer;
}

.irkn-prod__media .flex-control-thumbs img.flex-active {
	border-color: var(--irkn-blue);
}

/* ---------- the buy column ---------- */

.irkn-prod__title {
	margin: 0 0 12px;
	/*
	 * 30px / 500 — the owner's two notes of 2026-10-20, taken together.
	 *
	 * HEIGHT: 30px is the size every other page heading in this shop uses (measured on a category
	 * page: `.irkn-arch__title` computes to **30px**, `letter-spacing: -0.6px`). The first build used
	 * 34px, which is why the product page did not feel like the rest of the site.
	 *
	 * WEIGHT: 500, not 800 — *"title is too bold"*. That is also what Elementor template #288
	 * rendered on the live product page (500). The site's category headings are 800; the owner asked
	 * for this one to be lighter, so the two differ on purpose. **Do not raise it without being asked.**
	 */
	font-size: clamp(22px, 2.4vw, 30px);
	font-weight: 500;
	line-height: 1.2;
	/* The theme sets letter-spacing: 1px and it INHERITS — the D-095 family. -.02em = -0.6px at 30px,
	   which is exactly what the category heading computes. */
	letter-spacing: -.02em;
	text-transform: none;
	color: var(--irkn-ink);
	overflow-wrap: break-word;
}

.irkn-prod__lead {
	margin: 0 0 18px;
	color: var(--irkn-ink2);
	font-size: 16px;
	line-height: 1.6;
}

.irkn-prod__lead p {
	margin: 0 0 10px;
}

.irkn-prod__lead p:last-child {
	margin-bottom: 0;
}

/* The price and the buy control together, in one card — the one thing a visitor came for. */
.irkn-prod__buy {
	background: #fff;
	border: 1px solid var(--irkn-line);
	border-radius: var(--irkn-r);
	padding: clamp(16px, 2.2vw, 24px);
	box-shadow: var(--irkn-sh);
}

/*
 * THE PRICE — the shop's own price treatment, not a bigger one.
 *
 * ⚠️ It was first built at **30px / 800 / brand blue**, and the owner's note of 2026-10-20 was
 * *"price is over-bold"*. Measured on the shop for comparison: every product card renders its price
 * at **22px, 1px letter-spacing, ink colour (#0e1626)** — blue prices appear nowhere else on the
 * site. So this is 22px, **700** (one notch lighter than the cards) and ink, which makes the price
 * read as the same kind of object as a price anywhere else in the shop.
 */
.irkn-prod__buy .price {
	margin: 0 0 16px;
	color: var(--irkn-ink);
	font-size: 22px;
	font-weight: 700;
	letter-spacing: 1px;
}

.irkn-prod__buy .price del {
	color: var(--irkn-muted);
	font-weight: 400;
	margin-right: 8px;
}

.irkn-prod__buy .price ins {
	text-decoration: none;
}

/* The add-to-cart form: quantity beside the button, wrapping on a phone rather than overflowing. */
.irkn-prod__buy form.cart {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	margin: 0;
}

.irkn-prod__buy form.cart .quantity {
	margin: 0;
}

.irkn-prod__buy form.cart .quantity .qty {
	width: 80px;
	height: 48px;
	padding: 0 10px;
	border: 1px solid var(--irkn-line);
	border-radius: 10px;
	font-size: 16px; /* 16px so a phone does not zoom the field on focus. */
	color: var(--irkn-ink);
	background: #fff;
}

.irkn-prod__buy .single_add_to_cart_button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 26px;
	border: 0;
	border-radius: 10px;
	background: var(--irkn-blue);
	color: #fff;
	font-size: 16px;
	font-weight: 700;
	line-height: 1;
	text-transform: none;
	letter-spacing: normal;
	text-decoration: none;
	cursor: pointer;
	transition: background-color .18s ease;
}

.irkn-prod__buy .single_add_to_cart_button:hover,
.irkn-prod__buy .single_add_to_cart_button:focus {
	background: var(--irkn-blue-2);
	color: #fff;
}

/* Keyboards get a visible ring; a mouse does not. */
.irkn-prod__buy .single_add_to_cart_button:focus-visible {
	outline: 3px solid #9db2ff;
	outline-offset: 2px;
}

/*
 * The owner-approved sold-out sentence (D-050). It arrives with `.irkn-soldout-notice` from
 * `functions.php`, which already styles it; only the spacing inside this card is set here.
 */
.irkn-prod__buy .irkn-soldout-notice {
	margin: 0;
}

/* ---------- the long description ---------- */

/*
 * The long description — PLAIN TEXT, back inside the right-hand column.
 *
 * ⚠️ It was first built as a full-width card BELOW both columns. **The owner asked for it back
 * where it was** (2026-10-20), and in template #288 it was a plain paragraph in this column, between
 * the short description and the price. So it keeps the class (which is what the checks look for) and
 * loses the card: no background, no border, no shadow, no extra padding.
 */
.irkn-prod__desc {
	margin: 0 0 18px;
	color: var(--irkn-ink2);
	font-size: 16px;
	line-height: 1.7;
}

.irkn-prod__desc > *:first-child {
	margin-top: 0;
}

.irkn-prod__desc > *:last-child {
	margin-bottom: 0;
}

.irkn-prod__desc p {
	margin: 0 0 12px;
}

.irkn-prod__desc ul,
.irkn-prod__desc ol {
	margin: 0 0 12px 20px;
}

/*
 * An empty description must not leave an empty white card behind — several products have only a
 * short description. `:empty` cannot be used because the block is only printed when there is
 * content, so this is a defensive rule only.
 */
.irkn-prod__desc:empty {
	display: none;
}

/* ---------- phones and tablets ---------- */

@media (max-width: 900px) {
	.irkn-prod__grid {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (max-width: 480px) {
	.irkn-prod__buy form.cart {
		gap: 10px;
	}

	.irkn-prod__buy .single_add_to_cart_button {
		flex: 1 1 auto;
	}
}

/* ---------------------------------------------------------------------------
   THE "ADDED TO CART" NOTICE — the owner's note of 2026-10-20
---------------------------------------------------------------------------

   HIS WORDS: *"The message after adding to cart also feels incorrect."* Measured on the clone
   before this section existed, the shop printed that notice in **Open Sans, 18px, `uppercase`,
   `letter-spacing: 1px`**, as a full-width bar with a dark, wide-tracked `ŽIŪRĖTI KREPŠELĮ` button —
   the theme's own styling, which is the one place on the page that does not speak 4B at all.

   ⚠️ **SCOPED TO THE PRODUCT PAGE, AND THAT IS DELIBERATE.** `body.irkn-prod-page` only exists on a
   product page, and the cart and the checkout are live, verified pages whose notices were not part of
   this work. **The same notice still appears on the cart page in the theme's old style** — if the
   owner wants it everywhere, this block is the whole change, widened to the cart and checkout after
   they have been looked at.

   The words are NOT changed here: the sentence and the button label are WooCommerce's Lithuanian
   translation, and rewording them is a copy decision, not a styling one.
*/
.irkn-prod-page .woocommerce-message,
.irkn-prod-page .woocommerce-info,
.irkn-prod-page .woocommerce-error {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 14px;
	margin: 0 0 22px;
	padding: 14px 16px;
	background: #eef2ff;
	border: 1px solid #dbe3ff;
	border-left: 4px solid #203ba6;
	border-radius: 12px;
	color: #0e1626;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.5;
	letter-spacing: normal;
	text-transform: none;
}

/* The theme absolutely-positions its tick and pads the bar to make room for it. Undo both. */
.irkn-prod-page .woocommerce-message::before,
.irkn-prod-page .woocommerce-info::before,
.irkn-prod-page .woocommerce-error::before {
	position: static;
	left: auto;
	top: auto;
	margin: 0;
	padding: 0;
	color: #203ba6;
	font-size: 15px;
	line-height: 1;
}

.irkn-prod-page .woocommerce-message .button,
.irkn-prod-page .woocommerce-info .button,
.irkn-prod-page .woocommerce-error .button {
	margin-left: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0 20px;
	background: #203ba6;
	border: 0;
	border-radius: 10px;
	color: #fff;
	font-family: inherit;
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: normal;
	text-transform: none;
	text-decoration: none;
}

.irkn-prod-page .woocommerce-message .button:hover,
.irkn-prod-page .woocommerce-message .button:focus,
.irkn-prod-page .woocommerce-info .button:hover,
.irkn-prod-page .woocommerce-info .button:focus,
.irkn-prod-page .woocommerce-error .button:hover,
.irkn-prod-page .woocommerce-error .button:focus {
	background: #3b62e8;
	color: #fff;
}

/* On a phone the button goes under the sentence rather than squeezing it. */
@media (max-width: 600px) {
	.irkn-prod-page .woocommerce-message .button,
	.irkn-prod-page .woocommerce-info .button,
	.irkn-prod-page .woocommerce-error .button {
		margin-left: 0;
		width: 100%;
	}
}
