:root {
  /* Medical-grade color palette - Clean blues and teals */
  --primary: #0277bd; /* Professional medical blue */
  --primary-dark: #01579b; /* Deeper blue for contrast */
  --primary-light: #4fc3f7; /* Light blue for accents */
  --secondary: #00897b; /* Medical teal */
  --secondary-dark: #00695c;
  --accent: #26a69a; /* Soft teal accent */
  --accent-dark: #00796b;
  
  /* Neutral grays for backgrounds and text */
  --bg: #fafbfc; /* Very light gray background */
  --bg-secondary: #f5f7fa; /* Slightly darker for sections */
  --text: #1a2332; /* Dark gray for primary text */
  --text-secondary: #4a5568; /* Medium gray for secondary text */
  --muted: #718096; /* Muted gray for less important text */
  --border: #e2e8f0; /* Light border color */
  --border-light: #f1f5f9; /* Very light border */
  
  /* Card and surface colors */
  --card-bg: #ffffff;
  --card-border: #e8ecf1;
  --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --card-shadow-hover: 0 4px 12px rgba(2, 119, 189, 0.08), 0 2px 4px rgba(0, 0, 0, 0.04);
  
  /* Gradients */
  --bg-gradient: linear-gradient(135deg, #0277bd 0%, #00897b 100%);
  --overlay-gradient: linear-gradient(135deg, rgba(2, 119, 189, 0.15) 0%, rgba(0, 137, 123, 0.15) 100%);
  
  /* Border radius - softer, medical-appropriate */
  --radius: 0.75rem;
  --radius-sm: 0.5rem;
  --radius-lg: 1rem;
  
  /* Spacing system - consistent and generous */
  --spacing-xs: 0.5rem;
  --spacing-sm: 0.75rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  
  /* Typography - Modern, highly readable */
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
  --font-weight-light: 300;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  
  /* Line heights for readability */
  --line-height-tight: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.75;
  
  /* Transitions - subtle and professional */
  --transition-fast: 0.15s ease;
  --transition-base: 0.2s ease;
  --transition-slow: 0.3s ease;
}

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
  font-size: 1rem;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  /* Improve scrolling on mobile */
  -webkit-overflow-scrolling: touch;
  overflow-x: hidden;
  /* Prevent horizontal scroll on mobile */
  width: 100%;
  max-width: 100vw;
}

/* Tablet optimizations (481px - 980px) */
@media (min-width: 481px) and (max-width: 980px) {
  .layout {
    padding: var(--spacing-xl) var(--spacing-lg);
    gap: var(--spacing-xl);
  }
  
  .catalog-wrapper {
    padding: var(--spacing-xl);
  }
  
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
  }
  
  .catalog {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
  }
  
  .utility-bar-content {
    padding: var(--spacing-md) var(--spacing-lg);
  }
  
  .product-detail-content {
    gap: var(--spacing-xl);
    padding: var(--spacing-xl);
  }
}

/* Top Utility Bar - Above Video Header */
.utility-bar {
  position: relative;
  width: 100%;
  background: #0F766E; /* dark blue example */
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(3, 213, 132, 0.04);
  z-index: 1000;
}


.utility-bar-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  padding: 1.5rem clamp(1.5rem, 4vw, 3rem);
}

.utility-branding {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
  min-width: 0;
}

.utility-logo {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: contain;
  background: var(--card-bg);
  border: 2px solid var(--border);
  box-shadow: var(--card-shadow);
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.utility-logo:hover {
  transform: scale(1.05);
}

.utility-slogan {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  min-width: 0;
  flex: 1;
}

.utility-company-name {
  font-size: 1.35rem;
  font-weight: var(--font-weight-semibold);
  color: #e2e8f0;
  letter-spacing: -0.01em;
  line-height: var(--line-height-tight);
  margin: 0;
}

.utility-tagline {
  font-size: 0.9rem;
  font-weight: var(--font-weight-normal);
  color: #ffffff;
  line-height: var(--line-height-normal);
  margin: 0;
  max-width: 600px;
}

.utility-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.utility-search-wrapper {
  position: relative;
  flex: 1;
  min-width: 200px;
  max-width: 400px;
}

.utility-search {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  background: var(--bg);
  color: var(--text);
  transition: all var(--transition-base);
  -webkit-appearance: none;
  font-weight: var(--font-weight-normal);
}

.utility-search:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--card-bg);
  box-shadow: 0 0 0 3px rgba(2, 119, 189, 0.1);
}

.utility-search::placeholder {
  color: var(--muted);
}

.utility-btn {
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card-bg);
  color: var(--primary);
  font-size: 0.95rem;
  font-weight: var(--font-weight-medium);
  cursor: pointer;
  transition: all var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  min-height: 44px;
}

.utility-btn:hover {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  box-shadow: var(--card-shadow-hover);
}

.utility-btn:active {
  transform: translateY(0);
}

.cart-toggle-btn {
  position: relative;
}

.cart-count {
  background: var(--primary);
  color: #ffffff;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  margin-left: -4px;
}

.cart-icon {
  font-size: 1.25rem;
}

/* Hero Section with Video Background */
.hero {
  position: relative;
  min-height: 300px;
  height: 60vh;
  max-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #fff;
  -webkit-overflow-scrolling: touch;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

.hero-fallback {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  object-fit: cover;
  z-index: 0;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.hero-fallback.show {
  opacity: 1;
  z-index: 2;
}

.hero-video-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  transition: opacity 1s ease-in-out;
}

.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  object-fit: cover;
  object-position: center center;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
  z-index: 0;
  pointer-events: none;
  display: block;
  /* Prevent video from stretching or distorting */
  will-change: opacity;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.hero-video.active {
  opacity: 1;
  z-index: 1;
}

.hero-video.loading {
  opacity: 0;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(2, 119, 189, 0.3) 0%, rgba(0, 137, 123, 0.3) 100%);
  z-index: 2;
  background-blend-mode: overlay;
  box-shadow: inset 0 0 150px rgba(0, 0, 0, 0.1);
}

/* Additional overlay for mobile - Calmer, more professional medical aesthetic */
@media (max-width: 768px) {
  .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.25) 0%,
      rgba(2, 119, 189, 0.3) 30%,
      rgba(0, 137, 123, 0.35) 50%,
      rgba(2, 119, 189, 0.3) 70%,
      rgba(0, 0, 0, 0.3) 100%
    );
    box-shadow: inset 0 0 200px rgba(0, 0, 0, 0.15);
  }
  
  /* Reduce video brightness/contrast on mobile for calmer appearance */
  .hero-video {
    filter: brightness(0.85) contrast(0.95);
    -webkit-filter: brightness(0.85) contrast(0.95);
  }
  
  /* Add subtle blur to reduce visual noise (optional, can be removed if too much) */
  .hero-video-container {
    filter: blur(0.5px);
    -webkit-filter: blur(0.5px);
  }
}

