/* v2: Bulma default + minimal theme + motion (no v1 styles). */
:root {
  --bulma-primary-h: 38;
  --bulma-primary-s: 92%;
  --bulma-primary-l: 50%;
  --bulma-primary: hsl(var(--bulma-primary-h) var(--bulma-primary-s) var(--bulma-primary-l));
  --bulma-link: var(--bulma-primary);
}
html,
body {
  transition: background-color 180ms ease, color 180ms ease;
}

.navbar-menu.is-active {
  animation: navDown 160ms ease-out;
}

@keyframes navDown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

html[data-theme="dark"] body {
  background-color: #0d0b09;
  color: #f5f5f5;
}

html[data-theme="dark"] .section,
html[data-theme="dark"] .footer {
  background-color: #0d0b09;
  color: #f5f5f5;
}

html[data-theme="dark"] .title,
html[data-theme="dark"] .subtitle,
html[data-theme="dark"] .content,
html[data-theme="dark"] .label {
  color: #f5f5f5;
}

html[data-theme="dark"] .navbar {
  background-color: #000;
}

/* Navbar prominence: larger brand text */
.navbar-brand > .navbar-item {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* Mobile navbar: keep toggle right-aligned, just left of burger */
@media (max-width: 1023px) {
  .navbar-brand {
    width: 100%;
  }

  .navbar-brand .nav-utility-spacer {
    margin-left: auto;
  }

  .navbar-brand .navbar-burger {
    margin-left: 0.25rem;
  }
}

.shop-carousel {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 0.75rem;
}

.shop-carousel-item {
  flex: 0 0 85%;
  scroll-snap-align: start;
}

.shop-carousel::-webkit-scrollbar {
  display: none;
}

.shop-carousel {
  scrollbar-width: none;
}

@media (min-width: 769px) {
  .shop-carousel-item {
    flex-basis: 100%;
  }
  .shop-carousel {
    overflow: hidden;
    padding: 0;
  }
  .shop-carousel-item:not(:first-child) {
    display: none;
  }
}

/* PLP image normalization (non-destructive, crops to frame) */
#productGrid .card-image .image,
#productGrid .shop-carousel-item .image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
}

/* Skeleton loading for images */
#productGrid .is-skeleton,
.product-gallery .is-skeleton {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}

@keyframes skeleton-pulse {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

html:not([data-theme="dark"]) #productGrid .is-skeleton,
html:not([data-theme="dark"]) .product-gallery .is-skeleton {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

#productGrid .card-image img,
#productGrid .shop-carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.shop-card {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.28);
}

html[data-theme="dark"] .shop-card {
  background-color: #141414;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .shop-card .card-content {
  background-color: #141414;
}

.shop-card .title a {
  color: var(--bulma-text-strong);
}

.shop-card .shop-price {
  color: var(--bulma-text-strong);
}

.product-header {
  margin-bottom: 1.25rem;
}

.product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.product-tags .tag {
  background-color: rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 0, 0, 0.08);
  color: inherit;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}

html[data-theme="dark"] .product-tags .tag {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
}

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

.product-gallery-item {
  break-inside: avoid;
  margin-bottom: 1rem;
}

@media (min-width: 769px) {
  .product-gallery {
    column-count: 2;
  }
}

@media (min-width: 1024px) {
  .product-gallery {
    column-count: 3;
  }
}

/* Commission status pill */
.commission-status {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #111;
  color: #fff;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
}

html[data-theme="dark"] .commission-status {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.commission-status__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
}

/* Commission gallery cards */
.commission-card {
  display: block;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.28);
  color: inherit;
  transition: transform 150ms ease, box-shadow 150ms ease;
  background: #fff;
}

.commission-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.34);
  color: inherit;
}

html[data-theme="dark"] .commission-card {
  background: #141414;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.commission-card__image figure {
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.commission-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.commission-card__body {
  padding: 1.5rem 1.5rem 1.75rem;
}

.commission-card__format {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bulma-primary);
  margin-bottom: 0.75rem;
}

.commission-card__title {
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.3;
  margin-bottom: 0.5rem;
  color: var(--bulma-text-strong);
}

html[data-theme="dark"] .commission-card__title {
  color: #f5f5f5;
}

.commission-card__detail {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--bulma-text);
  margin-bottom: 1rem;
}

