/* ================================================================
   Single Product Page — Skyline Ceramics
   ================================================================ */

/* ── Page wrapper ───────────────────────────────────────────── */
.sp-page {
	padding-block: 32px 80px;
}

/* ── Breadcrumb ─────────────────────────────────────────────── */
.sp-breadcrumb ol {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px;
	list-style: none;
	margin: 0 0 24px;
	padding: 0;
	font-size: 13px;
	color: var(--clr-text-muted, #6b7280);
}
.sp-breadcrumb a {
	color: var(--clr-navy, #0f2044);
	text-decoration: none;
}
.sp-breadcrumb a:hover { text-decoration: underline; }
.sp-breadcrumb__sep { opacity: .45; }
.sp-breadcrumb [aria-current="page"] { color: var(--clr-text-muted, #6b7280); }

/* ── Two-column layout ──────────────────────────────────────── */
.sp-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 56px;
	align-items: start;
}

/* ─── LEFT: Gallery ─────────────────────────────────────────── */
.sp-gallery {
	position: sticky;
	top: 96px;
}

/* Main image */
.sp-gallery__zoom-wrap {
	position: relative;
	overflow: hidden;
	border-radius: 16px;
	background: var(--clr-surface, #f8f6f2);
	cursor: zoom-in;
}
.sp-gallery__main-img {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	transition: transform 0.35s ease;
}
.sp-gallery__zoom-wrap:hover .sp-gallery__main-img {
	transform: scale(1.06);
}
.sp-gallery__zoom-wrap--placeholder {
	cursor: default;
}
.sp-gallery__zoom-wrap--placeholder img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
}

/* Zoom lens overlay */
.sp-gallery__zoom-lens {
	display: none;
	position: absolute;
	border-radius: 50%;
	border: 2px solid rgba(255,255,255,.7);
	background: rgba(255,255,255,.12);
	pointer-events: none;
	width: 120px;
	height: 120px;
	transform: translate(-50%, -50%);
}
.sp-gallery__zoom-wrap.is-zooming .sp-gallery__zoom-lens {
	display: block;
}

/* Sale / out-of-stock badges */
.sp-gallery__sale-badge,
.sp-gallery__stock-badge {
	position: absolute;
	top: 14px;
	left: 14px;
	padding: 4px 12px;
	border-radius: 20px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .06em;
	text-transform: uppercase;
}
.sp-gallery__sale-badge {
	background: var(--clr-amber, #f59e0b);
	color: #fff;
}
.sp-gallery__stock-badge {
	background: #ef4444;
	color: #fff;
}

/* Thumbnails */
.sp-gallery__thumbs {
	display: flex;
	gap: 8px;
	margin-top: 12px;
	overflow-x: auto;
	scrollbar-width: none;
	-ms-overflow-style: none;
	padding-bottom: 4px;
}
.sp-gallery__thumbs::-webkit-scrollbar { display: none; }

.sp-gallery__thumb {
	flex: 0 0 68px;
	width: 68px;
	height: 68px;
	border-radius: 10px;
	overflow: hidden;
	border: 2px solid transparent;
	padding: 0;
	cursor: pointer;
	background: var(--clr-surface, #f8f6f2);
	transition: border-color 0.2s;
}
.sp-gallery__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.sp-gallery__thumb.is-active,
.sp-gallery__thumb:focus-visible {
	border-color: var(--clr-amber, #f59e0b);
	outline: none;
}
.sp-gallery__thumb:hover:not(.is-active) {
	border-color: var(--clr-navy, #0f2044);
}

/* Sample link */
.sp-sample-link {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	margin-top: 16px;
	font-size: 13px;
	font-weight: 600;
	color: var(--clr-navy, #0f2044);
	text-decoration: none;
	border-bottom: 1.5px dashed var(--clr-amber, #f59e0b);
	padding-bottom: 1px;
	transition: color 0.2s;
}
.sp-sample-link:hover {
	color: var(--clr-amber, #f59e0b);
}

/* ─── RIGHT: Details ────────────────────────────────────────── */
.sp-details {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

/* Category badge */
.sp-cat-badge {
	display: inline-block;
	padding: 4px 14px;
	border-radius: 20px;
	background: var(--clr-amber, #f59e0b);
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .05em;
	text-transform: uppercase;
	text-decoration: none;
	align-self: flex-start;
	transition: background 0.2s;
}
.sp-cat-badge:hover { background: var(--clr-amber-dark, #d97706); color: #fff; }

/* Title */
.sp-title {
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: clamp(22px, 3vw, 32px);
	font-weight: 800;
	color: var(--clr-navy, #0f2044);
	line-height: 1.2;
	margin: 0;
}

/* Rating */
.sp-rating {
	display: flex;
	align-items: center;
	gap: 8px;
}
.sp-stars {
	display: flex;
	gap: 2px;
}
.sp-star {
	font-size: 18px;
	position: relative;
	color: #e5e7eb;
}
.sp-star::after {
	content: '★';
	position: absolute;
	top: 0; left: 0;
	overflow: hidden;
	width: var(--fill, 0%);
	color: var(--clr-amber, #f59e0b);
}
.sp-rating__count {
	font-size: 13px;
	color: var(--clr-text-muted, #6b7280);
}

/* Price */
.sp-price .price {
	font-size: clamp(20px, 2.5vw, 28px);
	font-weight: 800;
	color: var(--clr-navy, #0f2044);
	font-family: 'Plus Jakarta Sans', sans-serif;
}
.sp-price .price del {
	font-size: 16px;
	color: var(--clr-text-muted, #6b7280);
	font-weight: 500;
	margin-right: 6px;
}
.sp-price .price ins {
	text-decoration: none;
	color: var(--clr-amber, #f59e0b);
}

/* Short description */
.sp-short-desc {
	font-size: 15px;
	line-height: 1.7;
	color: var(--clr-text, #374151);
}
.sp-short-desc p:last-child { margin: 0; }

/* Attribute badges */
.sp-attr-badges {
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.sp-attr-badge-group {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
}
.sp-attr-badge-group__label {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--clr-text-muted, #6b7280);
	width: 80px;
	flex-shrink: 0;
}
.sp-attr-badge {
	padding: 4px 12px;
	border-radius: 20px;
	background: var(--clr-surface, #f8f6f2);
	border: 1px solid var(--clr-border, #e5e7eb);
	font-size: 12px;
	font-weight: 600;
	color: var(--clr-navy, #0f2044);
}

/* Stock status */
.sp-stock {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-size: 13px;
	font-weight: 600;
	padding: 5px 12px;
	border-radius: 20px;
}
.sp-stock--in {
	background: #ecfdf5;
	color: #059669;
}
.sp-stock--out {
	background: #fef2f2;
	color: #dc2626;
}

/* ── Form & Quantity ────────────────────────────────────────── */
.sp-form { display: contents; }

/* Hide the WooCommerce default quantity field we rendered just for cart compat */
.sp-form .quantity { display: none !important; }

.sp-qty-wrap {
	display: flex;
	align-items: center;
	gap: 12px;
}
.sp-qty-label {
	font-size: 13px;
	font-weight: 600;
	color: var(--clr-navy, #0f2044);
	flex-shrink: 0;
}
.sp-qty {
	display: flex;
	align-items: center;
	border: 2px solid var(--clr-navy, #0f2044);
	border-radius: 10px;
	overflow: hidden;
}
.sp-qty__btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: none;
	border: none;
	cursor: pointer;
	color: var(--clr-navy, #0f2044);
	transition: background 0.15s;
}
.sp-qty__btn:hover { background: var(--clr-navy, #0f2044); color: #fff; }
.sp-qty__input {
	width: 52px;
	height: 40px;
	border: none;
	border-left: 1px solid #e5e7eb;
	border-right: 1px solid #e5e7eb;
	text-align: center;
	font-size: 15px;
	font-weight: 700;
	color: var(--clr-navy, #0f2044);
	font-family: inherit;
	-moz-appearance: textfield;
}
.sp-qty__input::-webkit-outer-spin-button,
.sp-qty__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.sp-qty__input:focus { outline: none; background: #f8f9ff; }

/* ── Action buttons ─────────────────────────────────────────── */
.sp-actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.sp-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	width: 100%;
	padding: 14px 24px;
	border-radius: 10px;
	font-size: 15px;
	font-weight: 700;
	font-family: 'Plus Jakarta Sans', sans-serif;
	cursor: pointer;
	text-decoration: none;
	transition: background 0.2s, color 0.2s, transform 0.15s;
	border: 2px solid transparent;
}
.sp-btn:active { transform: scale(.98); }

/* Add to Cart */
.sp-btn--cart {
	background: var(--clr-navy, #0f2044);
	color: #fff;
	border-color: var(--clr-navy, #0f2044);
}
.sp-btn--cart:hover {
	background: var(--clr-amber, #f59e0b);
	border-color: var(--clr-amber, #f59e0b);
	color: #fff;
}

/* WhatsApp */
.sp-btn--wa {
	background: #25d366;
	border-color: #25d366;
	color: #fff;
}
.sp-btn--wa:hover {
	background: #1ebe5d;
	border-color: #1ebe5d;
	color: #fff;
}

/* Quote */
.sp-btn--quote {
	background: transparent;
	border-color: var(--clr-navy, #0f2044);
	color: var(--clr-navy, #0f2044);
}
.sp-btn--quote:hover {
	background: var(--clr-navy, #0f2044);
	color: #fff;
}

/* ── Trust badges ───────────────────────────────────────────── */
.sp-trust {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 20px;
	padding-top: 4px;
	border-top: 1px solid var(--clr-border, #e5e7eb);
}
.sp-trust__item {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 600;
	color: var(--clr-text-muted, #6b7280);
}
.sp-trust__item svg { color: var(--clr-amber, #f59e0b); flex-shrink: 0; }

/* ── Tabs section ───────────────────────────────────────────── */
.sp-tabs-section {
	margin-top: 64px;
}

.sp-tabs {
	display: flex;
	gap: 0;
	border-bottom: 2px solid var(--clr-border, #e5e7eb);
	overflow-x: auto;
	scrollbar-width: none;
}
.sp-tabs::-webkit-scrollbar { display: none; }

.sp-tab {
	padding: 12px 24px;
	background: none;
	border: none;
	border-bottom: 2px solid transparent;
	margin-bottom: -2px;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 14px;
	font-weight: 600;
	color: var(--clr-text-muted, #6b7280);
	cursor: pointer;
	white-space: nowrap;
	transition: color 0.2s, border-color 0.2s;
}
.sp-tab:hover { color: var(--clr-navy, #0f2044); }
.sp-tab.is-active {
	color: var(--clr-navy, #0f2044);
	border-bottom-color: var(--clr-amber, #f59e0b);
}
.sp-tab__count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	background: var(--clr-amber, #f59e0b);
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	margin-left: 5px;
}

.sp-tab-panel {
	padding: 36px 0;
}
.sp-tab-panel[hidden] { display: none; }
.sp-tab-panel__empty {
	color: var(--clr-text-muted, #6b7280);
	font-style: italic;
}

/* Prose */
.sp-prose {
	font-size: 15px;
	line-height: 1.8;
	color: var(--clr-text, #374151);
	max-width: 720px;
}
.sp-prose p { margin: 0 0 16px; }
.sp-prose p:last-child { margin: 0; }
.sp-prose ul, .sp-prose ol { padding-left: 20px; margin: 0 0 16px; }
.sp-prose li { margin-bottom: 6px; }
.sp-prose strong { color: var(--clr-navy, #0f2044); }
.sp-prose a { color: var(--clr-amber, #f59e0b); }

/* Specifications table */
.sp-specs-table {
	width: 100%;
	max-width: 600px;
	border-collapse: collapse;
	font-size: 14px;
}
.sp-specs-table th,
.sp-specs-table td {
	padding: 11px 16px;
	text-align: left;
	border-bottom: 1px solid var(--clr-border, #e5e7eb);
}
.sp-specs-table th {
	width: 40%;
	font-weight: 600;
	color: var(--clr-navy, #0f2044);
	background: var(--clr-surface, #f8f6f2);
}
.sp-specs-table td { color: var(--clr-text, #374151); }
.sp-specs-table tr:last-child th,
.sp-specs-table tr:last-child td { border-bottom: none; }

/* ── Related products ───────────────────────────────────────── */
.sp-related {
	margin-top: 72px;
}
.sp-related__heading {
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: clamp(20px, 2.5vw, 28px);
	font-weight: 800;
	color: var(--clr-navy, #0f2044);
	margin: 0 0 32px;
}
.sp-related__grid {
	grid-template-columns: repeat(4, 1fr) !important;
}

/* ── WooCommerce overrides (reviews tab) ────────────────────── */
#tab-reviews #comments h2 { font-size: 20px; font-weight: 700; color: var(--clr-navy, #0f2044); margin-bottom: 24px; }
#tab-reviews .comment-reply-title { font-size: 18px; font-weight: 700; color: var(--clr-navy, #0f2044); }
#tab-reviews #respond { margin-top: 40px; }

/* ════════════════════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════════════════════ */

/* Tablet */
@media (max-width: 1024px) {
	.sp-layout {
		gap: 36px;
	}
	.sp-related__grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

/* Mobile landscape */
@media (max-width: 768px) {
	.sp-layout {
		grid-template-columns: 1fr;
		gap: 32px;
	}
	.sp-gallery {
		position: static;
	}
	.sp-related__grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

/* Mobile portrait */
@media (max-width: 480px) {
	.sp-page { padding-block: 16px 60px; }
	.sp-title { font-size: 22px; }
	.sp-related__grid {
		grid-template-columns: 1fr !important;
	}
	.sp-tabs { gap: 0; }
	.sp-tab { padding: 10px 16px; font-size: 13px; }
}
