/**
 * Ergoshop - Main Stylesheet
 * Colors based on salons.lv: Blue #3498db, #258cd1
 */

/* ============================================
   CSS Variables
   ============================================ */
:root {
    /* Colors */
    --color-primary: #3498db;
    --color-primary-dark: #258cd1;
    --color-primary-light: #5dade2;

    --color-text: #333333;
    --color-text-light: #666666;
    --color-text-muted: #999999;

    --color-bg: #fafafa;
    --color-bg-white: #ffffff;
    --color-bg-light: #f5f5f5;

    --color-border: #e0e0e0;
    --color-border-light: #eeeeee;

    --color-success: #27ae60;
    --color-error: #e74c3c;
    --color-warning: #f39c12;

    /* Typography */
    --font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-size-base: 16px;
    --font-size-sm: 14px;
    --font-size-xs: 12px;
    --font-size-lg: 18px;
    --font-size-xl: 24px;
    --font-size-2xl: 32px;
    --font-size-3xl: 40px;

    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    --spacing-3xl: 64px;

    /* Layout */
    --container-max: 1200px;
    --header-height: auto;
    --section-spacing: 40px;
    --page-top-margin: 0px;

    /* Effects - Square corners by default */
    --shadow-sm: none;
    --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.15);
    --transition: 0.3s ease;
    --border-radius: 0;
    --border-radius-sm: 0;
    --btn-border-radius: 0; /* Only for buttons, controlled by admin */
}

/* ============================================
   Reset & Base
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: var(--font-size-base);
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    color: var(--color-text);
    overflow-x: hidden;
    background-color: var(--color-bg);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--color-primary-dark);
}

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

ul, ol {
    list-style: none;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

button {
    cursor: pointer;
    border: none;
    background: none;
}

/* ============================================
   Layout
   ============================================ */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--spacing-xl);
}

.main {
    flex: 1;
    background: transparent;
    padding-top: var(--page-top-margin, 0px);
    position: relative;
    z-index: auto; /* No stacking context - allows fixed toolbars to escape */
}

/* In admin edit mode, ensure main doesn't trap fixed-position toolbars */
body.admin-edit-mode .main {
    z-index: auto !important;
}

/* Force ALL section toolbars to be above EVERYTHING - including header */
body.admin-edit-mode .section-toolbar {
    position: fixed !important;
    z-index: 999999 !important;
    background: #2c3e50 !important;
}

.main > .container {
    max-width: var(--container-max);
    background: white;
    margin-bottom: var(--spacing-lg);
    border: 1px solid var(--color-border);
}

/* ============================================
   Homepage Sections - Independent Layout
   ============================================ */
.partners-section,
.categories-section,
.products-section {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--spacing-xl);
}

.products-section {
    background: white;
    padding-top: var(--spacing-lg);
    padding-bottom: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

/* ============================================
   Header - Two Row Structure
   ============================================ */
.header {
    background: transparent;
    box-shadow: none;
    border-bottom: none;
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

/* In admin edit mode, header stays low so toolbars can be above it */
body.admin-edit-mode .header {
    z-index: 100;
}

.header > .container {
    max-width: 100%;
    padding: 0;
}

/* Header Top Row */
.header-top {
    display: flex;
    justify-content: center;
    background: transparent;
    position: relative;
}

/* Top row: Logo + Header Actions */
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--header-padding, 16px) var(--spacing-xl);
    max-width: var(--container-max);
    width: 100%;
    background: transparent;
}

/* Logo */
.logo-wrapper {
    position: relative;
    margin-left: var(--logo-margin-left, 24px);
}

.logo {
    display: flex;
    align-items: center;
    padding: var(--spacing-sm) 0;
}

.logo-img {
    height: var(--logo-height, 45px);
    width: auto;
    transition: opacity var(--transition);
}

.logo:hover .logo-img {
    opacity: 0.8;
}

/* Cart Widget Wrapper */
.cart-widget-wrapper,
.checkout-btn-wrapper {
    position: relative;
}

/* Header On-Canvas Controls (Edit Mode) - Hidden until hover */
.header-control {
    display: none;
    position: absolute;
    pointer-events: none;
}

/* Show control wrapper on hover, but buttons still hidden */
body.admin-edit-mode .header-control {
    display: block;
}

.header-control-move,
.header-control-resize {
    position: absolute;
    width: 22px;
    height: 22px;
    background: #2c3e50;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
    color: white;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s, visibility 0.15s, background 0.15s;
    z-index: 10003;
}

.header-control-btn {
    position: absolute;
    width: 22px;
    height: 22px;
    background: #2c3e50;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
    color: white;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s, visibility 0.15s, background 0.15s;
    z-index: 10003;
}

.header-control-move,
.header-control-resize {
    cursor: grab;
}

.header-control-resize {
    cursor: ns-resize;
}

.header-control-btn {
    cursor: pointer;
    top: -4px;
    left: 50%;
    transform: translateX(-50%);
}

/* Show controls only when hovering over the wrapper */
body.admin-edit-mode .logo-wrapper:hover .header-control-move,
body.admin-edit-mode .logo-wrapper:hover .header-control-resize,
body.admin-edit-mode .logo-wrapper:hover .header-control-btn,
body.admin-edit-mode .cart-widget-wrapper:hover .header-control-move,
body.admin-edit-mode .cart-widget-wrapper:hover .header-control-resize,
body.admin-edit-mode .checkout-btn-wrapper:hover .header-control-move,
body.admin-edit-mode .checkout-btn-wrapper:hover .header-control-resize,
body.admin-edit-mode .header-cart-area:hover .header-control-move,
body.admin-edit-mode .header-cart-area:hover .header-control-resize {
    opacity: 0.85;
    visibility: visible;
}

.header-control-move:hover,
.header-control-resize:hover {
    opacity: 1 !important;
    background: var(--color-primary);
}

/* Logo change button - no animation, just simple hover */
.header-control-btn:hover {
    opacity: 1 !important;
    background: var(--color-primary);
}

.header-control-move:active,
.header-control-resize:active {
    background: #27ae60;
}

.header-control-btn:active {
    background: var(--color-primary-dark);
}

/* Bounding box highlight - only on hover */
body.admin-edit-mode .logo-wrapper,
body.admin-edit-mode .cart-widget-wrapper,
body.admin-edit-mode .checkout-btn-wrapper {
    outline: none;
}

body.admin-edit-mode .logo-wrapper:hover,
body.admin-edit-mode .cart-widget-wrapper:hover,
body.admin-edit-mode .checkout-btn-wrapper:hover {
    outline: 1px dashed var(--color-primary);
    outline-offset: 4px;
}

/* Logo control - Move at top-right, Resize at bottom-left */
.header-control-logo {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.header-control-logo .header-control-move {
    top: -4px;
    right: -4px;
}

.header-control-logo .header-control-resize {
    bottom: -4px;
    left: -4px;
}

/* Cart control - Resize at bottom-right */
.header-control-cart {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.header-control-cart .header-control-resize {
    bottom: -4px;
    right: -4px;
}

/* Checkout button control - Resize at bottom-right */
.header-control-checkout {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.header-control-checkout .header-control-resize {
    bottom: -4px;
    right: -4px;
}

/* ============================================
   On-Canvas Edit System - Comprehensive Controls
   ============================================ */

/* Editable section highlight on hover */
body.admin-edit-mode .editable-section {
    position: relative;
    transition: background 0.2s ease;
}

body.admin-edit-mode .editable-section:hover {
    outline: 1px dashed rgba(52, 152, 219, 0.4);
    outline-offset: 4px;
}

/* Hide dashed border when toolbar is active (user is editing via toolbar) */
body.admin-edit-mode .editable-section.toolbar-editing,
body.admin-edit-mode .editable-section.toolbar-editing:hover {
    outline: none !important;
}

/* Also apply to nested editable elements like logo/cart */
body.admin-edit-mode .toolbar-editing.logo-wrapper,
body.admin-edit-mode .toolbar-editing.logo-wrapper:hover,
body.admin-edit-mode .toolbar-editing.cart-widget-wrapper,
body.admin-edit-mode .toolbar-editing.cart-widget-wrapper:hover,
body.admin-edit-mode .toolbar-editing.checkout-btn-wrapper,
body.admin-edit-mode .toolbar-editing.checkout-btn-wrapper:hover {
    outline: none !important;
}

/* Editable sections keep their original background on hover - no changes */

/* Section Contextual Toolbar - Fixed position, draggable anywhere */
/* Main floating toolbars MUST be above everything - using !important to override any stacking context issues */
.section-toolbar {
    display: none;
    position: fixed !important;
    z-index: 999999 !important; /* Very high z-index - above header (100) */
    background: #2c3e50 !important;
    align-items: center;
    gap: 12px;
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    overflow: hidden; /* Ensures children respect border-radius */
    box-shadow: var(--toolbar-shadow, none); /* Default no shadow, can be enabled per-toolbar */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, box-shadow 0.2s ease;
    font-size: 12px;
}

/* Show grabbing cursor only when actively dragging */
.section-toolbar.dragging {
    cursor: grabbing;
}

/* Interactive elements inside toolbar should have pointer cursor */
.section-toolbar input,
.section-toolbar button,
.section-toolbar select,
.section-toolbar label {
    cursor: pointer;
}

.section-toolbar input[type="range"] {
    cursor: ew-resize;
}

/* Toolbars visible when dragging, focus-within, or active class - MUST come after base rule */
body.admin-edit-mode .section-toolbar.dragging,
body.admin-edit-mode .section-toolbar:focus-within,
body.admin-edit-mode .section-toolbar.active {
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* Cart toolbar - follows same show/hide logic as others */

/* Multi-row toolbar (e.g., Cart + Checkout combined) */
.section-toolbar.section-toolbar-multirow {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
}

.section-toolbar-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Only allow interaction when toolbar is active/visible */
.section-toolbar.active input,
.section-toolbar.active button,
.section-toolbar.active select {
    pointer-events: auto;
}

/* Show toolbar in edit mode */
body.admin-edit-mode .section-toolbar {
    display: flex;
}

/* Partner page toolbar - always visible when present */
.partner-page-toolbar {
    display: flex !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    position: relative !important;
    margin: 16px 0;
}

/* Drag handle for toolbar - matches hero toolbar style */
.section-toolbar-drag {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 28px;
    margin-left: -4px;
    margin-right: 4px;
    cursor: grab;
    opacity: 0.5;
    transition: opacity 0.2s;
    color: white;
}

.section-toolbar-drag svg {
    width: 10px;
    height: 16px;
}

.section-toolbar-drag:hover {
    opacity: 1;
}

.section-toolbar-drag:active {
    cursor: grabbing;
}

.section-toolbar.dragging {
    cursor: grabbing;
    opacity: 0.95 !important;
}

/* Reset position button - matches hero toolbar */
.section-toolbar-reset {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.5;
    transition: opacity 0.2s, background 0.2s;
}

.section-toolbar-reset:hover {
    opacity: 1;
    background: rgba(255,255,255,0.2);
}

.section-toolbar-reset svg {
    width: 12px;
    height: 12px;
}

/* Section toolbar button - matches hero toolbar */
.section-toolbar-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.section-toolbar-btn:hover {
    background: rgba(255,255,255,0.15);
}

.section-toolbar-btn.active {
    background: var(--color-primary);
}

.section-toolbar-btn svg {
    width: 14px;
    height: 14px;
}

/* Toolbar save button - hidden by default, shown when changes exist */
.section-toolbar-save {
    background: var(--color-primary);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0;
    transform: scale(0.5);
    pointer-events: none;
    position: relative;
    overflow: visible;
}

/* Show save button when toolbar has changes */
.section-toolbar.has-changes .section-toolbar-save,
.section-toolbar-multirow.has-changes .section-toolbar-save,
.hero-toolbar.has-changes .section-toolbar-save {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
    animation: pulse-save 1s ease-in-out infinite;
}

/* Unified toolbar save button states */
.section-toolbar-unified .toolbar-save-btn {
    background: #7f8c8d; /* Gray - no changes */
}

.section-toolbar-unified.has-changes .toolbar-save-btn {
    background: var(--color-primary); /* Blue - unsaved changes */
    animation: pulse-save 1s ease-in-out infinite;
}

.section-toolbar-unified .toolbar-save-btn.saved {
    background: #27ae60 !important; /* Green - saved successfully */
    animation: none !important;
}

@keyframes pulse-save {
    0%, 100% { box-shadow: 0 0 0 0 rgba(52, 152, 219, 0.4); }
    50% { box-shadow: 0 0 0 6px rgba(52, 152, 219, 0); }
}

.section-toolbar-save:hover {
    background: var(--color-primary-dark);
    transform: scale(1.1);
}

/* Loading state with spinner */
.section-toolbar-save.saving {
    pointer-events: none;
    background: #7f8c8d !important;
}

.section-toolbar-save.saving svg {
    display: none;
}

.section-toolbar-save.saving::after {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: toolbar-spin 0.6s linear infinite;
}

@keyframes toolbar-spin {
    to { transform: rotate(360deg); }
}

/* Success state with pop animation */
.section-toolbar-save.saved {
    background: #27ae60 !important;
    animation: save-pop 0.4s ease;
}

@keyframes save-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.4); }
    100% { transform: scale(1); }
}

/* Success sparkle lines */
.section-toolbar-save.saved::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 10px;
    background: #27ae60;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    animation: sparkle-up 0.5s ease-out forwards;
}

.section-toolbar-save.saved::after {
    content: '';
    position: absolute;
    width: 10px;
    height: 2px;
    background: #27ae60;
    left: -6px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    border-radius: 0;
    animation: sparkle-left 0.5s ease-out forwards;
}

@keyframes sparkle-up {
    0% { opacity: 1; height: 0; top: 50%; }
    50% { opacity: 1; height: 10px; top: -6px; }
    100% { opacity: 0; height: 10px; top: -12px; }
}

