/* Jewel Shop design system — tokens and layout per Design.md. Mobile-first. */

:root {
	--color-bg: #fffaf3;
	--color-surface: #ffffff;
	--color-text: #2b2420;
	--color-text-muted: #6b6055;
	--color-accent: #a8752c;
	/* WCAG AA-safe variant of --color-accent (5.1:1 on --color-bg, 5.3:1
	   with white text) for any use as small/normal-size text or as a
	   background under white text — --color-accent itself only clears the
	   3:1 minimum, which is enough for borders/large text but not body-size
	   text or button labels. See Design.md's own contrast note. */
	--color-accent-contrast: #8f6224;
	--color-accent-deep: #6e2e2e;
	--color-border: #e8dfd1;
	--font-body: system-ui, sans-serif;
	--font-heading: "Playfair Display", Georgia, serif;
	--radius: 10px;
	--shadow-card: 0 1px 3px rgba(43, 36, 32, 0.08);
	--shadow-card-hover: 0 6px 18px rgba(43, 36, 32, 0.12);
	--container: 72rem;
}

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	font-family: var(--font-body);
	background: var(--color-bg);
	color: var(--color-text);
	line-height: 1.6;
}

h1, h2, h3, h4 {
	font-family: var(--font-heading);
	font-weight: 600;
	line-height: 1.2;
	margin: 0 0 0.5em;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.15rem; }

@media (min-width: 48rem) {
	h1 { font-size: 4rem; }
}

a {
	color: var(--color-accent-contrast);
}

img {
	max-width: 100%;
	height: auto;
	display: block;
}

.skip-link {
	position: absolute;
	left: -999px;
	top: 0;
	background: var(--color-surface);
	padding: 0.5rem 1rem;
	z-index: 100;
}

.skip-link:focus {
	left: 0;
}

/* ---- Buttons ---- */

.button {
	display: inline-flex;
	align-items: center;
	padding: 0.65rem 1.4rem;
	border-radius: 999px;
	border: 1px solid transparent;
	font-size: 0.95rem;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.cta-icon,
.fact-icon {
	width: 1.1em;
	height: 1.1em;
	flex-shrink: 0;
	margin-right: 0.45em;
}

/* The map-pin glyph's ink (ring + tail) sits lower within its box than a
   typical icon, so centering the box alone still reads as off-balance
   against the text — nudge it up to align optically. */
.icon-pin {
	transform: translateY(-0.1em);
}

.button-primary {
	background: var(--color-accent-contrast);
	color: #fff;
}

.button-primary:hover {
	background: #8f6224;
	color: #fff;
}

.button-outline {
	border-color: var(--color-accent);
	color: var(--color-accent-contrast);
	background: transparent;
}

.button-outline:hover {
	background: var(--color-accent-contrast);
	color: #fff;
}

.button-whatsapp {
	background: #1fa855;
	color: #fff;
}

.button-whatsapp:hover {
	background: #17853f;
	color: #fff;
}

.enquire-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 0.6rem;
	margin-top: 0.75rem;
}

/* ---- Header ---- */

.site-header {
	background: var(--color-surface);
	border-bottom: 1px solid var(--color-border);
	position: sticky;
	top: 0;
	z-index: 50;
}

.site-header-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 0.75rem 1.25rem;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}

.site-title,
.footer-brand {
	font-family: var(--font-heading);
	font-size: 1.4rem;
	font-weight: 700;
	color: var(--color-text);
	text-decoration: none;
}

.primary-nav {
	display: flex;
	align-items: center;
	gap: 1.25rem;
}

.primary-nav ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 1.25rem;
	align-items: center;
}

.primary-nav a {
	color: var(--color-text);
	text-decoration: none;
	font-size: 0.95rem;
}

.primary-nav a:hover,
.primary-nav .current-menu-item > a {
	color: var(--color-accent-contrast);
}

.header-actions {
	display: flex;
	align-items: center;
	gap: 1rem;
}

.header-wishlist {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #d1373f;
	text-decoration: none;
	padding: 0.25rem;
}

.header-actions .header-wishlist:hover {
	color: #d1373f;
}

.wishlist-icon {
	width: 1.75rem;
	height: 1.75rem;
}

.wishlist-count[hidden] {
	display: none;
}

