feat: redesign contact page for POD sellers & add theme enhancements
Contact page redesign: - Replace retail-style contact info (phone, address, hours) with POD-appropriate layout - Add order tracking card with email input - Add "Handy to know" section with printing/delivery/returns info - Add email contact with response time promise - Add social links (Instagram, Pinterest) - Update intro text to be warmer and more personal Collection page improvements: - Replace sidebar filters with horizontal category pills - Add filter pill CSS with theme token integration PDP enhancements: - Add image lightbox with keyboard navigation - Add thumbnail gallery with active state - Add reviews section (toggleable) - Add related products section (toggleable) - Add trust badges section (toggleable) Theme system additions: - Add button_style setting (filled/outline/soft) - Add product_text_align setting (left/center) - Add image_aspect_ratio setting (square/portrait/landscape) - Add responsive form layouts with flex-wrap 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -252,6 +252,89 @@
|
||||
box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
/* =============================================
|
||||
Dynamic Theme Settings (consume CSS variables)
|
||||
============================================= */
|
||||
|
||||
/* Density - apply to product grids */
|
||||
.preview-frame .product-grid {
|
||||
gap: var(--space-lg, 1.5rem);
|
||||
}
|
||||
|
||||
.preview-frame[data-density="spacious"] .product-grid {
|
||||
gap: calc(var(--space-lg, 1.5rem) * 1.25);
|
||||
}
|
||||
|
||||
.preview-frame[data-density="compact"] .product-grid {
|
||||
gap: calc(var(--space-lg, 1.5rem) * 0.75);
|
||||
}
|
||||
|
||||
/* Density also affects card padding */
|
||||
.preview-frame .product-card > div:last-child {
|
||||
padding: var(--space-md, 1rem);
|
||||
}
|
||||
|
||||
.preview-frame[data-density="spacious"] .product-card > div:last-child {
|
||||
padding: calc(var(--space-md, 1rem) * 1.25);
|
||||
}
|
||||
|
||||
.preview-frame[data-density="compact"] .product-card > div:last-child {
|
||||
padding: calc(var(--space-md, 1rem) * 0.75);
|
||||
}
|
||||
|
||||
/* Product Text Alignment - targets the product info area inside cards */
|
||||
.preview-frame .product-card > div:last-child {
|
||||
text-align: var(--t-product-text-align, left);
|
||||
}
|
||||
|
||||
/* Image Aspect Ratio - targets the image container inside product cards */
|
||||
.preview-frame .product-card .product-image-container {
|
||||
aspect-ratio: var(--t-image-aspect-ratio, 1 / 1);
|
||||
}
|
||||
|
||||
/* Font Size Scale - applied to base font (16px is accessible minimum) */
|
||||
.preview-frame {
|
||||
font-size: calc(16px * var(--t-font-size-scale, 1));
|
||||
}
|
||||
|
||||
/* Heading Weight Override - takes precedence over typography preset */
|
||||
.preview-frame h1,
|
||||
.preview-frame h2,
|
||||
.preview-frame h3,
|
||||
.preview-frame h4,
|
||||
.preview-frame h5,
|
||||
.preview-frame h6 {
|
||||
font-weight: var(--t-heading-weight-override, var(--t-heading-weight, 600)) !important;
|
||||
}
|
||||
|
||||
/* Layout Max Width - applied via data attribute for better specificity */
|
||||
.preview-frame[data-layout="contained"] .max-w-7xl {
|
||||
max-width: var(--t-layout-max-width, 1100px);
|
||||
}
|
||||
|
||||
.preview-frame[data-layout="wide"] .max-w-7xl {
|
||||
max-width: var(--t-layout-max-width, 1400px);
|
||||
}
|
||||
|
||||
.preview-frame[data-layout="full"] .max-w-7xl {
|
||||
max-width: var(--t-layout-max-width, 100%);
|
||||
}
|
||||
|
||||
/* Button Style - using data attribute approach */
|
||||
/* Outline button style */
|
||||
.preview-frame[data-button-style="outline"] button[style*="background-color: hsl(var(--t-accent"] {
|
||||
background-color: transparent !important;
|
||||
color: hsl(var(--t-accent-h) var(--t-accent-s) var(--t-accent-l)) !important;
|
||||
border: 2px solid hsl(var(--t-accent-h) var(--t-accent-s) var(--t-accent-l)) !important;
|
||||
}
|
||||
|
||||
/* Soft button style */
|
||||
.preview-frame[data-button-style="soft"] button[style*="background-color: hsl(var(--t-accent"] {
|
||||
background-color: hsl(var(--t-accent-h) var(--t-accent-s) 90%) !important;
|
||||
color: hsl(var(--t-accent-h) var(--t-accent-s) 30%) !important;
|
||||
border: 2px solid transparent !important;
|
||||
}
|
||||
|
||||
/* Product Badges */
|
||||
.product-badge {
|
||||
position: absolute;
|
||||
@@ -276,6 +359,11 @@
|
||||
color: var(--t-text-inverse);
|
||||
}
|
||||
|
||||
.badge-sold-out {
|
||||
background-color: var(--t-text-tertiary, #737373);
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
/* Product Hover Image */
|
||||
.product-image-container {
|
||||
position: relative;
|
||||
@@ -292,20 +380,46 @@
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.product-card:hover .product-image-primary {
|
||||
/* Only hide primary image on hover when a hover image sibling exists */
|
||||
.product-card:hover .product-image-primary:has(+ .product-image-hover) {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
/* Secondary Accent (Hover Colour) Usage */
|
||||
/* Applied to interactive elements on hover for visual feedback */
|
||||
|
||||
/* Links in body text */
|
||||
.preview-frame a:not([class*="btn"]):not([class*="button"]):not(.product-card):not(.nav-link):hover {
|
||||
color: var(--t-secondary-accent, var(--t-text-primary));
|
||||
}
|
||||
|
||||
/* Product card hover effect - subtle accent border */
|
||||
.preview-frame .product-card:hover {
|
||||
border-color: var(--t-secondary-accent, var(--t-border-default)) !important;
|
||||
}
|
||||
|
||||
/* Button hover states - darken or use secondary accent */
|
||||
.preview-frame button:hover,
|
||||
.preview-frame [role="button"]:hover {
|
||||
filter: brightness(0.95);
|
||||
}
|
||||
|
||||
/* Nav links hover */
|
||||
.preview-frame .nav-link:hover,
|
||||
.preview-frame nav a:hover {
|
||||
color: var(--t-secondary-accent, var(--t-text-primary));
|
||||
}
|
||||
|
||||
/* Social Links */
|
||||
.social-link:hover {
|
||||
background-color: var(--t-surface-sunken);
|
||||
color: var(--t-text-primary);
|
||||
color: var(--t-secondary-accent, var(--t-text-primary));
|
||||
}
|
||||
|
||||
/* Header Icon Buttons */
|
||||
.header-icon-btn:hover {
|
||||
background-color: var(--t-surface-sunken);
|
||||
color: var(--t-text-primary);
|
||||
color: var(--t-secondary-accent, var(--t-text-primary));
|
||||
}
|
||||
|
||||
/* Search Modal Animation */
|
||||
@@ -318,3 +432,225 @@
|
||||
transform: translateY(0);
|
||||
transition: transform 0.2s ease;
|
||||
}
|
||||
|
||||
/* Lightbox - using native dialog */
|
||||
.lightbox {
|
||||
position: fixed;
|
||||
inset: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
max-width: 100%;
|
||||
max-height: 100%;
|
||||
border: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
background: transparent;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.lightbox::backdrop {
|
||||
background: rgba(0, 0, 0, 0.95);
|
||||
}
|
||||
|
||||
.lightbox:not([open]) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.lightbox-content {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.lightbox-close {
|
||||
position: absolute;
|
||||
top: var(--space-md, 1rem);
|
||||
right: var(--space-md, 1rem);
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
border: none;
|
||||
border-radius: 50%;
|
||||
color: white;
|
||||
cursor: pointer;
|
||||
transition: background 0.15s ease;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.lightbox-close:hover {
|
||||
background: rgba(255, 255, 255, 0.1);
|
||||
}
|
||||
|
||||
.lightbox-close svg {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
}
|
||||
|
||||
.lightbox-nav {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: rgba(255, 255, 255, 0.1);
|
||||
border: none;
|
||||
border-radius: 50%;
|
||||
color: white;
|
||||
cursor: pointer;
|
||||
transition: background 0.15s ease;
|
||||
}
|
||||
|
||||
.lightbox-nav:hover {
|
||||
background: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.lightbox-nav svg {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
}
|
||||
|
||||
.lightbox-prev {
|
||||
left: var(--space-md, 1rem);
|
||||
}
|
||||
|
||||
.lightbox-next {
|
||||
right: var(--space-md, 1rem);
|
||||
}
|
||||
|
||||
.lightbox-image-container {
|
||||
max-width: 90vw;
|
||||
max-height: 75vh;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.lightbox-image {
|
||||
max-width: 100%;
|
||||
max-height: 75vh;
|
||||
object-fit: contain;
|
||||
border-radius: var(--t-radius-image, 8px);
|
||||
}
|
||||
|
||||
.lightbox-figure {
|
||||
margin: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: var(--space-md, 1rem);
|
||||
}
|
||||
|
||||
.lightbox-caption {
|
||||
color: rgba(255, 255, 255, 0.8);
|
||||
font-family: var(--t-font-body);
|
||||
font-size: 0.875rem;
|
||||
text-align: center;
|
||||
max-width: 600px;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.lightbox-counter {
|
||||
position: absolute;
|
||||
bottom: var(--space-md, 1rem);
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
color: rgba(255, 255, 255, 0.7);
|
||||
font-size: 0.875rem;
|
||||
font-family: var(--t-font-body);
|
||||
}
|
||||
|
||||
/* PDP Main Image zoom cursor */
|
||||
.pdp-main-image-container {
|
||||
cursor: zoom-in;
|
||||
}
|
||||
|
||||
/* =============================================
|
||||
Type Scale Utility Classes
|
||||
These scale with the font-size setting
|
||||
============================================= */
|
||||
|
||||
/* Body text sizes */
|
||||
.preview-frame .t-caption { font-size: var(--t-text-caption); }
|
||||
.preview-frame .t-small { font-size: var(--t-text-small); }
|
||||
.preview-frame .t-base { font-size: var(--t-text-base); }
|
||||
.preview-frame .t-large { font-size: var(--t-text-large); }
|
||||
.preview-frame .t-xl { font-size: var(--t-text-xl); }
|
||||
.preview-frame .t-2xl { font-size: var(--t-text-2xl); }
|
||||
|
||||
/* Heading sizes */
|
||||
.preview-frame .t-heading-sm { font-size: var(--t-heading-sm); }
|
||||
.preview-frame .t-heading-md { font-size: var(--t-heading-md); }
|
||||
.preview-frame .t-heading-lg { font-size: var(--t-heading-lg); }
|
||||
.preview-frame .t-heading-xl { font-size: var(--t-heading-xl); }
|
||||
.preview-frame .t-heading-display { font-size: var(--t-heading-display); }
|
||||
|
||||
/* Override Tailwind text-* classes within preview to use our scale */
|
||||
.preview-frame .text-xs { font-size: var(--t-text-caption) !important; }
|
||||
.preview-frame .text-sm { font-size: var(--t-text-small) !important; }
|
||||
.preview-frame .text-base { font-size: var(--t-text-base) !important; }
|
||||
.preview-frame .text-lg { font-size: var(--t-text-large) !important; }
|
||||
.preview-frame .text-xl { font-size: var(--t-text-xl) !important; }
|
||||
.preview-frame .text-2xl { font-size: var(--t-text-2xl) !important; }
|
||||
|
||||
/* Map larger Tailwind sizes to our heading scale */
|
||||
.preview-frame .text-3xl { font-size: var(--t-heading-lg) !important; }
|
||||
.preview-frame .text-4xl { font-size: var(--t-heading-xl) !important; }
|
||||
.preview-frame .text-5xl,
|
||||
.preview-frame .text-6xl,
|
||||
.preview-frame .text-7xl,
|
||||
.preview-frame .text-8xl,
|
||||
.preview-frame .text-9xl { font-size: var(--t-heading-display) !important; }
|
||||
|
||||
/* =============================================
|
||||
Filter Pills (Collection Page)
|
||||
============================================= */
|
||||
|
||||
.preview-frame .filter-pills-container {
|
||||
scrollbar-width: none;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
.preview-frame .filter-pills-container::-webkit-scrollbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.preview-frame .filter-pill {
|
||||
flex-shrink: 0;
|
||||
padding: 0.5rem 1rem;
|
||||
font-size: var(--t-text-small);
|
||||
font-weight: 500;
|
||||
border-radius: var(--t-radius-button);
|
||||
border: 1px solid var(--t-border-default);
|
||||
background-color: var(--t-surface-base);
|
||||
color: var(--t-text-secondary);
|
||||
cursor: pointer;
|
||||
transition: all 0.15s ease;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.preview-frame .filter-pill:hover {
|
||||
background-color: var(--t-surface-sunken);
|
||||
color: var(--t-text-primary);
|
||||
}
|
||||
|
||||
.preview-frame .filter-pill-active {
|
||||
background-color: hsl(var(--t-accent-h) var(--t-accent-s) var(--t-accent-l));
|
||||
color: var(--t-text-inverse);
|
||||
border-color: transparent;
|
||||
}
|
||||
|
||||
.preview-frame .filter-pill-active:hover {
|
||||
background-color: hsl(var(--t-accent-h) var(--t-accent-s) calc(var(--t-accent-l) - 5%));
|
||||
color: var(--t-text-inverse);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user