:root {
  --bg-base: #F8F9FC;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #FFFFFF;
  --bg-subtle: #F1F3F9;
  --bg-subtle-hover: #E8EBF4;
  --border-subtle: #E2E5F0;
  --border-strong: #C8CDDE;
  --text-main: #0F1124;
  --text-muted: #5E6380;
  --text-subtle: #8E94B2;
  
  /* Brand colors */
  --primary: #E4007C;
  --primary-hover: #C5006B;
  --primary-light: rgba(228, 0, 124, 0.08);
  --cyan: #0093D0;
  --cyan-light: rgba(0, 147, 208, 0.08);
  --yellow: #FFD100;
  --yellow-dark: #B89600;
  --dark-navy: #12142E;
  --emerald: #0E9F6E;
  --emerald-light: rgba(14, 159, 110, 0.1);
  --amber: #FF7A00;
  --danger: #E02424;

  /* Typography */
  --font-display: 'Bricolage Grotesque', -apple-system, sans-serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  /* Elevation Shadows */
  --shadow-sm: 0 2px 4px rgba(18, 20, 46, 0.04);
  --shadow-md: 0 6px 18px rgba(18, 20, 46, 0.06);
  --shadow-lg: 0 14px 34px rgba(18, 20, 46, 0.1);
  --shadow-xl: 0 22px 50px rgba(18, 20, 46, 0.15);
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --nav-height: 72px;
  --bottom-dock-height: 64px;
}

[data-theme="dark"] {
  --bg-base: #0B0D1B;
  --bg-surface: #13172C;
  --bg-surface-elevated: #1A1F3B;
  --bg-subtle: #1D2342;
  --bg-subtle-hover: #262D55;
  --border-subtle: #272F55;
  --border-strong: #3D487D;
  --text-main: #F4F6FD;
  --text-muted: #A3AABF;
  --text-subtle: #6D7596;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 14px 34px rgba(0, 0, 0, 0.6);
  --shadow-xl: 0 22px 50px rgba(0, 0, 0, 0.75);
}

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

body {
  font-family: var(--font-body);
  background: var(--bg-base);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--text-main);
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

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

/* =========================================================
   TOP NAVIGATION BAR
   ========================================================= */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-height);
  background: color-mix(in srgb, var(--bg-surface) 85%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 40px);
  gap: 16px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: var(--text-main);
}

.brand-badge {
  display: grid;
  grid-template-columns: 8px 8px;
  gap: 3px;
}

.brand-badge span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--text-muted);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text-main);
  background: var(--bg-subtle);
}

.nav-link.active {
  background: var(--text-main);
  color: var(--bg-surface);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.role-badge-select {
  display: flex;
  align-items: center;
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 4px 12px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.role-badge-select select {
  border: none;
  background: transparent;
  padding-left: 4px;
  font-weight: 700;
  color: var(--text-main);
  outline: none;
}

.btn-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  display: grid;
  place-items: center;
  font-size: 1.15rem;
  color: var(--text-main);
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: var(--bg-subtle-hover);
  border-color: var(--border-strong);
}

.btn-cart-nav {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: var(--primary);
  color: #FFFFFF;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.92rem;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(228, 0, 124, 0.3);
}

.btn-cart-nav:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
}

.cart-count-pill {
  background: #FFFFFF;
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: var(--radius-full);
}

/* =========================================================
   BOTTOM MOBILE NAVIGATION DOCK
   ========================================================= */
.mobile-bottom-dock {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--bottom-dock-height) + env(safe-area-inset-bottom, 0px));
  background: color-mix(in srgb, var(--bg-surface) 92%, transparent);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-subtle);
  z-index: 1000;
  justify-content: space-around;
  align-items: flex-start;
  padding-top: 6px;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.mobile-dock-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 600;
  flex: 1;
  position: relative;
  transition: color 0.15s ease;
}

.mobile-dock-btn .dock-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.mobile-dock-btn.active {
  color: var(--primary);
}

