/* 
 * ROBO ARENA - High-Performance Design System
 * Theme: Modern Minimalism / Premium Robotics
 */

:root {
  /* --- Color Palette --- */
  --bg-core: #0a0a0c;
  --bg-surface: #141416;
  --bg-card: #1c1c1f;
  --bg-card-hover: #252529;

  --accent-primary: #00f0ff;
  --accent-glow: rgba(0, 240, 255, 0.4);
  --accent-dim: rgba(0, 240, 255, 0.1);

  --text-main: #ffffff;
  --text-secondary: #a0a0a5;
  --text-muted: #6e6e73;

  --border-subtle: #2a2a2e;
  --border-accent: rgba(0, 240, 255, 0.3);

  /* --- Typography --- */
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-tech: 'JetBrains Mono', monospace;

  /* --- Spacing System --- */
  --space-2: 0.5rem;
  --space-4: 1rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-24: 6rem;
  --space-32: 8rem;

  --container-max: 1280px;
}

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

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg-core);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
}

h1, h2, h3, h4 { font-family: var(--font-heading); color: var(--text-main); }
p { color: var(--text-secondary); }
a { color: inherit; text-decoration: none; transition: 0.3s; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* Utility Classes */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.text-accent { color: var(--accent-primary); }
.text-mono { font-family: var(--font-tech); }
.bg-surface { background-color: var(--bg-surface); }
.text-center { text-align: center; }

    /* Header */
#main-header {
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  padding: var(--space-4) 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  background: rgba(10, 10, 12, 0.8);
  -webkit-backdrop-filter: blur(12px); /* Safari Fix */
  backdrop-filter: blur(12px);
  transition: padding 0.3s;
}

/* ... existing code ... */

.text-gradient {
    background: linear-gradient(135deg, #fff 0%, var(--accent-primary) 100%);
    -webkit-background-clip: text; /* Safari Fix */
    background-clip: text;
    -webkit-text-fill-color: transparent; /* Safari Fix */
    color: transparent;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.05em;
}

.desktop-nav {
  display: none;
  gap: var(--space-8);
}

@media(min-width: 768px) {
  .desktop-nav { display: flex; }
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-primary);
  transition: width 0.3s;
}

.nav-link:hover::after { width: 100%; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8em 2em;
  font-family: var(--font-heading);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.875rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
}

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

.btn-primary:hover {
  background-color: transparent;
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: 0 0 20px var(--accent-dim);
}

.btn-secondary {
  border-color: var(--border-subtle);
  background-color: transparent;
  color: var(--text-main);
}

.btn-secondary:hover {
  border-color: var(--text-main);
  background: rgba(255,255,255,0.05);
}

.btn-lg { padding: 1em 2.5em; font-size: 1rem; }
.btn-sm { padding: 0.5em 1.2em; font-size: 0.8rem; }
.btn-icon {
  background: transparent;
  border: none;
  color: var(--text-main);
  cursor: pointer;
}
.btn-icon:hover { color: var(--accent-primary); }

/* Hero Section */
.hero-section {
  padding-top: 140px;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
}

@media(min-width: 992px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.1;
  margin-bottom: var(--space-4);
}

.hero-desc {
  font-size: 1.125rem;
  margin-bottom: var(--space-8);
  max-width: 50ch;
}

.image-wrapper {
  position: relative;
  border-radius: var(--space-2);
  overflow: hidden;
}

.glow-effect::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, var(--accent-dim), transparent 70%);
  z-index: -1;
}

/* Sections */
.section { padding: var(--space-24) 0; }
.section-header {
  margin-bottom: var(--space-12);
  border-left: 2px solid var(--accent-primary);
  padding-left: var(--space-4);
}
.section-subtitle {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.875rem;
  font-family: var(--font-tech);
  color: var(--accent-primary);
  display: block;
  margin-bottom: var(--space-2);
}
.section-title { font-size: 2.5rem; }

/* Grid 3 */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-8);
}

/* Grid 2 */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: var(--space-8);
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  transition: all 0.3s ease;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0; /* Safari Grid Fix */
}

.card:hover {
  border-color: var(--border-accent);
  transform: translateY(-5px);
}

.card-image {
  background: linear-gradient(to bottom, #1b1b1e, var(--bg-card));
  padding: var(--space-4); /* Reduced padding for larger images */
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4/3;
  width: 100%; /* Explicit width for Safari */
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.5s ease;
}

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

.card-content, .product-info { padding: var(--space-8); }
.product-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.card-title, .product-title { margin-bottom: var(--space-2); font-size: 1.25rem; }
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: var(--space-4);
  color: var(--accent-primary);
  font-weight: 500;
}
.link-arrow:hover { gap: 0.8rem; }