.wishlist-count {
	position: absolute;
	top: -0.5em;
	right: -0.7em;
	display: inline-block;
	min-width: 1.3em;
	padding: 0 0.3em;
	border-radius: 999px;
	background: #d1373f;
	color: #fff;
	font-size: 0.7rem;
	line-height: 1.3em;
	text-align: center;
}

.header-phone {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	white-space: nowrap;
}

.header-actions .header-phone,
.header-actions .header-phone:hover {
	color: #fff;
}

.header-phone-icon {
	width: 1rem;
	height: 1rem;
	fill: #fff;
	flex-shrink: 0;
	transform-origin: 50% 50%;
	animation: phone-ring 2.5s ease-in-out infinite;
}

@keyframes phone-ring {
	0%, 100% { transform: rotate(0deg); }
	4% { transform: rotate(-15deg); }
	8% { transform: rotate(15deg); }
	12% { transform: rotate(-12deg); }
	16% { transform: rotate(12deg); }
	20% { transform: rotate(-6deg); }
	24% { transform: rotate(6deg); }
	28% { transform: rotate(0deg); }
}

@media (prefers-reduced-motion: reduce) {
	.header-phone-icon {
		animation: none;
	}
}

.nav-toggle {
	display: none;
	background: none;
	border: none;
	padding: 0.5rem;
	cursor: pointer;
}

.nav-toggle-bar {
	display: block;
	width: 22px;
	height: 2px;
	background: var(--color-text);
	margin: 5px 0;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 52rem) {
	.nav-toggle {
		display: block;
	}

	.primary-nav {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: var(--color-surface);
		border-bottom: 1px solid var(--color-border);
		padding: 1rem 1.25rem 1.25rem;
	}

	.primary-nav.is-open {
		display: block;
	}

	.primary-nav ul {
		flex-direction: column;
		align-items: flex-start;
		gap: 0.75rem;
	}

	.header-actions {
		margin: 1rem 0 0;
		flex-wrap: wrap;
	}

	.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
		transform: translateY(7px) rotate(45deg);
	}

	.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
		opacity: 0;
	}

	.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
		transform: translateY(-7px) rotate(-45deg);
	}
}

/* ---- Layout containers ---- */

.section {
	max-width: var(--container);
	margin: 0 auto;
	padding: 2.5rem 1.25rem;
}

.section-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 1.25rem;
}

.section-head h2 {
	margin: 0;
}

.section-link {
	font-size: 0.9rem;
	white-space: nowrap;
}

.content-area {
	max-width: 46rem;
	margin: 0 auto;
	padding: 2.5rem 1.25rem;
}

.content-area img {
	border-radius: var(--radius);
}

/* ---- Hero ---- */

.hero {
	position: relative;
	background: linear-gradient(160deg, #f7ecd9, var(--color-bg));
	overflow: hidden;
}

.hero-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 3.5rem 1.25rem;
	display: grid;
	gap: 2rem;
	align-items: center;
}

@media (min-width: 48rem) {
	.hero-inner {
		grid-template-columns: 1.1fr 1fr;
		padding: 5rem 1.25rem;
	}
}

.hero h1 {
	margin-bottom: 0.4em;
}

.hero-subtext {
	color: var(--color-text-muted);
	font-size: 1.1rem;
	max-width: 34rem;
	margin: 0 0 1.5rem;
}

.hero-image img {
	border-radius: var(--radius);
	box-shadow: var(--shadow-card-hover);
	width: 100%;
	object-fit: cover;
	aspect-ratio: 4 / 3;
}

/* ---- Category tiles ---- */

.category-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 1rem;
}

@media (min-width: 48rem) {
	.category-grid {
		grid-template-columns: repeat(4, 1fr);
	}
}

.category-tile {
	position: relative;
	display: block;
	border-radius: var(--radius);
	overflow: hidden;
	text-decoration: none;
	background: var(--color-surface);
	box-shadow: var(--shadow-card);
}

.category-tile img {
	aspect-ratio: 1;
	object-fit: cover;
	width: 100%;
	transition: transform 0.25s ease;
}

.category-tile:hover img {
	transform: scale(1.04);
}

.category-tile-label {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 1.5rem 0.9rem 0.7rem;
	background: linear-gradient(transparent, rgba(43, 36, 32, 0.75));
	color: #fff;
	font-weight: 600;
}