.hero-content {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
  padding: 3rem clamp(1.5rem, 5vw, 4rem);
}

.branding {
  position: relative;
  z-index: 3;
  max-width: 800px;
}

/* Video background optimized for performance */
.hero-video-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  z-index: -1;
}


/* Hidden class for page navigation */
.hidden {
  display: none !important;
}
.branding h1 {
  margin: 0 0 1rem;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 4px 12px rgba(0, 0, 0, 0.1);
  color: #ffffff;
  line-height: 1.2;
}

.branding p {
  margin: 0;
  font-size: clamp(1rem, 2vw, 1.1rem);
  opacity: 0.95;
  font-weight: 300;
  line-height: 1.6;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  max-width: 600px;
}

.branding-logo {
  width: 64px; /* Larger for better detail */
  height: 64px;
  border-radius: 50%;
  object-fit: contain;
  background: #ffffff;
  border: 3px solid rgba(255,255,255,0.6); /* Clean, premium border */
  /* Elevated, soft shadow */
  box-shadow: 
    0 4px 10px rgba(0,0,0,0.15),
    0 0 12px rgba(0,0,0,0.05) inset;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* Optional hover polish */
.branding-logo:hover {
  transform: scale(1.05);
  box-shadow:
    0 8px 16px rgba(0,0,0,0.18),
    0 0 16px rgba(0,0,0,0.08) inset;
}

/* Responsive tweaks so logo + title align nicely on mobile and laptop */
@media (max-width: 600px) {
  .branding h1 {
    font-size: clamp(1.8rem, 7vw, 2.4rem);
    gap: 0.6rem;
  }

  .branding-logo {
    width: 48px;
    height: 48px;
  }
}

@media (min-width: 1024px) {
  .branding h1 {
    flex-wrap: nowrap;
  }
}


/* Utility Bar Responsive Styles */
@media (max-width: 980px) {
  .utility-bar-content {
    flex-wrap: wrap;
    gap: 1.5rem;
    padding: 1.25rem clamp(1.25rem, 3vw, 2rem);
  }
  
  .utility-branding {
    flex: 1 1 100%;
    justify-content: flex-start;
  }
  
  .utility-slogan {
    max-width: 100%;
  }
  
  .utility-company-name {
    font-size: 1.25rem;
  }
  
  .utility-tagline {
    font-size: 0.875rem;
  }
  
  .utility-actions {
    flex: 1 1 100%;
    justify-content: center;
    flex-wrap: wrap;
  }
  
  .utility-search-wrapper {
    flex: 1 1 100%;
    max-width: 100%;
    min-width: 0;
  }
}

@media (max-width: 768px) {
  .utility-bar-content {
    padding: 1.25rem 1.25rem;
    gap: 1.25rem;
  }
  
  .utility-branding {
    flex: 1 1 100%;
    justify-content: flex-start;
    gap: 1rem;
  }
  
  .utility-logo {
    width: 48px;
    height: 48px;
  }
  
  .utility-company-name {
    font-size: 1.15rem;
  }
  
  .utility-tagline {
    font-size: 0.85rem;
    line-height: 1.4;
  }
  
  .utility-actions {
    flex: 1 1 100%;
    justify-content: space-between;
    gap: 0.75rem;
  }
  
  .utility-search-wrapper {
    flex: 1 1 auto;
    min-width: 150px;
    max-width: none;
  }
  
  .utility-search {
    font-size: 16px; /* Prevents zoom on iOS */
    padding: 0.75rem 1rem;
  }
  
  .utility-btn {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    min-height: 44px; /* Touch-friendly */
    flex: 0 0 auto;
  }
  
  .contact-btn {
    display: none; /* Hide on small mobile, can be shown in menu if needed */
  }
}

@media (max-width: 480px) {
  .utility-bar-content {
    padding: 1rem 1rem;
    gap: 1rem;
  }
  
  .utility-branding {
    gap: 0.75rem;
  }
  
  .utility-logo {
    width: 44px;
    height: 44px;
  }
  
  .utility-company-name {
    font-size: 1.1rem;
  }
  
  .utility-tagline {
    font-size: 0.8rem;
    line-height: 1.4;
  }
  
  .utility-actions {
    gap: 0.5rem;
  }
  
  .utility-search-wrapper {
    min-width: 120px;
  }
  
  .utility-search {
    padding: 0.625rem 0.875rem;
    font-size: 16px;
  }
  
  .utility-btn {
    padding: 0.625rem 0.875rem;
    min-height: 44px;
  }
  
  .cart-toggle-btn {
    min-width: 44px;
    padding: 0.625rem;
  }
}

/* Back Button */
.back-btn {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 1.5rem;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px; /* Touch-friendly */
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
  touch-action: manipulation;
}

.back-btn:hover {
  background: var(--primary-dark);
  transform: translateX(-4px);
}

.back-btn:active {
  transform: translateX(-2px);
}

@media (max-width: 768px) {
  .back-btn {
    width: 100%;
    justify-content: center;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    margin-bottom: 1.25rem;
  }
  
  .back-btn:hover {
    transform: none; /* Remove transform on mobile */
  }
}

.lang-switcher {
  display: flex;
  gap: 0.25rem;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 0.25rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.lang-btn {
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  background: transparent;
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 44px;
}

.lang-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.lang-btn.active {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
  font-weight: 700;
}

/* RTL Support */
html[dir="rtl"] {
  direction: rtl;
}

html[dir="rtl"] .hero-actions {
  flex-direction: row-reverse;
}

html[dir="rtl"] .branding h1 {
  flex-direction: row-reverse;
}

html[dir="rtl"] .cart-item header {
  flex-direction: row-reverse;
}

html[dir="rtl"] .cart-qty-controls {
  flex-direction: row-reverse;
}

html[dir="rtl"] footer {
  flex-direction: row-reverse;
}

.hero-actions input {
  padding: 1rem 1.5rem;
  border-radius: 999px;
  border: none;
  min-width: 280px;
  flex: 1;
  font-size: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  color: var(--text);
}

.hero-actions input::placeholder {
  color: var(--muted);
  opacity: 0.7;
}

.hero-actions input:focus {
  outline: none;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2), 0 4px 8px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
  background: #ffffff;
}

@media (max-width: 768px) {
  .hero-actions input {
    min-width: 100%;
    width: 100%;
    font-size: 16px; /* Prevents zoom on iOS */
    padding: 0.875rem 1.25rem;
  }
}

.hero-actions button {
  border: none;
  padding: 1rem 1.75rem;
  border-radius: 999px;
  background: var(--accent);
  color: #1a202c;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), 0 2px 4px rgba(0, 0, 0, 0.1);
  letter-spacing: 0.3px;
  min-height: 44px;
  white-space: nowrap;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
}

.hero-actions button:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.hero-actions button:active {
  transform: translateY(0);
}

.cart-toggle-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--accent);
  border: 2px solid rgba(0, 0, 0, 0.04);
  color: #1a202c;
  padding: 1rem 1.4rem;
  border-radius: 999px;
  min-height: 44px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), 0 2px 4px rgba(0, 0, 0, 0.1);
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.cart-toggle-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25), 0 4px 8px rgba(0, 0, 0, 0.15);
}