@keyframes sparkle-left {
    0% { opacity: 1; width: 0; left: 50%; }
    50% { opacity: 1; width: 10px; left: -6px; }
    100% { opacity: 0; width: 10px; left: -12px; }
}

/* Error state */
.section-toolbar-save.error {
    background: #e74c3c !important;
    animation: save-shake 0.4s ease;
}

@keyframes save-shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-3px); }
    40%, 80% { transform: translateX(3px); }
}

/* Toolbar fade out after successful save */
.section-toolbar.fade-out,
.section-toolbar-multirow.fade-out,
.hero-toolbar.fade-out {
    animation: toolbar-fadeout 0.4s ease forwards;
    animation-delay: 1.2s;
}

@keyframes toolbar-fadeout {
    to {
        opacity: 0;
        transform: translateY(-10px);
        pointer-events: none;
    }
}

.section-toolbar-save svg {
    width: 14px;
    height: 14px;
}

/* Toolbar group - like hero-toolbar-group */
.section-toolbar-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-toolbar-group label {
    font-size: 11px;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.section-toolbar-label {
    font-size: 11px;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* Separator - matches hero toolbar */
.section-toolbar-sep {
    width: 1px;
    height: 24px;
    background: rgba(255,255,255,0.2);
}

/* Editable text hover effect - ONLY for hero section text */
body.admin-edit-mode .hero .editable-text:hover {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    cursor: text;
}

/* ============================================
   PARTNERS PAGE EDIT MODE
   ============================================ */

/* Partners page header toolbar (on hover) */
.partners-page-header {
    position: relative;
}

.page-header-toolbar {
    position: absolute;
    top: 0;
    right: 0;
    display: none;
    align-items: center;
    gap: 4px;
    background: #2c3e50;
    padding: 4px 8px;
    border-radius: 4px;
    z-index: 10;
}

body.admin-edit-mode .partners-page-header:hover .page-header-toolbar {
    display: flex;
}

.header-toolbar-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.header-toolbar-btn:hover {
    background: var(--color-primary);
}

.header-toolbar-btn.has-changes {
    background: #f39c12;
    animation: pulse 1s infinite;
}

.header-toolbar-btn.saving {
    opacity: 0.5;
    pointer-events: none;
}

.header-toolbar-btn.saved {
    background: #27ae60;
}

/* Partners content area - clickable to show toolbar */
.partners-content-area {
    position: relative;
}

/* Show dashed border on hover to indicate clickable area (like other editable sections) */
body.admin-edit-mode .partners-content-area:hover {
    outline: 1px dashed rgba(52, 152, 219, 0.4);
    outline-offset: 4px;
}

/* Hide outline when toolbar is active (being edited) */
body.admin-edit-mode .partners-content-area.toolbar-editing,
body.admin-edit-mode .partners-content-area.toolbar-editing:hover {
    outline: none;
}

/* Partner card wrapper - edit mode */
body.admin-edit-mode .partner-card-wrapper {
    position: relative;
}

body.admin-edit-mode .partner-card-wrapper:hover {
    outline: 1px dashed rgba(52, 152, 219, 0.4);
    outline-offset: 4px;
}

/* Partner card toolbar (appears on hover) */
.partner-card-toolbar {
    position: absolute;
    top: -32px;
    right: 8px;
    display: none;
    align-items: center;
    gap: 4px;
    background: #2c3e50;
    padding: 4px 8px;
    border-radius: 4px;
    z-index: 10;
}

body.admin-edit-mode .partner-card-wrapper:hover .partner-card-toolbar {
    display: flex;
}

.partner-toolbar-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.partner-toolbar-btn:hover {
    background: var(--color-primary);
}

.partner-toolbar-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.partner-toolbar-btn:disabled:hover {
    background: rgba(255,255,255,0.1);
}

.partner-toolbar-btn.delete-partner:hover {
    background: #e74c3c;
}

.partner-toolbar-btn.upload-logo:hover {
    background: #27ae60;
}

/* Drag and drop reordering */
body.admin-edit-mode .partner-card-wrapper {
    cursor: grab;
}

body.admin-edit-mode .partner-card-wrapper.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

body.admin-edit-mode .partner-card-wrapper.drag-over {
    outline: 2px solid var(--color-primary) !important;
    outline-offset: 4px;
}

body.admin-edit-mode .partners-grid.dragging-active .partner-card-wrapper:not(.dragging):hover {
    outline: 2px dashed rgba(52, 152, 219, 0.6);
}

/* =============================================
   PARTNER LOGO DISPLAY PRESETS
   ============================================= */

/* Preset Switcher Buttons */
.preset-switcher {
    display: flex;
    gap: 4px;
}

.preset-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: rgba(255,255,255,0.7);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
}

.preset-btn:hover {
    background: rgba(255,255,255,0.2);
    color: white;
}

.preset-btn.active {
    background: var(--color-primary);
    color: white;
}

/* =====================================================
   PARTNER CARDS - CONFIGURABLE DESIGN
   Uses CSS variables for real-time adjustments
   Higher specificity to override legacy styles
===================================================== */

/* Partner card base styles with CSS variables */
.partners-grid .partner-card-wrapper .partner-card {
    border: none;
    background: transparent;
}

.partners-grid .partner-card-wrapper .partner-card-link {
    display: flex;
    flex-direction: column;
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--card-radius, 8px);
    overflow: hidden;
    transition: all 0.3s;
}

.partners-grid .partner-card-wrapper .partner-card-link:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: var(--color-primary);
}

.partners-grid .partner-card-wrapper .partner-card-link:hover .partner-card {
    border-color: transparent;
    box-shadow: none;
}

.partners-grid .partner-card-wrapper .partner-logo {
    width: 100%;
    height: var(--card-height, 100px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: none !important;
    border-bottom: none !important;
    border-top: none !important;
    outline: none !important;
    box-shadow: none !important;
    padding: var(--logo-padding, 15px);
    flex-shrink: 0;
}

.partners-grid .partner-card-wrapper .partner-logo img {
    max-width: 100%;
    max-height: var(--max-logo-height, 67px);
    width: auto;
    height: auto;
    object-fit: contain;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
}

/* Placeholder for partners without logo */
.partners-grid .partner-card-wrapper .partner-logo-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-primary);
    color: white;
    font-size: var(--font-size-xl);
    font-weight: 700;
}

/* Hide partner name, only show country */
.partners-grid .partner-card-wrapper .partner-name {
    display: none;
}

/* Info bar base styles */
.partners-grid .partner-card-wrapper .partner-card-info {
    padding: var(--info-padding, 10px) 15px;
    background: var(--color-bg-light);
    border-top: 1px solid var(--color-border-light);
    text-align: left;
}

.partners-grid .partner-card-wrapper .partner-info-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.partners-grid .partner-card-wrapper .partner-country {
    font-size: var(--info-font-size, 12px);
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0;
}

.partners-grid .partner-card-wrapper .partner-website {
    display: none;
    align-items: center;
    gap: 4px;
    font-size: calc(var(--info-font-size, 12px) - 1px);
    color: var(--color-text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.partners-grid .partner-card-wrapper .partner-website:hover {
    color: var(--color-primary);
}

.partners-grid .partner-card-wrapper .partner-website svg {
    flex-shrink: 0;
}

/* INFO LAYOUT: Center (default) */
.partners-grid.info-center .partner-info-row {
    justify-content: center;
}

/* INFO LAYOUT: Left + URL */
.partners-grid.info-left .partner-info-row {
    justify-content: space-between;
}

.partners-grid.info-left .partner-website {
    display: flex;
}

/* INFO LAYOUT: Hidden */
.partners-grid.info-hidden .partner-card-info {
    display: none;
}

/* INFO LAYOUT: Partial hidden (location + URL off) - hide entire info section */
.partners-grid.info-hidden-partial .partner-card-info {
    display: none !important;
}

/* Editable partner fields - NO LAYOUT SHIFT */
body.admin-edit-mode .editable-partner-field {
    cursor: text;
    transition: box-shadow 0.2s;
    border-radius: 2px;
}

body.admin-edit-mode .editable-partner-field:hover {
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.3);
}

body.admin-edit-mode .editable-partner-field.editing,
body.admin-edit-mode .editable-partner-field.editing:hover {
    box-shadow: 0 0 0 2px var(--color-primary);
    background: #fffef5;
    outline: none;
}

/* Page title/subtitle editable */
body.admin-edit-mode .page-header .editable-text {
    cursor: text;
    transition: box-shadow 0.2s;
    border-radius: 4px;
}

body.admin-edit-mode .page-header .editable-text:hover {
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.3);
}

body.admin-edit-mode .page-header .editable-text.editing,
body.admin-edit-mode .page-header .editable-text.editing:hover {
    box-shadow: 0 0 0 2px var(--color-primary);
    background: #fffef5;
    outline: none;
}

/* Confirmation dialog overlay */
.confirm-dialog-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    align-items: center;
    justify-content: center;
}

.confirm-dialog-overlay.active {
    display: flex;
}

.confirm-dialog {
    background: white;
    padding: 24px;
    border-radius: 8px;
    text-align: center;
    max-width: 350px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.confirm-dialog h3 {
    margin: 0 0 12px 0;
    font-size: 18px;
}

.confirm-dialog p {
    margin: 0 0 20px 0;
    color: #666;
}

.confirm-dialog-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.btn-danger {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.btn-danger:hover {
    background: #c0392b;
}

/* Add partner button in toolbar */
.section-toolbar-add {
    background: #27ae60 !important;
}

.section-toolbar-add:hover {
    background: #2ecc71 !important;
}

/* Mini label in toolbar */
.section-toolbar-mini-label {
    font-size: 10px;
    opacity: 0.6;
    text-transform: uppercase;
}

/* Value display in toolbar */
.section-toolbar-value {
    font-size: 11px;
    min-width: 28px;
    text-align: center;
}

/* Transform handles for sections */
.section-handle {
    position: absolute;
    width: 20px;
    height: 20px;
    background: #2c3e50;
    border: 2px solid #3498db;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s, transform 0.15s;
    z-index: 10003;
}

body.admin-edit-mode .editable-section:hover .section-handle {
    opacity: 1;
    pointer-events: auto;
}

.section-handle:hover {
    background: #3498db;
    transform: scale(1.15);
}

.section-handle-tl { top: -10px; left: -10px; cursor: nwse-resize; }
.section-handle-tr { top: -10px; right: -10px; cursor: nesw-resize; }
.section-handle-bl { bottom: -10px; left: -10px; cursor: nesw-resize; }
.section-handle-br { bottom: -10px; right: -10px; cursor: nwse-resize; }

.section-handle-move {
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    cursor: grab;
    width: 40px;
    border-radius: 10px;
}

.section-handle-move:active {
    cursor: grabbing;
}

/* Slider control in toolbar - matches hero toolbar */
.section-toolbar-slider {
    width: 80px;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    cursor: pointer;
    margin: 0;
    padding: 0;
    border: none;
    outline: none;
}

.section-toolbar-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    margin-top: -5px;
}

.section-toolbar-slider::-webkit-slider-runnable-track {
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
}

.section-toolbar-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.section-toolbar-slider::-moz-range-track {
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
}

.section-toolbar-value {
    font-size: 11px;
    min-width: 36px;
    text-align: right;
    font-family: monospace;
    color: white;
}

/* Toolbar toggle checkbox */
.section-toolbar-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    font-size: 11px;
    opacity: 0.8;
}

.section-toolbar-toggle:hover {
    opacity: 1;
}

.section-toolbar-toggle input[type="checkbox"] {
    width: 14px;
    height: 14px;
    margin: 0;
    cursor: pointer;
    accent-color: var(--color-primary);
}

.section-toolbar-toggle .toggle-label {
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 10px;
}

/* Toolbar toggle with switch track */
.toolbar-toggle-item {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 11px;
}

.toolbar-toggle-label {
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 10px;
    opacity: 0.8;
}

.toolbar-toggle-item:hover .toolbar-toggle-label {
    opacity: 1;
}

.toolbar-toggle-item input[type="checkbox"] {
    display: none;
}

.toolbar-toggle-track {
    position: relative;
    width: 28px;
    height: 14px;
    background: rgba(255,255,255,0.25);
    border-radius: 7px;
    transition: background 0.2s;
}

.toolbar-toggle-track::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 10px;
    height: 10px;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s;
}

.toolbar-toggle-item input[type="checkbox"]:checked + .toolbar-toggle-track {
    background: var(--color-primary);
}

.toolbar-toggle-item input[type="checkbox"]:checked + .toolbar-toggle-track::after {
    transform: translateX(14px);
}

/* Multi-row toolbar */
.section-toolbar-multirow {
    flex-direction: column;
    gap: 8px;
    padding: 10px 12px;
}

.section-toolbar-row {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
}

.section-toolbar-mini-label {
    font-size: 9px;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.section-toolbar-slider-mini {
    width: 40px !important;
}

.section-toolbar-select {
    background: rgba(255,255,255,0.15);
    color: white;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    cursor: pointer;
    min-width: 100px;
}

.section-toolbar-select option {
    background: #2c3e50;
    color: white;
}

/* Compact horizontal toolbar layout */
.section-toolbar-compact {
    flex-direction: column;
    padding: 0;
    border-radius: 6px;
    overflow: hidden;
}

.toolbar-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: #2c3e50;
}

.toolbar-row-primary {
    background: #2c3e50;
}

.toolbar-row-overlay,
.toolbar-row-more {
    background: rgba(0,0,0,0.15);
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 6px 10px;
}

.toolbar-group {
    display: flex;
    align-items: center;
    gap: 5px;
}

.toolbar-group-label {
    font-size: 10px;
    color: rgba(255,255,255,0.5);
    white-space: nowrap;
}

.toolbar-divider {
    width: 1px;
    height: 20px;
    background: rgba(255,255,255,0.15);
    margin: 0 2px;
}