.category-tile-placeholder {
	aspect-ratio: 1;
	background: linear-gradient(145deg, #f2e6d0, #e0cba4);
}

/* ---- Product grid & cards ---- */

.product-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 1rem;
}

@media (min-width: 40rem) {
	.product-grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (min-width: 60rem) {
	.product-grid {
		grid-template-columns: repeat(4, 1fr);
		gap: 1.5rem;
	}
}

.product-card {
	position: relative;
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	overflow: hidden;
	transition: box-shadow 0.2s ease;
}

.product-card:hover {
	box-shadow: var(--shadow-card-hover);
}

.product-card > a {
	text-decoration: none;
	color: inherit;
	display: block;
}

.product-card img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
}

.product-card-image-placeholder {
	aspect-ratio: 1;
	background: linear-gradient(145deg, #f7f0e3, #eaddc4);
}

.product-card-body {
	padding: 0.75rem 0.9rem 0.9rem;
}

.product-card h3 {
	margin: 0 0 0.25rem;
	font-size: 1rem;
}

.product-card-meta {
	color: var(--color-text-muted);
	font-size: 0.85rem;
	margin: 0 0 0.5rem;
}

.product-card-enquire {
	font-size: 0.9rem;
	font-weight: 600;
	text-decoration: none;
}

.wishlist-toggle {
	position: absolute;
	top: 0.6rem;
	right: 0.6rem;
	background: rgba(255, 255, 255, 0.9);
	border: 1px solid var(--color-border);
	border-radius: 999px;
	width: 2.2rem;
	height: 2.2rem;
	font-size: 1.1rem;
	line-height: 1;
	cursor: pointer;
	color: #b5a897;
	z-index: 2;
}

.wishlist-toggle.is-active {
	color: var(--color-accent-deep);
	border-color: var(--color-accent-deep);
}

/* ---- Feed embeds (Instagram, Facebook, Reviews) ---- */

.feed-embed {
	width: 100%;
	max-width: 100%;
	overflow-x: auto;
}

/* ---- Filter bar (catalog) ---- */

.filter-bar {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0 0 1.5rem;
}

.filter-chip {
	padding: 0.35rem 1rem;
	border-radius: 999px;
	border: 1px solid var(--color-border);
	background: var(--color-surface);
	color: var(--color-text);
	text-decoration: none;
	font-size: 0.9rem;
}

.filter-chip.is-active,
.filter-chip:hover {
	background: var(--color-accent-contrast);
	border-color: var(--color-accent-contrast);
	color: #fff;
}

/* ---- Badge cards (offers / schemes / investment plans) ---- */

.badge-card-grid {
	display: grid;
	gap: 1rem;
}

@media (min-width: 48rem) {
	.badge-card-grid {
		grid-template-columns: repeat(3, 1fr);
		gap: 1.5rem;
	}
}

.badge-card {
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	padding: 1.25rem;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	transition: box-shadow 0.2s ease;
}

.badge-card:hover {
	box-shadow: var(--shadow-card-hover);
}

.badge-card h3 {
	margin: 0;
}

.badge-card h3 a {
	color: inherit;
	text-decoration: none;
}

.badge-card p {
	margin: 0;
	color: var(--color-text-muted);
	font-size: 0.95rem;
}

.badge {
	align-self: flex-start;
	background: var(--color-accent-deep);
	color: #fff;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	padding: 0.25rem 0.7rem;
	border-radius: 999px;
}

/* ---- Single design page ---- */

.single-product-layout {
	max-width: var(--container);
	margin: 0 auto;
	padding: 2.5rem 1.25rem;
	display: grid;
	gap: 2rem;
}

@media (min-width: 48rem) {
	.single-product-layout {
		grid-template-columns: 1.1fr 1fr;
		align-items: start;
	}
}

.product-gallery {
	display: flex;
	gap: 0.75rem;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	border-radius: var(--radius);
	-webkit-overflow-scrolling: touch;
}

.product-gallery figure {
	margin: 0;
	flex: 0 0 100%;
	scroll-snap-align: center;
}

.product-gallery img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	border-radius: var(--radius);
}

.product-summary .product-card-meta {
	font-size: 1rem;
}

