/* Five Engine components. Brand colours come from the Five theme; fallbacks are discount5. */

.five-grid,
.five-card,
.five-dealbox,
.five-product,
.five-section,
.five-newsletter,
.five-sister {
	--_ink: var(--five-ink, #15131A);
	--_paper: var(--five-paper, #FAF6EF);
	--_paper-2: var(--five-paper-2, #F0E9DD);
	--_line: var(--five-line, #DDD3C3);
	--_muted: var(--five-muted, #5C5650);
	--_accent: var(--five-accent, #FF4A1C);
	--_accent-ink: var(--five-accent-ink, #15131A);
	--_highlight: var(--five-highlight, #FFE45C);
	--_deep: var(--five-deep, #C8290B);
	--_soft: var(--five-soft, #FFF3C2);
	--_display: var(--five-font-display, "Bricolage Grotesque", system-ui, sans-serif);
	--_mono: var(--five-font-mono, "JetBrains Mono", ui-monospace, monospace);
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
}

/* Sections and grid */
.five-section { margin-block: 2.5rem; }
.five-section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.five-section__title { margin: 0; font-family: var(--_display); font-weight: 800; font-size: clamp(1.6rem, 3.5vw, 2.2rem); letter-spacing: -0.03em; line-height: 1.05; }
.five-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 1rem; }
.five-empty { color: var(--five-muted, #5C5650); }

/* Chips, stickers, meta */
.five-chip { display: inline-block; font-family: var(--_mono); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; padding: 0.35em 0.6em; border-radius: 6px; background: var(--_accent); color: var(--_accent-ink); text-decoration: none; line-height: 1.2; }
.five-chip--clearance { background: var(--_ink); color: var(--_highlight); }
.five-chip--coupon { background: var(--_highlight); color: var(--_ink); outline: 2px dashed var(--_ink); outline-offset: -2px; }
.five-chip--promo,
.five-chip--bogo,
.five-chip--free-shipping,
.five-chip--store { background: var(--_paper); color: var(--_ink); box-shadow: inset 0 0 0 2px var(--_ink); }
.five-chip--flash-sale { background: var(--_ink); color: var(--_paper); }
.five-chip--nations-favorit5 { background: var(--_highlight); color: var(--_ink); }
.five-sticker { font-family: var(--_display); font-weight: 800; font-size: 1.35rem; line-height: 1; padding: 0.25em 0.45em; border-radius: 8px; background: var(--_highlight); color: var(--_ink); letter-spacing: -0.02em; }
.five-sticker--l { font-size: clamp(2rem, 6vw, 3.5rem); border-radius: 14px; transform: rotate(-4deg); }
.five-meta { font-family: var(--_mono); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; color: var(--_muted); text-transform: uppercase; }
.five-countdown.is-urgent { color: var(--_deep); }
.five-ended { color: var(--_muted); }

/* Images */
.five-img { display: block; width: 100%; height: 100%; object-fit: contain; background: #fff; }
.five-img--placeholder { display: flex; align-items: center; justify-content: center; background: var(--_paper-2); color: #8A8178; }

/* Cards */
.five-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--_line); border-radius: 18px; overflow: hidden; }
.five-card__media { position: relative; display: block; aspect-ratio: 4 / 3; background: var(--_paper-2); }
.five-card__chip { position: absolute; top: 12px; left: 12px; }
.five-card__media .five-sticker { position: absolute; top: 10px; right: 12px; }
.five-card__body { display: flex; flex-direction: column; gap: 0.55rem; padding: 1rem; flex-grow: 1; }
.five-card__title { margin: 0; font-size: 1.15rem; font-weight: 600; line-height: 1.3; letter-spacing: -0.005em; }
.five-card__title a { color: inherit; text-decoration: none; }
.five-card__title a:hover { text-decoration: underline; }
.five-card__excerpt { margin: 0; color: var(--_muted); font-size: 0.95rem; }
.five-card__actions { margin-top: auto; padding-top: 0.25rem; }
.five-card.is-expired { opacity: 0.65; }

/* Prices */
.five-prices { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.6rem; }
.five-price { font-family: var(--_display); font-weight: 800; font-size: 1.8rem; line-height: 1; letter-spacing: -0.03em; }
.five-prices--l .five-price { font-size: clamp(2.6rem, 7vw, 4rem); }
.five-price-old { color: var(--_muted); font-size: 1rem; }
.five-prices--l .five-price-old { font-size: 1.4rem; }
.five-discount-text { margin: 0; font-weight: 600; }

/* Coupon code */
.five-code { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; padding: 0.35rem 0.35rem 0.35rem 0.9rem; border: 2px dashed var(--_ink); border-radius: 12px; background: var(--_paper); }
.five-code code { font-family: var(--_mono); font-weight: 700; font-size: 1.2rem; letter-spacing: 0.04em; background: none; }
.five-copy { min-height: 44px; padding: 0 1rem; border: 0; border-radius: 8px; background: var(--_ink); color: var(--_paper); font-family: var(--_mono); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer; }
.five-copy.is-copied { background: var(--_accent); color: var(--_accent-ink); }

/* Buttons and links */
.five-btn { display: flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 48px; padding: 0 1.1rem; border-radius: 12px; font-weight: 700; font-size: 1rem; text-decoration: none; text-align: center; }
.five-btn--primary { background: var(--_accent); color: var(--_accent-ink); }
.five-btn--secondary { background: transparent; color: var(--_ink); box-shadow: inset 0 0 0 2px var(--_ink); }
.five-btn:hover { filter: brightness(0.95); text-decoration: none; }
.five-btn:focus-visible,
.five-copy:focus-visible,
.five-filter:focus-visible { outline: 3px solid var(--_ink); outline-offset: 2px; }
.five-link { display: inline-flex; align-items: center; gap: 0.35rem; min-height: 44px; font-weight: 700; color: var(--_deep); text-decoration: none; }
.five-link:hover { text-decoration: underline; }

/* Filters */
.five-filters { display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.25rem; scrollbar-width: none; }
.five-filter { flex-shrink: 0; display: inline-flex; align-items: center; min-height: 44px; padding: 0 1rem; border-radius: 999px; box-shadow: inset 0 0 0 1.5px var(--_line); color: var(--_ink); font-weight: 600; font-size: 0.95rem; text-decoration: none; background: #fff; }
.five-filter.is-current { background: var(--_ink); color: var(--_paper); box-shadow: none; }

/* Disclosure, notices */
.five-disclosure { font-family: var(--_mono); font-size: 0.75rem; letter-spacing: 0.03em; color: var(--_muted); margin: 0 0 1.25rem; }
.five-dealbox .five-disclosure { margin: 0.5rem 0 0; }
.five-notice { margin: 0; padding: 0.75rem 1rem; border-radius: 12px; background: var(--_paper-2); font-weight: 600; }

/* Single deal box */
.five-dealbox { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.5rem; margin-block: 1.5rem 2rem; }
.five-dealbox__media { position: relative; aspect-ratio: 1 / 1; border-radius: 22px; overflow: hidden; background: #fff; border: 1px solid var(--_line); }
.five-dealbox__media .five-sticker { position: absolute; top: 16px; right: 16px; }
.five-dealbox__body { display: flex; flex-direction: column; gap: 1rem; justify-content: center; }
.five-dealbox__chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.five-dealbox__title { margin: 0; font-family: var(--_display); font-weight: 800; font-size: clamp(1.9rem, 4.5vw, 3rem); line-height: 1.02; letter-spacing: -0.035em; }
.five-dealbox__status .five-countdown { font-family: var(--_mono); font-weight: 700; font-size: 1rem; }
.five-dealbox__actions { display: grid; gap: 0.75rem; }
.five-dealbox.is-expired .five-dealbox__media { filter: grayscale(1); }
@media (min-width: 782px) {
	.five-dealbox { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 3rem; }
	.five-dealbox__actions { max-width: 420px; }
}

/* Product box */
.five-ranking { display: grid; gap: 1rem; margin-block: 1.5rem; }
.five-product { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; padding: 1.25rem; background: #fff; border: 1px solid var(--_line); border-radius: 20px; margin-block: 1.25rem; }
.five-ranking .five-product { margin: 0; }
.five-product.is-first { box-shadow: inset 0 0 0 2px var(--_highlight); }
.five-product__media { aspect-ratio: 4 / 3; border-radius: 14px; overflow: hidden; background: #fff; }
.five-product__body { display: flex; flex-direction: column; gap: 0.5rem; }
.five-product__label { margin: 0; font-family: var(--_mono); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--_deep); }
.five-product__title { margin: 0; font-family: var(--_display); font-weight: 800; font-size: 1.5rem; line-height: 1.1; letter-spacing: -0.02em; }
.five-product__title a { color: inherit; text-decoration: none; }
.five-product__brand { margin: 0; color: var(--_muted); font-weight: 600; }
.five-product__actions { display: grid; gap: 0.5rem; margin-top: 0.5rem; }
.five-rank { position: absolute; top: -12px; left: -8px; display: flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 50%; background: var(--_accent); color: var(--_accent-ink); font-family: var(--_display); font-weight: 800; font-size: 1.4rem; box-shadow: 0 0 0 3px var(--_paper); }
.five-product.is-first .five-rank { background: var(--_highlight); color: var(--_ink); }
.five-rating { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.4rem; margin: 0; }
.five-rating__score { font-weight: 800; font-size: 1.1rem; }
.five-rating__star { color: var(--_highlight); -webkit-text-stroke: 1px var(--_ink); }
.five-rating__count,
.five-rating__source { color: var(--_muted); font-size: 0.9rem; }
.five-rating__source { flex-basis: 100%; font-family: var(--_mono); font-size: 0.72rem; letter-spacing: 0.03em; }
.five-specs { margin: 0.25rem 0 0; padding-left: 1.1rem; color: var(--_ink); }
.five-specs li { margin: 0.15rem 0; }
@media (min-width: 700px) {
	.five-product { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 1.5rem; padding: 1.5rem; }
}

/* Compare */
.five-compare { margin-block: 1.5rem; }
.five-compare__cards { display: grid; gap: 1rem; align-items: start; }
.five-compare__cards .five-product { grid-template-columns: minmax(0, 1fr); margin: 0; }
.five-compare__vs { justify-self: center; font-family: var(--_display); font-weight: 800; font-size: 1.5rem; color: var(--_muted); }
.five-compare__table { overflow-x: auto; margin-top: 1rem; }
.five-compare__table table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.five-compare__table th,
.five-compare__table td { padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--_line); text-align: left; vertical-align: top; }
.five-compare__table thead th { font-family: var(--_display); font-weight: 800; }
@media (min-width: 782px) {
	.five-compare__cards { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); }
	.five-compare__vs { align-self: center; }
}

/* Reviewer */
.five-reviewer { margin: 1.25rem 0; padding: 1.25rem; border-radius: 18px; background: var(--five-paper-2, #F0E9DD); }
.five-reviewer__summary { margin: 0; padding: 0; border: 0; font-size: 1.05rem; }
.five-reviewer__summary p:last-child { margin-bottom: 0; }
.five-reviewer__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: 0.75rem; font-size: 0.9rem; }
.five-reviewer__name { font-weight: 700; }
.five-verdict { font-family: var(--five-font-mono, "JetBrains Mono", monospace); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; padding: 0.3em 0.55em; border-radius: 6px; }
.five-verdict--positive { background: #CFEBDD; color: #0B4A3A; }
.five-verdict--mixed { background: #FFE9A8; color: #5A4200; }
.five-verdict--negative { background: #F9D4CB; color: #8A1F0A; }

/* Newsletter */
.five-newsletter { margin-block: 2.5rem; padding: clamp(1.5rem, 4vw, 2.5rem); border-radius: 22px; background: var(--_ink); color: var(--_paper); }
.five-newsletter__title { margin: 0 0 1rem; font-family: var(--_display); font-weight: 800; font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.05; letter-spacing: -0.03em; color: var(--_paper); }
.five-newsletter__form label { display: block; margin-bottom: 0.4rem; font-family: var(--_mono); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: #C9C1B7; }
.five-newsletter__row { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.five-newsletter__row input { flex: 1 1 220px; min-height: 48px; padding: 0 0.9rem; border: 0; border-radius: 12px; font-size: 1rem; background: var(--_paper); color: var(--_ink); }
.five-newsletter__row button { min-height: 48px; padding: 0 1.4rem; border: 0; border-radius: 12px; background: var(--_highlight); color: var(--_ink); font-weight: 700; font-size: 1rem; cursor: pointer; }
.five-newsletter__note { margin: 0.75rem 0 0; font-size: 0.85rem; color: #C9C1B7; }

/* Sister site */
.five-sister { margin-block: 2rem; padding: 1.25rem 1.5rem; border-radius: 18px; background: var(--_soft); }
.five-sister__kicker { margin: 0; font-family: var(--_mono); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--_muted); }
.five-sister__title { margin: 0.35rem 0 0; font-weight: 600; font-size: 1.15rem; }
.brand-discount5 .five-sister { --_soft: #CFEBDD; }
.brand-discount5 .five-sister .five-link { color: #0E5A47; }
.brand-favorit5 .five-sister { --_soft: #FFF3C2; }
.brand-favorit5 .five-sister .five-link { color: #C8290B; }

/* Pagination */
.navigation.pagination { margin-top: 2rem; }
.navigation.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.navigation.pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 0.75rem; border-radius: 10px; box-shadow: inset 0 0 0 1.5px var(--five-line, #DDD3C3); color: inherit; text-decoration: none; font-weight: 600; }
.navigation.pagination .page-numbers.current { background: var(--five-ink, #15131A); color: var(--five-paper, #FAF6EF); box-shadow: none; }