.section-toolbar-compact .section-toolbar-drag {
    margin: 0;
    padding: 4px;
    margin-left: -4px;
    cursor: grab;
}

.section-toolbar-compact .section-toolbar-slider {
    width: 55px;
}

.section-toolbar-compact .section-toolbar-select {
    padding: 3px 6px;
    font-size: 11px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 3px;
    color: white;
}

.section-toolbar-compact .hero-align-btns {
    display: flex;
    gap: 2px;
}

.section-toolbar-compact .hero-align-btn {
    width: 24px;
    height: 24px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 3px;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    transition: all 0.15s;
}

.section-toolbar-compact .hero-align-btn:hover {
    background: rgba(255,255,255,0.2);
    color: white;
}

.section-toolbar-compact .hero-align-btn.active {
    background: var(--color-primary);
    color: white;
}

.section-toolbar-compact .hero-overlay-direction {
    display: flex;
    gap: 2px;
    margin-left: 8px;
}

.section-toolbar-compact .hero-dir-btn {
    width: 22px;
    height: 22px;
    padding: 0;
    font-size: 11px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 3px;
    color: rgba(255,255,255,0.6);
    cursor: pointer;
    transition: all 0.15s;
}

.section-toolbar-compact .hero-dir-btn:hover {
    background: rgba(255,255,255,0.2);
    color: white;
}

.section-toolbar-compact .hero-dir-btn.active {
    background: var(--color-primary);
    color: white;
}

.toolbar-more-btn.active {
    background: var(--color-primary) !important;
}

/* =============================================
   UNIFIED FLOATING TOOLBAR DESIGN SYSTEM

   Pattern: Header row + 4 Quadrants (2x2 grid)

   QUADRANT LAYOUT (predictable across all toolbars):
   ┌─────────────┬─────────────┐
   │ 1. SIZE     │ 2. SPACING  │
   │ dimensions  │ margins     │
   │ font sizes  │ padding     │
   │ heights     │ gaps        │
   ├─────────────┼─────────────┤
   │ 3. STYLE    │ 4. LAYOUT   │
   │ colors      │ alignment   │
   │ borders     │ toggles     │
   │ shadows     │ visibility  │
   └─────────────┴─────────────┘
   ============================================= */

/* Base unified toolbar style - dark glass */
.section-toolbar-unified {
    position: fixed !important;
    z-index: 999999 !important;
    display: flex;
    flex-direction: column;
    background: rgba(15, 23, 42, 0.98);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    padding: 0;
    overflow: hidden;
    min-width: 320px;
    color: white;
    font-size: 11px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    /* Hidden by default */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

/* Show when active */
.section-toolbar-unified.active {
    opacity: 1;
    pointer-events: auto;
}


/* Header row - consistent across all toolbars */
.toolbar-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.3);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.toolbar-header .section-toolbar-drag {
    margin: 0;
    opacity: 0.4;
    cursor: grab;
}

.toolbar-header .section-toolbar-drag:hover {
    opacity: 1;
}

.toolbar-header .toolbar-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.7;
    margin-right: 8px;
}

.toolbar-header .section-toolbar-btn {
    background: rgba(255,255,255,0.08);
    border-radius: 5px;
    width: 26px;
    height: 26px;
}

.toolbar-header .section-toolbar-save {
    background: var(--color-primary);
}

/* Header controls - universal settings (margins, wide toggle) */
.toolbar-header-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 1; /* Expand to fill available space */
    margin-right: 8px;
}

.toolbar-header-label {
    font-size: 9px;
    color: rgba(255,255,255,0.5);
    font-weight: 500;
    white-space: nowrap;
}

.toolbar-header-slider {
    flex: 1; /* Expand with container */
    min-width: 50px;
    max-width: 300px; /* Don't get too wide */
    height: 3px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    cursor: pointer;
}

.toolbar-header-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.7);
    cursor: pointer;
}

.toolbar-header-slider::-webkit-slider-thumb:hover {
    background: white;
}

.toolbar-header-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    font-size: 9px;
    color: rgba(255,255,255,0.6);
    padding: 3px 6px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    transition: all 0.15s;
}

.toolbar-header-toggle:hover {
    background: rgba(255,255,255,0.15);
    color: white;
}

.toolbar-header-toggle input[type="checkbox"] {
    display: none;
}

.toolbar-header-toggle:has(input:checked) {
    background: var(--color-primary);
    color: white;
}

/* Quadrant grid - 2x2 layout */
.toolbar-quadrants {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: rgba(255,255,255,0.06);
}

.toolbar-quadrant {
    background: rgba(15, 23, 42, 0.95);
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toolbar-quadrant-title {
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.4);
    margin-bottom: 2px;
}

/* Quadrant-specific colors for visual distinction */
.toolbar-quadrant[data-quadrant="size"] .toolbar-quadrant-title { color: rgba(99, 179, 237, 0.8); }
.toolbar-quadrant[data-quadrant="spacing"] .toolbar-quadrant-title { color: rgba(154, 230, 180, 0.8); }
.toolbar-quadrant[data-quadrant="style"] .toolbar-quadrant-title { color: rgba(246, 173, 85, 0.8); }
.toolbar-quadrant[data-quadrant="layout"] .toolbar-quadrant-title { color: rgba(183, 148, 244, 0.8); }

/* Control row within quadrant */
.toolbar-control {
    display: flex;
    align-items: center;
    gap: 6px;
}

.toolbar-control-label {
    font-size: 10px;
    color: rgba(255,255,255,0.5);
    min-width: 45px;
    white-space: nowrap;
}

.toolbar-control .section-toolbar-slider {
    flex: 1;
    min-width: 50px;
    max-width: 70px;
}

.toolbar-control .section-toolbar-color {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    padding: 0;
    cursor: pointer;
}

.toolbar-control .section-toolbar-select {
    flex: 1;
    padding: 4px 6px;
    font-size: 10px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 4px;
    color: white;
}

/* Toggle control */
.toolbar-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 10px;
    color: rgba(255,255,255,0.6);
}

.toolbar-toggle input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: var(--color-primary);
}

.toolbar-toggle:hover {
    color: rgba(255,255,255,0.9);
}

/* Button group (alignment, etc) */
.toolbar-btn-group {
    display: flex;
    gap: 2px;
    background: rgba(0,0,0,0.2);
    padding: 2px;
    border-radius: 4px;
}

.toolbar-btn-group button {
    width: 24px;
    height: 24px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 3px;
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.toolbar-btn-group button:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

.toolbar-btn-group button.active {
    background: var(--color-primary);
    color: white;
}

/* Toolbar drag handle */
.toolbar-drag {
    color: rgba(255,255,255,0.4);
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.toolbar-drag:hover {
    color: rgba(255,255,255,0.8);
}

/* Toolbar actions container */
.toolbar-actions {
    display: flex;
    gap: 4px;
}

/* Toolbar action button */
.toolbar-action-btn {
    width: 26px;
    height: 26px;
    padding: 0;
    background: rgba(255,255,255,0.08);
    border: none;
    border-radius: 5px;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.toolbar-action-btn:hover {
    background: rgba(255,255,255,0.15);
    color: white;
}

/* Toolbar save button */
.toolbar-save-btn {
    width: 26px;
    height: 26px;
    padding: 0;
    background: var(--color-primary);
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.toolbar-save-btn svg {
    width: 14px;
    height: 14px;
}

.toolbar-save-btn:hover {
    filter: brightness(1.1);
}

/* Quadrant row */
.toolbar-quadrant-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Slider */
.toolbar-slider {
    flex: 1;
    min-width: 50px;
    max-width: 80px;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255,255,255,0.15);
    border-radius: 2px;
    cursor: pointer;
}

.toolbar-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--color-primary);
    cursor: pointer;
}

/* Select dropdown */
.toolbar-select {
    flex: 1;
    max-width: 80px;
    padding: 4px 6px;
    font-size: 10px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 4px;
    color: white;
    cursor: pointer;
}

.toolbar-select option {
    background: #1e293b;
    color: white;
}

/* Color picker */
.toolbar-color {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    padding: 0;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.toolbar-color::-webkit-color-swatch-wrapper {
    padding: 2px;
}

.toolbar-color::-webkit-color-swatch {
    border-radius: 2px;
    border: none;
}

/* Icon button */
.toolbar-icon-btn {
    width: 24px;
    height: 24px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 3px;
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    font-size: 12px;
}

.toolbar-icon-btn:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

.toolbar-icon-btn.active {
    background: var(--color-primary);
    color: white;
}

/* Wrap button group for multiple rows */
.toolbar-btn-group-wrap {
    flex-wrap: wrap;
    width: fit-content;
}

/* Resize handle for toolbar */
.toolbar-resize-handle {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 20px;
    height: 20px;
    cursor: nwse-resize;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.3);
    transition: color 0.15s;
    z-index: 10;
}

.toolbar-resize-handle:hover {
    color: rgba(255,255,255,0.7);
}

.toolbar-resize-handle:active {
    color: var(--color-primary);
}

/* Make toolbar resizable - sliders expand with width */
.section-toolbar-unified {
    min-width: 320px;
    max-width: 800px;
}

.section-toolbar-unified.resizing {
    transition: none;
    user-select: none;
}

/* Sliders expand to fill available space when toolbar is wider */
.section-toolbar-unified .toolbar-slider {
    flex: 1;
    min-width: 50px;
    max-width: none; /* Remove max-width constraint */
}

.section-toolbar-unified .toolbar-quadrant-row {
    flex: 1;
}

/* Legacy support - keep old quadrant styles working */
.section-toolbar-quadrant {
    flex-direction: column;
    padding: 0;
    min-width: auto;
}

.section-toolbar-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.2);
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.section-toolbar-header .section-toolbar-drag {
    margin: 0;
}

.section-toolbar-header .section-toolbar-label {
    flex: 1;
}

.section-toolbar-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: rgba(255,255,255,0.1);
}

.toolbar-quadrant {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px 12px;
    background: #2c3e50;
}

.quadrant-title {
    font-size: 9px;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.quadrant-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

.quadrant-controls .section-toolbar-slider {
    flex: 1;
    min-width: 50px;
    max-width: 70px;
}

.quadrant-controls .section-toolbar-mini-label {
    min-width: 28px;
}

.quadrant-controls .section-toolbar-toggle {
    margin: 0;
}

/* Navigation - Same width as container */
.nav {
    background: var(--nav-bg-color, #3d3d3d);
    max-width: var(--container-max);
    margin: 0 auto;
}

/* Navigation Style Variants */
.nav.nav-light {
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.nav.nav-light .nav-item {
    border-right-color: rgba(0, 0, 0, 0.08);
}

.nav.nav-light .nav-link {
    color: #333;
}

.nav.nav-light .nav-link:hover,
.nav.nav-light .nav-link.active {
    background: #1e1f21;
    color: #fff;
}

.nav.nav-primary {
    background: var(--color-primary);
}

.nav.nav-primary .nav-link:hover,
.nav.nav-primary .nav-link.active {
    background: var(--color-primary-dark);
}

/* Nav Inner - padding for content */
.nav-inner {
    padding: 0 var(--spacing-xl) 0 var(--nav-left-indent, 0px);
    display: flex;
    justify-content: space-between;
    align-items: stretch;
}

.nav-list {
    display: flex;
    justify-content: flex-start;
    gap: var(--nav-gap, 0px);
    align-items: stretch;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-item {
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
}

.nav-link {
    color: var(--nav-text-color, rgba(255, 255, 255, 0.9));
    font-weight: 500;
    text-transform: var(--nav-text-transform, uppercase);
    font-size: var(--nav-font-size, 14px);
    letter-spacing: var(--nav-letter-spacing, 0.5px);
    padding: var(--nav-padding-v, 12px) var(--nav-padding-h, 24px);
    border-radius: var(--border-radius);
    line-height: 1.4;
    display: flex;
    align-items: center;
    height: 100%;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: white;
    background: var(--color-primary);
}

/* Cart Area (Top Right) */
.header-cart-area {
    display: flex;
    align-items: stretch;
    gap: var(--spacing-lg);
}

.cart-widget {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    background: var(--color-bg-white);
    padding: 0 var(--spacing-md);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    height: var(--cart-height, 36px);
    width: var(--cart-width, 120px);
    box-sizing: border-box;
}

.cart-icon-link {
    position: relative;
    display: flex;
    align-items: center;
    color: var(--color-text);
    padding: var(--spacing-xs);
}

.cart-icon-link:hover {
    color: var(--color-primary);
}

.cart-icon {
    width: var(--cart-icon-size, 24px);
    height: var(--cart-icon-size, 24px);
}

.cart-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--color-primary);
    color: white;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-count:empty,
.cart-count[data-count="0"] {
    display: none;
}

.cart-info {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.cart-label {
    font-size: var(--font-size-xs);
    color: var(--color-text-muted);
}

.cart-total {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--color-text);
}

.cart-checkout-btn {
    white-space: nowrap;
    padding: 0;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    height: var(--cart-height, 36px);
    width: var(--button-width, 100px);
    line-height: 1;
    box-sizing: border-box;
}

/* Language Switcher (in header area) */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: var(--font-size-sm);
}

.lang-link {
    color: var(--color-text-muted);
    font-weight: 500;
    padding: var(--spacing-xs);
    transition: color var(--transition);
}

.lang-link:hover {
    color: var(--color-primary);
}

.lang-link.active {
    color: var(--color-primary);
    font-weight: 600;
}

.lang-divider {
    color: var(--color-border);
}

/* Language Switcher in Navbar */
.nav-lang-switcher {
    display: flex;
    align-items: center;
    padding: 0 var(--spacing-md);
}

.nav-lang-switcher .lang-link {
    color: rgba(255, 255, 255, 0.7);
    padding: var(--spacing-xs) var(--spacing-sm);
}

.nav-lang-switcher .lang-link:hover {
    color: white;
}

.nav-lang-switcher .lang-link.active {
    color: white;
    font-weight: 600;
}

.nav-lang-switcher .lang-divider {
    color: rgba(255, 255, 255, 0.3);
}

/* VAT Toggle - Simple text style in header */
.vat-toggle-simple {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: var(--font-size-xs);
}

.vat-option {
    color: var(--color-text-muted);
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 3px;
    transition: all var(--transition);
}

.vat-option:hover {
    color: var(--color-text);
}

.vat-option.active {
    color: var(--color-primary);
    font-weight: 600;
    background: rgba(52, 152, 219, 0.1);
}

.vat-divider {
    color: var(--color-border);
}

/* VAT Toggle Switch - Cart Page */
.cart-vat-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md);
    background: var(--color-bg-alt);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-md);
}

