/* ========================================
   VAVORY SHOP - Design System
   Based on teamvavory.de branding
   ======================================== */

:root {
  /* Colors (from main website) */
  --color-bg: #070712;
  --color-surface: #131125;
  --color-surface-alt: #1c1933;
  --color-primary: #8b5cf6;
  --color-primary-dark: #6d28d9;
  --color-accent: #22d3ee;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-text: #ffffff;
  --color-muted: #a2a1c2;
  --color-border: rgba(255,255,255,0.14);
  --color-placeholder: rgba(162,161,194,0.9);
  
  /* Shop-specific colors */
  --color-cart: #ff44cc;
  --color-discount: #10b981;
  --color-badge: rgba(139,92,246,0.15);
  
  /* Layout */
  --max-width: 1400px;
  --header-height: 80px;
  --sidebar-width: 280px;
  
  /* Radius */
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 10px;
  
  /* Shadows */
  --shadow-card: 0 18px 45px rgba(8,6,18,0.55);
  --shadow-hover: 0 24px 58px rgba(8,6,18,0.65);
  --shadow-glow: 0 0 45px rgba(139,92,246,0.45);
  
  /* Motion */
  --motion-fast: 180ms;
  --motion-medium: 300ms;
  --motion-slow: 450ms;
  
  /* Z-index layers */
  --z-header: 100;
  --z-cart-drawer: 200;
  --z-modal: 300;
  --z-toast: 400;
}

/* ========================================
   RESET & BASE
   ======================================== */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

body.menu-open {
  overflow: hidden;
}

main {
  display: block;
}

.hero--storefront {
  position: relative;
  padding: clamp(3rem, 6vw, 5rem) 0 clamp(2rem, 5vw, 4rem);
  background: linear-gradient(135deg, #4c1d95 0%, #2f155c 45%, #34146d 65%, #4f1f8b 100%);
  overflow: hidden;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  opacity: 0.12;
  background-image:
    radial-gradient(circle at 25px 25px, rgba(255,255,255,0.25) 2%, transparent 0%),
    radial-gradient(circle at 75px 75px, rgba(255,255,255,0.12) 2%, transparent 0%);
  background-size: 100px 100px;
}

.hero__content {
  position: relative;
  z-index: 1;
}

.hero__inner {
  max-width: 820px;
  margin: 0 auto;
  text-align: center;
}

.hero__title {
  font-size: clamp(2.75rem, 6vw, 4.5rem);
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff, rgba(139,92,246,0.85), rgba(34,211,238,0.95));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero__subtitle {
  font-size: 1.125rem;
  color: rgba(226,225,255,0.82);
  margin: 0 auto 2rem;
  max-width: 640px;
}

.hero__cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.hero__trust-list {
  display: flex;
  gap: clamp(1rem, 3vw, 2.5rem);
  justify-content: center;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.9375rem;
  color: rgba(226,225,255,0.75);
}

.hero__trust-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero__trust-list svg {
  color: rgba(255,255,255,0.8);
}

@media (max-width: 768px) {
  .hero__inner {
    text-align: left;
    padding-inline: 0.75rem;
  }

  .hero__cta {
    justify-content: flex-start;
  }

  .hero__trust-list {
    justify-content: flex-start;
  }

  .section-header {
    text-align: left;
  }

  .section-header .section-lead {
    margin-left: 0;
  }
}

@media (max-width: 600px) {
  .hero__trust-list {
    gap: 0.75rem;
  }

  .hero__trust-list li {
    width: 100%;
    justify-content: flex-start;
  }

  .hero__cta .btn {
    width: 100%;
    justify-content: center;
  }

  .hero__subtitle {
    font-size: 1rem;
  }
}

.section--accent {
  background: var(--color-surface);
}

.section-header {
  text-align: center;
  margin: 0 auto clamp(2.5rem, 5vw, 3rem);
  max-width: 720px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem 0.75rem;
  margin-bottom: 1rem;
  border-radius: 999px;
  background: rgba(139,92,246,0.16);
  color: var(--color-accent);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.section-lead {
  color: var(--color-muted);
  font-size: 1rem;
  margin: 0 auto;
}

.product-utilities {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: flex-end;
  margin-bottom: 2.5rem;
}

.product-utilities .select-field {
  min-width: 220px;
  background-color: var(--color-surface);
  border-color: rgba(255,255,255,0.18);
}

.product-utilities .select-field:focus {
  border-color: rgba(139,92,246,0.45);
  box-shadow: 0 0 0 3px rgba(139,92,246,0.2);
}

@media (max-width: 768px) {
  .product-utilities {
    justify-content: stretch;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }

  .product-utilities .select-field {
    min-width: 100%;
  }
}

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

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--motion-fast) ease;
}

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

