/* INTERLAY Phase 2 Custom Refinements — Milanese Footwear Atelier Theme */

/* Smooth scrolling and refined typography */
html {
  scroll-behavior: smooth;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

/* Classical atelier editorial serif accents */
.font-atelier {
  font-family: -apple-system, BlinkMacSystemFont, "Didot", "Bodoni MT", "Cinzel", "Playfair Display", "Georgia", serif;
}

/* Custom crisp warm scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #faf8f5;
}

::-webkit-scrollbar-thumb {
  background: #dcd7cc;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #b8b0a2;
}

/* Three.js Canvas Container */
#three-canvas {
  outline: none;
  display: block;
}

/* Subtle transitions */
.transition-all {
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

/* Flexible, wrap-friendly card hover states with warm atelier elevation */
.card-hover:hover {
  border-color: #d6cfc2;
  box-shadow: 0 4px 12px -2px rgba(40, 18, 53, 0.05), 0 2px 4px -2px rgba(40, 18, 53, 0.04);
}

/* Footwear technical sheet convention: toe pointing right (Ref #1 and Ref #2) */
.shoe-mirror-h {
  -webkit-transform: scaleX(-1) !important;
  transform: scaleX(-1) !important;
}
.group:hover .shoe-mirror-h {
  -webkit-transform: scaleX(-1.05) scaleY(1.05) !important;
  transform: scaleX(-1.05) scaleY(1.05) !important;
}

/* Tab active indicators — Deep Milanese Plum (#401235) */
.tab-active {
  border-bottom: 2px solid #401235;
  color: #401235;
  font-weight: 600;
}

.tab-inactive {
  border-bottom: 2px solid transparent;
  color: #78716c;
}
.tab-inactive:hover {
  color: #401235;
  border-bottom-color: #dcd7cc;
}

/* Drawer sub-tab active states */
.drawer-tab-active {
  background-color: #401235;
  color: #ffffff;
  font-weight: 600;
}
.drawer-tab-inactive {
  background-color: #f5f2ec;
  color: #57534e;
}
.drawer-tab-inactive:hover {
  background-color: #ece7dc;
  color: #401235;
}

/* Language switcher pill active states */
.lang-btn-active {
  background-color: #401235;
  color: #ffffff;
  font-weight: 700;
}
.lang-btn-inactive {
  background-color: transparent;
  color: #78716c;
  font-weight: 600;
}
.lang-btn-inactive:hover {
  color: #401235;
}

/* Slide-over Drawer Animation */
.drawer-backdrop {
  transition: opacity 0.2s ease-in-out;
}
.drawer-panel {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Responsive wrap utility for longer Italian text without clipping */
.flexible-text-wrap {
  min-width: 0;
  word-break: normal;
  overflow-wrap: break-word;
}

/* Ensure mobile layouts never produce unwanted horizontal viewport overflow */
body {
  overflow-x: hidden;
}

@media (max-width: 640px) {
  #top-nav-operational-controls {
    width: 100%;
    justify-content: space-between;
  }
}

/* Print styles for Factory Technical Sheet */
@media print {
  body {
    background: white !important;
    color: black !important;
  }
  header, footer, #sketches-section, #components-section, #two-col-section, #discussion-section, #factory-bridge-section, .no-print {
    display: none !important;
  }
  #tech-sheet-modal {
    position: static !important;
    display: block !important;
    background: white !important;
    padding: 0 !important;
  }
  #tech-sheet-modal > div {
    max-width: 100% !important;
    box-shadow: none !important;
    border: none !important;
    padding: 0 !important;
  }
}
