/*
 * brand.css — JT Jewels brand layer
 *
 * Loads AFTER bootstrap.min.css and the template's own stylesheets. The
 * template routes almost all of its colour through the :root custom properties
 * declared in global.css, so re-pointing those few variables re-skins the whole
 * site without touching a line of the original CSS. Everything below the first
 * block patches the handful of places that hardcoded a colour.
 *
 * Palette sampled from jewel_logo.png.
 */

:root {
	/* ---- brand tokens ------------------------------------------------- */
	--brand-gold:        #C79032;
	--brand-gold-dark:   #A6761F;
	--brand-gold-light:  #E3B566;
	--brand-ink:         #121212;
	--brand-ink-soft:    #3A3A3A;
	--brand-cream:       #FDF9E9;
	--brand-cream-dark:  #F2EAD3;
	--brand-border:      #E6DCC0;

	/* ---- template variables, re-pointed ------------------------------- */
	--primary:                 var(--brand-ink);          /* was #333     */
	--secondry:                var(--brand-gold);         /* was #cc7722  */
	--bg_primary_light:        var(--brand-cream);        /* was #dfdfdf  */
	--border_light_primary:    var(--brand-border);       /* was #d3cdcd  */
	--black_transparent:       #12121299;
	--black_transparent_dark:  var(--brand-ink);          /* navbar + .button_2 */
	--black_transparent_light: #1212128c;
	--border_dark:             var(--brand-ink);

	/* ---- Bootstrap 5.3, steered off its default blue ------------------- */
	--bs-primary:             var(--brand-gold);
	--bs-primary-rgb:         199, 144, 50;
	--bs-primary-text-emphasis: var(--brand-gold-dark);
	--bs-primary-bg-subtle:   var(--brand-cream);
	--bs-primary-border-subtle: var(--brand-gold-light);
	--bs-link-color:          var(--brand-ink);
	--bs-link-color-rgb:      18, 18, 18;
	--bs-link-hover-color:    var(--brand-gold);
	--bs-link-hover-color-rgb: 199, 144, 50;
	--bs-border-color:        var(--brand-border);
	--bs-focus-ring-color:    rgba(199, 144, 50, .25);
	--bs-body-color:          #4A4A4A;
	--bs-emphasis-color:      var(--brand-ink);
}


/* ===================================================================== *
 * 1. Hardcoded colours in the template, re-pointed
 * ===================================================================== */

/* global.css painted its image overlays in a warm near-black. */
.black_transparent {
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgb(18 18 18 / 62%) 80%);
}

/* The template's soft green-grey shadow reads cold against cream. */
.shadow {
	box-shadow: 0 .35rem 1.1rem rgb(18 18 18 / 7%) !important;
}

/* shop.css used the macOS system blue for the zoom lens and active thumbnail. */
.lens,
.mySwiperThumbs .swiper-slide-thumb-active,
.mySwiperThumbs .swiper-slide:hover {
	border-color: var(--brand-gold);
}


/* ===================================================================== *
 * 2. Bootstrap components the template leaves at factory blue
 * ===================================================================== */

.btn-primary {
	--bs-btn-bg:              var(--brand-gold);
	--bs-btn-border-color:    var(--brand-gold);
	--bs-btn-hover-bg:        var(--brand-gold-dark);
	--bs-btn-hover-border-color: var(--brand-gold-dark);
	--bs-btn-active-bg:       var(--brand-gold-dark);
	--bs-btn-active-border-color: var(--brand-gold-dark);
	--bs-btn-disabled-bg:     var(--brand-gold-light);
	--bs-btn-disabled-border-color: var(--brand-gold-light);
}

.btn-outline-primary {
	--bs-btn-color:           var(--brand-gold-dark);
	--bs-btn-border-color:    var(--brand-gold);
	--bs-btn-hover-bg:        var(--brand-gold);
	--bs-btn-hover-border-color: var(--brand-gold);
	--bs-btn-active-bg:       var(--brand-gold-dark);
	--bs-btn-active-border-color: var(--brand-gold-dark);
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus {
	border-color: var(--brand-gold-light);
	box-shadow: 0 0 0 .2rem rgba(199, 144, 50, .2);
}

.form-check-input:checked {
	background-color: var(--brand-gold);
	border-color: var(--brand-gold);
}

.form-range {
	accent-color: var(--brand-gold);
}

.form-range::-webkit-slider-thumb { background: var(--brand-gold); }
.form-range::-moz-range-thumb     { background: var(--brand-gold); border: 0; }

.nav-tabs .nav-link.active,
.nav-tabs .nav-link:hover {
	color: var(--brand-gold);
	border-color: transparent transparent var(--brand-gold);
}

.btn-close:focus {
	box-shadow: 0 0 0 .2rem rgba(199, 144, 50, .25);
}


/* ===================================================================== *
 * 3. Swiper
 * ===================================================================== */

.swiper-pagination-bullet-active {
	background: var(--brand-gold);
}

.swiper-button-next,
.swiper-button-prev {
	color: var(--brand-gold);
}

.carousel-indicators [class] {
	background-color: var(--brand-cream);
}

.carousel-indicators .active {
	background-color: var(--brand-gold);
}


/* ===================================================================== *
 * 4. The logo in the navbar, footer and elsewhere
 * ===================================================================== */

.brand-lockup {
	display: inline-flex;
	align-items: center;
	gap: .6rem;
	line-height: 1;
}

.brand-logo {
	width: auto;
	height: 48px;
	display: block;
	transition: height .3s ease;
}

.brand-name {
	font-family: "Cormorant Garamond", serif;
	font-weight: 700;
	letter-spacing: .5px;
	white-space: nowrap;
}

/* The navbar shrinks once it sticks, so the mark comes down with it. */
.navbar.sticky .brand-logo {
	height: 40px;
}

.footer_2_mid .brand-logo {
	height: 72px;
	margin-inline: auto;
}

@media (max-width: 575.98px) {
	.brand-logo      { height: 38px; }
	.navbar-brand    { font-size: 1.35rem !important; }
}


/* ===================================================================== *
 * 5. Small brand-wide finishes
 * ===================================================================== */

::selection {
	background: var(--brand-gold);
	color: #fff;
}

body {
	background: #fff;
	color: var(--bs-body-color);
}

/* Gold needs a darker shade to stay legible as small text on cream. */
a.col_secondry:hover,
a.col_secondry:focus {
	color: var(--brand-gold-dark) !important;
}


/* ===================================================================== *
 * 6. Storefront cards
 * ===================================================================== */

/*
 * The template assumed every product photo was a 310x310 square. Real
 * catalogues are not that tidy — and neither is the demo artwork — so the card
 * crops to a square itself. Without this, one portrait image drags its whole
 * grid row out of alignment.
 */
.shop_1_inner_left1 > a > img,
.shop_1_inner_left1 img.image_overlay_animation {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	object-position: center;
}

/* The detail gallery keeps its own proportions but stays bounded. */
.mySwiperMain .swiper-slide img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
}

