/* Gifts page: the hero with instant prints, budget chips and the gift finder (inc/gifts.php). */

/* ---------- Hero ---------- */
.ic-gtop { display: grid; gap: 16px; }
.ic-ghero {
	position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: center;
	gap: clamp(20px, 4vw, 56px); min-height: 440px; padding: clamp(28px, 5vw, 64px); overflow: hidden; isolation: isolate;
	border-radius: var(--ic-radius); background: radial-gradient(circle at 78% 18%, #fff6da 0, rgba(255, 246, 218, 0) 46%), linear-gradient(135deg, #fff9ec 0%, #fcecc4 100%);
}
/* Confetti on the prints' side */
.ic-ghero::before {
	content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
	background-image: radial-gradient(circle, rgba(245, 188, 65, .7) 2.2px, transparent 2.8px), radial-gradient(circle, rgba(229, 72, 77, .45) 1.8px, transparent 2.3px), radial-gradient(circle, rgba(28, 97, 231, .3) 1.8px, transparent 2.3px);
	background-size: 46px 46px, 71px 71px, 97px 97px; background-position: 0 0, 20px 31px, 41px 9px;
	-webkit-mask-image: linear-gradient(90deg, transparent 35%, #000 75%); mask-image: linear-gradient(90deg, transparent 35%, #000 75%);
}
.icam-rtl .ic-ghero::before { -webkit-mask-image: linear-gradient(270deg, transparent 35%, #000 75%); mask-image: linear-gradient(270deg, transparent 35%, #000 75%); }
/* The ribbon down the gift, and its bow */
.ic-ghero__ribbon { position: absolute; top: 0; bottom: 0; inset-inline-end: 16%; z-index: -1; width: 28px; background: linear-gradient(90deg, #b71f25 0%, #e5484d 45%, #c8262c 100%); box-shadow: 0 0 0 4px rgba(255, 255, 255, .35); }
.ic-ghero__bow { position: absolute; top: -8px; inset-inline-end: calc(16% + 14px - 60px); z-index: 0; width: 120px; height: auto; filter: drop-shadow(0 6px 8px rgba(120, 20, 20, .18)); pointer-events: none; }

.ic-ghero__body { position: relative; z-index: 1; }
.ic-ghero__eyebrow {
	display: inline-flex; align-items: center; gap: 8px; padding: 7px 15px 7px 12px; border-radius: var(--ic-radius-pill);
	background: #fff; color: var(--ic-ink); font-family: var(--ic-font-h); font-size: 13px; font-weight: 600; box-shadow: 0 2px 10px rgba(120, 80, 0, .08);
}
.ic-ghero__eyebrow .ic-gicon { width: 18px; height: 18px; color: #c8262c; }
.ic-ghero__title { margin: 18px 0 14px; color: var(--ic-ink); font-family: var(--ic-font-h); font-size: clamp(32px, 1.3rem + 2.6vw, 58px); font-weight: 700; line-height: 1.08; }
.ic-ghero__text { max-width: 46ch; margin: 0; color: #5d5a52; font-size: clamp(15px, .85rem + .3vw, 17px); line-height: 1.65; }
.ic-ghero__btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.ic-ghero__btns .ic-btn { min-height: 48px; padding-inline: 26px; border-radius: var(--ic-radius-pill); font-size: 15px; }
.ic-ghero .ic-btn.ic-btn--gold { color: var(--ic-ink); box-shadow: 0 6px 16px rgba(227, 166, 38, .35); }
.ic-ghero .ic-btn.ic-btn--gold:hover { color: var(--ic-ink); }
.ic-btn.ic-btn--line { background: transparent; color: var(--ic-ink); box-shadow: inset 0 0 0 1.5px var(--ic-ink); }
.ic-btn.ic-btn--line:hover { background: var(--ic-ink); color: #fff; }

/* Three gifts as instant prints */
.ic-ghero__prints { position: relative; z-index: 1; height: clamp(300px, 29vw, 400px); }
.ic-print {
	--r: 0deg;
	position: absolute; display: flex; flex-direction: column; width: clamp(150px, 14.5vw, 210px); padding: 10px 10px 12px;
	border-radius: 3px; background: #fff; color: var(--ic-ink); transform: rotate(var(--r));
	box-shadow: 0 16px 34px rgba(90, 60, 0, .17), 0 2px 6px rgba(0, 0, 0, .06);
	transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease;
}
.ic-print--1 { --r: -7deg; inset-inline-start: 0; top: 14%; z-index: 1; }
.ic-print--2 { --r: 3deg; inset-inline-start: 34%; top: 0; z-index: 3; }
.ic-print--3 { --r: 8deg; inset-inline-end: 0; top: 24%; z-index: 2; }
.ic-print:hover { z-index: 4; color: var(--ic-ink); transform: rotate(0deg) translateY(-6px) scale(1.03); box-shadow: 0 22px 44px rgba(90, 60, 0, .22); }
.ic-print__photo { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 2px; background: #f4efe4; }
.ic-print__photo img { display: block; width: 100%; height: 100%; padding: 9%; object-fit: contain; mix-blend-mode: multiply; }
.ic-print__name {
	display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
	margin-top: 10px; font-family: var(--ic-font-h); font-size: 13px; font-weight: 600; line-height: 1.3;
	unicode-bidi: plaintext; /* an English name on an Arabic page reads left to right and is cut at its end */
}
.icam-rtl .ic-print__name { text-align: right; }
.ic-print__price { margin-top: 3px; color: var(--ic-gold-dark); font-size: 13px; font-weight: 600; }
.ic-print__price del { color: var(--ic-muted); font-weight: 400; }
/* Four gifts: two by two, the second column a step lower, so the box grows with them */
.ic-ghero__prints--4 {
	display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: center; column-gap: clamp(14px, 2vw, 30px);
	height: auto; padding-block: 6px 26px;
}
.ic-ghero__prints--4 .ic-print { position: relative; inset: auto; width: 100%; max-width: clamp(150px, 12.5vw, 184px); }
.ic-ghero__prints--4 .ic-print:nth-child(odd) { justify-self: end; }
.ic-ghero__prints--4 .ic-print:nth-child(even) { justify-self: start; top: 26px; }
.ic-ghero__prints--4 .ic-print:nth-child(n+3) { margin-top: 20px; }
.ic-ghero__prints--4 .ic-print--1 { --r: -6deg; z-index: 1; }
.ic-ghero__prints--4 .ic-print--2 { --r: 4deg; z-index: 2; }
.ic-ghero__prints--4 .ic-print--3 { --r: 3deg; z-index: 3; }
.ic-ghero__prints--4 .ic-print--4 { --r: -5deg; z-index: 2; }
.ic-ghero__prints--4 .ic-print:hover { z-index: 4; }

/* Shop by budget */
.ic-gbudgets { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ic-gbudget {
	display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 14px; padding: 14px 18px;
	border-radius: var(--ic-radius); background: #fff; color: var(--ic-ink); box-shadow: var(--ic-shadow);
	transition: transform .25s cubic-bezier(.2, .7, .2, 1), box-shadow .25s ease;
}
.ic-gbudget__icon { grid-row: 1 / 3; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--ic-cream); color: #c8262c; }
.ic-gbudget__name { font-family: var(--ic-font-h); font-size: 15px; font-weight: 600; line-height: 1.3; }
.ic-gbudget__count { color: var(--ic-text); font-size: 13px; }
.ic-gbudget:hover { color: var(--ic-ink); transform: translateY(-3px); box-shadow: var(--ic-shadow-pop); }

/* ---------- Gift finder ---------- */
.ic-gifts {
	padding: clamp(18px, 3vw, 32px); border-radius: var(--ic-radius); background: #fff; box-shadow: var(--ic-shadow);
	scroll-margin-top: calc(var(--ic-admin) + var(--ic-bar-h) + 16px);
}
.ic-gifts__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 20px; }
.ic-gifts__head .ic-home__title { margin: 0; font-size: clamp(22px, 1rem + 1vw, 28px); }
.ic-gifts__intro { margin: 0; color: var(--ic-text); font-size: 14px; }
.ic-gifts__row { display: grid; grid-template-columns: 130px minmax(0, 1fr); align-items: center; gap: 12px; margin-bottom: 14px; }
.ic-gifts__label { margin: 0; color: var(--ic-title); font-family: var(--ic-font-h); font-size: 14px; font-weight: 600; }
.ic-gifts__people { grid-auto-columns: max-content; gap: 10px; padding: 2px 2px 4px; }
.ic-gchip {
	display: flex; flex-direction: column; align-items: center; gap: 7px; min-width: 108px; padding: 12px 12px 11px;
	border: 1.5px solid transparent; border-radius: 14px; background: var(--ic-page); color: var(--ic-title);
	font-family: var(--ic-font-h); font-size: 13px; font-weight: 600; line-height: 1.25; text-align: center;
	transition: background-color .2s, border-color .2s, transform .2s;
}
.ic-gchip__icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: #fff; color: var(--ic-ink); transition: background-color .2s; }
.ic-gchip:hover { color: var(--ic-ink); transform: translateY(-2px); }
.ic-gchip.is-on { border-color: var(--ic-gold); background: var(--ic-cream); color: var(--ic-ink); }
.ic-gchip.is-on .ic-gchip__icon { background: var(--ic-gold); }
.ic-gifts__budgets { display: flex; flex-wrap: wrap; gap: 8px; }
.ic-bchip {
	padding: 9px 16px; border: 1.5px solid var(--ic-line); border-radius: var(--ic-radius-pill); background: #fff; color: var(--ic-title);
	font-family: var(--ic-font-h); font-size: 13px; font-weight: 600; white-space: nowrap; transition: background-color .2s, color .2s, border-color .2s;
}
.ic-bchip:hover { border-color: var(--ic-ink); color: var(--ic-ink); }
.ic-bchip.is-on { border-color: var(--ic-ink); background: var(--ic-ink); color: #fff; }
.ic-bchip.is-empty:not(.is-on) { opacity: .45; }
.ic-gifts__status { margin: 20px 0 12px; color: var(--ic-text); font-size: 14px; }
.ic-gifts__grid { transition: opacity .2s ease; }
.ic-gifts.is-loading .ic-gifts__grid { opacity: .45; pointer-events: none; }
.ic-gifts__grid li.product { border: 1px solid var(--ic-line); box-shadow: none; }
.ic-gifts__grid li.product.is-new { animation: icGiftIn .5s cubic-bezier(.2, .7, .2, 1) backwards; animation-delay: calc(var(--n, 0) * 45ms); }
.ic-gifts__more { margin-top: 22px; text-align: center; }
.ic-gifts__more .ic-btn { min-width: 220px; border-radius: var(--ic-radius-pill); }

/* ---------- Motion: the prints drop in and "develop" ---------- */
@keyframes icPrintIn { from { opacity: 0; transform: translateY(-26px) rotate(calc(var(--r) - 8deg)); } }
@keyframes icDevelop { from { opacity: .15; filter: sepia(1) saturate(.4) brightness(1.5); } 55% { opacity: 1; } }
@keyframes icGiftIn { from { opacity: 0; transform: translateY(12px); } }
.ic-print { animation: icPrintIn .8s cubic-bezier(.2, .7, .2, 1) backwards; }
.ic-print--1 { animation-delay: .15s; }
.ic-print--2 { animation-delay: .3s; }
.ic-print--3 { animation-delay: .45s; }
.ic-print--4 { animation-delay: .6s; }
.ic-print__photo img { animation: icDevelop 1.8s ease-out backwards; }
.ic-print--1 .ic-print__photo img { animation-delay: .5s; }
.ic-print--2 .ic-print__photo img { animation-delay: .65s; }
.ic-print--3 .ic-print__photo img { animation-delay: .8s; }
.ic-print--4 .ic-print__photo img { animation-delay: .95s; }
@media (prefers-reduced-motion: reduce) {
	.ic-print, .ic-print__photo img, .ic-gifts__grid li.product.is-new { animation: none; }
}
.ic-still .ic-print, .ic-still .ic-print__photo img, .ic-still .ic-gifts__grid li.product.is-new { animation: none; }

/* ---------- Tablets and phones ---------- */
@media (max-width: 1024px) {
	.ic-gbudgets { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
	.ic-ghero { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-bottom: 36px; }
	.ic-ghero__prints { height: clamp(250px, 58vw, 340px); max-width: 560px; width: 100%; margin-inline: auto; }
	.ic-print { width: clamp(124px, 30vw, 190px); }
	.ic-ghero__prints--4 { height: auto; max-width: 470px; }
	.ic-ghero__prints--4 .ic-print { width: 100%; max-width: 210px; }
	/* One column: a ribbon down the box would cross the words, so only the bow stays, on the corner. */
	.ic-ghero__ribbon { display: none; }
	.ic-ghero__bow { top: -10px; inset-inline-end: 6px; width: 92px; }
	.ic-ghero::before { -webkit-mask-image: linear-gradient(180deg, transparent 30%, #000 70%); mask-image: linear-gradient(180deg, transparent 30%, #000 70%); }
}
@media (max-width: 767px) {
	.ic-ghero { padding: 26px 20px 30px; }
	.ic-ghero__title { margin-top: 14px; }
	.ic-ghero__btns { margin-top: 22px; }
	.ic-ghero__btns .ic-btn { flex: 1 1 auto; }
	.ic-gbudgets { gap: 10px; }
	.ic-gbudget { grid-template-columns: minmax(0, 1fr); row-gap: 2px; padding: 12px 14px; }
	.ic-gbudget__icon { display: none; }
	.ic-gbudget__name { font-size: 14px; }
	.ic-gifts__row { grid-template-columns: minmax(0, 1fr); gap: 8px; }
	.ic-gifts__people { margin-inline: -18px; padding-inline: 18px; scroll-padding-inline: 18px; }
	.ic-gchip { min-width: 96px; padding: 10px 8px; font-size: 12px; }
	.ic-gifts__budgets { flex-wrap: nowrap; overflow-x: auto; margin-inline: -18px; padding: 2px 18px 4px; scrollbar-width: none; }
	.ic-gifts__budgets::-webkit-scrollbar { display: none; }
	.ic-gifts__grid li.product { border: 0; box-shadow: var(--ic-shadow); }
}