.product-price-note {
	background: #f7ecd9;
	border-left: 3px solid var(--color-accent);
	padding: 0.75rem 1rem;
	border-radius: 0 var(--radius) var(--radius) 0;
	font-size: 0.95rem;
	margin: 1.25rem 0;
}

.product-summary .wishlist-toggle {
	position: static;
	width: auto;
	height: auto;
	padding: 0.5rem 1.1rem;
	font-size: 0.95rem;
	margin-top: 0.75rem;
}

.related-products {
	max-width: var(--container);
	margin: 0 auto;
	padding: 0 1.25rem 3rem;
}

/* ---- Single scheme/offer/plan ---- */

.plan-single {
	max-width: 46rem;
	margin: 0 auto;
	padding: 2.5rem 1.25rem;
}

.plan-facts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
	gap: 1rem;
	margin: 1.5rem 0;
}

.plan-fact {
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	padding: 0.9rem 1rem;
	min-width: 0;
}

.plan-fact-label {
	display: block;
	font-size: 0.8rem;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--color-text-muted);
}

.plan-fact-map {
	grid-column: 1 / -1;
}

.plan-fact-map .plan-fact-value {
	display: block;
	margin-top: 0.5rem;
}

.plan-fact-map iframe {
	width: 100%;
	height: 280px;
	border: 0;
	border-radius: var(--radius);
}

.plan-fact-value {
	font-weight: 600;
	font-size: 1.05rem;
	overflow-wrap: anywhere;
}

.plan-fact-phone {
	display: inline-flex;
	align-items: center;
}

.plan-terms {
	color: var(--color-text-muted);
	font-size: 0.9rem;
	border-top: 1px solid var(--color-border);
	padding-top: 1rem;
	margin-top: 2rem;
}

/* ---- Blog ---- */

.post-list article {
	border-bottom: 1px solid var(--color-border);
	padding: 1.5rem 0;
}

.post-list h2 {
	font-size: 1.4rem;
	margin-bottom: 0.25rem;
}

.post-list h2 a {
	color: inherit;
	text-decoration: none;
}

.post-list h2 a:hover {
	color: var(--color-accent-contrast);
}

.post-meta {
	color: var(--color-text-muted);
	font-size: 0.85rem;
	margin: 0 0 0.5rem;
}

/* ---- Visit band + footer ---- */

.visit-band {
	background: var(--color-surface);
	border-top: 1px solid var(--color-border);
}

.visit-band-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 2.5rem 1.25rem;
	display: grid;
	gap: 2rem;
}

@media (min-width: 48rem) {
	.visit-band-inner {
		grid-template-columns: 1fr 1fr;
		align-items: center;
	}
}

.visit-band-map iframe {
	width: 100%;
	height: 280px;
	border: 0;
	border-radius: var(--radius);
}

.visit-address,
.visit-hours {
	color: var(--color-text-muted);
}

.site-footer {
	background: var(--color-text);
	color: #e9e2d8;
}

.site-footer-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 2.5rem 1.25rem 1rem;
	display: grid;
	gap: 2rem;
}

@media (min-width: 48rem) {
	.site-footer-inner {
		grid-template-columns: repeat(3, 1fr);
	}
}

.site-footer a {
	color: #f0d9ae;
	text-decoration: none;
}

.site-footer a:hover {
	text-decoration: underline;
}

.footer-brand {
	color: #fff;
	font-size: 1.3rem;
	margin: 0 0 0.25rem;
}

.footer-tagline {
	color: #b8ad9f;
	margin: 0;
	font-size: 0.9rem;
}

.footer-nav ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 0.5rem;
}

.footer-contact p {
	margin: 0 0 0.5rem;
	font-size: 0.95rem;
}

.site-info {
	text-align: center;
	font-size: 0.8rem;
	color: #b8ad9f;
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	margin: 0;
	padding: 1rem;
}

/* ---- Floating WhatsApp button ---- */

.whatsapp-float {
	position: fixed;
	right: 1rem;
	bottom: 1rem;
	z-index: 60;
	width: 3.25rem;
	height: 3.25rem;
	border-radius: 999px;
	background: #1fa855;
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 14px rgba(31, 168, 85, 0.45);
}

