:root {
  --accent-deep: #d94f17;
  --accent-soft: #fff1ea;
  --surface-raised: #ffffff;
  --surface-subtle: #f7f8fa;
  --line-strong: #dfe3e8;
  --focus-ring: 0 0 0 4px rgba(255, 106, 26, .17);
}

html {
  scroll-padding-top: 96px;
}

body {
  background: #fbfcfd;
  color: #15171b;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 0;
  box-shadow: var(--focus-ring);
}

.site-header {
  box-shadow: 0 7px 26px rgba(15, 23, 42, .05);
}

.nav-wrap {
  position: relative;
}

.main-nav > a {
  transition: color .18s ease;
}

.main-nav > a:hover {
  color: var(--accent-deep);
}

.mobile-menu {
  display: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: 13px;
  font-size: 1.25rem;
  cursor: pointer;
  transition: .18s ease;
}

.mobile-menu:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}

.mobile-nav {
  display: none;
}

.hero {
  background: radial-gradient(circle at 84% 7%, rgba(255, 106, 26, .2), transparent 29%), linear-gradient(180deg, #fff 0%, #f5f7fa 100%);
  padding-top: 84px;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero h1 {
  max-width: 700px;
}

.hero h1 span {
  color: var(--accent-deep);
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.trust-row span::first-letter {
  color: var(--green);
}

.stats-strip {
  box-shadow: 0 16px 40px rgba(15, 23, 42, .06);
}

.stats-strip > div {
  transition: background .18s ease;
}

.stats-strip > div:hover {
  background: #fffaf7;
}

.featured-section {
  padding: 12px 0 92px;
  background: linear-gradient(180deg, #fbfcfd 0%, #f4f6f8 100%);
}

.featured-head {
  margin-bottom: 28px;
}

.featured-head > p {
  max-width: 560px;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.featured-card {
  grid-column: span 2;
}

.featured-card-primary {
  grid-column: span 6;
}

.featured-card-primary .product-image {
  aspect-ratio: 1.22 / 1;
}

.featured-card:not(.featured-card-primary) .product-image {
  aspect-ratio: 1 / 1;
}

.featured-card .product-body {
  padding: 21px;
}

.featured-card .product-image {
  min-height: 0;
}

.featured-card .product-body p {
  min-height: 72px;
}

.featured-mini {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border: 1px solid #ffd4c0;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.featured-mini::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.product-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.product-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border-color: #e4e7eb;
  border-radius: 20px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, .045);
}

.product-card:hover {
  transform: translateY(-5px);
  border-color: #d9dde3;
  box-shadow: 0 22px 46px rgba(15, 23, 42, .12);
}

.product-image {
  isolation: isolate;
  aspect-ratio: 1 / 1;
  background: #eef1f4;
}

.product-image img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  transition: transform .45s cubic-bezier(.2, .7, .2, 1), filter .3s ease;
}

.product-image-backdrop {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(180deg, rgba(13, 16, 21, .02) 35%, rgba(13, 16, 21, .7) 100%);
  opacity: 0;
  transition: opacity .25s ease;
}

.product-image-hover {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 15px;
  z-index: 4;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  color: #fff;
  text-align: left;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .25s ease, transform .25s ease;
}

.product-image-link {
  position: absolute;
  inset: 0;
  z-index: 3;
}

.product-image-action {
  display: inline-flex;
  flex: 1 1 auto;
  justify-content: center;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, .85);
  border-radius: 10px;
  background: #fff;
  color: #15171b;
  font-size: .875rem;
  font-weight: 750;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.product-image-action:hover {
  background: #ffe4d6;
}

.product-image-action:focus-visible {
  outline: 3px solid #ff6a1a;
  outline-offset: 3px;
}

.product-image:hover img,
.product-image:focus-within img {
  transform: scale(1.045);
}

.product-image:hover .product-image-backdrop,
.product-image:focus-within .product-image-backdrop,
.product-image:hover .product-image-hover,
.product-image:focus-within .product-image-hover {
  opacity: 1;
  transform: translateY(0);
}

.product-image:focus-within {
  box-shadow: var(--focus-ring);
  outline: 0;
}

.product-image .badge,
.product-image .m3d-badges,
.product-image .photo-count {
  pointer-events: none;
}

.product-card:has(.m3d-badges .m3d-badge) .product-image .badge {
  top: 3.5rem;
  bottom: auto;
}

.product-image .m3d-badges {
  z-index: 5;
}

@media (hover: none), (pointer: coarse) {
  .product-image-hover,
  .product-image-backdrop {
    opacity: 1;
    transform: none;
  }
}

.badge {
  z-index: 5;
  top: 13px;
  left: 13px;
  border-color: rgba(255, 255, 255, .9);
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(8px);
}

.badge.sold {
  background: #fff4f2;
}

.photo-count {
  position: absolute;
  top: 13px;
  right: 13px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, .88);
  border-radius: 999px;
  background: rgba(13, 16, 21, .72);
  color: #fff;
  font-size: .72rem;
  font-weight: 850;
  backdrop-filter: blur(8px);
}

.product-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px;
}

.product-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 25px;
}