/* ========================================
   TYPOGRAPHY
   ======================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: "Anton", sans-serif;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
h4 { font-size: 1.5rem; }

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

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

/* ========================================
   LAYOUT
   ======================================== */

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

.section {
  padding: clamp(3.5rem, 6vw, 5rem) 0;
}

.grid {
  display: grid;
  gap: 2rem;
}

.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   BUTTONS
   ======================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all var(--motion-medium) ease;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: white;
  box-shadow: 0 8px 24px rgba(139,92,246,0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(139,92,246,0.5);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

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

.btn-accent {
  background: var(--color-accent);
  color: var(--color-bg);
}

.btn-cart {
  background: linear-gradient(135deg, #ff44cc, #d946ef);
  color: white;
  box-shadow: 0 8px 24px rgba(255,68,204,0.4);
}

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

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1.125rem 2.5rem;
  font-size: 1.125rem;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* ========================================
   CARDS
   ======================================== */

.card {
  background: var(--color-surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-card);
  transition: all var(--motion-medium) ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(139,92,246,0.3);
}

.newsletter-card {
  padding: clamp(2rem, 4vw, 3rem);
  text-align: center;
  background: linear-gradient(135deg, rgba(139,92,246,0.18), rgba(34,211,238,0.12));
}

.newsletter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  align-items: center;
  margin-top: 1.5rem;
}

.newsletter-form .input-field {
  flex: 1;
  min-width: min(320px, 100%);
}

@media (max-width: 640px) {
  .newsletter-form {
    flex-direction: column;
    align-items: stretch;
  }

  .newsletter-form .input-field,
  .newsletter-form .btn {
    width: 100%;
  }
}

/* ========================================
   PRODUCT CARD (Main shop component)
   ======================================== */

.product-card {
  background: var(--color-surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--motion-medium) ease;
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(139,92,246,0.4);
}

.product-image-wrapper {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--color-surface-alt);
}

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

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

.product-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: var(--color-badge);
  backdrop-filter: blur(10px);
  color: var(--color-primary);
  padding: 0.375rem 0.875rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.product-badge.sale {
  background: rgba(239,68,68,0.15);
  color: var(--color-error);
}

.product-badge.new {
  background: rgba(16,185,129,0.15);
  color: var(--color-success);
}

.product-content {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-category {
  font-size: 0.875rem;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.product-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.product-description {
  color: var(--color-muted);
  font-size: 0.9375rem;
  margin-bottom: 1.25rem;
  flex: 1;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.product-price-wrapper {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.product-price {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--color-text);
}

.product-price.sale {
  color: var(--color-error);
}

.product-original-price {
  font-size: 1.125rem;
  color: var(--color-muted);
  text-decoration: line-through;
}

.product-stock {
  font-size: 0.875rem;
  color: var(--color-success);
  font-weight: 600;
}

.product-stock.out-of-stock {
  color: var(--color-error);
}

.product-card__cta {
  padding: 0 1.5rem 1.5rem;
  margin-top: auto;
}

.product-card__cta .btn {
  width: 100%;
}

/* ========================================
   FORMS & INPUTS
   ======================================== */

.input-field, .textarea-field, .select-field {
  width: 100%;
  padding: 0.875rem 1.25rem;
  background: var(--color-surface-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text);
  font-size: 1rem;
  transition: all var(--motion-fast) ease;
}

.input-field:focus, .textarea-field:focus, .select-field:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(34,211,238,0.25);
}

.input-field::placeholder {
  color: var(--color-placeholder);
}

/* Map native form controls to our input styles for legacy inline forms */
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="search"], input[type="tel"], input[type="url"], textarea, select {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  color: var(--color-text);
}

input::placeholder, textarea::placeholder {
  color: var(--color-placeholder);
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(34,211,238,0.25);
}

/* ========================================
   BADGES & TAGS
   ======================================== */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.875rem;
  background: var(--color-badge);
  color: var(--color-primary);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ========================================
   UTILITIES
   ======================================== */

.text-center { text-align: center; }
.text-right { text-align: right; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* Cart Button Hover */
.cart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 68, 204, 0.4);
}