.cart-vat-label {
    font-size: var(--font-size-sm);
    color: var(--color-text);
    font-weight: 500;
}

/* Modern iOS-style switch */
.vat-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
    flex-shrink: 0;
}

.vat-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.vat-switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #ccc;
    border-radius: 28px;
    transition: 0.3s;
}

.vat-switch-slider::before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.vat-switch input:checked + .vat-switch-slider {
    background: var(--color-primary);
}

.vat-switch input:checked + .vat-switch-slider::before {
    transform: translateX(22px);
}

.vat-switch input:focus + .vat-switch-slider {
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    width: 30px;
    height: 24px;
    position: relative;
}

.hamburger,
.hamburger::before,
.hamburger::after {
    width: 100%;
    height: 3px;
    background: var(--color-text);
    border-radius: 2px;
    transition: var(--transition);
}

.hamburger {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    background-color: #2c3e50;
    background-image: var(--hero-overlay, none), url('../images/hero1.png');
    background-position: var(--hero-focal-x, 50%) var(--hero-focal-y, 50%);
    background-size: cover;
    position: relative;
    background-repeat: no-repeat;
    color: white;
    padding: var(--spacing-3xl) 0;
    text-align: var(--hero-text-align, center);
    margin: 0 0 var(--spacing-xl);
    min-height: var(--hero-height, 450px);
    display: flex;
    align-items: var(--hero-vertical-align, center);
    justify-content: var(--hero-horizontal-align, center);
    border-radius: 0;
    /* Use outline instead of border - outlines don't affect box model,
       so absolutely positioned children (like toolbars) won't shift */
    border: none;
    outline: var(--hero-border-width, 1px) solid var(--hero-border-color, var(--color-border));
    outline-offset: calc(-1 * var(--hero-border-width, 1px));
}

/* Full-width hero - breaks out of container */
.hero.full-width {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
}


/* Hero content wrapper - positioned within hero */
.hero-content-wrapper {
    position: relative;
    display: inline-block;
    text-align: var(--hero-text-align, center);
    max-width: 600px;
    padding: 20px;
    z-index: 2;
    /* Position controlled by CSS variables */
    transform: translate(var(--hero-content-x, 0px), var(--hero-content-y, 0px));
}

/* Legacy container support */
.hero .container {
    width: 100%;
    padding: 0 var(--spacing-xl);
    transform: translate(var(--hero-title-offset-x, 0px), var(--hero-title-offset-y, 0px));
    z-index: 2;
    position: relative;
}