/* Product Card Specifics */
.product-card { position: relative; }
.product-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--accent-primary);
  color: var(--bg-core);
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: 2px;
}
.product-specs {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.tech-spec {
  font-family: var(--font-tech);
  font-size: 0.8rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.05);
  padding: 2px 6px;
}
.product-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
}
.price { font-family: var(--font-tech); font-size: 1.1rem; color: var(--text-main); }


/* Why Choose Us - Enhanced */
.section-dark-grid {
  background-image: 
    linear-gradient(rgba(20, 20, 22, 0.9), rgba(10, 10, 12, 1)), /* Fade out */
    linear-gradient(rgba(42, 42, 46, 0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 42, 46, 0.3) 1px, transparent 1px);
  background-size: 100% 100%, 40px 40px, 40px 40px;
  background-position: center;
}

.why-grid {
  align-items: center;
}

.feature-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: var(--space-6);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
}

.feature-item:hover {
  border-color: var(--accent-primary);
  transform: translateX(10px);
  background: linear-gradient(90deg, var(--bg-surface), #18181c);
  box-shadow: -4px 4px 0 var(--accent-dim);
}

.feature-icon-wrapper {
  color: var(--accent-primary);
  background: rgba(0, 240, 255, 0.08);
  padding: 0;
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  max-width: 48px;
  max-height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  align-self: flex-start; /* Override parent alignment */
}

.feature-text h4 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.feature-text p {
  font-size: 0.95rem;
  margin: 0;
  color: var(--text-secondary);
}

/* Hologram Visual */
.info-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 500px;
}

.hologram-container {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hologram-image {
  max-width: 100%;
  height: auto;
  opacity: 0.9;
  filter: drop-shadow(0 0 20px var(--accent-dim));
  animation: float 6s ease-in-out infinite;
}

.hologram-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  height: 80%;
  background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

/* Decorative Data Points */
.data-point {
  position: absolute;
  width: 8px;
  height: 8px;
  border: 1px solid var(--accent-primary);
  background: rgba(0, 240, 255, 0.2);
  border-radius: 50%;
}

.data-point.p1 { top: 20%; right: 20%; }
.data-point.p2 { bottom: 30%; left: 10%; }
.data-point.p3 { top: 40%; left: 25%; }

.data-point::after {
  content: '';
  position: absolute;
  width: 40px;
  height: 1px;
  background: var(--accent-primary);
  top: 50%;
}

.data-point.p1::after { right: 100%; }
.data-point.p2::after { left: 100%; }
.data-point.p3::after { left: 50%; width: 20px; transform: rotate(45deg); transform-origin: left; }

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-15px); }
  100% { transform: translateY(0px); }
}


/* Footer */
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-12);
  margin-bottom: var(--space-12);
}
.footer-links h4, .footer-newsletter h4 {
  font-size: 1rem;
  margin-bottom: var(--space-4);
  color: var(--text-main);
}
.footer-links a {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}
.footer-links a:hover { color: var(--accent-primary); }
.newsletter-form { display: flex; gap: 0.5rem; }
.newsletter-form input {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 0.5rem 1rem;
  color: white;
  flex: 1;
}
.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-8);
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Animations */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in-up {
  opacity: 0;
  animation: fadeInUp 0.8s ease-out forwards;
}

/* Responsive Tweaks */
@media (max-width: 768px) {
  .hero-title { font-size: 2.5rem; }
  .grid-2 { gap: var(--space-8); }
  .section { padding: var(--space-12) 0; }
  .newsletter-form { flex-direction: column; }
  .hologram-container { height: 300px; }
  .info-visual { height: auto; margin-top: var(--space-8); }
}

/* Enhanced Hero Styles */

/* Hero Background & Atmosphere */
.hero-section {
  position: relative;
  overflow: hidden;
  background: 
    radial-gradient(circle at 80% 50%, rgba(0, 240, 255, 0.03) 0%, transparent 50%),
    linear-gradient(rgba(10, 10, 12, 1) 0%, rgba(10, 10, 12, 0.9) 100%),
    repeating-linear-gradient(transparent 0, transparent 49px, rgba(42, 42, 46, 0.1) 50px),
    repeating-linear-gradient(90deg, transparent 0, transparent 49px, rgba(42, 42, 46, 0.1) 50px);
    background-size: cover, cover, 50px 50px, 50px 50px;
}

.hero-bg-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.6;
}

.shape-1 {
    top: -20%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 240, 255, 0.15), transparent 70%);
}

.shape-2 {
    bottom: -10%;
    right: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(0, 100, 255, 0.08), transparent 70%);
}