.mobile-dock-btn .dock-badge {
  position: absolute;
  top: -2px;
  right: 28%;
  background: var(--primary);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 99px;
}

@media (max-width: 860px) {
  .nav-links {
    display: none;
  }
  .mobile-bottom-dock {
    display: flex;
  }
  body {
    padding-bottom: calc(var(--bottom-dock-height) + env(safe-area-inset-bottom, 0px) + 20px);
  }
}

/* =========================================================
   SHARED LAYOUT & CONTAINER
   ========================================================= */
.container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 clamp(16px, 3.5vw, 40px);
}

.section {
  padding: clamp(32px, 5vw, 64px) 0;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.section-header h2 {
  font-size: clamp(1.6rem, 3.2vw, 2.4rem);
}

.section-header p {
  color: var(--text-muted);
  font-size: 1rem;
  margin-top: 4px;
}

/* =========================================================
   BUTTONS & BADGES
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #FFFFFF;
  box-shadow: 0 4px 16px rgba(228, 0, 124, 0.28);
}

.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(228, 0, 124, 0.38);
}

.btn-secondary {
  background: var(--bg-subtle);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
}

.btn-secondary:hover {
  background: var(--bg-subtle-hover);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.btn-dark {
  background: var(--dark-navy);
  color: #FFFFFF;
}

.btn-dark:hover {
  background: #1B1E40;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 16px 32px;
  font-size: 1.05rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
}

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

.badge-cyan {
  background: var(--cyan-light);
  color: var(--cyan);
}

.badge-emerald {
  background: var(--emerald-light);
  color: var(--emerald);
}

.badge-yellow {
  background: rgba(255, 209, 0, 0.15);
  color: var(--yellow-dark);
}

/* =========================================================
   HERO SECTION
   ========================================================= */
.hero {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
  padding: clamp(24px, 5vw, 60px) 0;
}

.hero-copy h1 {
  font-size: clamp(2.4rem, 5.2vw, 4.4rem);
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin-bottom: 20px;
}

.hero-copy h1 span.highlight {
  color: var(--primary);
  display: inline-block;
}

.hero-copy p.lede {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--text-muted);
  max-width: 50ch;
  margin-bottom: 28px;
}

.hero-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
}

.hero-input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hero-input-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.hero-input-group input, .hero-input-group select {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-weight: 600;
  outline: none;
  min-width: 170px;
}

.hero-input-group input:focus, .hero-input-group select:focus {
  border-color: var(--primary);
}

.hero-stage {
  position: relative;
  background: radial-gradient(circle at 60% 40%, var(--bg-surface), var(--bg-subtle));
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  height: clamp(380px, 60vh, 560px);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.hero-viewport {
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}

.hero-viewport:active {
  cursor: grabbing;
}

.hero-floating-controls {
  position: absolute;
  top: 14px;
  left: 14px;
  display: flex;
  gap: 6px;
  background: color-mix(in srgb, var(--bg-surface) 80%, transparent);
  backdrop-filter: blur(12px);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.hero-floating-controls button {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
}

.hero-floating-controls button.active {
  background: var(--primary);
  color: #fff;
}

.hero-hint {
  position: absolute;
  bottom: 12px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-subtle);
  pointer-events: none;
}

@media (max-width: 960px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .hero-stage {
    height: 400px;
  }
}

/* =========================================================
   FEATURE RIBBON
   ========================================================= */
.ribbon-banner {
  background: var(--dark-navy);
  color: #FFFFFF;
  border-radius: var(--radius-md);
  padding: 16px 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  align-items: center;
  gap: 16px;
  margin: 12px 0 36px;
  box-shadow: var(--shadow-md);
}

.ribbon-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  font-weight: 600;
}

.ribbon-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* =========================================================
   COMMUNITY CREATIONS LIVE TICKER & SHOWCASE
   ========================================================= */
.community-section {
  background: color-mix(in srgb, var(--primary) 4%, var(--bg-surface));
  border: 1px solid color-mix(in srgb, var(--primary) 20%, var(--border-subtle));
  border-radius: var(--radius-lg);
  padding: 32px clamp(16px, 3vw, 36px);
  margin: 36px 0;
  position: relative;
  overflow: hidden;
}