.cart-toggle-btn:active {
  transform: translateY(0);
}

.cart-toggle-btn:hover {
  background: var(--accent-dark);
  border-color: rgba(0, 0, 0, 0.08);
}

.cart-icon {
  font-size: 1.4rem;
  line-height: 1;
  display: inline-block;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.1));
}

.cart-count {
  background: #ef4444;
  color: #fff;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  min-width: 24px;
  position: absolute;
  top: -8px;
  right: -8px;
  border: 3px solid #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  animation: pulse 2s infinite;
}

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

/* Layout */
.layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  padding: 3rem clamp(1.5rem, 5vw, 4rem);
  transition: grid-template-columns 0.3s ease;
  max-width: 1600px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .layout {
    padding: var(--spacing-lg) var(--spacing-md);
    gap: var(--spacing-xl);
  }
}

@media (max-width: 480px) {
  .layout {
    padding: var(--spacing-md) var(--spacing-sm);
    gap: var(--spacing-lg);
  }
}

.layout.cart-open {
  grid-template-columns: minmax(0, 3fr) minmax(350px, 1fr);
}

@media (max-width: 980px) {
  .layout.cart-open {
    grid-template-columns: 1fr;
    position: relative;
  }
  
  /* Override hidden class for mobile - use transform instead of display:none */
  .cart-panel.hidden {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    transform: translateX(100%) !important;
  }
  
  .cart-panel {
    position: fixed !important;
    top: 0;
    right: 0;
    width: 90%;
    max-width: 400px;
    height: 100vh;
    padding: 0;
    z-index: 10000 !important;
    overflow-y: auto;
    overflow-x: hidden;
    border-radius: 0;
    box-shadow: -5px 0 25px rgba(0,0,0,0.5);
    -webkit-overflow-scrolling: touch;
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
  
  .cart-panel:not(.hidden) {
    transform: translateX(0) !important;
  }
  
  .cart-header {
    position: sticky;
    top: 0;
    background: var(--bg-gradient);
    padding: 1.5rem;
    z-index: 10;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .cart-list {
    padding: var(--spacing-md);
    min-height: auto;
    flex: 1;
    gap: var(--spacing-sm);
  }
  
  .cart-item-content {
    padding: var(--spacing-sm);
    gap: var(--spacing-sm);
  }
  
  .cart-item-image {
    width: 50px;
    height: 50px;
    flex-shrink: 0;
    min-width: 50px;
    min-height: 50px;
  }
  
  .cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 3px;
    max-width: 100%;
    max-height: 100%;
  }
  
  .cart-item-name {
    font-size: 0.95rem;
  }
  
  .cart-item-price {
    font-size: 0.95rem;
  }
  
  .cart-item-description {
    font-size: 0.8rem;
    -webkit-line-clamp: 1;
    line-clamp: 1;
  }
  
  .cart-item-actions {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-xs);
    flex-wrap: nowrap;
  }
  
  .cart-qty-controls {
    flex: 0 0 auto;
  }
  
  .cart-qty-btn {
    min-width: 40px;
    min-height: 40px;
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
  
  .cart-qty-value {
    min-width: 2.5rem;
    font-size: 1rem;
  }
  
  .cart-remove-btn {
    flex: 0 0 auto;
    min-width: auto;
    padding: var(--spacing-xs) var(--spacing-sm);
  }
  
  .cart-remove-btn .remove-text {
    display: none;
  }
  
  .cart-remove-btn .remove-icon {
    font-size: 1.4rem;
  }
  
  #checkoutForm {
    padding: var(--spacing-md);
  }
  
  #checkoutForm h3 {
    font-size: 1rem;
  }
  
  #checkoutForm label {
    font-size: 0.875rem;
  }
  
  .cart-header {
    padding: var(--spacing-md);
  }
  
  .cart-header h2 {
    font-size: 1.25rem;
  }
  
  .close-cart-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    font-size: 1.6rem;
  }
  
  .cart-total {
    padding: var(--spacing-md);
    font-size: 1rem;
  }
  
  .cart-total span:last-child {
    font-size: 1.1rem;
  }
  
  /* Cart overlay backdrop */
  .cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }
  
  .cart-overlay.active {
    opacity: 1;
    pointer-events: all;
  }
  
  /* Prevent body scroll when cart is open on mobile */
  body.cart-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
  }
}

/* Landscape mobile optimizations */
@media (max-width: 980px) and (orientation: landscape) {
  .cart-panel {
    max-height: 100vh;
  }
  
  .cart-header {
    padding: var(--spacing-sm) var(--spacing-md);
  }
  
  .cart-list {
    padding: var(--spacing-sm);
  }
  
  .cart-item-content {
    padding: var(--spacing-xs) var(--spacing-sm);
  }
  
  .cart-item-image {
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    flex-shrink: 0;
  }
  
  .cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 3px;
    max-width: 100%;
    max-height: 100%;
  }
}

/* Small mobile devices (320px - 375px) */
@media (max-width: 375px) {
  .cart-panel {
    width: 100%;
  }
  
  .cart-item-image {
    width: 45px;
    height: 45px;
    min-width: 45px;
    min-height: 45px;
    flex-shrink: 0;
  }
  
  .cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 2px;
    max-width: 100%;
    max-height: 100%;
  }
  
  .cart-item-name {
    font-size: 0.85rem;
  }
  
  .cart-item-price {
    font-size: 0.85rem;
  }
  
  .cart-qty-btn {
    min-width: 40px;
    min-height: 40px;
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }
  
  .cart-header h2 {
    font-size: 1.1rem;
  }
  
  .cart-total {
    font-size: 0.9rem;
  }
  
  .cart-total span:last-child {
    font-size: 0.95rem;
  }
  
  .close-cart-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    font-size: 1.4rem;
  }
}