.product-kicker {
  overflow: hidden;
  color: #77808c;
  font-size: .7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-body h3 {
  margin: 12px 0 7px;
  font-size: 1.14rem;
  letter-spacing: -.015em;
}

.product-title {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.product-title:hover {
  color: var(--accent-deep);
}

.product-body p {
  display: -webkit-box;
  overflow: hidden;
  min-height: 66px;
  margin: 0;
  color: #68707d;
  font-size: .9rem;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.product-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 18px;
  color: #71808e;
  font-size: .73rem;
  font-weight: 750;
}

.stock-pill,
.photo-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.stock-pill {
  color: var(--green);
}

.stock-pill.is-sold {
  color: var(--danger);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 3px rgba(13, 139, 94, .14);
}

.stock-pill.is-sold .status-dot {
  box-shadow: 0 0 0 3px rgba(180, 35, 24, .12);
}

.photo-meta {
  color: #7b8793;
}

.product-footer {
  align-items: end;
  margin-top: 13px;
  padding-top: 15px;
  border-top: 1px solid #edf0f2;
}

.price-block {
  min-width: 0;
}

.price-label {
  display: block;
  margin-bottom: 2px;
  color: #8b96a3;
  font-size: .65rem;
  font-weight: 850;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.price {
  font-size: 1.28rem;
  letter-spacing: -.025em;
}

.price small {
  display: block;
  max-width: 110px;
  color: #68707d;
  font-size: .74rem;
  line-height: 1.25;
}

.product-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.btn.small {
  min-height: 38px;
  border-radius: 10px;
  padding: 8px 12px;
}

.btn.filled-soft {
  border-color: #ffd4c0;
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.btn.filled-soft:hover {
  border-color: #ffad88;
  background: #ffe6d8;
}

.product-modal-card {
  padding: 34px;
  background: linear-gradient(145deg, #fff 0%, #fbfcfd 100%);
}

.product-layout {
  gap: 52px;
}

@media (min-width: 921px) {
  .gallery {
    position: sticky;
    top: 0;
  }
}

.gallery-main {
  position: relative;
  border-color: #e2e6eb;
  border-radius: 24px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .08);
}

.gallery-image-button {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #f1f3f5;
  cursor: zoom-in;
}

.gallery-image-button img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  transition: transform .3s ease;
}

.gallery-image-button:hover img {
  transform: scale(1.018);
}

.gallery-image-button::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, .75);
  border-radius: 22px;
  pointer-events: none;
}

.gallery-zoom-label {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 999px;
  background: rgba(13, 16, 21, .72);
  color: #fff;
  font-size: .7rem;
  font-weight: 850;
  opacity: 0;
  transform: translateY(5px);
  transition: .2s ease;
}

.gallery-image-button:hover .gallery-zoom-label,
.gallery-image-button:focus-visible .gallery-zoom-label {
  opacity: 1;
  transform: translateY(0);
}

.gallery-count {
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 2;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  color: #4b5563;
  font-size: .72rem;
  font-weight: 850;
  box-shadow: 0 6px 15px rgba(15, 23, 42, .08);
}

.gallery-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 13px 2px 0;
  color: #7a8592;
  font-size: .72rem;
}