.mySwiperThumbs .swiper-slide img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
}

/* New-arrival circles crop to a circle rather than squashing. */
.categ_2_inner_left img {
	aspect-ratio: 1;
	object-fit: cover;
}

/* Saved items read as filled gold. */
.wishlist-toggle.is-saved i,
.wishlist-toggle.is-saved {
	color: var(--brand-gold) !important;
}

/* The account icon is a dropdown, but a caret beside it would crowd the row. */
.nav-icons .dropdown-toggle.no-caret::after { display: none; }


/* ===================================================================== *
 * 7. Status pills
 *
 * Shared by the admin tables and the customer's order history, so one
 * vocabulary of colour means the same thing in both places.
 * ===================================================================== */

.pill {
	display: inline-block;
	padding: 3px 10px;
	border-radius: 20px;
	font-size: .76rem;
	font-weight: 600;
	letter-spacing: .3px;
}

.pill-active    { background: #E4F1E4; color: #2F6B36; }
.pill-suspended { background: #FBE3E3; color: #9B2C2C; }
.pill-admin     { background: var(--brand-cream); color: var(--brand-gold-dark); }
.pill-customer  { background: #ECEBE7; color: #5A5648; }
.pill-muted     { background: #ECEBE7; color: #6F6A5E; }


/* ===================================================================== *
 * 8. Phones
 *
 * The template neutralises `w-50` only inside `.center_sm`, and only below
 * 767px. Several blocks that inherited it — the hero copy, the cart totals,
 * the coupon field, the newsletter pill and the 404 copy — are left at half
 * width on a phone, where half of 390px is unreadable.
 * ===================================================================== */

@media (max-width: 767.98px) {

	.center_home h1.w-50,
	.center_home p.w-50,
	.carousel-caption .w-50,
	.cart_2_left .input-group.w-50,
	.cart_2_left table.w-50,
	.footer_1 .input-group.w-50,
	.error_1 p.w-50,
	.error_1_inner.w-50,
	.error_1_inner.w-25 {
		width: 100% !important;
	}

	/* The hero caption sits over the image; give it room to breathe. */
	.carousel-caption {
		padding: 1rem;
		right: 5%;
		left: 5%;
	}

	.carousel-caption h1 { font-size: 1.75rem; }
	.carousel-caption p  { font-size: .9rem; }

	/* Buttons that sat side by side should stack rather than squeeze. */
	.carousel-caption ul,
	.error_1_inner {
		gap: .5rem;
	}

	/* The newsletter pill is round; at full width it needs its own line. */
	.footer_1 .input-group.w-50 .btn { white-space: nowrap; }

	/* The account and shop sidebars sit above their content once stacked. */
	.shop_pg1_right.ps-4,
	.blog_pg1_left.ps-4 {
		padding-left: 0 !important;
		margin-top: 2rem;
	}

	/* Product detail: the gallery should not pin itself while scrolling. */
	.gallery-container.sticky-top { position: static !important; }
}

/* Nothing should be able to push the page sideways.
 *
 * `clip` rather than `hidden`, and on one element rather than both: a `hidden`
 * axis makes the other axis `auto`, which turns <body> into a scroll container
 * and silently kills `position: sticky` inside it — the admin sidebar scrolls
 * away with the page instead of staying put. `clip` holds the page in without
 * creating that scroll container. */
html { overflow-x: clip; }
body { overflow-x: visible; }


/* ===================================================================== *
 * 9. The brand lockup against a changing navbar
 *
 * global.css turns the navbar white below 768px. The lockup is built for the
 * dark bar above that width, so cream-on-white would make the logo and the
 * store name disappear exactly where there is least room to spare. Both logo
 * variants are in the markup; only one is ever shown.
 * ===================================================================== */

.brand-logo--dark { display: none; }

.navbar .brand-name { color: #fff; }

@media (max-width: 767.98px) {
	.navbar .brand-logo--light { display: none; }
	.navbar .brand-logo--dark  { display: block; }
	.navbar .brand-name        { color: var(--brand-ink); }
}

/* The offcanvas panel is dark at every width, so it keeps the light mark. */
.offcanvas .brand-logo--light { display: block !important; }
.offcanvas .brand-logo--dark  { display: none !important; }
.offcanvas .brand-name        { color: #fff; }