/* Extra small devices (max-width: 320px) */
@media (max-width: 320px) {
  .cart-panel {
    width: 100%;
  }
  
  .cart-header {
    padding: var(--spacing-xs) var(--spacing-sm);
  }
  
  .cart-list {
    padding: var(--spacing-xs);
  }
  
  .cart-item-content {
    padding: var(--spacing-xs);
  }
  
  .cart-item-image {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    flex-shrink: 0;
  }
  
  .cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 2px;
    max-width: 100%;
    max-height: 100%;
  }
  
  .cart-item-name {
    font-size: 0.8rem;
  }
  
  .cart-item-price {
    font-size: 0.8rem;
  }
  
  .cart-qty-btn {
    min-width: 36px;
    min-height: 36px;
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }
  
  .cart-total {
    padding: var(--spacing-xs) var(--spacing-sm);
    font-size: 0.85rem;
  }
  
  #checkoutForm {
    padding: var(--spacing-xs) var(--spacing-sm);
  }
  
  #checkoutForm h3 {
    font-size: 0.9rem;
  }
  
  #checkoutForm label {
    font-size: 0.8rem;
  }
}

/* Category Grid */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  margin-top: 2rem;
}

@media (max-width: 768px) {
  .category-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

.category-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: all var(--transition-slow);
  cursor: pointer;
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  -webkit-tap-highlight-color: rgba(2, 119, 189, 0.1);
  touch-action: manipulation;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--primary);
}

.category-image {
  width: 100%;
  height: 300px;
  overflow: hidden;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.category-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2rem;
  transition: transform 0.3s ease;
}

.category-card:hover .category-image img {
  transform: scale(1.1);
}

.category-content {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1;
}

@media (max-width: 768px) {
  .category-content {
    padding: var(--spacing-lg);
  }
  
  .category-content h3 {
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .category-content {
    padding: var(--spacing-md);
  }
  
  .category-content h3 {
    font-size: 1.35rem;
  }
}

.category-content h3 {
  margin: 0;
  font-size: 1.75rem;
  font-weight: var(--font-weight-semibold);
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: var(--line-height-tight);
}

@media (max-width: 768px) {
  .category-content h3 {
    font-size: 1.5rem;
  }
  
  .category-content {
    padding: var(--spacing-lg);
  }
  
  .category-image {
    height: 250px;
  }
}

@media (max-width: 480px) {
  .category-content h3 {
    font-size: 1.35rem;
  }
  
  .category-content {
    padding: var(--spacing-md);
  }
  
  .category-image {
    height: 220px;
  }
}

.category-content p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: var(--line-height-normal);
  flex: 1;
  font-weight: var(--font-weight-normal);
}

.category-btn {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 1rem 2rem;
  border-radius: var(--radius-sm);
  font-weight: var(--font-weight-medium);
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition-base);
  margin-top: auto;
  width: 100%;
  min-height: 44px;
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
}

.category-btn:hover {
  background: var(--primary-dark);
  box-shadow: var(--card-shadow-hover);
}

/* Catalog */
.catalog-wrapper {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: var(--spacing-2xl);
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-light);
}

@media (max-width: 768px) {
  .catalog-wrapper {
    padding: var(--spacing-lg);
    border-radius: var(--radius-sm);
  }
}

@media (max-width: 480px) {
  .catalog-wrapper {
    padding: var(--spacing-md);
  }
}

.section-header h2 {
  margin: 0 0 var(--spacing-sm);
  font-size: 2rem;
  font-weight: var(--font-weight-semibold);
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: var(--line-height-tight);
}

.section-header p {
  margin: 0 0 var(--spacing-xl);
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
}

@media (max-width: 768px) {
  .section-header h2 {
    font-size: 1.75rem;
  }
  
  .section-header p {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .section-header h2 {
    font-size: 1.5rem;
  }
  
  .section-header p {
    font-size: 0.95rem;
  }
}

@media (max-width: 768px) {
  .section-header h2 {
    font-size: 1.75rem;
    margin-bottom: var(--spacing-xs);
  }
  
  .section-header p {
    font-size: 1rem;
    margin-bottom: var(--spacing-lg);
  }
}

@media (max-width: 480px) {
  .section-header h2 {
    font-size: 1.5rem;
  }
  
  .section-header p {
    font-size: 0.95rem;
  }
}

.catalog {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
}

@media (max-width: 768px) {
  .catalog {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* Card */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: var(--spacing-lg);
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  transition: all var(--transition-slow);
  height: 100%;
  border: 1px solid var(--border-light);
  overflow: hidden;
  touch-action: manipulation;
}

.card-inner {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  align-items: stretch;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--primary);
}

.card figure {
  margin: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  flex-shrink: 0;
}

.card img {
  width: 100%;
  max-width: 240px;
  height: 200px;
  border-radius: var(--radius-sm);
  object-fit: contain;
  transition: all var(--transition-slow);
  cursor: pointer;
  background: var(--bg);
  padding: var(--spacing-md);
  border: 1px solid var(--border-light);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.card img:hover {
  transform: scale(1.05);
  box-shadow: var(--card-shadow-hover);
}

.card .details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
  flex: 1;
  min-height: 0;
}

.card h3 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-normal);
  color: var(--text);
  min-height: 2.8em;
  display: flex;
  align-items: flex-start;
  letter-spacing: -0.01em;
}

@media (max-width: 768px) {
  .card {
    padding: var(--spacing-lg);
  }
  
  .card h3 {
    font-size: 1.1rem;
    min-height: auto;
  }
  
  .card img {
    height: 180px;
  }
}

@media (max-width: 480px) {
  .card {
    padding: var(--spacing-md);
  }
  
  .card h3 {
    font-size: 1rem;
  }
  
  .card img {
    height: 160px;
  }
  
  .card .price-line {
    font-size: 1.25rem;
  }
}