.hero-title {
    font-size: var(--hero-title-size, 36px);
    font-weight: 700;
    margin-bottom: var(--spacing-md);
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: var(--hero-subtitle-size, 18px);
    opacity: 0.95;
    margin-bottom: var(--spacing-xl);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Hero Overlay Effects - CSS variable driven */
.hero.overlay-solid::before,
.hero.overlay-gradient::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.hero.overlay-solid::before {
    background: var(--hero-overlay-color, rgba(0, 0, 0, 0.5));
}

/* Gradient directions - uses CSS variables for color, opacity, extent */
.hero.overlay-gradient[data-overlay-dir="top"]::before {
    background: linear-gradient(to bottom, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="bottom"]::before {
    background: linear-gradient(to top, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="left"]::before {
    background: linear-gradient(to right, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="right"]::before {
    background: linear-gradient(to left, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="tl"]::before {
    background: linear-gradient(135deg, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="tr"]::before {
    background: linear-gradient(225deg, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="bl"]::before {
    background: linear-gradient(45deg, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}
.hero.overlay-gradient[data-overlay-dir="br"]::before {
    background: linear-gradient(315deg, var(--hero-overlay-color, rgba(0,0,0,0.7)), transparent var(--hero-overlay-extent, 70%));
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-xl);
    font-weight: 600;
    border-radius: var(--btn-border-radius);
    transition: all var(--transition);
    cursor: pointer;
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-secondary:hover {
    background: var(--color-primary);
    color: white;
}

.btn-white {
    background: white;
    color: var(--color-primary);
    border-color: white;
    font-weight: 600;
    text-shadow: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.btn-white:hover {
    background: rgba(255, 255, 255, 0.95);
    border-color: white;
    color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* Hero CTA button - needs higher specificity to override .btn-lg */
.hero-content-wrapper .hero-cta.btn {
    font-size: var(--hero-cta-font-size, 16px) !important;
    padding: var(--hero-cta-padding-v, 14px) var(--hero-cta-padding-h, 32px) !important;
}

.hero-cta.hidden {
    display: none !important;
}

.btn-sm {
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: var(--font-size-sm);
}

.btn-lg {
    padding: var(--spacing-lg) var(--spacing-2xl);
    font-size: var(--font-size-lg);
}

.btn-block {
    width: 100%;
}

/* ============================================
   Section Titles
   ============================================ */
.section-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    margin-bottom: var(--spacing-xl);
    text-align: center;
    color: var(--color-text);
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--color-primary);
    margin: var(--spacing-md) auto 0;
    border-radius: var(--border-radius);
}

/* ============================================
   Partners Section (Home Page) - Logo Cards Display
   ============================================ */
.partners-section {
    text-align: center;
    background: var(--partners-bg, white);
    border: var(--partners-border, 1px solid var(--color-border));
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    margin-top: var(--spacing-lg);
    margin-left: auto;
    margin-right: auto;
}

/* Full-width partners - breaks out of container */
.partners-section.full-width {
    width: 100vw;
    max-width: none;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    border-radius: 0;
    border-left: none;
    border-right: none;
}

/* ============================================
   Partners Cards Grid (Home Page)
   Always 2 rows layout
   ============================================ */
.partners-cards-wrapper {
    display: flex;
    flex-direction: column;
    gap: var(--row-gap, 12px);
    align-items: center;
}

.partners-cards-row {
    display: flex;
    flex-wrap: wrap;
    gap: var(--card-gap, 15px);
    justify-content: center;
}

.partners-cards-wrapper .partner-card-item {
    display: block;
    background: var(--color-bg-white);
    border: 1px solid var(--color-border-light);
    border-radius: var(--card-radius, 8px);
    overflow: hidden;
    transition: all 0.2s ease;
    text-decoration: none;
    width: var(--card-width, 80px);
    height: var(--card-height, 60px);
    flex-shrink: 0;
}

.partners-cards-wrapper .partner-card-item:hover {
    border-color: var(--color-primary);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.partners-cards-wrapper .partner-card-logo {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--card-inner-pad, 10px);
    background: var(--color-bg-white);
}

.partners-cards-wrapper .partner-card-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.partners-cards-wrapper .partner-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-light);
    color: var(--color-text-muted);
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
}

/* Responsive for cards grid */
@media (max-width: 768px) {
    .partners-cards-wrapper {
        gap: var(--row-gap, 8px);
    }
    .partners-cards-row {
        gap: var(--card-gap, 8px);
    }
}

/* ============================================
   Product Grid
   ============================================ */
.products-grid {
    display: grid;
    grid-template-columns: repeat(var(--product-grid-columns, 3), 1fr);
    gap: var(--product-grid-gap, var(--spacing-xl));
}

/* Product Card */
.product-card {
    background: var(--color-bg-white);
    border-radius: var(--product-border-radius, var(--border-radius));
    overflow: hidden;
    border: var(--product-border-width, 1px) solid var(--product-border-color, var(--color-border));
    transition: all var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
    box-shadow: 0 4px var(--product-shadow-blur, 10px) rgba(0, 0, 0, var(--product-shadow-opacity, 0));
}

.product-card:hover {
    box-shadow: 0 8px calc(var(--product-shadow-blur, 10px) * 1.5) rgba(0, 0, 0, calc(var(--product-shadow-opacity, 0) + 0.1));
}

.product-card-image {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: var(--color-bg-light);
    border-radius: var(--border-radius);
}

.product-card-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.product-card:hover .product-card-image::after {
    opacity: 1;
}

/* Sale Badge */
.sale-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #e74c3c;
    color: white;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--border-radius);
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Black Friday Sale Badge (Product Cards) - Minimalist */
.sale-badge.black-friday,
.sale-badge.bf-badge {
    background: #1a1a1a;
    color: white;
    font-size: 11px;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: 3px;
    text-align: center;
}

/* 3D View Button on Product Cards */
.product-3d-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: var(--border-radius);
    padding: 6px 10px;
    cursor: pointer;
    z-index: 10;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: background 0.2s, transform 0.2s;
}
.product-3d-btn:hover {
    background: #2980b9;
    transform: scale(1.05);
}
.product-3d-btn svg {
    flex-shrink: 0;
}

/* 3D Buttons Container */
.product-3d-buttons {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 10;
}
.product-3d-buttons .product-3d-btn {
    position: static;
}
.product-3d-progressive {
    background: #9b59b6 !important;
    padding: 6px 8px !important;
    text-decoration: none;
}
.product-3d-progressive:hover {
    background: #8e44ad !important;
}
.product-3d-simple {
    background: #1abc9c !important;
    padding: 6px 8px !important;
    text-decoration: none;
}
.product-3d-simple:hover {
    background: #16a085 !important;
}

/* 3D View Button for Product Detail Page */
.btn-3d-view {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
}

/* Black Friday product card - subtle styling */
.product-card.black-friday-deal {
    /* No special border, keep default card style */
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition);
}

.product-card:hover .product-card-image img {
    transform: scale(1.05);
}

.product-card-body {
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    flex: 1;
}

.product-card-category {
    display: none; /* Hidden by default, shown via layout CSS */
    align-items: center;
    gap: 4px;
    font-size: var(--font-size-xs);
    color: var(--color-primary);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: var(--spacing-xs);
    text-decoration: none;
    transition: opacity 0.2s;
}

.product-card-category .category-icon {
    display: inline-flex;
    flex-shrink: 0;
}

.product-card-category .category-icon svg {
    width: 12px;
    height: 12px;
}

.product-card-category:hover {
    opacity: 0.7;
}

.product-card-sku {
    font-size: var(--font-size-xs);
    color: var(--color-text-muted, #888);
    font-family: var(--font-mono, monospace);
    margin-bottom: var(--spacing-xs);
    display: none; /* Hidden by default, shown via layout CSS */
}

.product-card-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: var(--spacing-sm);
    line-height: 1.3;
    min-height: 2.6em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-title a {
    color: inherit;
}

.product-card-title a:hover {
    color: var(--color-primary);
}

/* Product description - hidden by default, shown via layout CSS */
.product-card-description {
    display: none;
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
    line-height: 1.5;
    margin-bottom: var(--spacing-sm);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.product-card-price {
    display: none; /* Hidden by default, shown via layout CSS */
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: var(--spacing-md);
}

.vat-label {
    font-size: var(--font-size-xs);
    font-weight: 400;
    color: var(--color-text-muted);
    margin-left: var(--spacing-xs);
}

/* Discount Price Styles */
.price-original {
    text-decoration: line-through;
    color: #1a1a1a;
    font-size: 0.85em;
    font-weight: 600;
}

.price-discounted {
    color: #e74c3c;
    font-weight: 700;
}

.product-price-wrapper {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.product-sale-badge {
    background: #e74c3c;
    color: white;
    font-size: 14px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: var(--border-radius);
}

/* Black Friday Special Badge - Minimalist PDP */
.product-sale-badge.black-friday {
    background: #1a1a1a;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 4px;
}

/* Black Friday Product Card - Minimalist */
.product-card.black-friday {
    /* Keep default card styling */
}

/* Black Friday on Product Single Page - Minimalist */
.product-single.black-friday .product-sale-badge {
    background: #1a1a1a;
    font-size: 16px;
    padding: 8px 14px;
}

.product-card-actions {
    display: none; /* Hidden by default, shown via layout CSS */
    gap: var(--spacing-sm);
    margin-top: auto;
    padding-top: var(--spacing-md);
}

.product-card-actions .btn {
    flex: 1;
}

/* Row mode (single column) - horizontal card layout */
.products-grid[style*="--product-grid-columns: 1"],
.products-grid[style*="--product-grid-columns:1"] {
    gap: var(--spacing-md);
}

.products-grid[style*="--product-grid-columns: 1"] .product-card,
.products-grid[style*="--product-grid-columns:1"] .product-card {
    flex-direction: row;
    max-height: 180px;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-image,
.products-grid[style*="--product-grid-columns:1"] .product-card-image {
    width: 200px;
    min-width: 200px;
    aspect-ratio: unset;
    height: 100%;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-body,
.products-grid[style*="--product-grid-columns:1"] .product-card-body {
    flex-direction: row;
    align-items: center;
    gap: var(--spacing-lg);
    padding: var(--spacing-md) var(--spacing-lg);
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-title,
.products-grid[style*="--product-grid-columns:1"] .product-card-title {
    min-height: unset;
    flex: 1;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-description,
.products-grid[style*="--product-grid-columns:1"] .product-card-description {
    display: block;
    flex: 2;
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-price,
.products-grid[style*="--product-grid-columns:1"] .product-card-price {
    margin-bottom: 0;
    white-space: nowrap;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-actions,
.products-grid[style*="--product-grid-columns:1"] .product-card-actions {
    margin-top: 0;
    padding-top: 0;
}

.products-grid[style*="--product-grid-columns: 1"] .product-card-actions .btn,
.products-grid[style*="--product-grid-columns:1"] .product-card-actions .btn {
    flex: none;
    white-space: nowrap;
}

/* ============================================
   Categories Section (Home Page) - Outside container, adjustable spacing
   ============================================ */
.categories-section {
    padding: 0 var(--categories-inset, 0px);
    margin-bottom: var(--categories-margin-bottom, 0px);
    background: none;
}

.categories-section .category-grid {
    max-width: calc(var(--container-max, 1400px) - var(--categories-inset, 0px) * 2);
    margin: 0 auto;
    padding: 0;
}

/* Featured Products Section */
.featured-section {
    margin-top: var(--section-spacing, var(--spacing-xl));
    padding: var(--spacing-xl) 0;
}

/* ============================================
   Category Grid - columns determined by --cat-columns variable
   ============================================ */
.category-grid {
    display: grid;
    grid-template-columns: repeat(var(--cat-columns, 5), 1fr);
    gap: var(--cat-gap, 0px);
    margin-bottom: 0;
}

/* ============================================
   Hovereffect Style (salons.lv style)
   ============================================ */
.hovereffect-grid {
    margin: 0 auto;
    max-width: var(--container-max, 1280px);
}

.hovereffect {
    width: 100%;
    height: 100%;
    float: left;
    overflow: hidden;
    position: relative;
    text-align: center;
    cursor: pointer;
    background: #11a4d8;
    aspect-ratio: 1;
    box-sizing: border-box;
    box-shadow: 0 4px 12px rgba(0, 0, 0, var(--cat-element-shadow-opacity, 0));
    transition: box-shadow 0.2s ease;
}

.hovereffect:hover {
    box-shadow: 0 6px 16px rgba(0, 0, 0, calc(var(--cat-element-shadow-opacity, 0) + 0.1));
}

/* Border overlay - sits on top of everything */
.hovereffect::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 10;
    box-shadow: var(--cat-border-shadow, none);
}

.hovereffect img.img-responsive {
    display: block;
    position: relative;
    max-width: none;
    width: calc(100% + 20px);
    height: 100%;
    object-fit: cover;
    -webkit-transition: opacity 0.35s, -webkit-transform 0.35s;
    transition: opacity 0.35s, transform 0.35s;
    -webkit-transform: translate3d(-10px,0,0);
    transform: translate3d(-10px,0,0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

.hovereffect:hover img.img-responsive {
    opacity: 0.4;
    -webkit-transform: translate3d(0,0,0);
    transform: translate3d(0,0,0);
}

.hovereffect a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    text-decoration: none;
}

.hovereffect .overlay {
    width: 100%;
    height: 100%;
    position: absolute;
    overflow: hidden;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 0;
}

.hovereffect .overlay h2 {
    color: #fff;
    text-align: center;
    position: relative;
    font-size: 14px;
    font-weight: 400;
    overflow: hidden;
    padding: 0.5em 0.5em;
    background: rgba(0, 0, 0, 0.5);
    margin: 0;
    line-height: 1.3;
}

.hovereffect .overlay h2:after {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #fff;
    content: '';
    -webkit-transition: -webkit-transform 0.35s;
    transition: transform 0.35s;
    -webkit-transform: translate3d(-100%,0,0);
    transform: translate3d(-100%,0,0);
}

.hovereffect:hover .overlay h2:after {
    -webkit-transform: translate3d(0,0,0);
    transform: translate3d(0,0,0);
}

.hovereffect .overlay p {
    color: #FFF;
    opacity: 0;
    font-size: 12px;
    padding: 0.3em 0.5em;
    margin: 0;
    background: rgba(0, 0, 0, 0.3);
    -webkit-transition: opacity 0.35s, -webkit-transform 0.35s;
    transition: opacity 0.35s, transform 0.35s;
    -webkit-transform: translate3d(100%,0,0);
    transform: translate3d(100%,0,0);
}

.hovereffect:hover .overlay p {
    opacity: 1;
    -webkit-transform: translate3d(0,0,0);
    transform: translate3d(0,0,0);
}

/* Legacy category-tile styles (keep for other pages if needed) */
.category-tile {
    position: relative;
    background: var(--color-bg-white);
    overflow: hidden;
    aspect-ratio: 1;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
    min-width: 0;
    min-height: 0;
}

.category-tile:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-color: var(--color-primary);
}

/* Allow dropdown to show outside tile on hover */
.category-tile.has-children:hover {
    overflow: visible;
}

.category-tile-link {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    text-decoration: none;
    color: inherit;
    border-radius: var(--border-radius);
    overflow: hidden;
}

/* Title bar at TOP - fixed height, text truncates */
.category-tile-info-static {
    padding: var(--spacing-sm) var(--spacing-xs);
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    text-align: center;
    height: var(--cat-title-height, 40px);
    max-height: var(--cat-title-height, 40px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    transition: background 0.2s ease;
    flex-shrink: 0;
    flex-grow: 0;
}

.category-tile:hover .category-tile-info-static {
    background: var(--color-primary);
}

.category-tile.active .category-tile-info-static {
    background: var(--color-primary);
}

.category-tile-name {
    font-weight: 600;
    font-size: var(--cat-font-size, 13px);
    line-height: 1.2;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    width: 100%;
}

.category-tile-count {
    font-size: var(--font-size-xs);
    opacity: 0.8;
    line-height: 1;
    flex-shrink: 0;
}

/* Has children indicator */
.category-tile.has-children .category-tile-info-static::after {
    content: "▼";
    font-size: 8px;
    margin-top: 2px;
    opacity: 0.7;
}

/* Image fills remaining space */
.category-tile-image {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    overflow: hidden;
    position: relative;
    min-height: 0;
}

.category-tile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.category-tile-placeholder {
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: #f0f0f0;
}

.category-tile:hover .category-tile-placeholder {
    background: #e8e8e8;
}

/* Overlay with title - appears on hover (for detailed view) */
.category-tile-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--spacing-md);
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.6) 60%, transparent 100%);
    color: white;
    text-align: center;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    min-height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.category-tile:hover .category-tile-info {
    transform: translateY(0);
}

/* Subcategory Dropdown */
.category-tile-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}

.category-tile.has-children:hover .category-tile-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.category-tile-dropdown-inner {
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    border-top: 3px solid var(--color-primary);
    box-shadow: var(--shadow-lg);
    max-height: 300px;
    overflow-y: auto;
}

.category-tile-sub {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-sm) var(--spacing-md);
    text-decoration: none;
    color: var(--color-text);
    font-size: var(--font-size-sm);
    border-bottom: 1px solid var(--color-border-light);
    transition: background 0.15s ease, color 0.15s ease;
}

.category-tile-sub:last-child {
    border-bottom: none;
}

.category-tile-sub:hover {
    background: #e8f4fc;
    color: var(--color-primary);
}

.category-tile-sub.active {
    background: rgba(52, 152, 219, 0.15);
    color: var(--color-primary);
    font-weight: 600;
}

.category-tile-sub .sub-name {
    flex: 1;
}

.category-tile-sub .sub-count {
    color: var(--color-text-muted);
    font-size: var(--font-size-xs);
}

/* ============================================
   Background Patterns - Applied to .main for visibility
   Using ::before pseudo-element for opacity control
   ============================================ */
:root {
    --pattern-opacity: 0.5;
}

/* Base styles for pattern containers - pattern applied to body pseudo-element */
[class*="bg-pattern-"]::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    opacity: var(--pattern-opacity);
    z-index: -1; /* Behind all content, no stacking context issues */
}

/* Make header and main transparent to show pattern */
body[class*="bg-pattern-"] .header {
    background: rgba(250, 250, 250, 0.95);
}

/* Main no longer needs z-index since pattern is now behind everything */

.bg-pattern-dots::before {
    background-image: radial-gradient(circle, #999 1px, transparent 1px);
    background-size: 16px 16px;
}

.bg-pattern-grid::before {
    background-image:
        linear-gradient(to right, #999 1px, transparent 1px),
        linear-gradient(to bottom, #999 1px, transparent 1px);
    background-size: 24px 24px;
}

.bg-pattern-diagonal::before {
    background-image: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 8px,
        #999 8px,
        #999 9px
    );
}

.bg-pattern-crosshatch::before {
    background-image:
        repeating-linear-gradient(45deg, #999, #999 1px, transparent 1px, transparent 8px),
        repeating-linear-gradient(-45deg, #999, #999 1px, transparent 1px, transparent 8px);
}

.bg-pattern-subtle::before {
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23666666' fill-rule='evenodd'%3E%3Ccircle cx='3' cy='3' r='1.5'/%3E%3Ccircle cx='13' cy='13' r='1.5'/%3E%3C/g%3E%3C/svg%3E");
}

/* ============================================
   Single Product Page
   ============================================ */
.product-single {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--spacing-2xl);
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

/* Description Below Layout - hides inline description when separate section is used */
.product-single.description-below .product-description {
    display: none;
}

/* Description Section (displayed below product grid) */
.product-description-section {
    margin-top: var(--spacing-xl);
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-xl);
}

.product-description-full {
    font-size: var(--font-size-base);
    line-height: 1.7;
    color: var(--color-text);
}

.product-gallery {
    background: var(--color-bg-light);
    max-width: 600px;
}

.product-gallery-main {
    overflow: hidden;
    position: relative;
    background: var(--color-bg-light);
}

.product-gallery-main img {
    display: block;
    max-width: 100%;
    height: auto;
    transition: opacity 0.3s ease;
    background: var(--color-bg-light);
}

/* Gallery Navigation */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s;
    z-index: 2;
}

.product-gallery-main:hover .gallery-nav {
    opacity: 1;
}

.gallery-nav:hover {
    background: white;
}

.gallery-prev {
    left: 10px;
}

.gallery-next {
    right: 10px;
}

.gallery-counter {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 4px 10px;
    font-size: var(--font-size-sm);
    z-index: 2;
}

/* Slide Animation */
.product-gallery-main img {
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.product-gallery-main img.slide-out-left {
    transform: translateX(-100%);
    opacity: 0;
}

.product-gallery-main img.slide-in-right {
    transform: translateX(100%);
    opacity: 0;
}

/* Pagination Dots */
.gallery-pagination {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 3;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
}

.gallery-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-dot:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: scale(1.2);
}

.gallery-dot.active {
    background: white;
    transform: scale(1.2);
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.6);
}

.product-gallery-thumbs {
    display: flex;
    gap: var(--product-thumb-gap, 8px);
    padding: var(--spacing-md);
    flex-wrap: wrap;
}

.product-gallery-thumb {
    width: var(--product-thumb-size, 80px);
    aspect-ratio: 4/3;
    border-radius: var(--border-radius);
    overflow: hidden;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity var(--transition);
    border: 2px solid transparent;
    flex-shrink: 0;
    background: var(--color-bg-light);
}

.product-gallery-thumb:hover,
.product-gallery-thumb.active {
    opacity: 1;
    border-color: var(--color-primary);
}

.product-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.product-info {
    padding: var(--spacing-2xl);
}

.product-category {
    font-size: var(--font-size-sm);
    color: var(--color-primary);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: 6px;
}

.category-icon {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.category-icon svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
}

.product-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: var(--spacing-sm);
    line-height: 1.3;
}

.product-meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md) var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    font-size: var(--font-size-sm);
    color: var(--color-text-light);
}

.product-meta-info span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.product-meta-info strong {
    color: var(--color-text);
    font-weight: 600;
}

.product-extended-desc {
    font-size: var(--font-size-base);
    color: var(--color-text-light);
    line-height: 1.6;
    margin-bottom: var(--spacing-lg);
    padding: var(--spacing-md);
    background: var(--color-surface);
    border-radius: var(--border-radius);
    border-left: 3px solid var(--color-primary);
}

.product-price {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: var(--spacing-md);
}

/* Product Share Buttons */
.product-share {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    padding: var(--spacing-sm) 0;
}

.share-label {
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
}

.share-buttons {
    display: flex;
    gap: var(--spacing-xs);
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--color-border);
    background: var(--color-bg-white);
    color: var(--color-text-light);
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.share-btn.share-facebook:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: white;
}

.share-btn.share-twitter:hover {
    background: #000;
    border-color: #000;
    color: white;
}

.share-btn.share-whatsapp:hover {
    background: #25d366;
    border-color: #25d366;
    color: white;
}

.share-btn.share-copy:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
}

.share-btn.share-copy.copied {
    background: var(--color-success);
    border-color: var(--color-success);
    color: white;
}

/* AR View Button */
.product-ar-view {
    margin-bottom: var(--spacing-lg);
}

.btn-ar {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: var(--font-size-sm);
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.btn-ar:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-ar svg {
    flex-shrink: 0;
}

.product-description {
    color: var(--color-text-light);
    margin-bottom: var(--spacing-xl);
    line-height: 1.8;
}

.product-specs {
    margin-bottom: var(--spacing-xl);
}

.product-specs h3 {
    font-size: var(--font-size-lg);
    margin-bottom: var(--spacing-md);
}

.product-specs-list {
    display: grid;
    gap: var(--spacing-sm);
}

.product-specs-item {
    display: flex;
    padding: var(--spacing-sm) 0;
    border-bottom: 1px solid var(--color-border-light);
}

.product-specs-label {
    font-weight: 600;
    min-width: 150px;
    color: var(--color-text);
}

.product-specs-value {
    color: var(--color-text-light);
}

.product-add-to-cart {
    display: flex;
    gap: var(--spacing-md);
    align-items: center;
}

.quantity-input {
    display: flex;
    align-items: center;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.quantity-btn {
    width: 40px;
    height: 40px;
    background: var(--color-bg-light);
    color: var(--color-text);
    font-size: var(--font-size-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--transition);
    border-radius: var(--btn-border-radius, 0);
}

.quantity-btn:hover {
    background: var(--color-border);
}

.quantity-btn:first-child {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.quantity-btn:last-child {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.quantity-input input {
    width: 60px;
    height: 40px;
    border: none;
    text-align: center;
    font-weight: 600;
    -moz-appearance: textfield;
}

.quantity-input input::-webkit-outer-spin-button,
.quantity-input input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ============================================
   Cart Page
   ============================================ */
.cart-page {
    max-width: 800px;
    margin: 0 auto;
}

.cart-items {
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
}

.cart-item {
    display: grid;
    grid-template-columns: 80px 1fr auto auto auto;
    gap: var(--spacing-md);
    align-items: center;
    padding: var(--spacing-md) var(--spacing-lg);
    border-bottom: 1px solid var(--color-border-light);
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: var(--border-radius);
    overflow: hidden;
    background: var(--color-bg-light);
    display: block;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    min-width: 0;
}

.cart-item-name {
    font-size: var(--font-size-base);
    font-weight: 500;
    margin: 0 0 4px 0;
    line-height: 1.3;
}

.cart-item-name a {
    color: var(--color-text);
}

.cart-item-name a:hover {
    color: var(--color-primary);
}

.cart-item-price {
    color: var(--color-text-muted);
    font-size: var(--font-size-sm);
}

.cart-item-controls {
    display: flex;
    align-items: center;
}

.cart-item-subtotal {
    font-size: var(--font-size-base);
    font-weight: 600;
    color: var(--color-text);
    min-width: 80px;
    text-align: right;
}

.cart-item-remove {
    background: none;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    padding: 8px;
    border-radius: var(--border-radius);
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item-remove:hover {
    color: var(--color-error);
    background: rgba(231, 76, 60, 0.1);
}

.cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-3xl);
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
}

.cart-empty h2 {
    margin-bottom: var(--spacing-lg);
    color: var(--color-text-light);
    font-weight: 500;
}

/* Cart Footer */
.cart-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: var(--spacing-lg);
    gap: var(--spacing-lg);
}

.cart-continue-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--color-text-muted);
    font-size: var(--font-size-sm);
    padding: var(--spacing-sm) 0;
}

.cart-continue-link:hover {
    color: var(--color-primary);
}

.cart-total-box {
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-lg);
    min-width: 280px;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
    font-size: var(--font-size-lg);
}

.cart-total-amount {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--color-primary);
}