/* Typography Enhancements */
.text-gradient {
    background: linear-gradient(135deg, var(--accent-primary) 0%, #ffffff 80%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(0, 240, 255, 0.2);
}

/* Robot Visuals */
.robot-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-robot-img {
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 0 50px rgba(0, 240, 255, 0.15));
    animation: floatRobot 6s ease-in-out infinite;
}

@keyframes floatRobot {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* HUD Elements */
.hud-badge {
    position: absolute;
    background: rgba(10, 10, 12, 0.8);
    border: 1px solid var(--accent-dim);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    backdrop-filter: blur(8px);
    z-index: 3;
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 15px rgba(0,0,0,0.5);
    animation: fadeInHud 1s ease-out forwards;
    opacity: 0;
}

.badge-right {
    top: 20%;
    right: 0;
    border-right: 3px solid var(--accent-primary);
    animation-delay: 1s;
}

.badge-left {
    bottom: 20%;
    left: 0;
    border-left: 3px solid var(--accent-primary);
    animation-delay: 1.2s;
}

.hud-label {
    font-family: var(--font-tech);
    font-size: 0.65rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
}

.hud-value {
    font-family: var(--font-tech);
    font-size: 0.9rem;
    color: var(--text-main);
    font-weight: 700;
}

.hud-circle {
    position: absolute;
    width: 120%;
    height: 120%;
    border: 1px dashed var(--accent-dim);
    border-radius: 50%;
    z-index: 1;
    animation: rotate 60s linear infinite;
}

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

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

/* Shop Page Styles */

.shop-sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
    padding-right: var(--space-4);
    border-right: 1px solid var(--border-subtle);
}

.filter-group {
    margin-bottom: var(--space-8);
}

.filter-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-4);
    color: var(--text-muted);
}

.filter-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-link {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.5rem;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all 0.2s;
}

.filter-link i {
    width: 18px;
    height: 18px;
}

.filter-link:hover, .filter-link.active {
    background: rgba(0, 240, 255, 0.05);
    color: var(--accent-primary);
}

.filter-link.active {
    border-left: 2px solid var(--accent-primary);
}

/* Price Slider Interactive */
.price-slider-container {
  position: relative;
  width: 100%;
  padding-top: 15px; 
}

.slider-track {
  width: 100%;
  height: 4px;
  background-color: var(--border-subtle);
  position: absolute;
  top: 15px; /* Aligns with input track */
  border-radius: 2px;
  z-index: 1;
}

input[type="range"] {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  width: 100%;
  outline: none;
  position: absolute;
  margin: auto;
  top: 15px; /* Check alignment */
  bottom: 0;
  background-color: transparent;
  pointer-events: none;
  z-index: 2;
}

.slider-track {
    background: linear-gradient(to right, 
        var(--border-subtle) 0%, 
        var(--border-subtle) 0%, /* Start of active range */
        var(--accent-primary) 0%, /* Start of highlight */
        var(--accent-primary) 60%, /* End of highlight */
        var(--border-subtle) 60%, 
        var(--border-subtle) 100%);
}

input[type="range"]::-webkit-slider-runnable-track {
  -webkit-appearance: none;
  height: 4px;
}

input[type="range"]::-moz-range-track {
  -moz-appearance: none;
  height: 4px;
}

input[type="range"]::-ms-track {
  appearance: none;
  height: 4px;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  height: 18px;
  width: 18px;
  background-color: var(--bg-core);
  border: 2px solid var(--accent-primary);
  border-radius: 50%;
  cursor: pointer;
  margin-top: -7px; /* Center thumb on track */
  pointer-events: auto;
  box-shadow: 0 0 5px rgba(0,0,0,0.5);
}

input[type="range"]::-moz-range-thumb {
  height: 18px;
  width: 18px;
  cursor: pointer;
  border-radius: 50%;
  background-color: var(--bg-core);
  border: 2px solid var(--accent-primary);
  pointer-events: auto;
  box-shadow: 0 0 5px rgba(0,0,0,0.5);
}

input[type="range"]::-ms-thumb {
  appearance: none;
  height: 18px;
  width: 18px;
  cursor: pointer;
  border-radius: 50%;
  background-color: var(--bg-core);
  border: 2px solid var(--accent-primary);
  pointer-events: auto;
  box-shadow: 0 0 5px rgba(0,0,0,0.5);
}

input[type="range"]:active::-webkit-slider-thumb {
  background-color: var(--accent-primary);
}