.card .tagline {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.card .price-line {
  margin: var(--spacing-sm) 0;
  font-weight: var(--font-weight-semibold);
  font-size: 1.4rem;
  color: var(--primary);
}

.card .description {
  margin: var(--spacing-sm) 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: var(--line-height-normal);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 4.5em;
  font-weight: var(--font-weight-normal);
}

.card .specs {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.card .specs li {
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding-left: 1.2rem;
  position: relative;
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
}

.card .specs li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: bold;
  font-size: 0.85rem;
}

/* Controls with add to cart button */
.controls {
  display: flex;
  justify-content: stretch;
  margin-top: auto;
  padding-top: 1.25rem;
  border-top: 2px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.add-to-cart-btn {
  border: none;
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--primary);
  color: #fff;
  font-size: 0.95rem;
  font-weight: var(--font-weight-medium);
  cursor: pointer;
  border-radius: var(--radius-sm);
  width: 100%;
  transition: all var(--transition-base);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: var(--card-shadow);
  position: relative;
  overflow: hidden;
  min-height: 44px;
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
  touch-action: manipulation;
}

.add-to-cart-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.add-to-cart-btn:hover::before {
  left: 100%;
}

.add-to-cart-btn:hover {
  background: var(--primary-dark);
  box-shadow: var(--card-shadow-hover);
}

.add-to-cart-btn:active {
  transform: translateY(-1px);
}

/* Cart Panel */
.cart-panel {
  background: var(--bg-gradient);
  color: #ffffff;
  border-radius: var(--radius);
  padding: 0;
  box-shadow: var(--card-shadow-hover);
  display: flex;
  flex-direction: column;
  gap: 0;
  position: sticky;
  top: 0;
  max-height: 80vh;
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.1);
  -webkit-overflow-scrolling: touch;
}

.cart-header {
  padding: var(--spacing-lg) var(--spacing-xl);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  background: var(--bg-gradient);
  z-index: 10;
}

.cart-header h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: var(--font-weight-semibold);
  color: #ffffff;
  letter-spacing: -0.01em;
}

.close-cart-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  border-radius: var(--radius-sm);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.close-cart-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

.close-cart-btn:active {
  transform: scale(0.95);
}

.cart-panel::-webkit-scrollbar {
  width: 8px;
}

.cart-panel::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.cart-panel::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.cart-panel::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

.cart-panel.hidden {
  display: none;
}
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  width: 36px;
  height: 36px;
  padding: 0 !important;
  font-size: 1.5rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50% !important;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}


.cart-list {
  list-style: none;
  margin: 0;
  padding: var(--spacing-lg);
  background: rgba(255, 255, 255, 0.05);
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  min-height: 0;
}

.cart-item {
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  transition: all var(--transition-base);
}

.cart-item:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.15);
}

.cart-item-content {
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  align-items: flex-start;
}

@media (max-width: 980px) {
  .cart-item-content {
    gap: var(--spacing-sm);
    padding: var(--spacing-sm);
    align-items: center;
  }
}

@media (max-width: 480px) {
  .cart-item-content {
    gap: var(--spacing-xs);
    padding: var(--spacing-xs);
    align-items: center;
  }
}

.cart-item-image {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  min-width: 80px;
  min-height: 80px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-item-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: var(--spacing-xs);
  max-width: 100%;
  max-height: 100%;
}

.cart-item-details {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.cart-item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--spacing-sm);
}

.cart-item-name {
  margin: 0;
  font-size: 1rem;
  font-weight: var(--font-weight-medium);
  color: #ffffff;
  line-height: var(--line-height-tight);
  flex: 1;
  min-width: 0;
}

.cart-item-price {
  font-size: 1rem;
  font-weight: var(--font-weight-semibold);
  color: #ffffff;
  white-space: nowrap;
  flex-shrink: 0;
}

.cart-item-description {
  margin: 0;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-xs);
  flex-wrap: wrap;
}

.cart-remove-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.9);
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: var(--font-weight-normal);
  transition: all var(--transition-base);
  min-height: 32px;
  touch-action: manipulation;
}

.cart-remove-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
  color: #ffffff;
}

.cart-remove-btn .remove-icon {
  font-size: 1.2rem;
  line-height: 1;
}

.cart-remove-btn .remove-text {
  display: inline;
}

@media (max-width: 480px) {
  .cart-remove-btn .remove-text {
    display: none;
  }
  
  .cart-remove-btn {
    min-width: 32px;
    min-height: 32px;
    padding: var(--spacing-xs);
    justify-content: center;
  }
}

.cart-qty-controls {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  padding: var(--spacing-xs);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.cart-qty-btn {
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  border-radius: var(--radius-sm);
  border: none;
  outline: none;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  font-weight: var(--font-weight-medium);
  font-size: 1.1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-base);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
}

.cart-qty-btn:focus {
  outline: none !important;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2) !important;
}

.cart-qty-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.25);
}

.cart-qty-btn:active:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(0.95);
}

.cart-qty-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  background: rgba(255, 255, 255, 0.08);
}

.cart-qty-value {
  min-width: 2rem;
  text-align: center;
  font-weight: var(--font-weight-medium);
  font-size: 0.95rem;
  color: #ffffff;
  user-select: none;
  padding: 0 var(--spacing-xs);
}


.cart-item button:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.6);
}

.cart-total {
  padding: var(--spacing-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: var(--font-weight-semibold);
  font-size: 1.1rem;
  color: #ffffff;
  margin: 0;
  flex-shrink: 0;
}

.cart-total span:first-child {
  font-weight: var(--font-weight-medium);
  color: rgba(255, 255, 255, 0.9);
}

.cart-total span:last-child {
  font-weight: var(--font-weight-semibold);
  font-size: 1.2rem;
  color: #ffffff;
}

/* Cart Checkout Form */
#checkoutForm {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  padding: var(--spacing-lg) var(--spacing-xl);
  background: rgba(255, 255, 255, 0.05);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

#checkoutForm h3 {
  margin: 0 0 var(--spacing-sm);
  font-size: 1.1rem;
  font-weight: var(--font-weight-semibold);
  color: #ffffff;
}

#checkoutForm label {
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.9rem;
}

#checkoutForm input,
#checkoutForm textarea {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 16px; /* Prevents zoom on iOS */
}

#checkoutForm input::placeholder,
#checkoutForm textarea::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

#checkoutForm input:focus,
#checkoutForm textarea:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

#checkoutForm button.primary {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  margin-top: var(--spacing-xs);
}

#checkoutForm button.primary:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.4);
}

/* Forms */
form {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  padding: var(--spacing-lg);
}

@media (max-width: 768px) {
  form {
    padding: var(--spacing-md);
    gap: var(--spacing-sm);
  }
}