.btn-checkout {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Legacy support */
.cart-summary {
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-xl);
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    padding: var(--spacing-sm) 0;
}

.cart-summary-total {
    font-size: var(--font-size-xl);
    font-weight: 700;
    border-top: 2px solid var(--color-border);
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-md);
}

.cart-summary-total .amount {
    color: var(--color-primary);
}

.cart-actions {
    display: flex;
    gap: var(--spacing-md);
    margin-top: var(--spacing-xl);
}

/* ============================================
   Checkout Page
   ============================================ */
.checkout-page {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: var(--spacing-xl);
    max-width: 900px;
    margin: 0 auto;
}

.checkout-form {
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-xl);
}

.checkout-form h2 {
    margin-bottom: var(--spacing-lg);
    font-size: var(--font-size-lg);
}

.form-row {
    display: grid;
    grid-template-columns: var(--product-gallery-width, 50%) 1fr;
    gap: var(--spacing-md);
}

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--color-text);
    font-size: var(--font-size-sm);
}

.form-label .required {
    color: var(--color-error);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-textarea {
    min-height: 80px;
    resize: vertical;
}

.order-summary {
    background: var(--color-bg-light);
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    height: fit-content;
    position: sticky;
    top: calc(120px + var(--spacing-lg));
}

.order-summary h2 {
    margin-bottom: var(--spacing-md);
    font-size: var(--font-size-lg);
}

.order-items {
    margin-bottom: var(--spacing-md);
}

.order-item {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 8px;
    padding: 8px 0;
    font-size: var(--font-size-sm);
    border-bottom: 1px solid var(--color-border-light);
}

.order-item:last-child {
    border-bottom: none;
}

.order-item-name {
    color: var(--color-text);
}

.order-item-qty {
    color: var(--color-text-muted);
}

.order-item-price {
    font-weight: 500;
    text-align: right;
}

.order-totals {
    border-top: 1px solid var(--color-border);
    padding-top: var(--spacing-md);
    margin-top: var(--spacing-sm);
}

.order-total-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: var(--font-size-sm);
    color: var(--color-text-light);
}

.order-total-final {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--color-text);
    padding-top: var(--spacing-sm);
    margin-top: var(--spacing-xs);
    border-top: 1px solid var(--color-border);
}

.order-total-final span:last-child {
    color: var(--color-primary);
}

.order-edit-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: var(--spacing-md);
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
}

.order-edit-link:hover {
    color: var(--color-primary);
}

/* Success/Error states */
.checkout-success {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-3xl);
}

.checkout-success .success-icon {
    color: var(--color-success);
    margin-bottom: var(--spacing-lg);
}

.checkout-success h2 {
    color: var(--color-success);
    margin-bottom: var(--spacing-md);
}

.checkout-success p {
    color: var(--color-text-light);
    margin-bottom: var(--spacing-xl);
}

.checkout-error {
    max-width: 500px;
    margin: var(--spacing-lg) auto;
    padding: var(--spacing-lg);
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.3);
    border-radius: var(--border-radius);
    color: var(--color-error);
}

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   Contact & About Pages
   ============================================ */
.page-content {
    max-width: 800px;
    margin: 0 auto;
}

.page-header {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
}

.page-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.products-count {
    display: block;
    font-size: var(--font-size-base);
    color: var(--color-text-muted);
    font-weight: 400;
}

.category-count {
    font-weight: 400;
    font-size: 0.85em;
    opacity: 0.7;
    margin-left: 2px;
}

.content-card {
    background: var(--color-bg-white);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    padding: var(--spacing-2xl);
}

.content-card p {
    margin-bottom: var(--spacing-lg);
    line-height: 1.8;
    color: var(--color-text-light);
}

.content-card p:last-child {
    margin-bottom: 0;
}

/* ============================================
   Breadcrumb
   ============================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    font-size: var(--font-size-sm);
    color: var(--color-text-muted);
    background: var(--color-bg-light);
    padding: var(--spacing-sm) var(--spacing-md);
    border-left: 3px solid var(--color-primary);
}

.breadcrumb a {
    color: var(--color-text-muted);
}

.breadcrumb a:hover {
    color: var(--color-primary);
}

.breadcrumb-separator {
    color: var(--color-border);
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    margin-top: auto;
    position: relative;
    z-index: 1;
}

.footer-main {
    padding: var(--spacing-2xl) 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1.3fr 1fr 1.5fr;
    gap: var(--spacing-2xl);
}

.footer-section {
    min-width: 0;
    padding-right: var(--spacing-md);
}

.footer-section:last-child {
    padding-right: 0;
}

.footer-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: white;
}

.footer-text {
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.7;
    font-size: var(--font-size-sm);
}

/* Footer Links List */
.footer-link-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-link-list li {
    margin-bottom: var(--spacing-sm);
}

.footer-link-list a {
    color: rgba(255, 255, 255, 0.75);
    font-size: var(--font-size-sm);
    transition: color var(--transition);
    display: inline-block;
    padding: 2px 0;
}

.footer-link-list a:hover {
    color: white;
}

.footer-logo {
    margin-top: var(--spacing-md);
}

.footer-logo-img {
    max-height: 50px;
    width: auto;
    opacity: 0.9;
}

/* Footer Contact Info */
.footer-info-list {
    list-style: none;
}

.footer-info-list li {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    color: rgba(255, 255, 255, 0.75);
    font-size: var(--font-size-sm);
}

.footer-info-list li svg {
    flex-shrink: 0;
    margin-top: 2px;
    stroke: var(--color-primary-light);
}

.footer-info-list a {
    color: rgba(255, 255, 255, 0.9);
    transition: color var(--transition);
}

.footer-info-list a:hover {
    color: white;
}

/* Footer Map */
.footer-map-container {
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: var(--spacing-sm);
}

.footer-map-container iframe {
    display: block;
}

.footer-map-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.75);
    font-size: var(--font-size-sm);
    transition: color var(--transition);
}

.footer-map-link:hover {
    color: white;
}

/* Footer Contact Form */
.footer-form-note {
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--font-size-xs);
    margin-bottom: var(--spacing-sm);
}

.footer-contact-form input,
.footer-contact-form textarea {
    width: 100%;
    padding: 10px 12px;
    margin-bottom: var(--spacing-sm);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius-sm);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: var(--font-size-sm);
    transition: border-color var(--transition), background var(--transition);
}

.footer-contact-form input::placeholder,
.footer-contact-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.footer-contact-form input:focus,
.footer-contact-form textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    background: rgba(255, 255, 255, 0.15);
}

.footer-contact-form textarea {
    resize: vertical;
    min-height: 80px;
}

.footer-contact-form .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.footer-form-status {
    font-size: var(--font-size-xs);
    margin-top: var(--spacing-sm);
    padding: 6px 10px;
    border-radius: var(--border-radius-sm);
}

.footer-form-status.loading {
    color: rgba(255, 255, 255, 0.7);
}

.footer-form-status.success {
    background: rgba(39, 174, 96, 0.2);
    color: #6be89e;
}

.footer-form-status.error {
    background: rgba(231, 76, 60, 0.2);
    color: #f5a5a0;
}

/* Footer Bottom */
.footer-bottom {
    background: rgba(0, 0, 0, 0.15);
    padding: var(--spacing-md) 0;
}

.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: var(--font-size-sm);
}

.footer-bottom p {
    margin: 0;
}

.footer-social {
    display: flex;
    gap: var(--spacing-sm);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transition: background var(--transition), transform var(--transition);
}

.social-link:hover {
    transform: scale(1.1);
}

.social-link.whatsapp:hover {
    background: #25d366;
}

/* ============================================
   Alerts
   ============================================ */
.alert {
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-lg);
}

.alert-success {
    background: rgba(39, 174, 96, 0.1);
    color: var(--color-success);
    border: 1px solid rgba(39, 174, 96, 0.2);
}

.alert-error {
    background: rgba(231, 76, 60, 0.1);
    color: var(--color-error);
    border: 1px solid rgba(231, 76, 60, 0.2);
}

/* ============================================
   Partners Page
   ============================================ */
.page-subtitle {
    color: var(--color-text-light);
    font-size: var(--font-size-lg);
    margin-top: var(--spacing-sm);
}

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: var(--spacing-lg);
}

/* Legacy partner card styles - replaced by configurable .partners-grid styles
   See lines ~940-1050 for new styles with CSS variables */

.partner-website:hover {
    color: var(--color-primary-dark);
}

/* Partner Slideshow */
.partner-slideshow {
    display: none;
    position: relative;
    width: 100%;
    background: var(--color-bg-light);
}

.slideshow-container {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.slideshow-images {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

.slideshow-images .slide {
    display: none;
    width: 100%;
}

.slideshow-images .slide.active {
    display: block;
}

.slideshow-images .slide img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    background: var(--color-bg-white);
}

.slideshow-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: var(--spacing-sm) var(--spacing-md);
    cursor: pointer;
    font-size: var(--font-size-lg);
    z-index: 10;
    transition: background var(--transition);
}

.slideshow-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.slideshow-prev {
    left: 0;
}

.slideshow-next {
    right: 0;
}

.slideshow-dots {
    text-align: center;
    padding: var(--spacing-sm) 0;
    background: var(--color-bg-light);
}

.slideshow-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin: 0 4px;
    padding: 0;
    background: var(--color-border);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: background var(--transition);
}

.slideshow-dot.active,
.slideshow-dot:hover {
    background: var(--color-primary);
}

/* Loading Spinner */
.loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--color-border-light);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: var(--spacing-md) auto;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.text-muted {
    color: var(--color-text-muted);
}

/* ============================================
   Partner Detail Page
   ============================================ */
#logo-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 20px 10px;
    border-bottom: 1px solid var(--color-border-light);
    margin-bottom: var(--spacing-lg);
}

#logo-container img {
    max-height: 80px;
    max-width: 45%;
    object-fit: contain;
}

.partner-page-container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    padding-top: var(--spacing-md);
}

.partner-text-content {
    flex: 1;
    min-width: 300px;
    display: flex;
    flex-direction: column;
}

.partner-text-content a {
    text-decoration: none;
    color: var(--color-primary);
}

.partner-text-content a:hover {
    text-decoration: underline;
}

#text-description {
    flex-grow: 1;
}

#text-description p {
    margin-bottom: 1em;
    line-height: 1.7;
    color: var(--color-text-light);
}

#text-links-container {
    flex-shrink: 0;
    margin-top: var(--spacing-md);
    border-top: 1px solid var(--color-border-light);
    padding-top: var(--spacing-md);
}

#text-links-container h3 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: var(--spacing-md);
}

#text-links-container ul {
    list-style-type: disc;
    list-style-position: inside;
    padding-left: 0;
}

#text-links-container li {
    margin-bottom: var(--spacing-sm);
}

.partner-slideshow-wrapper {
    flex: 1;
    min-width: 300px;
    max-width: 500px;
}

.partner-slideshow-container {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 400px;
    height: 500px;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    background-color: var(--color-bg-light);
}

.slideshow-inner {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: var(--border-radius);
}

.slideshow-track {
    display: flex;
    height: 100%;
    align-items: center;
    transition: transform .5s ease-in-out;
    will-change: transform;
}

.partner-slideshow-container .slide {
    flex: 0 0 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
}

.partner-slideshow-container .slide-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    filter: blur(200px) saturate(1.2);
    opacity: 0.6;
    z-index: 0;
    transform: scale(1.5);
}

.partner-slideshow-container .slide img {
    position: relative;
    z-index: 1;
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.slideshow-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, .4);
    color: #fff;
    border: none;
    border-radius: var(--border-radius);
    font-size: 24px;
    padding: 10px 15px;
    cursor: pointer;
    z-index: 5;
    opacity: 0;
    transition: opacity .3s ease;
    display: none;
}