.range-values {
    display: flex;
    justify-content: space-between;
    margin-top: 25px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Responsive Shop */
@media (max-width: 992px) {
    .container { grid-template-columns: 1fr !important; }
    .shop-sidebar { 
        display: block; /* Show container */
        margin-bottom: var(--space-8);
    }
    
    #sidebar-content {
        display: none; /* Hidden by default on mobile */
        margin-top: var(--space-4);
        padding: var(--space-4);
        background: var(--bg-card);
        border: 1px solid var(--border-subtle);
        border-radius: var(--radius-sm);
    }
    
    #sidebar-content.active {
        display: block;
        animation: fadeIn 0.3s;
    }
    
    .mobile-filter-btn {
        display: flex;
        width: 100%;
        justify-content: space-between;
        align-items: center;
    }
}

@media (min-width: 993px) {
    .mobile-filter-btn {
        display: none; /* Hide toggle on desktop */
    }
    #sidebar-content {
        display: block !important;
    }
}

/* Carousel Styles */
.carousel-container {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-sm);
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex; /* Stack slides horizontally, though we toggle display for simplicity */
}

/* Simple fade/toggle approach */
.carousel-slide {
    display: none;
    width: 100%;
    height: 100%;
    animation: fadeEffect 0.5s;
}

.carousel-slide.active {
    display: block;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

@keyframes fadeEffect {
    from {opacity: 0.4}
    to {opacity: 1}
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(10, 10, 12, 0.8);
    color: var(--accent-primary);
    border: 1px solid var(--border-subtle);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    z-index: 10;
    opacity: 0;
    transition: all 0.3s;
}

.carousel-container:hover .carousel-btn {
    opacity: 1;
}

.carousel-btn:hover {
    background: var(--accent-primary);
    color: var(--bg-core);
    box-shadow: 0 0 10px var(--accent-dim);
}

.carousel-btn.prev { left: 10px; }
.carousel-btn.next { right: 10px; }

.carousel-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.dot {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transition: background 0.3s;
}

/* Product Detail Page Styles */

.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-8);
}

@media(min-width: 992px) {
    .product-detail-grid {
        grid-template-columns: 1.2fr 1fr;
        gap: var(--space-12);
    }
}

/* Gallery */
.product-gallery {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    /* Safari Flex Fixes */
    min-width: 0; 
}

.main-image-container {
    background: linear-gradient(to bottom, #1b1b1e, var(--bg-card));
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: var(--space-8);
    display: flex;
    align-items: center;
    justify-content: center;
    
    /* Safari aspect-ratio fallback mechanism */
    width: 100%;
    aspect-ratio: 4/3;
    /* In case aspect-ratio fails in very old versions, min-height helps */
    min-height: 300px;
    position: relative;
    overflow: hidden;
}

/* Ensure image doesn't overflow or collapse */
.main-image-container img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(0,0,0,0.5));
    transition: opacity 0.3s;
}

.thumbnail-list {
    display: flex;
    gap: var(--space-2);
    /* Safari gap fallback handled by flex wrap usually, but for row: */
    flex-wrap: wrap; 
}

.thumbnail {
    width: 80px;
    height: 80px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: var(--space-2);
    cursor: pointer;
    transition: all 0.2s;
    
    /* Prevent thumbnail squishing */
    flex-shrink: 0; 
    display: flex;
    align-items: center;
    justify-content: center;
}

.thumbnail.active, .thumbnail:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.1);
}

.thumbnail img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Info Panel */
.product-title-large {
    font-size: 2.5rem;
    line-height: 1.1;
    margin-bottom: var(--space-4);
}

.product-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-4);
    padding-bottom: var(--space-4);
    border-bottom: 1px solid var(--border-subtle);
}

.rating {
    display: flex;
    align-items: center;
}

.product-price-large {
    font-family: var(--font-tech);
    font-size: 2rem;
    color: var(--accent-primary);
    margin-bottom: var(--space-4);
    display: flex;
    align-items: baseline;
}

.product-short-desc {
    font-size: 1.1rem;
    margin-bottom: var(--space-8);
}

.product-actions {
    display: flex;
    gap: var(--space-4);
    margin-bottom: var(--space-8);
}

.quantity-selector {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-subtle);
    border-radius: 4px;
    background: var(--bg-card);
}

.qty-btn {
    background: transparent;
    border: none;
    color: var(--text-main);
    padding: 0 1rem;
    font-size: 1.2rem;
    cursor: pointer;
}

.qty-btn:hover { background: rgba(255,255,255,0.05); }

#qty-input {
    width: 50px;
    text-align: center;
    background: transparent;
    border: none;
    color: var(--text-main);
    font-family: var(--font-tech);
    font-size: 1.1rem;
    -moz-appearance: textfield;
}
#qty-input::-webkit-outer-spin-button,
#qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.btn-icon-lg {
    width: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.stock-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-tech);
    font-size: 0.9rem;
    color: #00ff88;
}

