/* /=== LARGE SCREENS START ===/ */
@media (max-width: 1280px) {
  .shop-grid {
    grid-template-columns: repeat(3, minmax(220px, 1fr));
  }
  .palette-controls {
  grid-template-columns: 1fr;
}
}
/* /=== LARGE SCREENS END ===/ */


/* /=== TABLET LAYOUT START ===/ */
@media (max-width: 1060px) {
  .studio-layout {
    display: block;
  }

  .palette-column {
    position: relative;
    top: auto;
    left: auto;

    width: 100%;
    height: auto;
    min-height: auto;

    padding: 24px 18px;
  }

  .main-palette.svg-palette {
    width: min(78vw, 320px);
  }

  .canvas-wrap {
    grid-column: auto;
  }

  .content-section {
    min-height: auto;
    padding: 42px 24px;
  }

  .home-section,
  .product-detail-grid {
    grid-template-columns: 1fr;
  }

  .home-art-window {
    min-height: 420px;
  }

  .detail-gallery {
    position: static;
  }
}
/* /=== TABLET LAYOUT END ===/ */


/* /=== MOBILE START ===/ */
@media (max-width: 720px) {
  .topbar {
    padding: 12px;
  }

  .topbar-inner {
    position: relative;
    display: flex;
    align-items: center;
  }

  .brand {
    flex: 1;
    min-width: 0;
  }

  .brand span:last-child {
    font-size: 1.35rem;
    line-height: 1.1;
  }

/* /=== MOBILE MENU BUTTON START ===/ */
/* /=== MOBILE MENU BUTTON START ===/ */
.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;

  width: 54px;
  height: 54px;

  border: 0;
  border-radius: 16px;

  background: rgba(255, 255, 255, .10);

  cursor: pointer;

  transition:
    background .18s ease,
    transform .14s ease;
}

.menu-toggle:hover {
  background: rgba(255,255,255,.16);
}

.menu-toggle:active {
  transform: scale(.96);
}

.menu-toggle span {
  width: 24px;
  height: 3px;

  border-radius: 999px;

  background: var(--cream);

  transition:
    transform .18s ease,
    opacity .14s ease;
}

/* /=== OPEN STATE START ===/ */
.menu-toggle.open span:nth-child(1) {
  transform:
    translateY(8px)
    rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform:
    translateY(-8px)
    rotate(-45deg);
}
/* /=== OPEN STATE END ===/ */
/* /=== MOBILE MENU BUTTON END ===/ */
/* /=== MOBILE MENU BUTTON END ===/ */

.main-nav {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 1000;

  display: none;
  width: min(220px, 80vw);
  padding: 10px;

  border-radius: 16px;
  background: rgba(32, 20, 13, .96);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .35);
}

.main-nav.open {
  display: grid;
  gap: 6px;
}

.main-nav button {
  text-align: left;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, .06);
}
  .content-section {
    padding: 34px 18px;
  }

  .home-hero h1 {
    font-size: clamp(3rem, 16vw, 5rem);
  }

  .section-heading {
    font-size: clamp(2.5rem, 14vw, 4rem);
  }

  .home-stats,
  .shop-grid,
  .gallery-grid,
  .tools-grid,
  .social-grid {
    grid-template-columns: 1fr;
  }

  .home-art-window {
    min-height: 340px;
  }

  .section-topline,
  .cart-summary {
    flex-direction: column;
    align-items: stretch;
  }

  .product-image-btn {
    height: 245px;
  }

  .product-detail-page,
  .cart-page,
  .checkout-page {
    max-width: none;
  }

  .detail-image-frame img {
    aspect-ratio: 1 / 1;
  }

  .cart-item {
    grid-template-columns: 82px minmax(0, 1fr);
  }

  .cart-item input,
  .cart-item .remove-btn {
    grid-column: 2;
  }

  .floating-cart {
    right: 14px;
    bottom: 14px;
    padding: 12px 14px;
  }
}
/* /=== MOBILE END ===/ */


/* /=== SMALL PHONES START ===/ */
@media (max-width: 390px) {
  .main-palette.svg-palette {
    width: min(84vw, 260px);
  }

  .sidebar-stats {
    width: min(100%, 320px);
  }

  .home-hero h1 {
    font-size: 3rem;
  }

  .section-heading {
    font-size: 2.8rem;
  }
}
/* /=== SMALL PHONES END ===/ */


/* /=== TINY SCREENS START ===/ */
@media (max-width: 260px) {
  body {
    font-size: 13px;
  }

  .brand span:last-child {
    display: none;
  }

  .main-palette.svg-palette {
    width: 200px;
  }

  .btn {
    min-height: 36px;
    padding: 8px 10px;
    font-size: .78rem;
  }
}
/* /=== TINY SCREENS END ===/ */


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