.partner-slideshow-container:hover .slideshow-nav {
    opacity: 0.9;
}

.slideshow-nav:hover {
    opacity: 1 !important;
    background-color: rgba(0, 0, 0, .7);
}

.partner-slideshow-container .slideshow-dots {
    position: absolute;
    bottom: 15%;
    left: 50%;
    transform: translateX(-50%);
    display: none;
    gap: 10px;
    z-index: 5;
    padding: 5px 0;
}

.partner-slideshow-container .slideshow-dot {
    width: 12px;
    height: 12px;
    background-color: rgba(0, 0, 0, .3);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color .3s ease;
    padding: 0;
    border: none;
    position: relative;
}

.partner-slideshow-container .slideshow-dot:hover {
    background-color: rgba(0, 0, 0, .5);
}

.partner-slideshow-container .slideshow-dot.active {
    background-color: rgba(0, 0, 0, .7);
}

.partner-slideshow-container .slideshow-dot.active::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 4px;
    height: 4px;
    background-color: #fff;
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.slideshow-loading {
    color: var(--color-text-muted);
    padding: 20px;
    text-align: center;
}

.partner-official-link {
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border-light);
    text-align: center;
}

.partner-official-link .btn {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
}

/* Partner Card Link (listing page) */
.partner-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.partner-card-link:hover .partner-card {
    border-color: var(--color-primary);
    box-shadow: var(--shadow-md);
}

.partner-card-link .partner-card {
    transition: border-color var(--transition), box-shadow var(--transition);
}

/* Partner card info - uses CSS variables from grid */
/* Legacy .partner-card-info removed - now controlled by .partners-grid styles */

/* ============================================
   Admin Login
   ============================================ */
/* Admin buttons - fixed position top right */
.admin-login-btn,
.admin-menu {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.admin-login-btn {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
    cursor: pointer;
    padding: var(--spacing-sm) var(--spacing-md);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    transition: color var(--transition), background var(--transition);
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    font-size: var(--font-size-sm);
    border-radius: var(--border-radius);
}

.admin-login-btn svg {
    width: 24px;
    height: 24px;
}

.admin-login-btn:hover {
    color: var(--color-primary);
    background: white;
}

.admin-menu {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    background: rgba(255, 255, 255, 0.98);
    padding: var(--spacing-sm) var(--spacing-md);
    border: 1px solid var(--color-border);
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    border-radius: var(--border-radius);
}

.admin-menu svg {
    width: 22px;
    height: 22px;
}

.admin-link,
.admin-logout {
    color: var(--color-primary);
    padding: var(--spacing-xs);
    display: flex;
    align-items: center;
    transition: color var(--transition);
}

.admin-link:hover {
    color: var(--color-primary-dark);
}

.admin-logout {
    color: var(--color-text-muted);
}

.admin-logout:hover {
    color: var(--color-error);
}

/* Admin Overlay */
.admin-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: flex-end;
    align-items: flex-start;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.admin-overlay.active {
    display: flex;
}

.admin-login-modal {
    background: var(--color-bg-white);
    padding: var(--spacing-2xl);
    border-radius: var(--border-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 380px;
    position: relative;
    margin: 15px 20px 0 0;
}

.admin-modal-close {
    position: absolute;
    top: var(--spacing-md);
    right: var(--spacing-md);
    background: none;
    border: none;
    font-size: 24px;
    color: var(--color-text-muted);
    cursor: pointer;
    line-height: 1;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
    transition: all var(--transition);
}

.admin-modal-close:hover {
    background: var(--color-bg-light);
    color: var(--color-text);
}

.admin-login-modal h2 {
    margin-bottom: var(--spacing-xl);
    text-align: center;
    color: var(--color-text);
    font-size: var(--font-size-xl);
    font-weight: 600;
}

.admin-login-modal .form-group {
    margin-bottom: var(--spacing-lg);
}

.admin-login-modal label {
    display: block;
    margin-bottom: var(--spacing-xs);
    font-weight: 500;
    color: var(--color-text);
    font-size: var(--font-size-sm);
}

.admin-login-modal input[type="text"],
.admin-login-modal input[type="password"] {
    width: 100%;
    padding: var(--spacing-md);
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    transition: border-color var(--transition), box-shadow var(--transition);
    box-sizing: border-box;
}

.admin-login-modal input[type="text"]:focus,
.admin-login-modal input[type="password"]:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
}

.admin-login-modal .btn {
    padding: var(--spacing-md) var(--spacing-lg);
    font-size: var(--font-size-base);
    font-weight: 600;
    margin-top: var(--spacing-sm);
}

.admin-error {
    background: #fdf2f2;
    color: var(--color-error);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-lg);
    font-size: var(--font-size-sm);
    text-align: center;
    border: 1px solid rgba(231, 76, 60, 0.2);
}

/* Admin pages */
.admin-products-page {
    background: white;
    padding: var(--spacing-xl);
    border: 1px solid var(--color-border);
    margin-top: var(--spacing-lg);
}

/* ============================================
   Compact Mode Styles
   ============================================ */
html.compact {
    --spacing-xs: 2px;
    --spacing-sm: 4px;
    --spacing-md: 8px;
    --spacing-lg: 12px;
    --spacing-xl: 16px;
    --spacing-2xl: 24px;
    --spacing-3xl: 32px;
    --font-size-base: 14px;
    --font-size-sm: 12px;
    --font-size-xs: 11px;
    --font-size-lg: 16px;
    --font-size-xl: 20px;
    --font-size-2xl: 24px;
    --font-size-3xl: 28px;
}

html.compact .logo-img {
    height: var(--logo-height, 55px);
}

html.compact .hero {
    min-height: var(--hero-height, 450px);
    padding: var(--spacing-xl) 0;
}

html.compact .product-card-body {
    padding: var(--spacing-md);
}

html.compact .product-card-title {
    min-height: 2.6em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

html.compact .product-card-image {
    aspect-ratio: 4/3;
}

html.compact .btn {
    padding: var(--spacing-sm) var(--spacing-md);
}

html.compact .btn-lg {
    padding: var(--spacing-md) var(--spacing-lg);
}

html.compact .btn-sm {
    padding: var(--spacing-xs) var(--spacing-sm);
}

html.compact .section-title {
    margin-bottom: var(--spacing-lg);
}

html.compact .section-title::after {
    margin-top: var(--spacing-sm);
}

html.compact .products-grid {
    gap: var(--product-grid-gap, var(--spacing-md));
}

html.compact .content-card {
    padding: var(--spacing-lg);
}

html.compact .footer-main {
    padding: var(--spacing-xl) 0;
}

html.compact .footer-grid {
    gap: var(--spacing-lg);
}

/* nav-list gap is controlled by --nav-gap CSS variable */

html.compact .header-cart-area {
    gap: var(--spacing-md);
}

html.compact .cart-widget {
    padding: var(--spacing-xs) var(--spacing-md);
    gap: var(--spacing-md);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 991px) {
    .product-single {
        grid-template-columns: 1fr;
    }

    .checkout-page {
        grid-template-columns: 1fr;
    }

    .order-summary {
        position: static;
    }

    .nav {
        position: fixed;
        top: 0;
        left: -280px;
        width: 280px;
        height: 100vh;
        margin: 0;
        padding: var(--spacing-xl) var(--spacing-lg);
        z-index: 1000;
        transition: left 0.3s;
        flex-direction: column;
    }

    .nav.active {
        left: 0;
    }

    .nav-list {
        flex-direction: column;
    }

    .nav-item {
        border-right: none;
        border-left: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .main > .container {
        padding: var(--spacing-lg);
        margin: var(--spacing-md);
    }

    .partners-section,
    .categories-section,
    .products-section {
        padding: var(--spacing-lg);
        margin: var(--spacing-md) auto;
    }
}

@media (max-width: 767px) {
    :root {
        --spacing-xl: 24px;
        --spacing-2xl: 32px;
        --spacing-3xl: 48px;
    }

    /* Header Mobile */
    .mobile-menu-toggle {
        display: block;
    }

    .mobile-menu-toggle.active .hamburger {
        background: transparent;
    }

    .mobile-menu-toggle.active .hamburger::before {
        top: 0;
        transform: rotate(45deg);
    }

    .mobile-menu-toggle.active .hamburger::after {
        top: 0;
        transform: rotate(-45deg);
    }

    /* Cart widget mobile - simplified */
    .cart-info,
    .cart-checkout-btn {
        display: none;
    }

    .cart-widget {
        padding: var(--spacing-xs);
        border: none;
        background: transparent;
    }

    /* Hide VAT toggle on mobile in header (show in mobile menu) */
    .header-cart-area > .vat-toggle-btn {
        display: none;
    }

    .nav-inner {
        padding: 0;
        flex-direction: column;
    }

    /* Language switcher in navbar mobile - show at bottom of nav */
    .nav-lang-switcher {
        padding: var(--spacing-md);
        justify-content: center;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    /* Reset page margin on mobile */
    .main {
        padding-top: 0 !important;
    }

    /* Hero Mobile */
    .hero {
        padding: var(--spacing-lg) 0;
        margin: 0 0 var(--spacing-md);
        min-height: 220px;
        align-items: center !important;
        justify-content: center !important;
    }

    .hero-content-wrapper {
        transform: none !important;
        text-align: center !important;
        max-width: 90%;
        padding: 15px;
    }

    .hero .container {
        transform: none !important;
        text-align: center;
    }

    .hero-title {
        font-size: var(--font-size-xl);
    }

    .hero-subtitle {
        font-size: var(--font-size-sm);
    }

    /* Products Grid Mobile */
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: var(--spacing-md);
    }

    /* Category Grid Tablet - 3 columns */
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0;
    }

    .hovereffect .overlay h2 {
        font-size: 12px;
        padding: 0.4em;
    }

    /* Cart Mobile */
    .cart-item {
        grid-template-columns: 80px 1fr;
        gap: var(--spacing-md);
    }

    .cart-item-quantity,
    .cart-item-subtotal {
        grid-column: 2;
    }

    .cart-item-subtotal {
        text-align: left;
    }

    /* Footer Tablet */
    .footer-grid {
        grid-template-columns: var(--product-gallery-width, 50%) 1fr;
        gap: var(--spacing-xl);
    }

    .footer-section {
        padding-right: 0;
    }

    .footer-bottom-inner {
        flex-direction: column;
        gap: var(--spacing-md);
        text-align: center;
    }

    .cart-actions {
        flex-direction: column;
    }

    .logo-img {
        height: var(--logo-height, 60px);
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
    }

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

    .hovereffect .overlay h2 {
        font-size: 11px;
        padding: 0.3em;
    }

    .product-add-to-cart {
        flex-direction: column;
    }

    .product-add-to-cart .btn {
        width: 100%;
    }

    /* Footer smaller screens */
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-map-container iframe {
        height: 150px;
    }
}

/* ============================================
   WhatsApp Chat Widget
   ============================================ */
.whatsapp-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9998;
}

.whatsapp-float {
    width: 60px;
    height: 60px;
    background: #25d366;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(37, 211, 102, 0.5);
}

.whatsapp-float .whatsapp-icon {
    width: 32px;
    height: 32px;
}

.whatsapp-float .close-icon {
    display: none;
    width: 24px;
    height: 24px;
}

.whatsapp-widget.open .whatsapp-float .whatsapp-icon {
    display: none;
}

.whatsapp-widget.open .whatsapp-float .close-icon {
    display: block;
}

/* Popup */
.whatsapp-popup {
    position: absolute;
    bottom: 75px;
    right: 0;
    width: 320px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s ease;
}

.whatsapp-widget.open .whatsapp-popup {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.whatsapp-popup-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #25d366;
    color: white;
}

.whatsapp-popup-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    overflow: hidden;
    background: white;
    flex-shrink: 0;
}

.whatsapp-popup-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.whatsapp-popup-info {
    flex: 1;
    min-width: 0;
}

.whatsapp-popup-name {
    display: block;
    font-weight: 600;
    font-size: 15px;
}

.whatsapp-popup-status {
    display: block;
    font-size: 12px;
    opacity: 0.9;
}

.whatsapp-popup-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
}

.whatsapp-popup-close:hover {
    opacity: 1;
}

.whatsapp-popup-body {
    padding: 16px;
    background: #e5ddd5;
    min-height: 120px;
}

.whatsapp-popup-message {
    background: white;
    padding: 10px 12px;
    border-radius: 0 8px 8px 8px;
    max-width: 85%;
    position: relative;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.whatsapp-message-name {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #25d366;
    margin-bottom: 4px;
}

.whatsapp-popup-message p {
    margin: 0;
    font-size: 14px;
    color: #333;
    line-height: 1.4;
}

.whatsapp-message-time {
    display: block;
    text-align: right;
    font-size: 11px;
    color: #999;
    margin-top: 4px;
}

.whatsapp-popup-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: #f0f0f0;
}

.whatsapp-input {
    flex: 1;
    padding: 10px 14px;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
}

.whatsapp-input:focus {
    box-shadow: 0 0 0 2px rgba(37, 211, 102, 0.3);
}

.whatsapp-send {
    width: 40px;
    height: 40px;
    background: #25d366;
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
}

.whatsapp-send:hover {
    background: #20bd5a;
}

@media (max-width: 767px) {
    .whatsapp-widget {
        bottom: 20px;
        right: 20px;
    }

    .whatsapp-float {
        width: 50px;
        height: 50px;
    }

    .whatsapp-float .whatsapp-icon {
        width: 26px;
        height: 26px;
    }

    .whatsapp-popup {
        width: 290px;
        right: 0;
    }
}

/* ============================================
   Inspector - Bottom-Right Floating Panel
   ============================================ */

/* Hide edit icons when Inspector is closed */
body:not(.admin-edit-mode) .edit-trigger-btn,
body:not(.admin-edit-mode) .inline-edit-trigger,
body:not(.admin-edit-mode) .btn-ar-upload {
    display: none !important;
}