.gallery-caption strong {
  color: #4b5563;
  font-size: .72rem;
  font-weight: 750;
  text-align: right;
}

.gallery-thumbs {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 76px;
  justify-content: start;
  overflow-x: auto;
  gap: 9px;
  margin-top: 12px;
  padding: 2px 2px 6px;
}

.thumb {
  width: 76px;
  border-color: transparent;
  border-radius: 13px;
  background: #f1f3f5;
  box-shadow: 0 4px 10px rgba(15, 23, 42, .06);
}

.thumb.active {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 106, 26, .13);
}

.thumb img {
  width: 72px;
  height: 66px;
  border-radius: 10px;
  object-fit: cover;
}

.product-info {
  padding-top: 13px;
}

.product-info h2 {
  margin-top: 10px;
  font-size: clamp(2.1rem, 4vw, 4rem);
  letter-spacing: -.055em;
}

.detail-price {
  margin: 22px 0;
  color: var(--accent-deep);
  font-size: 2.25rem;
  letter-spacing: -.045em;
}

.spec-grid > div {
  border-color: #e5e8ec;
  background: rgba(255, 255, 255, .72);
}

.buy-row {
  margin-top: 28px;
}

.buy-row input {
  height: 49px;
}

.product-actions-secondary {
  margin-top: 8px;
}

.image-lightbox {
  z-index: 140;
}

.lightbox-card {
  position: relative;
  z-index: 1;
  width: min(1060px, 100%);
  max-height: 94vh;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 26px;
  background: #0d1015;
  box-shadow: 0 40px 120px rgba(0, 0, 0, .45);
}

.lightbox-card .modal-close {
  top: 12px;
  right: 12px;
  border-color: #3a424d;
  background: #171b22;
  color: #fff;
}

.lightbox-image-wrap {
  display: grid;
  place-items: center;
  min-height: 260px;
  max-height: calc(94vh - 95px);
  overflow: hidden;
  border-radius: 17px;
  background: #11151b;
}

.lightbox-image-wrap img {
  width: auto;
  max-width: 100%;
  max-height: calc(94vh - 125px);
  object-fit: contain;
}

.lightbox-caption {
  margin: 12px 48px 2px;
  color: #d8dde5;
  font-size: .85rem;
  text-align: center;
}

@media (max-width: 1100px) {
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .featured-card {
    grid-column: span 2;
  }

  .featured-card-primary {
    grid-column: span 6;
  }
}

@media (max-width: 920px) {
  .main-nav > a {
    display: none;
  }

  .mobile-menu {
    display: grid;
  }

  .mobile-nav {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 60;
    width: min(320px, calc(100vw - 24px));
    padding: 9px;
    border: 1px solid var(--line-strong);
    border-radius: 18px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 20px 50px rgba(15, 23, 42, .15);
  }

  .mobile-nav.open {
    display: grid;
  }

  .mobile-nav a,
  .mobile-nav button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 45px;
    padding: 10px 12px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--ink);
    font-size: .92rem;
    font-weight: 800;
    text-align: left;
    cursor: pointer;
  }

  .mobile-nav a:hover,
  .mobile-nav button:hover {
    background: var(--accent-soft);
    color: var(--accent-deep);
  }

  .mobile-nav button:last-child {
    margin-top: 4px;
    background: var(--dark);
    color: #fff;
  }

  .mobile-nav button:last-child:hover {
    background: #252b34;
    color: #fff;
  }

  .mobile-nav button span {
    display: inline-grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-size: .73rem;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .featured-card,
  .featured-card-primary {
    grid-column: span 6;
  }
}