@media (max-width: 480px) {
  form {
    padding: var(--spacing-sm);
  }
}

label {
  display: flex;
  flex-direction: column;
  font-weight: var(--font-weight-medium);
  font-size: 0.95rem;
  color: var(--text);
}

input,
textarea {
  margin-top: var(--spacing-xs);
  padding: var(--spacing-sm);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-size: 0.95rem;
  background: var(--card-bg);
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
  font-size: 16px;
  transition: all var(--transition-base);
  font-weight: var(--font-weight-normal);
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(2, 119, 189, 0.1);
}

@media (max-width: 768px) {
  input,
  textarea {
    min-height: 44px;
    padding: 0.875rem;
    font-size: 16px; /* Prevents zoom on iOS */
    width: 100%;
  }
  
  textarea {
    min-height: 100px;
  }
}

@media (max-width: 480px) {
  input,
  textarea {
    padding: 0.75rem;
  }
}

textarea {
  resize: vertical;
}

button.primary {
  border: none;
  padding: var(--spacing-md) var(--spacing-lg);
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: #ffffff;
  font-weight: var(--font-weight-medium);
  cursor: pointer;
  min-height: 44px;
  transition: all var(--transition-base);
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  touch-action: manipulation;
  box-shadow: var(--card-shadow);
}

button.primary:hover {
  background: var(--primary-dark);
  box-shadow: var(--card-shadow-hover);
}

/* Footer */
footer {
  background: var(--primary);
  color: #ffffff;
  padding: var(--spacing-xl) clamp(1.5rem, 5vw, 4rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-md);
}

@media (max-width: 768px) {
  footer {
    padding: var(--spacing-lg) var(--spacing-md);
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-lg);
  }
}

@media (max-width: 480px) {
  footer {
    padding: var(--spacing-md) var(--spacing-sm);
    gap: var(--spacing-md);
  }
}

.footer-left {
  display: flex;
  align-items: center;
}

.footer-logo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: contain;
  background: #ffffff;
  border: 2px solid rgba(255,255,255,0.5);
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.footer-logo:hover {
  transform: scale(1.05);
  box-shadow:
    0 8px 16px rgba(0,0,0,0.18),
    0 0 16px rgba(0,0,0,0.08) inset;
}

.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
  text-align: left;
}

.footer-contact p {
  margin: 0.15rem 0;
}

footer small {
  font-size: 0.85rem;
  opacity: 0.85;
}

@media (max-width: 640px) {
  .footer-right {
    align-items: flex-start;
    text-align: left;
  }
  
  .footer-logo {
    width: 48px;
    height: 48px;
  }
}

@media (max-width: 480px) {
  .footer-logo {
    width: 44px;
    height: 44px;
  }
  
  footer small {
    font-size: 0.8rem;
  }
}

/* Toast */
#toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  padding: 0.85rem 1.2rem;
  border-radius: 0.6rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 10;
}

#toast.show {
  opacity: 1;
}

/* FAQ Section */
.faq-section {
  max-width: 960px;
  margin: 0 auto 3rem;
  padding: 0 1.5rem;
}

.faq-section h2 {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  text-align: left;
}

@media (max-width: 768px) {
  .faq-section {
    padding: 0 1rem;
    margin: 0 auto 2rem;
  }
  
  .faq-section h2 {
    font-size: 1.75rem;
  }
  
  .faq-item summary {
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
  }
  
  .faq-item p {
    padding: 0.75rem 1rem 0.875rem;
    font-size: 0.9rem;
  }
}

.faq-section p.faq-intro {
  margin: 0 0 1.5rem;
  color: var(--muted);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.faq-item {
  background: #ffffff;
  border-radius: 0.9rem;
  box-shadow: var(--card-shadow);
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 1rem 1.25rem;
  list-style: none;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.faq-item summary::marker,
.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary span {
  pointer-events: none;
}

.faq-item summary .faq-icon {
  font-size: 1.25rem;
  margin-left: 0.75rem;
}

.faq-item[open] summary {
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.faq-item p {
  margin: 0;
  padding: 0.75rem 1.25rem 1rem;
  font-size: 0.95rem;
  color: var(--muted);
}

/* Product Detail Page */
.product-detail-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem clamp(1.5rem, 5vw, 4rem);
}

.product-detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 2.5rem;
  box-shadow: var(--card-shadow);
}

@media (max-width: 980px) {
  .product-detail-content {
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
    padding: var(--spacing-xl);
  }
}

@media (max-width: 768px) {
  .product-detail-content {
    padding: var(--spacing-lg);
    gap: var(--spacing-lg);
  }
}

@media (max-width: 480px) {
  .product-detail-content {
    padding: var(--spacing-md);
    gap: var(--spacing-md);
  }
}

.product-gallery {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.gallery-main {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: var(--radius-sm);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  touch-action: pan-y pinch-zoom;
  user-select: none;
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2rem;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  border: none;
  width: 48px;
  height: 48px;
  min-width: 44px; /* Touch target size */
  min-height: 44px; /* Touch target size */
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10;
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
  touch-action: manipulation;
}

.gallery-nav:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: translateY(-50%) scale(1.1);
}

.gallery-prev {
  left: 1rem;
}

.gallery-next {
  right: 1rem;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 0.75rem;
}

.gallery-thumb {
  aspect-ratio: 1;
  background: var(--bg);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition-base);
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(2, 119, 189, 0.2);
  user-select: none;
}

.gallery-thumb:hover {
  border-color: var(--primary);
  transform: scale(1.05);
}

.gallery-thumb.active {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(2, 119, 189, 0.2);
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.5rem;
}

.product-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.product-info h1 {
  margin: 0;
  font-size: 2rem;
  font-weight: var(--font-weight-semibold);
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: var(--line-height-tight);
}

@media (max-width: 768px) {
  .product-info h1 {
    font-size: 1.75rem;
  }
}

@media (max-width: 480px) {
  .product-info h1 {
    font-size: 1.5rem;
  }
}

.product-price {
  font-size: 2rem;
  font-weight: var(--font-weight-semibold);
  color: var(--primary);
  margin: 0;
}

@media (max-width: 768px) {
  .product-price {
    font-size: 1.75rem;
  }
}

@media (max-width: 480px) {
  .product-price {
    font-size: 1.5rem;
  }
}

.product-description {
  font-size: 1.1rem;
  line-height: var(--line-height-relaxed);
  color: var(--text-secondary);
  margin: 0;
  font-weight: var(--font-weight-normal);
}