.whatsapp-float:hover {
	background: #17853f;
	color: #fff;
}

/* ---- Wishlist page ---- */

.wishlist-empty {
	text-align: center;
	padding: 3rem 1rem;
	color: var(--color-text-muted);
}

/* ---- Misc ---- */

.archive-intro {
	color: var(--color-text-muted);
	max-width: 40rem;
	margin: -0.5rem 0 1.5rem;
}

.pagination,
.posts-navigation .nav-links {
	display: flex;
	gap: 0.75rem;
	justify-content: center;
	padding: 1.5rem 0 0;
	font-size: 0.95rem;
}

.pagination .page-numbers {
	padding: 0.3rem 0.8rem;
	border-radius: 999px;
	border: 1px solid var(--color-border);
	background: var(--color-surface);
	text-decoration: none;
}

.pagination .page-numbers.current {
	background: var(--color-accent-contrast);
	border-color: var(--color-accent-contrast);
	color: #fff;
}

/* ---- Engagement popup ---- */

.engagement-popup-overlay {
	position: fixed;
	inset: 0;
	z-index: 100;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
	background: rgba(43, 36, 32, 0.45);
	opacity: 0;
	transition: opacity 0.25s ease;
}

.engagement-popup-overlay[hidden] {
	display: none;
}

.engagement-popup-overlay.is-visible {
	opacity: 1;
}

.engagement-popup {
	position: relative;
	width: 100%;
	max-width: 22rem;
	background: var(--color-surface);
	border-radius: var(--radius);
	box-shadow: var(--shadow-card-hover);
	padding: 2rem 1.5rem 1.5rem;
	text-align: center;
	transform: translateY(0.5rem) scale(0.97);
	transition: transform 0.25s ease;
}

.engagement-popup-overlay.is-visible .engagement-popup {
	transform: translateY(0) scale(1);
}

.engagement-popup-close {
	position: absolute;
	top: 0.5rem;
	right: 0.5rem;
	width: 2rem;
	height: 2rem;
	border: none;
	background: transparent;
	color: var(--color-text-muted);
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
}

.engagement-popup-icon {
	font-size: 2.5rem;
	margin: 0 0 0.5rem;
}

.engagement-popup-title {
	font-family: var(--font-heading);
	margin: 0 0 0.5rem;
}

.engagement-popup-message {
	color: var(--color-text-muted);
	margin: 0 0 1.25rem;
}

.engagement-popup-cta {
	justify-content: center;
}

/* ---- WhatsApp chat bubble ---- */

.whatsapp-chat-bubble {
	position: fixed;
	right: 1rem;
	bottom: 5rem;
	z-index: 59;
	max-width: 16rem;
	background: var(--color-surface);
	border: 1px solid var(--color-border);
	border-radius: var(--radius);
	box-shadow: var(--shadow-card-hover);
	padding: 0.75rem 2rem 0.75rem 0.75rem;
	opacity: 0;
	transform: translateY(0.5rem);
	transition: opacity 0.25s ease, transform 0.25s ease;
}

.whatsapp-chat-bubble[hidden] {
	display: none;
}

.whatsapp-chat-bubble.is-visible {
	opacity: 1;
	transform: translateY(0);
}

.whatsapp-chat-bubble-close {
	position: absolute;
	top: 0.35rem;
	right: 0.5rem;
	width: 1.5rem;
	height: 1.5rem;
	border: none;
	background: transparent;
	color: var(--color-text-muted);
	font-size: 1.25rem;
	line-height: 1;
	cursor: pointer;
}

.whatsapp-chat-bubble-link {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	text-decoration: none;
	color: var(--color-text);
}

.whatsapp-chat-bubble-avatar {
	flex: 0 0 auto;
	width: 2rem;
	height: 2rem;
	border-radius: 999px;
	background: #1fa855;
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
}

.whatsapp-chat-bubble-text {
	font-size: 0.9rem;
	line-height: 1.3;
}

.whatsapp-chat-bubble-tail {
	position: absolute;
	right: 1.3rem;
	bottom: -0.4rem;
	width: 0.8rem;
	height: 0.8rem;
	background: var(--color-surface);
	border-right: 1px solid var(--color-border);
	border-bottom: 1px solid var(--color-border);
	transform: rotate(45deg);
}