.community-section::before {
  content: '';
  position: absolute;
  top: -40px;
  right: -40px;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(228, 0, 124, 0.15), transparent 70%);
  pointer-events: none;
}

.community-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.live-pulse {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(14, 159, 110, 0.15);
  color: var(--emerald);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 800;
}

.live-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--emerald);
  animation: pulse 1.8s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

.community-scroll {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 12px;
  -webkit-overflow-scrolling: touch;
}

.community-scroll::-webkit-scrollbar {
  height: 6px;
}
.community-scroll::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 99px;
}

.community-card {
  flex: 0 0 clamp(240px, 30vw, 300px);
  scroll-snap-align: start;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

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

.community-thumb {
  width: 100%;
  height: 180px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.community-thumb img, .community-thumb canvas {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  filter: drop-shadow(0 8px 12px rgba(18, 20, 46, 0.2));
}

.community-info h4 {
  font-size: 1rem;
  margin-bottom: 4px;
}

.community-creator-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* =========================================================
   PRODUCT CARDS & GRIDS
   ========================================================= */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 22px;
}

.product-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-sm);
}

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

.product-card-thumb {
  position: relative;
  background: radial-gradient(circle at 50% 40%, var(--bg-surface), var(--bg-subtle));
  height: 240px;
  display: grid;
  place-items: center;
  padding: 16px;
  cursor: pointer;
}

.product-card-thumb canvas, .product-card-thumb img {
  max-height: 100%;
  max-width: 90%;
  object-fit: contain;
  filter: drop-shadow(0 10px 16px rgba(18, 20, 46, 0.25));
  transition: transform 0.3s ease;
}

.product-card:hover .product-card-thumb canvas,
.product-card:hover .product-card-thumb img {
  transform: scale(1.05);
}

.product-badge-overlay {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.product-card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.product-card-title {
  font-size: 1.05rem;
  font-weight: 700;
}

.product-maker-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.maker-avatar-sm {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
}

.product-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
}

.product-price {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

/* =========================================================
   SHOP PAGE: FILTERS & LAYOUT
   ========================================================= */
.shop-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 32px;
  align-items: flex-start;
}

.shop-sidebar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  position: sticky;
  top: calc(var(--nav-height) + 20px);
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.filter-group h4 {
  font-size: 0.95rem;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
}

.filter-checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--text-muted);
  cursor: pointer;
}

.filter-checkbox-label input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--primary);
  border-radius: 4px;
}

.price-slider-wrap input[type="range"] {
  width: 100%;
  accent-color: var(--primary);
}

.filter-mobile-trigger {
  display: none;
}

@media (max-width: 900px) {
  .shop-layout {
    grid-template-columns: 1fr;
  }
  .shop-sidebar {
    position: static;
  }
}

/* =========================================================
   3D CASE STUDIO (INTERACTIVE BUILDER)
   ========================================================= */
.studio-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 28px;
  align-items: flex-start;
  padding: 20px 0 40px;
}

.studio-viewport-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: var(--shadow-md);
}

.studio-tab-bar {
  display: flex;
  gap: 8px;
}

.studio-tab-btn {
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.9rem;
  background: var(--bg-subtle);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
}

.studio-tab-btn.active {
  background: var(--text-main);
  color: var(--bg-surface);
  border-color: var(--text-main);
}

.studio-stage-box {
  position: relative;
  width: 100%;
  height: clamp(420px, 66vh, 640px);
  background: radial-gradient(circle at 50% 40%, var(--bg-surface), var(--bg-subtle));
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.studio-3d-canvas {
  width: 100%;
  height: 100%;
  touch-action: none;
}

.studio-flat-proof-view {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: var(--bg-subtle);
  cursor: crosshair;
}

.studio-flat-proof-view canvas {
  max-width: 92%;
  max-height: 92%;
  object-fit: contain;
}

.studio-orbit-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding-top: 6px;
}