html[data-theme="dark"] .commission-card__detail {
  color: rgba(255, 255, 255, 0.7);
}

.commission-card__price {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--bulma-text-strong);
  letter-spacing: -0.01em;
}

html[data-theme="dark"] .commission-card__price {
  color: rgba(255, 255, 255, 0.85);
}

/* FAQ boxes in dark mode */
html[data-theme="dark"] .box {
  background: #1a1a1a;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Size selector for product pages */
.size-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.size-option {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.875rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 150ms ease, background-color 150ms ease;
  background: rgba(255, 255, 255, 0.03);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.size-option:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.05);
}

.size-option.is-selected {
  border-color: var(--bulma-primary);
  background: rgba(249, 115, 22, 0.08);
}

.size-option-label {
  font-weight: 500;
}

.size-option-badges {
  display: flex;
  gap: 0.4rem;
}

/* Light mode size options */
html:not([data-theme="dark"]) .size-option {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.1);
}

html:not([data-theme="dark"]) .size-option:hover {
  border-color: rgba(0, 0, 0, 0.25);
  background: rgba(0, 0, 0, 0.04);
}

html:not([data-theme="dark"]) .size-option.is-selected {
  border-color: var(--bulma-primary);
  background: rgba(249, 115, 22, 0.06);
}

/* Homepage scattered gallery wall */
.gallery-scattered {
  position: relative;
  min-height: 520px;
  max-width: 1000px;
  margin: 0 auto;
}

.gallery-scattered-item {
  position: absolute;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2), 0 1px 4px rgba(0, 0, 0, 0.15);
  transition: transform 350ms cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 350ms ease,
              z-index 0ms;
}

.gallery-scattered-item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-scattered-item:hover {
  transform: rotate(0deg) scale(1.08) !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  z-index: 100 !important;
}

html[data-theme="dark"] .gallery-scattered-item {
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5), 0 1px 4px rgba(0, 0, 0, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .gallery-scattered-item:hover {
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  border-color: rgba(255, 255, 255, 0.12);
}

@media (max-width: 768px) {
  .gallery-scattered {
    min-height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    padding: 1rem 0;
  }

  .gallery-scattered-item {
    position: relative !important;
    width: 75% !important;
    height: auto !important;
    top: auto !important;
    left: auto !important;
  }
}

/* ═══════════════════════════════════════════
   Commission Gallery (C+D hybrid)
   Full-width editorial bands with
   finished/process reveal on hover (desktop)
   and timed crossfade (mobile).
   ═══════════════════════════════════════════ */

.comm-gallery {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.comm-gallery-band {
  position: relative;
  display: block;
  overflow: hidden;
  height: 55vh;
  min-height: 320px;
  max-height: 620px;
  -webkit-tap-highlight-color: rgba(249, 115, 22, 0.15);
}

/* Finished image (front, visible by default) */
.comm-gallery-band__finished {
  position: absolute;
  inset: 0;
  z-index: 2;
  transition: opacity 600ms ease;
  pointer-events: none;
}

.comm-gallery-band__finished img {
  object-fit: cover;
  object-position: center;
}

/* Process image (back, hidden by default) */
.comm-gallery-band__process {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.comm-gallery-band__process img {
  object-fit: cover;
  object-position: center;
}

/* Desktop hover reveal */
@media (min-width: 1024px) {
  .comm-gallery-band:hover .comm-gallery-band__finished {
    opacity: 0;
  }
  .comm-gallery-band:hover .comm-gallery-label--finished {
    opacity: 0;
  }
  .comm-gallery-band:hover .comm-gallery-label--process {
    opacity: 1;
  }
}

/* Mobile/touch: JS toggles .is-revealed class */
.comm-gallery-band.is-revealed .comm-gallery-band__finished {
  opacity: 0;
}
.comm-gallery-band.is-revealed .comm-gallery-label--finished {
  opacity: 0;
}
.comm-gallery-band.is-revealed .comm-gallery-label--process {
  opacity: 1;
}

/* Gradient overlay for text legibility */
.comm-gallery-band::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.6) 0%,
    rgba(0, 0, 0, 0.12) 35%,
    transparent 55%
  );
  pointer-events: none;
}