/* ========================================
   RESPONSIVE DESIGN - MOBILE FIRST
   ======================================== */

/* Container responsive padding */
@media (max-width: 1400px) {
  .container {
    padding: 0 1.5rem;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }
  
  .section {
    padding: 3rem 0;
  }
}

/* Header responsive */
@media (max-width: 1024px) {
  .shop-header .container {
    padding: 1rem;
  }
  
  .nav-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background: var(--color-surface);
    border-right: 1px solid rgba(255,255,255,0.1);
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem 2rem 2rem;
    gap: 0;
    transition: left var(--motion-medium) ease;
    z-index: var(--z-cart-drawer);
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
  }
  
  .nav-menu.open {
    left: 0;
  }
  
  .nav-menu li {
    width: 100%;
    border-bottom: 1px solid rgba(255,255,255,0.05);
  }
  
  .nav-menu a {
    display: block;
    width: 100%;
    padding: 1rem 0;
    font-size: 1.125rem;
  }
  
  .menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--color-text);
    cursor: pointer;
    padding: 0.5rem;
    z-index: calc(var(--z-cart-drawer) + 1);
    position: relative;
  }
}

/* Product grid responsive */
@media (max-width: 1200px) {
  .grid-4 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .grid-3, .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .grid {
    gap: 1.5rem;
  }
}

@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  
  .grid {
    gap: 1.25rem;
  }
}

/* Typography responsive */
@media (max-width: 768px) {
  :root {
    font-size: 15px;
  }
  
  h1 { font-size: clamp(2rem, 8vw, 3rem); }
  h2 { font-size: clamp(1.75rem, 6vw, 2.5rem); }
  h3 { font-size: clamp(1.35rem, 5vw, 1.75rem); }
}

@media (max-width: 480px) {
  :root {
    font-size: 14px;
  }
}

/* Product card responsive */
@media (max-width: 640px) {
  .product-card {
    max-width: 100%;
  }
  
  .product-content {
    padding: 1.25rem;
  }
  
  .product-price {
    font-size: 1.5rem;
  }
  
  .product-original-price {
    font-size: 1rem;
  }
  
  .product-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
}

/* Button responsive */
@media (max-width: 640px) {
  .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
  }
  
  .btn-lg {
    padding: 1rem 2rem;
    font-size: 1rem;
  }
  
  .btn-sm {
    padding: 0.5rem 0.875rem;
    font-size: 0.8125rem;
  }
}

/* Form elements responsive */
@media (max-width: 640px) {
  .input-field, .textarea-field, .select-field {
    padding: 0.75rem 1rem;
    font-size: 1rem; /* Prevent zoom on iOS */
  }
}

/* ========================================
   SCROLL ANIMATIONS
   ======================================== */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Scroll reveal system */
.will-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  transition-delay: var(--animation-delay, 0ms);
}

.will-animate.animate-in {
  opacity: 1;
  transform: translateY(0);
}

/* Specific animation variants */
[data-animate="fade"] {
  animation: fadeIn 0.6s ease forwards;
}

[data-animate="slide-up"] {
  animation: fadeInUp 0.6s ease forwards;
}

[data-animate="slide-left"] {
  animation: slideInLeft 0.6s ease forwards;
}

[data-animate="slide-right"] {
  animation: slideInRight 0.6s ease forwards;
}

[data-animate="scale"] {
  animation: scaleIn 0.6s ease forwards;
}

/* Product card stagger animation */
.product-card.will-animate {
  animation: fadeInUp 0.5s ease forwards;
  animation-delay: var(--animation-delay, 0ms);
}