/* Inspector - fixed bottom-right, auto height that grows with content */
.admin-floating-panel {
    position: fixed;
    bottom: 16px;
    right: 16px;
    width: min(400px, 50vw);
    min-height: 200px;
    max-height: 70vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2), 0 2px 8px rgba(0,0,0,0.1);
    z-index: 99999;
    font-size: 13px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.admin-floating-panel.visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

/* Inspector minimized state */
.admin-floating-panel.minimized {
    min-height: auto;
    max-height: none;
}

.admin-floating-panel.minimized .admin-panel-body,
.admin-floating-panel.minimized .admin-save-bar {
    display: none;
}

/* Inspector dock positions */
.admin-floating-panel.dock-bottom-left {
    right: auto;
    left: 16px;
    bottom: 16px;
}

.admin-floating-panel.dock-top-right {
    bottom: auto;
    top: 16px;
    right: 16px;
}

.admin-floating-panel.dock-top-left {
    bottom: auto;
    right: auto;
    top: 16px;
    left: 16px;
}

/* Inspector resize handle (left edge) */
.admin-panel-resize {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    cursor: ew-resize;
    background: transparent;
    z-index: 10;
    transition: background 0.2s;
}

.admin-panel-resize:hover,
.admin-panel-resize.resizing {
    background: rgba(52, 152, 219, 0.3);
}

.admin-floating-panel.dock-bottom-left .admin-panel-resize,
.admin-floating-panel.dock-top-left .admin-panel-resize {
    left: auto;
    right: 0;
}

/* Prevent panel flash on page load - start visible without animation */
html.admin-panel-preload .admin-floating-panel {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
    transition: none;
}

.admin-panel-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    flex-shrink: 0;
}

.admin-panel-header h2 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    flex: 1;
}

.admin-page-indicator {
    background: rgba(255,255,255,0.2);
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-panel-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.admin-panel-btn:hover {
    background: rgba(255,255,255,0.3);
}

.admin-panel-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.admin-panel-close:hover {
    background: rgba(255,255,255,0.3);
}

/* Floating Save Button */
.admin-save-bar {
    padding: 8px 12px;
    background: linear-gradient(to bottom, #f8f9fa, #eee);
    border-bottom: 1px solid #ddd;
}

.admin-save-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 10px 16px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.admin-save-btn:hover {
    background: linear-gradient(135deg, #2980b9, #2471a3);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
    transform: translateY(-1px);
}

.admin-save-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(52, 152, 219, 0.3);
}

.admin-save-btn .check-icon {
    display: none;
}

.admin-save-btn.saving {
    pointer-events: none;
    opacity: 0.8;
}

.admin-save-btn.saved {
    background: linear-gradient(135deg, #27ae60, #219a52);
    box-shadow: 0 2px 8px rgba(39, 174, 96, 0.4);
    animation: saveSuccess 0.4s ease;
}

.admin-save-btn.saved .save-icon {
    display: none;
}

.admin-save-btn.saved .check-icon {
    display: block;
    animation: checkPop 0.3s ease;
}

.admin-save-btn.error {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.4);
}

@keyframes saveSuccess {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes checkPop {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); opacity: 1; }
}

.admin-panel-body {
    padding: 12px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0; /* Allow flex item to shrink for scrolling */
}

/* Admin Layout Bar */
.admin-layout-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    margin-bottom: 10px;
}
.admin-layout-bar .layout-label {
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}
.admin-layout-bar .layout-buttons {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.admin-layout-bar .layout-btn {
    width: 28px;
    height: 28px;
    border: 2px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s;
}
.admin-layout-bar .layout-btn:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.5);
    transform: scale(1.1);
}
.admin-layout-bar .layout-btn.active {
    background: #fff;
    color: #764ba2;
    border-color: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* ==========================================================================
   PLP Layouts are now defined inline in products.php (progressive 1-10 system)
   ========================================================================== */

/* ==========================================================================
   PDP (Product Detail Page) LAYOUTS
   Optimized for landscape product images
   ========================================================================== */

/* Layout 1: Wide Gallery - Clean, larger image focus */
.layout-product-1 .product-single { display: grid; grid-template-columns: 1.6fr 1fr; gap: 32px; align-items: start; }
.layout-product-1 .product-gallery-main { aspect-ratio: 16/9; }
.layout-product-1 .product-gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.layout-product-1 .product-info { font-size: 14px; }
.layout-product-1 .product-title { font-size: 22px; }

/* Layout 2: Split Screen - Clean 50/50 with subtle background */
.layout-product-2 .product-single {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    align-items: stretch;
    min-height: 500px;
}
.layout-product-2 .product-gallery {
    background: #f5f7fa;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    position: relative;
}
.layout-product-2 .product-gallery::before {
    content: '';
    position: absolute;
    right: 0;
    top: 20%;
    bottom: 20%;
    width: 3px;
    background: var(--color-primary, #007bff);
}
.layout-product-2 .product-gallery-main {
    aspect-ratio: 1/1;
    max-width: 400px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}
.layout-product-2 .product-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
}
.layout-product-2 .product-gallery-thumbs {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    padding: 6px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.layout-product-2 .product-gallery-thumb {
    border: 2px solid transparent;
    border-radius: 6px;
}
.layout-product-2 .product-gallery-thumb.active {
    border-color: var(--color-primary, #007bff);
}
.layout-product-2 .product-info {
    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #fff;
}
.layout-product-2 .product-title {
    font-size: 26px;
    font-weight: 600;
}
.layout-product-2 .product-meta-info { margin-bottom: 16px; }

/* Layout 3: Card Stacked - Centered with prominent card styling */
.layout-product-3 .product-single {
    display: block;
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.1);
    overflow: hidden;
}
.layout-product-3 .product-gallery {
    background: #f8f9fa;
    padding: 30px;
}
.layout-product-3 .product-gallery-main {
    aspect-ratio: 16/10;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.layout-product-3 .product-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
}
.layout-product-3 .product-gallery-thumbs {
    margin-top: 16px;
    justify-content: center;
    gap: 10px;
}
.layout-product-3 .product-gallery-thumb {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: #fff;
}
.layout-product-3 .product-gallery-thumb.active {
    border-color: var(--color-primary, #007bff);
}
.layout-product-3 .product-info {
    padding: 32px 40px;
    background: #fff;
}
.layout-product-3 .product-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 16px;
}
.layout-product-3 .product-meta-info {
    font-size: 13px;
    color: #6c757d;
}
.layout-product-3 .product-price {
    font-size: 24px;
    font-weight: 700;
}
.layout-product-3 .btn-primary {
    border-radius: 8px;
    padding: 12px 28px;
}
.layout-product-3 .product-extended-desc {
    margin: 0 40px 32px;
}

/* Layout 4: Compact Side-by-Side - Tighter layout with image on right */
.layout-product-4 .product-single {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 40px;
    align-items: start;
}
.layout-product-4 .product-gallery {
    order: 2;
    background: #f8f9fa;
    border-radius: 16px;
    padding: 24px;
}
.layout-product-4 .product-gallery-main {
    aspect-ratio: 1/1;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.layout-product-4 .product-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 16px;
}
.layout-product-4 .product-gallery-thumbs {
    margin-top: 16px;
    justify-content: center;
}
.layout-product-4 .product-gallery-thumb {
    background: #fff;
    border: 2px solid #e9ecef;
    border-radius: 8px;
}
.layout-product-4 .product-gallery-thumb.active {
    border-color: var(--color-primary, #007bff);
}
.layout-product-4 .product-info {
    order: 1;
    padding: 20px 0;
}
.layout-product-4 .product-title {
    font-size: 24px;
    font-weight: 600;
}
.layout-product-4 .btn-primary {
    border-radius: 8px;
}
.layout-product-4 .product-extended-desc {
    background: #f8f9fa;
}

/* Layout 5: Gallery Focus - Large image top, info below */
.layout-product-5 .product-single {
    display: block;
    max-width: 1000px;
    margin: 0 auto;
}
.layout-product-5 .product-gallery {
    margin-bottom: 32px;
}
.layout-product-5 .product-gallery-main {
    aspect-ratio: 16/9;
    background: #f8f9fa;
    border-radius: 16px;
    overflow: hidden;
}
.layout-product-5 .product-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 32px;
}
.layout-product-5 .product-gallery-thumbs {
    margin-top: 16px;
    justify-content: center;
    gap: 12px;
}
.layout-product-5 .product-gallery-thumb {
    border-radius: 8px;
    border: 2px solid #e9ecef;
}
.layout-product-5 .product-gallery-thumb.active {
    border-color: var(--color-primary, #007bff);
}
.layout-product-5 .product-info {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 40px;
    align-items: start;
    padding: 24px 0;
    border-top: 1px solid #e9ecef;
}
.layout-product-5 .product-title {
    font-size: 26px;
    font-weight: 600;
}
.layout-product-5 .product-price {
    font-size: 22px;
}
.layout-product-5 .btn-primary {
    border-radius: 8px;
}
.layout-product-5 .product-extended-desc {
    grid-column: 1 / -1;
}

/* Admin Tabs */
.admin-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 12px;
    background: #f0f0f0;
    padding: 4px;
    border-radius: 8px;
}

.admin-tab {
    flex: 1;
    padding: 8px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    color: #666;
    border-radius: 6px;
    transition: all 0.2s;
}

.admin-tab:hover {
    color: #333;
}

.admin-tab.active {
    background: white;
    color: var(--color-primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.admin-tab-content {
    display: none;
}

.admin-tab-content.active {
    display: block;
}

/* Admin Sections */
.admin-section {
    margin-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
}

.admin-section:last-of-type {
    margin-bottom: 8px;
    border-bottom: none;
}

.admin-section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #666;
    margin: 0;
    padding: 6px 0;
    border-bottom: none;
}

/* Collapsible sections */
.admin-section.collapsible .admin-section-title {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s;
}

.admin-section.collapsible .admin-section-title:hover {
    color: var(--color-primary);
}

.admin-section.collapsible .section-arrow {
    font-size: 8px;
    transition: transform 0.2s;
    display: inline-block;
    width: 10px;
}

.admin-section.collapsible .admin-section-content {
    max-height: 0;
    overflow: hidden;
    padding-bottom: 0;
    transition: max-height 0.25s ease-out, padding 0.25s ease-out;
}

.admin-section.collapsible.expanded .admin-section-content {
    max-height: 600px;
    padding-bottom: 6px;
    transition: max-height 0.3s ease-in, padding 0.25s ease-in;
}

/* Admin Settings - Compact */
.admin-setting {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid #eee;
}

.admin-setting:last-of-type {
    border-bottom: none;
    margin-bottom: 6px;
}

.admin-setting > label:first-child {
    font-size: 12px;
    color: #333;
}

/* Slider setting */
.admin-setting.slider-setting {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.slider-row {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
}

.slider-input {
    flex: 1;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: #ddd;
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

.slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}

.slider-input::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}

/* Compact slider settings */
.admin-setting.compact-slider-setting {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.compact-slider-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
}

.compact-slider-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.slider-axis-label {
    font-size: 11px;
    font-weight: 600;
    color: #666;
    min-width: 12px;
}

.compact-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: #ddd;
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.compact-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.compact-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.compact-slider-value {
    font-size: 11px;
    font-weight: 600;
    color: #666;
    min-width: 32px;
    text-align: right;
}

.slider-value {
    font-size: 12px;
    font-weight: 600;
    color: #666;
    min-width: 35px;
    text-align: right;
}

/* Color picker */
.color-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.color-input {
    width: 32px;
    height: 24px;
    padding: 0;
    border: 2px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

.color-presets {
    display: flex;
    gap: 3px;
}

.color-btn {
    width: 18px;
    height: 18px;
    border: 2px solid white;
    border-radius: 4px;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
    transition: transform 0.15s;
}

.color-btn:hover {
    transform: scale(1.15);
}

/* Admin Select */
.admin-select-sm {
    padding: 6px 10px;
    font-size: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    cursor: pointer;
}

/* Admin Toggle */
.admin-toggle {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    cursor: pointer;
}

.admin-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.admin-toggle-track {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 22px;
}

.admin-toggle-track:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.admin-toggle input:checked + .admin-toggle-track {
    background-color: var(--color-primary);
}

.admin-toggle input:checked + .admin-toggle-track:before {
    transform: translateX(18px);
}

/* Anchor Grid - 3x3 position selector */
.anchor-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    width: 72px;
    height: 72px;
    padding: 6px;
    background: #f0f0f0;
    border-radius: 6px;
    border: 1px solid #ddd;
}

.anchor-point {
    width: 100%;
    aspect-ratio: 1;
    border: 2px solid #ccc;
    border-radius: 3px;
    background: white;
    cursor: pointer;
    transition: all 0.15s ease;
    padding: 0;
}

.anchor-point:hover {
    border-color: var(--color-primary);
    background: #e8f4fc;
}

.anchor-point.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.3);
}

/* Admin Link buttons */
.admin-link-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    margin-bottom: 8px;
    background: #f8f9fa;
    border-radius: 6px;
    color: #333;
    text-decoration: none;
    font-size: 13px;
    transition: background 0.2s, color 0.2s;
}

.admin-link-btn:hover {
    background: var(--color-primary);
    color: white;
}

.admin-link-btn:hover svg {
    stroke: white;
}

.admin-link-btn.logout:hover {
    background: #e74c3c;
}

/* Admin Status message */
.admin-status {
    padding: 8px;
    margin-top: 8px;
    border-radius: 4px;
    font-size: 12px;
    text-align: center;
    display: none;
}

.admin-status.success {
    display: block;
    background: #d4edda;
    color: #155724;
}

.admin-status.error {
    display: block;
    background: #f8d7da;
    color: #721c24;
}

/* Admin menu button styles */
.admin-menu .admin-link {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

