/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: system-ui, sans-serif; color: #222; line-height: 1.5; }
svg { display: block; }
ul { list-style: none; }
button { font: inherit; }

/* ===== SCREEN READER ONLY ===== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ===== SKIP LINK ===== */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  padding: 0.5rem 1rem;
  background: #000;
  color: #fff;
  text-decoration: none;
  z-index: 9999;
  font-weight: 600;
}
.skip-link:focus { top: 0.5rem; }

/* ===== HEADER ===== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: 70px;
  background: #fff;
  border-bottom: 1px solid #ddd;
  z-index: 100;
}

.main-nav {
  height: 100%;
  display: flex;
  align-items: center;
  padding: 0 2rem;
}

.nav-categories {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex: 1;
}

.nav-logo {
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: #000;
  flex-shrink: 0;
  margin: 0 2rem;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
  justify-content: flex-end;
}

/* ===== DROPDOWN ===== */
.dropdown { position: relative; }

.dropdown-trigger {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.9375rem;
  padding: 0.375rem 0;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.dropdown-trigger:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 0.75rem);
  left: 0;
  background: #fff;
  border: 1px solid #ddd;
  min-width: 180px;
  z-index: 200;
  padding: 0.5rem 0;
  display: none;
}

.dropdown-trigger[aria-expanded="true"] + .dropdown-menu { display: block; }

.dropdown-menu a {
  display: block;
  padding: 0.625rem 1rem;
  text-decoration: none;
  font-size: 0.9375rem;
  color: #222;
}

.dropdown-menu a:hover,
.dropdown-menu a:focus { background: #f5f5f5; }

.dropdown-menu a:focus { outline: none; }

/* ===== ICON BUTTONS ===== */
.icon-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #222;
}

.icon-btn:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

/* ===== BREADCRUMB ===== */
.breadcrumb {
  margin-top: 70px;
  padding: 0.75rem 2rem;
  border-bottom: 1px solid #eee;
  font-size: 0.875rem;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0;
  align-items: center;
}

.breadcrumb li { display: flex; align-items: center; }

.breadcrumb li + li::before {
  content: "›";
  color: #999;
  padding: 0 0.5rem;
}

.breadcrumb a { text-decoration: none; color: #555; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb [aria-current="page"] { color: #222; font-weight: 500; }

/* ===== MAIN ===== */
main {
  padding: 2rem;
  max-width: 1280px;
  margin: 0 auto;
}

/* ===== PRODUCT SECTION ===== */
.product-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-bottom: 5rem;
}

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

.gallery-figure { margin: 0; }

.gallery-figure svg {
  width: 100%;
  height: auto;
}

/* Sticky product info */
.product-info {
  position: sticky;
  top: 86px;
  align-self: start;
}

.product-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.product-price {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.product-description {
  color: #555;
  margin-bottom: 1.5rem;
}

/* ===== COLOR SWITCHER ===== */
.color-switcher { margin-bottom: 1.5rem; }

.color-switcher fieldset { border: none; padding: 0; }

.color-switcher legend {
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.color-options {
  display: flex;
  gap: 0.75rem;
}

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

.color-label {
  display: block;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid transparent;
  outline: 2px solid transparent;
  outline-offset: 3px;
}

.color-radio:checked + .color-label { border-color: #222; }

.color-radio:focus-visible + .color-label { outline-color: #005fcc; }

/* ===== PRODUCT ACTIONS ===== */
.product-actions {
  display: flex;
  gap: 1rem;
  align-items: stretch;
}

.btn-add-to-cart {
  flex: 1;
  padding: 0.875rem 1.5rem;
  background: #222;
  color: #fff;
  border: 2px solid #222;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.025em;
}

.btn-add-to-cart:hover { background: #444; border-color: #444; }

.btn-add-to-cart:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.btn-wishlist {
  padding: 0.875rem;
  background: none;
  border: 2px solid #222;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #222;
}

.btn-wishlist:hover { background: pink; }

.btn-wishlist[aria-pressed="true"] svg {
  fill: #e53e3e;
  stroke: #e53e3e;
}

.btn-wishlist:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

/* ===== RELATED PRODUCTS ===== */
.related-section { margin-bottom: 4rem; }

.section-heading {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.carousel-wrapper { position: relative; }

.carousel-viewport { overflow: hidden; }

.carousel-track {
  display: flex;
  gap: 1.5rem;
  transition: transform 0.3s ease;
}

.carousel-slide { flex: 0 0 calc(25% - 1.125rem); }

.carousel-slide a {
  text-decoration: none;
  color: #222;
  display: block;
}

.carousel-slide a:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.carousel-slide svg { width: 100%; height: auto; }

.slide-title {
  margin-top: 0.5rem;
  font-weight: 500;
  font-size: 0.9375rem;
}

.slide-price {
  color: #555;
  font-size: 0.9375rem;
  margin-top: 0.25rem;
}

.carousel-btn {
  position: absolute;
  top: 35%;
  transform: translateY(-50%);
  background: #fff;
  border: 1px solid #ddd;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.carousel-btn:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.carousel-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.carousel-btn-prev { left: -1.25rem; }
.carousel-btn-next { right: -1.25rem; }

/* ===== FOOTER ===== */
.site-footer {
  background: #1a1a1a;
  color: #fff;
  padding: 3rem 2rem 2rem;
}

.footer-grid {
  max-width: 1280px;
  margin: 0 auto 2rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}

.footer-col h2 {
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
  color: #fff;
}

.footer-col ul { display: flex; flex-direction: column; gap: 0.5rem; }

.footer-col a {
  color: #aaa;
  text-decoration: none;
  font-size: 0.875rem;
}

.footer-col a:hover,
.footer-col a:focus { color: #fff; text-decoration: underline; }

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding-top: 1.5rem;
  border-top: 1px solid #333;
  font-size: 0.8125rem;
  color: #777;
  text-align: center;
}

/* ===== CART DIALOG ===== */
.cart-dialog {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: auto;
  width: 400px;
  max-width: 100vw;
  margin: 0;
  padding: 0;
  border: none;
  border-left: 1px solid #ddd;
  background: #fff;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.cart-dialog:not([open]) { display: none; }

.cart-dialog.slide-in { transform: translateX(0); }

.cart-dialog::backdrop { background: rgba(0, 0, 0, 0.25); }

.dialog-inner {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.dialog-title { font-size: 1.125rem; font-weight: 700; }

.dialog-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  display: flex;
  align-items: center;
  color: #222;
}

.dialog-close:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.dialog-product {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.dialog-product-image { width: 80px; flex-shrink: 0; }
.dialog-product-image svg { width: 100%; height: auto; }

.dialog-product-name { font-weight: 600; margin-bottom: 0.25rem; }
.dialog-product-price { font-size: 1.125rem; font-weight: 600; }

#cursornone,
#cursornone a,
#cursornone a:hover,
#cursornone button,
#cursornone button:hover {
  cursor: none !important;
  text-decoration: none !important;
}

#cursornone .btn-add-to-cart:hover {
  background: #222 !important;
  border-color: #222 !important;
}

#cursornone .btn-wishlist:hover{
  background: #ffffff !important;
}

html:has(#cursornone),
#cursornone {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

html:has(#cursornone)::-webkit-scrollbar,
#cursornone::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}