/* ========================================
   MODAL & OVERLAY SYSTEM
   ======================================== */

.modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: fadeIn 0.3s ease;
}

.modal:not([hidden]) {
  display: flex;
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.modal__dialog {
  position: relative;
  background: var(--color-surface);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  padding: 2rem;
  max-width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  animation: scaleIn 0.3s ease;
}

.modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-text);
  transition: background var(--motion-fast) ease;
}

.modal__close:hover {
  background: rgba(255,255,255,0.2);
}

/* ========================================
   TOAST NOTIFICATIONS (CREATIVE VERSION)
   ======================================== */

.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 16px;
  padding: 1.25rem 1.75rem;
  box-shadow: 0 15px 50px rgba(102, 126, 234, 0.4), 
              0 5px 20px rgba(0,0,0,0.3);
  z-index: var(--z-toast);
  opacity: 0;
  transform: translateY(100px) scale(0.8);
  transition: all 0.3s ease;
  max-width: 90vw;
  backdrop-filter: blur(10px);
  color: white;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.3px;
}

.toast.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.toast__content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.toast__icon {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-weight: bold;
  animation: iconPulse 1s infinite;
}

.toast--success .toast__icon {
  background: rgba(255,255,255,0.3);
  color: white;
}

.toast--error .toast__icon {
  background: rgba(255,255,255,0.3);
  color: white;
}

.toast--info .toast__icon {
  background: rgba(255,255,255,0.3);
  color: white;
}

/* Toast Animations */
@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translateY(100px) scale(0.8) rotate(5deg);
  }
  50% {
    transform: translateY(-10px) scale(1.05) rotate(-2deg);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1) rotate(0deg);
  }
}

@keyframes toastSlideOut {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }
}

@keyframes iconPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
}

/* Confetti Animation */
@keyframes confettiFall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}

@media (max-width: 640px) {
  .toast {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    max-width: none;
  }
}

/* ========================================
   SKIP LINK (Accessibility)
   ======================================== */

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--color-primary);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  z-index: calc(var(--z-modal) + 1);
  transition: top 0.3s ease;
}

.skip-link:focus {
  top: 1rem;
}

/* ========================================
   KEYBOARD NAVIGATION
   ======================================== */

body.keyboard-nav *:focus {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* ========================================
   TOUCH IMPROVEMENTS
   ======================================== */

@media (hover: none) and (pointer: coarse) {
  /* Increase tap targets on touch devices */
  .btn {
    min-height: 44px;
    padding: 0.875rem 1.75rem;
  }
  
  .icon-btn {
    min-width: 44px;
    min-height: 44px;
  }
  
  /* Disable hover effects on touch */
  .product-card:hover .product-image {
    transform: none;
  }
  
  .btn:hover,
  .card:hover {
    transform: none;
  }
  
  /* Add active states for touch feedback */
  .btn:active {
    transform: scale(0.96);
  }
  
  .product-card:active {
    transform: scale(0.98);
  }
}

/* ========================================
   LOADING STATES
   ======================================== */

.loading {
  position: relative;
  pointer-events: none;
  opacity: 0.6;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 24px;
  height: 24px;
  margin: -12px 0 0 -12px;
  border: 3px solid var(--color-primary);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

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

/* ========================================
   IMAGE LAZY LOADING
   ======================================== */

img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.3s ease;
}

img.loaded,
img[loading="lazy"].loaded {
  opacity: 1;
}

.empty-state {
  text-align: center;
  padding: clamp(2.5rem, 5vw, 3rem);
  border-radius: var(--radius-lg);
  border: 1px dashed rgba(139,92,246,0.35);
  background: rgba(139,92,246,0.08);
}

.empty-state__title {
  font-size: clamp(1.5rem, 3vw, 1.875rem);
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.empty-state__text {
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ========================================
   PREFERS REDUCED MOTION
   ======================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  
  .will-animate {
    opacity: 1;
    transform: none;
  }
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
  header,
  footer,
  .cart-btn,
  .menu-toggle,
  .toast,
  .modal {
    display: none !important;
  }
  
  body {
    background: white;
    color: black;
  }
  
  .product-card {
    page-break-inside: avoid;
  }
}