.studio-pose-buttons {
  display: flex;
  gap: 6px;
}

.studio-controls-sidebar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: var(--shadow-md);
}

.control-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.control-section-title {
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  display: flex;
  justify-content: space-between;
}

.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip-btn {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-subtle);
  background: var(--bg-surface);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  transition: all 0.15s ease;
}

.chip-btn.active {
  border-color: var(--primary);
  background: var(--primary-light);
  color: var(--primary);
}

.swatch-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.swatch-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--border-subtle);
  transition: all 0.15s ease;
}

.swatch-btn.active {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}

.dpi-alert {
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
}

.dpi-good {
  background: rgba(14, 159, 110, 0.12);
  color: var(--emerald);
  border: 1px solid rgba(14, 159, 110, 0.3);
}

.dpi-warning {
  background: rgba(255, 122, 0, 0.12);
  color: var(--amber);
  border: 1px solid rgba(255, 122, 0, 0.3);
}

.studio-price-summary {
  border-top: 1px solid var(--border-subtle);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.price-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.price-total-line {
  display: flex;
  justify-content: space-between;
  font-size: 1.4rem;
  font-weight: 800;
  font-family: var(--font-display);
  color: var(--text-main);
  padding-top: 6px;
}

@media (max-width: 960px) {
  .studio-layout {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   3D PRODUCTS & STL CUSTOMIZER
   ========================================================= */
.prints-gallery-header {
  background: linear-gradient(135deg, var(--dark-navy) 0%, #20244E 100%);
  color: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 40px clamp(20px, 4vw, 48px);
  margin-bottom: 36px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 28px;
  align-items: center;
}

.prints-gallery-header h1 {
  color: #FFFFFF;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.05;
}

@media (max-width: 860px) {
  .prints-gallery-header {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   CART & CHECKOUT (PAKISTAN PAYMENT & SHIPPING)
   ========================================================= */
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 32px;
  align-items: flex-start;
  padding: 24px 0 60px;
}

.checkout-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: var(--shadow-md);
}

.cart-item-row {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.cart-item-img {
  width: 80px;
  height: 100px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
}

.cart-item-img img, .cart-item-img canvas {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.payment-methods-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.payment-method-card {
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.payment-method-card.active {
  border-color: var(--primary);
  background: var(--primary-light);
}

.payment-badge-jazzcash {
  color: #EB1B24;
  font-weight: 800;
}

.payment-badge-easypaisa {
  color: #00B14F;
  font-weight: 800;
}

@media (max-width: 900px) {
  .checkout-layout {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   SEPARATED & SECURED ADMIN PANEL
   ========================================================= */
.admin-wrapper {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  padding: 24px 0 60px;
  align-items: flex-start;
}

.admin-sidebar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: sticky;
  top: calc(var(--nav-height) + 20px);
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-muted);
  transition: all 0.2s ease;
}

.admin-nav-item:hover {
  background: var(--bg-subtle);
  color: var(--text-main);
}

.admin-nav-item.active {
  background: var(--primary);
  color: #FFFFFF;
}

.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.kpi-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}

.kpi-card .kpi-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-main);
}

.kpi-card .kpi-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.admin-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.admin-data-table th, .admin-data-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.admin-data-table th {
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

@media (max-width: 900px) {
  .admin-wrapper {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   MODALS & TOAST NOTIFICATION
   ========================================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 17, 36, 0.65);
  backdrop-filter: blur(8px);
  z-index: 1500;
  display: grid;
  place-items: center;
  padding: 16px;
}

.modal-content {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  max-width: 560px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  max-height: 90vh;
  overflow-y: auto;
}

#toastNotification {
  position: fixed;
  bottom: calc(var(--bottom-dock-height) + 20px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--dark-navy);
  color: #FFFFFF;
  padding: 12px 22px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.92rem;
  box-shadow: var(--shadow-lg);
  z-index: 2000;
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
  transition: all 0.25s ease;
}

[hidden] {
  display: none !important;
}