@media (max-width: 768px) {
  .product-description {
    font-size: 1rem;
    line-height: var(--line-height-normal);
  }
}

@media (max-width: 480px) {
  .product-description {
    font-size: 0.95rem;
  }
}

.product-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.product-features li {
  font-size: 1rem;
  color: var(--text-secondary);
  padding-left: 1.5rem;
  position: relative;
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
}

@media (max-width: 480px) {
  .product-features li {
    font-size: 0.95rem;
    padding-left: 1.25rem;
  }
}

.product-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: bold;
  font-size: 1.1rem;
}

.product-actions {
  margin-top: auto;
}

.add-to-cart-btn.large {
  width: 100%;
  padding: 1.25rem 2rem;
  font-size: 1.1rem;
}

@media (max-width: 768px) {
  .add-to-cart-btn.large {
    padding: 1rem 1.5rem;
    font-size: 1rem;
    min-height: 48px;
  }
}

@media (max-width: 480px) {
  .add-to-cart-btn.large {
    padding: 0.875rem 1.25rem;
    font-size: 0.95rem;
  }
}

/* WhatsApp Floating Button */
.whatsapp-float {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 64px;
  height: 64px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.5), 0 2px 8px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  color: #ffffff;
  text-decoration: none;
  border: 3px solid rgba(255, 255, 255, 0.3);
  min-width: 64px;
  min-height: 64px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

@media (max-width: 768px) {
  .whatsapp-float {
    width: 56px;
    height: 56px;
    min-width: 56px;
    min-height: 56px;
    bottom: 1.5rem;
    right: 1.5rem;
  }
  
  .whatsapp-float svg {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 480px) {
  .whatsapp-float {
    width: 52px;
    height: 52px;
    min-width: 52px;
    min-height: 52px;
    bottom: 1rem;
    right: 1rem;
  }
  
  .whatsapp-float svg {
    width: 28px;
    height: 28px;
  }
}

.whatsapp-float:hover {
  transform: scale(1.15) translateY(-2px);
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.7), 0 4px 12px rgba(0, 0, 0, 0.3);
  background: #20BA5A;
  border-color: rgba(255, 255, 255, 0.5);
}

.whatsapp-float:active {
  transform: scale(1.05) translateY(0);
}

.whatsapp-float svg {
  width: 38px;
  height: 38px;
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}