/* Subtle zoom on hover */
.comm-gallery-band__finished img,
.comm-gallery-band__process img {
  transition: transform 600ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.comm-gallery-band:hover .comm-gallery-band__finished img,
.comm-gallery-band:hover .comm-gallery-band__process img {
  transform: scale(1.03);
}

/* Caption */
.comm-gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem 2.5rem;
  z-index: 4;
  color: #fff;
  pointer-events: none;
}

.comm-gallery-caption h3 {
  font-size: 1.75rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  margin: 0 0 0.3rem;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.comm-gallery-caption p {
  font-size: 0.85rem;
  opacity: 0.8;
  margin: 0;
}

/* State labels */
.comm-gallery-label {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 5;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 0.7rem;
  border-radius: 4px;
  backdrop-filter: blur(6px);
  transition: opacity 400ms ease;
  pointer-events: none;
}

.comm-gallery-label--finished {
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  opacity: 1;
}

.comm-gallery-label--process {
  background: rgba(249, 115, 22, 0.7);
  color: #fff;
  opacity: 0;
}

@media (min-width: 769px) {
  .comm-gallery-band {
    height: 65vh;
    max-height: 720px;
  }
  .comm-gallery-caption {
    padding: 3rem 4rem;
  }
  .comm-gallery-caption h3 {
    font-size: 2.5rem;
  }
}

/* ═══════════════════════════════════════════
   Commission Detail Pages
   Consistent layout classes to replace
   inline styles across all detail pages.
   ═══════════════════════════════════════════ */

.comm-detail-hero {
  padding-top: 2rem;
  padding-bottom: 3rem;
}

.comm-detail-main-image {
  padding-top: 0;
  padding-bottom: 5rem;
}

.comm-detail-main-image img {
  border-radius: 8px;
}

.comm-detail-body {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.comm-detail-body .content {
  line-height: 2;
}

.comm-detail-process {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

/* Process gallery grid */
.comm-detail-gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 2rem;
}

@media (min-width: 769px) {
  .comm-detail-gallery {
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
  }
}

.comm-detail-gallery-item {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
}

.comm-detail-gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 400ms ease;
}

.comm-detail-gallery-item:hover img {
  transform: scale(1.02);
}

/* Full-width gallery item */
.comm-detail-gallery-item.is-full {
  grid-column: 1 / -1;
}

/* Stage label on gallery images */
.comm-detail-stage {
  position: absolute;
  bottom: 0.6rem;
  left: 0.6rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(0, 0, 0, 0.5);
  padding: 0.25rem 0.55rem;
  border-radius: 3px;
  backdrop-filter: blur(4px);
  pointer-events: none;
}

.comm-detail-cta {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

/* Next/prev navigation */
.comm-detail-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin-top: 2rem;
  font-size: 0.9rem;
}

html:not([data-theme="dark"]) .comm-detail-nav {
  border-top-color: rgba(0, 0, 0, 0.08);
}

.comm-detail-nav a {
  color: var(--bulma-primary);
  transition: opacity 200ms;
}

.comm-detail-nav a:hover {
  opacity: 0.7;
}

.comm-detail-nav .nav-spacer {
  flex: 1;
}

/* ═══════════════════════════════════════════
   Image loading placeholders
   Neutral background shown while images load.
   Prevents blank/broken appearance on slow
   connections and large files.
   ═══════════════════════════════════════════ */

/* Commission gallery bands — already have aspect ratio via height, just need bg */
.comm-gallery-band {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}

html:not([data-theme="dark"]) .comm-gallery-band {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

/* Commission detail page images */
.comm-detail-main-image figure {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
  border-radius: 8px;
  aspect-ratio: 3 / 2;
}

html:not([data-theme="dark"]) .comm-detail-main-image figure {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

.comm-detail-gallery-item {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
  aspect-ratio: 4 / 3;
}

html:not([data-theme="dark"]) .comm-detail-gallery-item {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

.comm-detail-gallery-item.is-full {
  aspect-ratio: 3 / 2;
}

/* Homepage scattered gallery */
.gallery-scattered-item {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}

html:not([data-theme="dark"]) .gallery-scattered-item {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

/* About section portrait */
#about figure.image {
  background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
  border-radius: 6px;
}

html:not([data-theme="dark"]) #about figure.image {
  background: linear-gradient(90deg, #e8e8e8 25%, #f5f5f5 50%, #e8e8e8 75%);
  background-size: 200% 100%;
}