@media (max-width: 640px) {
  body {
    overflow-x: hidden;
  }

  .container {
    width: min(calc(100% - 24px), 1180px);
  }

  .announcement {
    font-size: .7rem;
    line-height: 1.35;
  }

  .nav-wrap {
    height: 68px;
    gap: 10px;
  }

  .brand {
    gap: 9px;
    min-width: 0;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }

  .brand strong {
    font-size: .9rem;
  }

  .main-nav {
    gap: 6px;
  }

  .admin-nav-button {
    width: 42px;
    height: 42px;
    padding: 0;
    font-size: 0;
  }

  .admin-nav-button::first-letter {
    font-size: 1rem;
  }

  .cart-link {
    padding: 10px 11px;
    font-size: .82rem;
  }

  .mobile-menu {
    width: 42px;
    height: 42px;
  }

  .hero {
    padding: 48px 0 52px;
  }

  .hero h1 {
    font-size: clamp(2.65rem, 13vw, 3.55rem);
    line-height: .98;
  }

  .hero-copy > p {
    font-size: 1rem;
  }

  .hero-actions {
    gap: 9px;
    margin: 25px 0;
  }

  .trust-row {
    gap: 9px 14px;
    font-size: .76rem;
  }

  .hero-visual {
    min-height: 315px;
    margin-top: 8px;
  }

  .stats-strip {
    margin-top: 18px;
    margin-bottom: 48px;
    border-radius: 16px;
  }

  .stats-strip > div {
    padding: 15px;
  }

  .stats-strip span {
    font-size: .76rem;
  }

  .featured-section {
    padding-bottom: 58px;
  }

  .section-head h2,
  .about-section h2,
  .modal-card h2 {
    font-size: 2.15rem;
  }

  .featured-grid,
  .product-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .featured-card,
  .featured-card-primary {
    grid-column: auto;
  }

  .featured-card-primary .product-image,
  .featured-card:not(.featured-card-primary) .product-image {
    aspect-ratio: 1.08 / 1;
  }

  .product-card {
    border-radius: 18px;
  }

  .product-body {
    padding: 18px;
  }

  .product-body p {
    min-height: 0;
  }

  .product-footer {
    align-items: stretch;
    gap: 15px;
  }

  .product-actions {
    width: 100%;
    justify-content: stretch;
  }

  .product-actions .btn {
    flex: 1;
  }

  .modal {
    padding: 10px;
  }

  .product-modal-card {
    padding: 16px;
  }

  .product-layout {
    gap: 25px;
  }

  .gallery-main {
    border-radius: 18px;
  }

  .gallery-image-button::after {
    border-radius: 16px;
  }

  .gallery-image-button img {
    aspect-ratio: 1 / 1;
  }

  .gallery-zoom-label {
    opacity: 1;
    transform: none;
  }

  .gallery-caption {
    display: block;
    margin-top: 10px;
  }

  .gallery-caption strong {
    display: block;
    margin-top: 3px;
    text-align: left;
  }

  .product-info {
    padding-top: 0;
  }

  .product-info h2 {
    font-size: 2.2rem;
    line-height: 1.02;
  }

  .spec-grid {
    gap: 7px;
  }

  .spec-grid > div {
    padding: 11px 9px;
  }

  .buy-row {
    margin-top: 21px;
  }

  .product-actions-secondary {
    grid-template-columns: 1fr;
  }

  .lightbox-card {
    padding: 10px;
    border-radius: 18px;
  }

  .lightbox-image-wrap {
    min-height: 210px;
    border-radius: 12px;
  }

  .lightbox-image-wrap img {
    max-height: calc(94vh - 100px);
  }

  .lightbox-caption {
    margin: 10px 36px 1px;
    font-size: .77rem;
  }

  .drawer-panel {
    width: 100%;
    padding: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