/* Mobile and Tablet Optimizations */
@media (max-width: 980px) {
  .layout {
    padding: 2rem clamp(1rem, 4vw, 2rem);
    gap: 1.5rem;
  }
  
  .layout.cart-open {
    grid-template-columns: 1fr;
  }
  
  .catalog-wrapper {
    padding: 1.5rem;
  }
  
  .catalog {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
  }
  
  .category-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 768px) {
  /* Hero Section Mobile - Professional Medical Aesthetic */
  .hero {
    min-height: 50vh;
    height: 55vh;
    max-height: 400px;
    /* Ensure proper centering on mobile */
    align-items: center;
    justify-content: center;
    /* Calm, minimal appearance */
    background: #1a4d2e; /* Fallback medical green */
  }
  
  /* Video optimization for mobile */
  .hero-video {
    /* Ensure video covers entire area without distortion */
    min-width: 100%;
    min-height: 100%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    /* Prevent video from being too zoomed or cropped */
    transform: translate(-50%, -50%) scale(1);
    /* Smooth transitions */
    -webkit-transform: translate(-50%, -50%);
    will-change: opacity;
  }
  
  .hero-background {
    /* Ensure background container covers full area */
    width: 100%;
    height: 100%;
    overflow: hidden;
  }
  
  .hero-video-container {
    /* Ensure container is properly sized */
    width: 100%;
    height: 100%;
    overflow: hidden;
  }
  
  /* Content optimization for mobile - Calm, balanced layout */
  .hero-content {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    /* Generous padding for white space */
    padding: 2.5rem 1.5rem;
    gap: 2.5rem;
    text-align: center;
    /* Ensure content is always visible and centered */
    position: relative;
    z-index: 3;
    /* Prevent content from being pushed off-screen */
    min-height: auto;
    max-width: 100%;
  }
  
  /* Branding Mobile - Calm, Professional Medical Typography */
  .branding {
    text-align: center;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
  }
  
  .branding h1 {
    /* Calmer font size - not too bold or overwhelming */
    font-size: clamp(1.75rem, 5.5vw, 2.25rem);
    margin-bottom: 1.25rem;
    /* Softer font weight for medical professionalism */
    font-weight: 600;
    /* Enhanced text shadow for clarity without being heavy */
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5), 0 4px 20px rgba(0, 0, 0, 0.35);
    line-height: 1.3;
    letter-spacing: -0.01em;
    /* Calm, reassuring color */
    color: #ffffff;
  }
  
  .branding p {
    font-size: clamp(0.95rem, 2.8vw, 1.05rem);
    /* Generous line spacing for readability */
    line-height: 1.75;
    /* Enhanced text shadow for readability */
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5), 0 2px 12px rgba(0, 0, 0, 0.4);
    opacity: 0.98;
    max-width: 100%;
    margin: 0 auto;
    /* Calm font weight */
    font-weight: 400;
    /* More spacing between lines */
    letter-spacing: 0.01em;
  }
  
  .branding-logo {
    width: 60px;
    height: 60px;
    /* Softer shadow for medical aesthetic */
    box-shadow: 
      0 3px 8px rgba(0,0,0,0.2),
      0 0 10px rgba(0,0,0,0.08) inset;
  }
  
  /* Hero actions removed - now in utility bar */
  
  /* Category Cards Mobile */
  .category-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .category-image {
    height: 220px;
  }
  
  .category-content {
    padding: 1.5rem;
  }
  
  /* Product Cards Mobile */
  .catalog {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .card {
    padding: 1.5rem;
  }
  
  .card img {
    max-width: 100%;
    height: 180px;
  }
  
  .add-to-cart-btn {
    min-height: 44px; /* Touch target size */
    padding: 1rem 1.5rem;
  }
  
  /* Product Detail Mobile */
  .product-detail-content {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 1.5rem;
  }
  
  .product-gallery {
    gap: 0.75rem;
  }
  
  .gallery-main {
    aspect-ratio: 1;
    min-height: 300px;
  }
  
  .gallery-main img {
    padding: 1rem;
  }
  
  .gallery-nav {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    font-size: 1.25rem;
  }
  
  .gallery-prev {
    left: 0.5rem;
  }
  
  .gallery-next {
    right: 0.5rem;
  }
  
  .gallery-thumbs {
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 0.5rem;
  }
  
  .gallery-thumb {
    min-height: 60px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(2, 119, 189, 0.2);
  }
  
  .product-info h1 {
    font-size: 1.75rem;
    line-height: var(--line-height-tight);
  }
  
  .product-price {
    font-size: 1.5rem;
  }
  
  .add-to-cart-btn.large {
    min-height: 48px;
    padding: var(--spacing-md) var(--spacing-xl);
    width: 100%;
    font-size: 1rem;
  }
  
  /* Section Headers Mobile */
  .section-header {
    padding: 0 0 var(--spacing-lg) 0;
  }
  
  .section-header h2 {
    font-size: 1.75rem;
    line-height: var(--line-height-tight);
  }
  
  /* Back Button Mobile */
  .back-btn {
    width: 100%;
    min-height: 44px;
    justify-content: center;
  }
  
  /* WhatsApp Button Mobile */
  .whatsapp-float {
    width: 56px;
    height: 56px;
    bottom: 1.5rem;
    right: 1.5rem;
  }
  
  .whatsapp-float svg {
    width: 32px;
    height: 32px;
  }
  
  /* Video Carousel Mobile - Already optimized above */
  
  /* Footer Mobile */
  footer {
    flex-direction: column;
    text-align: center;
    padding: 2rem 1.5rem;
  }
  
  .footer-left,
  .footer-right {
    align-items: center;
    width: 100%;
  }
  
  .footer-right {
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 480px) {
  /* Extra Small Mobile - Calm, Professional Optimizations */
  .hero {
    min-height: 45vh;
    height: 50vh;
    max-height: 350px;
  }
  
  /* Ensure video is properly sized on very small screens */
  .hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    /* Further reduce visual noise on small screens */
    filter: brightness(0.8) contrast(0.9);
    -webkit-filter: brightness(0.8) contrast(0.9);
  }
  
  .hero-content {
    padding: 2rem 1.25rem;
    gap: 2rem;
  }
  
  .branding {
    margin-bottom: 1.25rem;
    padding: 0 0.75rem;
  }
  
  .branding h1 {
    font-size: clamp(1.5rem, 6.5vw, 2rem);
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.25;
  }
  
  .branding p {
    font-size: clamp(0.9rem, 3.2vw, 1rem);
    line-height: 1.7;
    font-weight: 400;
  }
  
  .branding-logo {
    width: 52px;
    height: 52px;
  }
  
  /* Hero actions removed - now in utility bar */
  
  .layout {
    padding: 1.5rem 1rem;
    gap: 1rem;
  }
  
  .catalog-wrapper {
    padding: 1rem;
  }
  
  .catalog {
    gap: 1rem;
  }
  
  .card {
    padding: 1.25rem;
  }
  
  .category-content {
    padding: 1.25rem;
  }
  
  .category-content h3 {
    font-size: 1.5rem;
  }
  
  .section-header h2 {
    font-size: 1.5rem;
  }
  
  .product-detail-content {
    padding: 1rem;
    gap: 1.5rem;
  }
  
  .product-gallery {
    gap: 0.5rem;
  }
  
  .gallery-main {
    min-height: 280px;
  }
  
  .gallery-thumbs {
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    gap: 0.5rem;
  }
  
  .gallery-thumb {
    min-height: 50px;
  }
  
  .gallery-nav {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    font-size: 1.1rem;
  }
  
  .product-info h1 {
    font-size: 1.5rem;
  }
  
  .product-price {
    font-size: 1.25rem;
  }
  
  .whatsapp-float {
    width: 52px;
    height: 52px;
    bottom: 1rem;
    right: 1rem;
  }
  
  .whatsapp-float svg {
    width: 28px;
    height: 28px;
  }
  
  .hero-video {
    transition: opacity 1.2s ease-in-out;
  }
  
  /* Ensure touch targets are adequate */
  button,
  .category-card,
  .card,
  .gallery-thumb,
  .gallery-nav {
    -webkit-tap-highlight-color: rgba(46, 125, 50, 0.1);
    touch-action: manipulation;
  }
  
  /* Improve scrolling on mobile */
  .cart-panel,
  .catalog-wrapper,
  .product-detail-content {
    -webkit-overflow-scrolling: touch;
  }
  
  /* Prevent text selection on touch */
  .gallery-main,
  .gallery-thumb {
    -webkit-user-select: none;
    user-select: none;
  }
}

/* Image Viewer Modal */
.image-viewer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.image-viewer:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

.image-viewer.hidden {
  display: none;
}

.image-viewer-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 1rem;
}

.image-viewer-content img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
}

.image-viewer-info {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.9rem;
}

.image-viewer-counter {
  font-weight: var(--font-weight-semibold);
}

.image-viewer-alt {
  font-size: 0.85rem;
  opacity: 0.9;
  text-align: center;
  max-width: 80vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.image-viewer-close,
.image-viewer-prev,
.image-viewer-next {
  position: absolute;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  border: none;
  width: 48px;
  height: 48px;
  min-width: 44px;
  min-height: 44px;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10001;
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
  touch-action: manipulation;
}

.image-viewer-close:hover,
.image-viewer-prev:hover,
.image-viewer-next:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

.image-viewer-close {
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
  line-height: 1;
}

.image-viewer-prev {
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.image-viewer-next {
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.image-viewer-prev:active,
.image-viewer-next:active {
  transform: translateY(-50%) scale(0.95);
}

.image-viewer-close:active {
  transform: scale(0.95);
}

@media (max-width: 768px) {
  .image-viewer-content {
    padding: 3rem 0.5rem;
  }
  
  .image-viewer-close,
  .image-viewer-prev,
  .image-viewer-next {
    width: 44px;
    height: 44px;
    font-size: 1.25rem;
  }
  
  .image-viewer-close {
    top: 0.75rem;
    right: 0.75rem;
  }
  
  .image-viewer-prev {
    left: 0.5rem;
  }
  
  .image-viewer-next {
    right: 0.5rem;
  }
  
  .image-viewer-info {
    bottom: 1rem;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
  }
  
  .image-viewer-alt {
    font-size: 0.75rem;
    max-width: 90vw;
  }
}

@media (max-width: 480px) {
  .image-viewer-content {
    padding: 2rem 0.25rem;
  }
  
  .image-viewer-close,
  .image-viewer-prev,
  .image-viewer-next {
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }
  
  .image-viewer-info {
    bottom: 0.75rem;
    padding: 0.5rem 0.75rem;
  }
}