/* Tabs */
.tabs-header {
    display: flex;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: var(--space-8);
}

.tab-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 1rem 2rem;
    font-family: var(--font-heading);
    font-size: 1rem;
    cursor: pointer;
    position: relative;
}

.tab-btn.active {
    color: var(--accent-primary);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent-primary);
}

.tab-content.hidden { display: none; }

.specs-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    background: var(--bg-card);
    padding: var(--space-8);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.spec-row {
    display: flex;
    justify-content: space-between;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.spec-row:last-child { border-bottom: none; }

.spec-label { color: var(--text-secondary); }
.spec-value { font-family: var(--font-tech); color: var(--text-main); }

/* CSS Polish */

.breadcrumb a:hover {
    color: var(--accent-primary);
    text-decoration: underline;
}

.qty-btn:active {
    transform: scale(0.95);
    color: var(--accent-primary);
}

.tab-btn:hover {
    color: var(--text-main);
}

/* Related products spacing */
.product-detail-grid {
    margin-bottom: var(--space-8);
}

/* Better disabled state */
.btn:disabled, .btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* --- Mobile Optimization --- */

/* Mobile Header */
@media (max-width: 768px) {
    .desktop-nav {
        display: none; /* Simple hide, sidebar toggle would be ideal for v2 */
    }

    .header-inner {
        padding: 0 var(--space-4);
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--space-8);
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .grid-3, .grid-2 {
        grid-template-columns: 1fr !important;
    }
    
    /* Shop Mobile */
    .shop-grid .toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-4);
    }
    
    /* Product Detail Mobile */
    .product-detail-grid {
        grid-template-columns: 1fr;
    }
    
    .main-image-container {
        aspect-ratio: 1/1; 
    }
    
    .product-title-large {
        font-size: 2rem;
    }
    
    .product-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .product-actions {
        flex-direction: column;
    }
    
    .quantity-selector {
        width: 100%;
        justify-content: space-between;
    }
    
    .tabs-header {
        overflow-x: auto;
        white-space: nowrap;
        padding-bottom: 2px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--space-8);
        text-align: center;
    }
}

/* Product Description Layout */
.desc-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: var(--space-12);
    padding: var(--space-8) 0;
}

.desc-sidebar {
    position: sticky;
    top: 120px; /* Adjust based on header height */
    height: fit-content;
    padding-right: var(--space-4);
    border-right: 1px solid var(--border-subtle);
}

.sidebar-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: var(--space-4);
    font-family: var(--font-tech);
}

.desc-nav {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.desc-nav-link {
    display: block;
    padding: var(--space-2);
    color: var(--text-secondary);
    border-left: 2px solid transparent;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.desc-nav-link:hover, .desc-nav-link.active {
    color: var(--accent-primary);
    background: linear-gradient(90deg, rgba(0, 240, 255, 0.05), transparent);
    border-left-color: var(--accent-primary);
    padding-left: var(--space-4);
}

.desc-section {
    margin-bottom: var(--space-12);
    scroll-margin-top: 140px; /* Offset for sticky header */
}

/* Last section shouldn't have huge margin if it's the end */
.desc-section:last-child {
    margin-bottom: 0;
}

/* Content Styling */
.desc-body h2, .desc-body h3 {
    margin-bottom: var(--space-4);
    color: var(--text-main);
}

.desc-body p {
    margin-bottom: var(--space-4);
    line-height: 1.8;
}

.desc-body ul {
    list-style: disc;
    margin-left: var(--space-4);
    margin-bottom: var(--space-4);
    color: var(--text-secondary);
}

.desc-body li {
    margin-bottom: var(--space-2);
}

.desc-body img {
    border-radius: var(--space-2);
    margin: var(--space-8) 0;
    width: 100%;
    border: 1px solid var(--border-subtle);
}

@media (max-width: 768px) {
    .desc-layout {
        grid-template-columns: 1fr;
        gap: var(--space-8);
    }
    
    .desc-sidebar {
        display: none;
    }
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-btn i {
    width: 24px;
    height: 24px;
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }
    
    .header-actions .btn {
        display: none;
    }
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-core);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-4);
    border-bottom: 1px solid var(--border-subtle);
}

.mobile-menu-close {
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-close i {
    width: 24px;
    height: 24px;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    padding: var(--space-8) var(--space-4);
}

.mobile-nav-link {
    padding: var(--space-4);
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--accent-primary);
    padding-left: var(--space-8);
}

