/* ============================================
   Vision Studio — Creative Portfolio
   Modern, Interactive, Responsive
   ============================================ */

/* ---- CSS Variables ---- */
:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #12121a;
  --bg-card: #1a1a2e;
  --bg-card-hover: #22223a;
  --text-primary: #f0f0f5;
  --text-secondary: #8888aa;
  --text-muted: #555577;
  --accent: #6c5ce7;
  --accent-light: #a29bfe;
  --accent-dark: #4834d4;
  --cursor-color: #ffffff;
  --gradient-start: #6c5ce7;
  --gradient-end: #fd79a8;
  --border: rgba(255, 255, 255, 0.06);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 40px rgba(108, 92, 231, 0.15);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-main: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Icons', 'Helvetica Neue', 'Helvetica', 'Arial', sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Icons', 'Helvetica Neue', 'Helvetica', 'Arial', sans-serif;
  --nav-height: 72px;
}

/* ============================================
   Loading Screen — CRT Monitor Style
   ============================================ */

.loading-screen {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: #080e08;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  transition: opacity 0.6s ease, visibility 0.6s ease;
  overflow: hidden;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* CRT screen curvature — subtle vignette */
.loading-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 80% 60% at 50% 50%,
    transparent 40%,
    rgba(0, 0, 0, 0.3) 100%
  );
  pointer-events: none;
  z-index: 1;
}

/* Scanline overlay — CRT monitor effect */
.loading-scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.3) 2px,
    rgba(0, 0, 0, 0.3) 4px
  );
  pointer-events: none;
  z-index: 2;
  animation: scanline-flicker 0.1s infinite;
}

@keyframes scanline-flicker {
  0%, 100% { opacity: 0.8; }
  50% { opacity: 0.85; }
}

/* CRT curvature overlay — subtle edge darkening */
.loading-screen::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 70% 55% at 50% 50%,
    transparent 50%,
    rgba(0, 0, 0, 0.25) 100%
  );
  pointer-events: none;
  z-index: 3;
}

/* Loading content — subtle CRT curvature */
.loading-content {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  /* subtle barrel distortion */
  transform: perspective(1200px) scaleY(1.01);
  transform-origin: center center;
}

/* Counter — 0% → 100% (bottom) + CRT phosphor glow */
.loading-counter {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.02em;
  text-shadow:
    0 0 10px rgba(108, 92, 231, 0.8),
    0 0 30px rgba(108, 92, 231, 0.5),
    0 0 60px rgba(108, 92, 231, 0.3);
  line-height: 1;
  margin-top: 8px;
}

.counter-suffix {
  font-size: 1.8rem;
  color: var(--accent-light);
  font-weight: 600;
  text-shadow:
    0 0 8px rgba(162, 155, 254, 0.8),
    0 0 20px rgba(162, 155, 254, 0.4);
}

/* Rainbow text — 80s Apple gradient + CRT phosphor glow */
.rainbow-text {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: 0.05em;
  background: linear-gradient(
    90deg,
    #ff0000 0%,
    #ff7700 14%,
    #ffff00 28%,
    #00ff00 42%,
    #0077ff 57%,
    #7700ff 71%,
    #ff00ff 85%,
    #ff0000 100%
  );
  background-size: 200% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: rainbow-shift 2s linear infinite;
  /* CRT phosphor glow */
  filter: drop-shadow(0 0 8px rgba(108, 92, 231, 0.6)) drop-shadow(0 0 20px rgba(108, 92, 231, 0.3));
}

@keyframes rainbow-shift {
  from { background-position: 0% 50%; }
  to { background-position: 200% 50%; }
}

.loading-subtitle {
  font-family: var(--font-main);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

/* Progress bar — CRT phosphor glow + curved */
.loading-bar-container {
  width: 200px;
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 0 4px rgba(126, 200, 227, 0.2);
}

.loading-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #7ec8e3, #b8e6f0, #7ec8e3);
  background-size: 200% 100%;
  animation: loading-progress 1.4s cubic-bezier(0.4, 0, 0.2, 1) forwards, skybar-shimmer 1.2s linear infinite;
  border-radius: 2px;
  box-shadow:
    0 0 6px rgba(126, 200, 227, 0.6),
    0 0 16px rgba(126, 200, 227, 0.3),
    0 0 32px rgba(126, 200, 227, 0.15);
}

@keyframes loading-progress {
  0% { width: 0%; }
  20% { width: 15%; }
  40% { width: 35%; }
  60% { width: 60%; }
  80% { width: 85%; }
  100% { width: 100%; }
}

@keyframes skybar-shimmer {
  from { background-position: 0% 50%; }
  to { background-position: 200% 50%; }
}

/* Status text */
.loading-status {
  font-family: 'Courier New', monospace;
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.1em;
  min-height: 1em;
}

/* Responsive */
@media (max-width: 768px) {
  .loading-content {
    gap: 10px;
  }
  .loading-counter {
    font-size: 2.5rem;
  }
  .counter-suffix {
    font-size: 1.3rem;
  }
  .loading-bar-container {
    width: 150px;
  }
}

/* ---- Reset ---- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-main);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  cursor: default;
}

a {
  color: inherit;
  text-decoration: none;
}

ul { list-style: none; }

img, video {
  max-width: 100%;
  display: block;
}

/* Custom cursor disabled — using OS cursor with white outline (see body rule above) */
.custom-cursor,
.custom-cursor-follower {
  display: none !important;
}

/* ---- Custom Cursor (high-visibility: black dot + white ring) [disabled] ---- */
.custom-cursor {
  position: fixed;
  width: 12px;
  height: 12px;
  background: #000;
  border-radius: 50%;
  pointer-events: none;
  z-index: 999999;
  transform: translate(-50%, -50%);
  transition: width 0.2s, height 0.2s, background 0.2s, border-color 0.2s, opacity 0.2s;
}

/* Click feedback — shrink while mouse button is down */
.custom-cursor.down {
  transform: translate(-50%, -50%) scale(0.7);
}

/* Hand (pointer) shape when hovering links / clickable cards */
.custom-cursor.pointer {
  width: 24px;
  height: 24px;
  background: transparent;
  border: none;
  border-radius: 0;
  transform: translate(-50%, -50%) rotate(-15deg);
}
.custom-cursor.pointer::before {
  content: '';
  position: absolute;
  inset: 0;
  background: #fff;
  border: 2px solid #000;
  clip-path: path('M8.4 2C7.6 2 7 2.6 7 3.4V10L4.6 7.6C4.2 7.2 3.5 7.2 3.1 7.6C2.7 8 2.7 8.7 3.1 9.1L7.4 13.4V20C7.4 21.3 8.5 22.4 9.8 22.4H15.6C16.9 22.4 18 21.3 18 20V12.6L20.9 15.5C21.3 15.9 22 15.9 22.4 15.5C22.8 15.1 22.8 14.4 22.4 14L18 9.6V3.4C18 2.6 17.4 2 16.6 2H8.4Z');
}
.featured-products .custom-cursor.pointer::before {
  background: #000;
  border-color: #fff;
}

.custom-cursor.hover {
  width: 48px;
  height: 48px;
  background: rgba(0, 0, 0, 0.1);
  border: 1px solid #000;
}

/* On light backgrounds (white Featured Products band etc.) invert to white */
.featured-products .custom-cursor {
  background: #fff;
}
.featured-products .custom-cursor.hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #fff;
}

.custom-cursor-follower {
  position: fixed;
  width: 36px;
  height: 36px;
  border: 1.5px solid #fff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 999998;
  transform: translate(-50%, -50%);
  transition: transform 0.15s ease-out, width 0.3s, height 0.3s, border-color 0.3s, opacity 0.2s;
}

.custom-cursor-follower.hover {
  width: 60px;
  height: 60px;
  border-color: #fff;
  opacity: 0;
}

/* Hide custom cursor on touch devices */
@media (hover: none) and (pointer: coarse) {
  .custom-cursor,
  .custom-cursor-follower {
    display: none;
  }
  body { cursor: auto; }
}

/* ---- Container ---- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---- Navigation ---- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  transition: background var(--transition), box-shadow var(--transition);
}

.navbar.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

/* Nav overlay — dark backdrop behind slide-in menu */
#navOverlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 15, 0.6);
  z-index: 9997;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#navOverlay.visible,
.nav-links.open ~ #navOverlay {
  opacity: 1;
  pointer-events: auto;
}

/* Hide shop debug overlay (development artifact) */
#__shopDebug { display: none !important; }

/* Prevent body scroll when menu is open */
body.menu-open {
  overflow: hidden !important;
  position: fixed;
  width: 100%;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
}

.cart-nav-btn {
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  position: relative;
  display: flex;
}

/* Cart logo in header (right side) — hidden; use cartNavBtn instead */
.cart-logo-img {
  display: none;
  height: 32px;
  width: auto;
  opacity: 0.6;
  transition: opacity 0.3s ease;
  margin: 0 8px;
}

.cart-logo-img:hover {
  opacity: 1;
}

/* Red badge on cart icon */
.cart-nav-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: #ff2d55;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-display);
  min-width: 20px;
  height: 20px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0;
  transition: transform 0.2s ease;
  pointer-events: none;
  display: none;
}

/* Show badge when count > 0 */
.cart-nav-btn .cart-nav-badge.show {
  display: flex;
}

.cart-nav-btn .cart-nav-badge.bump {
  animation: badge-bump 0.2s ease;
}

@keyframes badge-bump {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.logo-icon {
  font-size: 1.5rem;
  color: var(--accent);
  animation: rotate-icon 8s linear infinite;
}

@keyframes rotate-icon {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.nav-links {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition);
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.mobile-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition);
}

/* ---- Hero Section ---- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* ［変更］上詰めではなく、画面の縦中央にバランスよく配置 */
  justify-content: center; 
  position: relative;
  overflow: hidden;
  padding: 140px 24px 140px;
  /* ［追加］高さの計算にpaddingを含めることで、画面からはみ出るのを防ぐ */
  box-sizing: border-box; 
}

.hero-scroll-indicator {
  /* Bionic browser visibility enhancement (2026-10-18) */
  color: #fff;
  font-size: 0.9rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  /* ［変更］コンテンツとの間に程よい距離を作る */
  margin-top: 40px;
  /* ［追加］最下部に固定せず、コンテンツの流れの一部として配置 */
  position: relative;
  z-index: 2;
}

.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.particle {
  position: absolute;
  border-radius: 50%;
  will-change: transform, opacity;
  /* JSでwidth/height/background/opacityを設定 */
  width: 2px;
  height: 2px;
  pointer-events: none;
}

/* Organic particles — JSでtransform/opacityを毎フレーム制御 */
.particle-organic {
  /* 基本はJSで制御、CSSはリセットのみ */
  animation: none;
}

/* Section-level particle containers — reuse hero-particles class
   (About Us, Contact CTA) — identical to .hero-particles */

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
  padding-bottom: 40px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: rgba(108, 92, 231, 0.1);
  border: 1px solid rgba(108, 92, 231, 0.3);
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-light);
  margin-bottom: 24px;
}

.hero-badge::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.5); }
}

.hero-title {
  font-family: var(--font-display);
  font-size: 4.5rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 32px;
  margin-top: 16px;
  letter-spacing: -0.03em;
  text-align: center;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  position: relative;
}

.title-line {
  display: block;
}

.title-line-spaced {
  margin-bottom: 32px;
}

.title-line-tight {
  margin-bottom: 4px;
}

.title-gradient {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero-subtitle p {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-light);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin: 0;
  text-align: center;
}

.hero-subtitle p:empty {
  height: 16px;
}

.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
  opacity: 0;
  transition: opacity var(--transition);
}

.btn:hover::before {
  opacity: 1;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  box-shadow: 0 4px 20px rgba(108, 92, 231, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(108, 92, 231, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--accent);
  background: rgba(108, 92, 231, 0.05);
}

.btn-icon {
  width: 18px;
  height: 18px;
}

.btn-full {
  width: 100%;
  justify-content: center;
}

.scroll-mouse {
  /* Visibility enhancement (2026-10-18) */
  width: 32px;
  height: 50px;
  border: 2.5px solid #fff;
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 10px;
}

.scroll-wheel {
  /* Visibility enhancement (2026-10-18) */
  width: 4px;
  height: 10px;
  background: #fff;
  border-radius: 2px;
  animation: scroll-anim 1.2s ease-in-out infinite;
}

@keyframes scroll-anim {
  /* Visibility enhancement (2026-10-18): stronger movement */
  0%, 100% { transform: translateY(0); opacity: 1; }
  50% { transform: translateY(16px); opacity: 0.15; }
}

/* ---- Section Headers ---- */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.section-desc {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto;
}

.text-gradient {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ---- Page Header (for inner pages) ---- */
.page-header {
  padding: 120px 0 60px;
  text-align: center;
}

.page-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.03em;
}

.page-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ---- Featured Preview Sections (index page) ---- */
.featured-preview,
.featured-products {
  padding: 100px 0;
}

/* Homepage: gradient from dark hero into white at Featured Products, back to dark before footer */
.featured-products {
  background: linear-gradient(180deg,
    var(--bg-primary) 0%,
    #ffffff 24%,
    #ffffff 76%,
    #ffffff 100%);
}

/* Go to Shop link — black text on the white band */
.featured-products .view-all {
  color: #000;
}

.view-all {
  display: inline-block;
  margin-top: 24px;
}

/* ---- Featured Products Hover Effect (Homepage Only) ---- */
.featured-products .shop-grid {
  position: relative;
}

/* Base card styles for featured section */
.featured-products .shop-card {
  transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
  transform-origin: center center;
}

/* Hovered card — scales up, brightens, glows */
.featured-products .shop-card:hover {
  transform: scale(1.04);
  z-index: 10;
  filter: brightness(1.15) drop-shadow(0 0 30px rgba(108, 92, 231, 0.2));
  border-color: rgba(108, 92, 231, 0.3);
}

/* Non-hovered cards when hovering the grid — dim and shrink */
.featured-products .shop-grid:hover .shop-card:not(:hover) {
  filter: brightness(0.68) saturate(0.8);
  transform: scale(0.98);
}

/* Prevent image zoom on featured cards (scale already applied on card) */
.featured-products .shop-card:hover .shop-card-img,
.featured-products .shop-card:hover .shop-card-placeholder {
  transform: scale(1);
}

/* ---- Portfolio Section ---- */
.portfolio {
  padding: 80px 0;
}

.portfolio-filters {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.filter-btn {
  padding: 8px 20px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-family: var(--font-main);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  max-width: 1100px;
  margin: 0 auto;
}

.portfolio-card .portfolio-thumbnail {
  aspect-ratio: 16 / 9;
}

.portfolio-card .portfolio-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px;
  background: linear-gradient(to top, rgba(10, 10, 15, 0.95), transparent);
}

.portfolio-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: all var(--transition);
  cursor: pointer;
  opacity: 0;
  transform: translateY(30px);
  aspect-ratio: 16 / 9;
}

.portfolio-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.portfolio-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-glow);
  border-color: rgba(108, 92, 231, 0.3);
}

.portfolio-thumbnail {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.portfolio-thumbnail-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.portfolio-card:hover .portfolio-thumbnail-bg {
  transform: scale(1.05);
}

.portfolio-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 15, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition);
}

.portfolio-card:hover .portfolio-overlay {
  opacity: 1;
}

.play-btn {
  width: 56px;
  height: 56px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0.8);
  transition: transform var(--transition);
}

.portfolio-card:hover .play-btn {
  transform: scale(1);
}

.play-btn::after {
  content: '';
  width: 0;
  height: 0;
  border-left: 18px solid #fff;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
  margin-left: 4px;
}

.portfolio-info {
  padding: 20px;
}

.portfolio-category {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 8px;
}

.portfolio-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.portfolio-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ---- Shop Section ---- */
.shop {
  padding: 80px 0;
  background: var(--bg-secondary);
}

.shop-filters {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.shop-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition);
  opacity: 0;
  transform: translateY(30px);
}

.shop-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.shop-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: rgba(108, 92, 231, 0.2);
}

.shop-image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
}

.shop-image-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.shop-card:hover .shop-image-bg {
  transform: scale(1.05);
}

.shop-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 12px;
  background: var(--accent);
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #fff;
}

.shop-info {
  padding: 20px;
}

.shop-category {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.shop-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.shop-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.5;
}

.shop-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.shop-price {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent-light);
}

.shop-price .original {
  font-size: 0.9rem;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 8px;
  font-weight: 400;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

/* ---- Shop Card (updated) ---- */
.shop-card-image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
  background: var(--bg-secondary);
}

.shop-card-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.5s ease;
}

.shop-card:hover .shop-card-img {
  transform: none;
}

.shop-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.5s ease;
}

.shop-card:hover .shop-card-placeholder {
  transform: scale(1.05);
}

.shop-card-category {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(108, 92, 231, 0.3);
  border-radius: 100px;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-light);
}

.shop-card-info {
  padding: 16px 20px 20px;
}

.shop-card-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-card-desc {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-card-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}

.shop-card-price {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--accent-light);
  white-space: nowrap;
}

.shop-card-sizes {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: right;
  white-space: nowrap;
}

/* ---- Size Selection Modal ---- */
.size-modal {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.size-modal.active {
  opacity: 1;
  visibility: visible;
}

.size-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
}

.size-modal-content {
  position: relative;
  z-index: 1;
  max-width: 520px;
  width: 90%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  transition: transform 0.3s ease;
}

.size-modal.active .size-modal-content {
  transform: scale(1) translateY(0);
}

.size-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  z-index: 1;
  transition: background var(--transition);
}

.size-modal-close:hover {
  background: var(--accent);
}

.size-modal-product {
  display: flex;
  flex-direction: column;
}

.size-modal-image {
  aspect-ratio: 4 / 3;
  background: var(--bg-secondary);
  overflow: hidden;
}

.size-modal-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.size-modal-info {
  padding: 20px 24px;
}

.size-modal-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.size-modal-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 10px;
}

.size-modal-price {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent-light);
}

.size-modal-sizes {
  padding: 0 24px 20px;
}

.size-modal-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
  display: block;
}

.size-options {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.size-option-btn {
  padding: 10px 20px;
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-main);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
}

.size-option-btn:hover {
  border-color: var(--accent);
  color: var(--text-primary);
}

.size-option-btn.selected {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ---- Cart Modal (navigation cart) ---- */
.cart-modal {
  position: fixed;
  top: 0;
  right: 0;
  width: 600px;
  max-width: 100vw;
  height: 100vh;
  z-index: 5000;
  pointer-events: none;
}

.cart-modal-content {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  background: #fff;
  border-left: 1px solid #e5e5e5;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  color: #1a1a1a;
}

.cart-modal.active {
  pointer-events: auto;
}

.cart-modal.active .cart-modal-content {
  transform: translateX(0);
}

.cart-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.cart-modal.active .cart-modal-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.cart-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: #666;
  font-size: 1.1rem;
  cursor: pointer;
  transition: color var(--transition), background var(--transition);
  z-index: 1;
}

.cart-modal-close:hover {
  color: #000;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 50%;
}

.cart-modal-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: #1a1a1a;
  padding: 24px 24px 16px;
  border-bottom: 1px solid #e5e5e5;
}

.cart-modal-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
}

.cart-empty-message {
  color: #666;
  font-size: 0.85rem;
  text-align: center;
  padding: 40px 0;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid #e5e5e5;
}

.cart-item-image {
  width: 140px;
  height: 140px;
  object-fit: contain;
  flex-shrink: 0;
  background: #f5f5f5;
  border-radius: 8px;
}

.cart-item-size {
  font-family: var(--font-main);
  font-size: 0.85rem;
  color: #666;
  margin-top: 2px;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-name {
  font-family: var(--font-main);
  font-size: 1.05rem;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 4px;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.cart-item-qty-btn {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid #ccc;
  border-radius: 4px;
  color: #666;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
}

.cart-item-qty-btn:hover {
  border-color: #6c5ce7;
  color: #6c5ce7;
}

.cart-item-quantity {
  font-size: 0.82rem;
  color: #1a1a1a;
}

.cart-item-remove-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
}

.trash-btn-img {
  width: 20px;
  height: 20px;
  opacity: 0.7;
  transition: opacity var(--transition);
}

.cart-item-remove-btn:hover .trash-btn-img {
  opacity: 1;
}

.cart-item-price {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1a1a1a;
  white-space: nowrap;
  flex-shrink: 0;
  align-self: center;
  padding-top: 8px;
}

.cart-item-type {
  display: inline-block;
  font-size: 0.65rem;
  padding: 2px 8px;
  border-radius: 999px;
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.cart-item-type-physical {
  background: rgba(108, 92, 231, 0.15);
  color: var(--accent);
  border: 1px solid rgba(108, 92, 231, 0.3);
}

.cart-item-type-digital {
  background: rgba(253, 121, 168, 0.15);
  color: var(--pink);
  border: 1px solid rgba(253, 121, 168, 0.3);
}

.cart-item-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.cart-item-actions svg {
  cursor: pointer;
  color: #999;
  transition: color var(--transition);
  margin-left: 8px;
}

.cart-item-actions svg:hover {
  color: #e74c3c;
}

.cart-item-subtotal {
  font-size: 0.9rem;
  font-weight: 600;
  color: #6c5ce7;
  white-space: nowrap;
}

.cart-item-qty-btn {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid #ccc;
  border-radius: 4px;
  color: #666;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
}

.cart-item-qty-btn:hover {
  border-color: #6c5ce7;
  color: #6c5ce7;
}

.cart-item-quantity {
  font-size: 0.82rem;
  color: #1a1a1a;
}

.cart-item-remove-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  cursor: pointer;
  transition: color var(--transition);
}

.cart-item-remove-btn:hover {
  color: #e74c3c;
}

.cart-modal-footer {
  border-top: 1px solid #e5e5e5;
  padding: 20px 24px;
}

.cart-modal-total {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  align-items: center;
  font-size: 1.4rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 16px;
}



.btn-full {
  display: block;
  width: 100%;
  text-align: center;
}

/* ---- Shop Detail Modal ---- */
.shop-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 5000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.shop-detail-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.shop-detail-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
}

.shop-detail-content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1100px;
  max-height: 90vh;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow-y: auto;
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.shop-detail-modal.active .shop-detail-content {
  transform: scale(1);
}

.shop-detail-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-secondary);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.shop-detail-close:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.shop-detail-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

/* Gallery (left) */
.shop-detail-gallery {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.shop-detail-main-image {
  aspect-ratio: 4 / 3;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: zoom-in;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
}

.shop-detail-main-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
  pointer-events: none;
}

.shop-detail-main-image:hover img {
  transform: scale(1.03);
}

.shop-detail-main-image .shop-detail-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
}

.shop-detail-thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.shop-detail-thumbs::-webkit-scrollbar {
  height: 4px;
}

.shop-detail-thumbs::-webkit-scrollbar-track {
  background: transparent;
}

.shop-detail-thumbs::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 2px;
}

.shop-detail-thumb {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  opacity: 0.5;
  transition: all var(--transition);
  background: var(--bg-card);
}

.shop-detail-thumb.active {
  border-color: var(--accent);
  opacity: 1;
}

.shop-detail-thumb:hover {
  opacity: 0.8;
}

.shop-detail-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shop-detail-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

/* Info (right) */
.shop-detail-info {
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
}

.shop-detail-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
}

.shop-detail-price {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-light);
  display: block;
}

.shop-detail-shipping {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.shop-detail-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 4px;
}

.shop-detail-shipping a {
  color: var(--accent-light);
  text-decoration: underline;
  cursor: pointer;
}

.shop-detail-color {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.shop-detail-sizes {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.shop-detail-material {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.shop-detail-notes {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.shop-detail-select-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}

.shop-detail-select {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font-main);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238888aa' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  transition: border-color var(--transition);
}

.shop-detail-select:focus {
  outline: none;
  border-color: var(--accent);
}

.shop-detail-add-cart {
  padding: 14px 24px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--text-primary);
  color: var(--bg-primary);
  transition: all var(--transition);
}

.shop-detail-add-cart:hover {
  background: var(--accent);
  color: #fff;
}

.shop-detail-more-link {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-decoration: none;
  align-self: flex-start;
  transition: color var(--transition);
}

.shop-detail-more-link:hover {
  color: var(--accent-light);
}

/* Responsive */
@media (max-width: 768px) {
  .shop-detail-body {
    grid-template-columns: 1fr;
  }

  .shop-detail-gallery {
    padding: 16px;
  }

  .shop-detail-info {
    padding: 20px 16px;
  }

  .shop-detail-title {
    font-size: 1.2rem;
  }

  .shop-detail-price {
    font-size: 1.2rem;
  }

  .shop-detail-thumb {
    width: 52px;
    height: 52px;
  }

  .shop-detail-content {
    max-height: 95vh;
    border-radius: var(--radius-lg);
  }
}

/* ---- Shop Image Zoom Modal ---- */
.shop-image-zoom-modal {
  position: fixed;
  inset: 0;
  z-index: 6000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.shop-image-zoom-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.shop-image-zoom-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
}

.shop-image-zoom-content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 24px;
}

.shop-image-zoom-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-secondary);
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.shop-image-zoom-close:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.shop-image-zoom-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  user-select: none;
}

.shop-image-zoom-arrow:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.shop-image-zoom-arrow-left {
  left: 24px;
}

.shop-image-zoom-arrow-right {
  right: 24px;
}

.shop-image-zoom-main {
  aspect-ratio: 4 / 3;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  max-height: 60vh;
}

.shop-image-zoom-main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 0.2s ease;
}

.shop-image-zoom-main .shop-zoom-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 6rem;
}

.shop-image-zoom-counter {
  font-family: var(--font-display);
  font-size: 0.85rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

.shop-image-zoom-thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0;
  max-width: 100%;
}

.shop-image-zoom-thumbs::-webkit-scrollbar {
  height: 4px;
}

.shop-image-zoom-thumbs::-webkit-scrollbar-track {
  background: transparent;
}

.shop-image-zoom-thumbs::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 2px;
}

.shop-image-zoom-thumb {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  opacity: 0.5;
  transition: all var(--transition);
  background: var(--bg-card);
}

.shop-image-zoom-thumb.active {
  border-color: var(--accent);
  opacity: 1;
}

.shop-image-zoom-thumb:hover {
  opacity: 0.8;
}

.shop-image-zoom-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shop-image-zoom-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

/* Responsive */
@media (max-width: 768px) {
  .shop-image-zoom-content {
    padding: 16px;
  }

  .shop-image-zoom-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }

  .shop-image-zoom-arrow-left {
    left: 12px;
  }

  .shop-image-zoom-arrow-right {
    right: 12px;
  }

  .shop-image-zoom-main {
    max-height: 50vh;
  }

  .shop-image-zoom-thumb {
    width: 52px;
    height: 52px;
  }
}

/* ---- Plugins Section ---- */
.plugins {
  padding: 80px 0;
}

.plugins-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 24px;
}

.plugin-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all var(--transition);
  cursor: pointer;
  opacity: 0;
  transform: translateY(30px);
  position: relative;
  overflow: hidden;
}

.plugin-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
  transform: scaleX(0);
  transition: transform var(--transition);
}

.plugin-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.plugin-card:hover::before {
  transform: scaleX(1);
}

.plugin-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-glow);
  border-color: rgba(108, 92, 231, 0.2);
}

.plugin-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}

.plugin-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.plugin-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.plugin-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.plugin-tag {
  padding: 4px 10px;
  background: rgba(108, 92, 231, 0.1);
  border: 1px solid rgba(108, 92, 231, 0.2);
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--accent-light);
}

.plugin-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.plugin-status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: #00b894;
}

.plugin-status::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #00b894;
  border-radius: 50%;
}

/* ---- About Section ---- */
.about {
  padding: 80px 0;
  background: var(--bg-secondary);
}

.about-content {
  max-width: 900px;
  margin: 0 auto;
}

.about-heading {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 20px;
}

.about-desc {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 16px;
  max-width: 700px;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin: 48px 0;
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.stat-item {
  text-align: center;
}

.stat-item .stat-number {
  font-size: 2.5rem;
}

.stat-item .stat-label {
  font-size: 0.9rem;
  margin-top: 8px;
}

.about-values {
  margin-top: 48px;
}

.values-heading {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 24px;
  text-align: center;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 24px;
}

.value-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  transition: all var(--transition);
}

.value-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
  border-color: rgba(108, 92, 231, 0.2);
}

.value-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.value-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.value-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ---- Contact Section ---- */
.contact {
  padding: 80px 0;
  background: var(--bg-secondary);
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-heading {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.contact-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.contact-icon {
  width: 44px;
  height: 44px;
  background: rgba(108, 92, 231, 0.1);
  border: 1px solid rgba(108, 92, 231, 0.2);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.contact-label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.contact-value {
  font-weight: 500;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 44px;
  height: 44px;
  background: rgba(108, 92, 231, 0.08);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all var(--transition);
}

.social-link:hover {
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-3px);
}

/* ---- Contact Form ---- */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-main);
  font-size: 0.95rem;
  color: var(--text-primary);
  transition: all var(--transition);
  outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238888aa' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

.form-status {
  font-size: 0.85rem;
  text-align: center;
  min-height: 20px;
}

.form-status.success {
  color: #00b894;
}

.form-status.error {
  color: #ff6b6b;
}

/* ---- Footer ---- */
.footer {
  padding: 40px 0;
  border-top: 1px solid var(--border);
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
}

.footer-text {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---- Legal links in footer ---- */
.footer-legal-links {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.footer-legal-link {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}
.footer-legal-link:hover {
  color: #ffffff;
  text-decoration: underline;
}
.footer-legal-sep {
  color: rgba(255, 255, 255, 0.15);
}

/* ---- Footer right column ---- */
.footer-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* ---- Lightbox ---- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
}

.lightbox-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  width: 90%;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.lightbox.active .lightbox-content {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 1;
  transition: background var(--transition);
}

.lightbox-close:hover {
  background: var(--accent);
}

.lightbox-video {
  aspect-ratio: 16 / 9;
  background: #000;
}

.lightbox-video iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.lightbox-info {
  padding: 24px;
}

/* ---- Toast ---- */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 14px 24px;
  background: var(--bg-card);
  border: 1px solid var(--accent);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  color: var(--text-primary);
  box-shadow: var(--shadow);
  z-index: 3000;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s ease;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* ---- Film Grain Overlay (homepage only) ---- */
#filmGrain {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  opacity: 0.035;
  mix-blend-mode: overlay;
  image-rendering: pixelated;
}

/* Vignette — darkened edges, subtle cinematic feel */
#filmGrain::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 75% 65% at 50% 50%,
    transparent 45%,
    rgba(5, 5, 10, 0.25) 75%,
    rgba(5, 5, 10, 0.55) 100%
  );
  pointer-events: none;
}

/* ---- Typewriter Effect (Layer 1: Title) ---- */
.typewriter-text {
  display: inline;
  font-family: var(--font-display);
  font-size: 4.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  min-height: 1.15em;
}

.typewriter-cursor {
  display: inline-block;
  width: 3px;
  height: 0.9em;
  background: var(--accent-light);
  margin-left: 4px;
  vertical-align: baseline;
  animation: cursor-blink 0.8s ease-in-out infinite;
  box-shadow: 0 0 8px var(--accent), 0 0 16px rgba(108, 92, 231, 0.4);
}

@keyframes cursor-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* CRT Noise Scan Line overlay for subtitle only */
.subtitle-wrapper {
  position: relative;
  display: block;
}

.subtitle-wrapper::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg,
    transparent,
    rgba(162, 155, 254, 0.15),
    rgba(162, 155, 254, 0.3),
    rgba(162, 155, 254, 0.15),
    transparent
  );
  animation: noise-scan 3s linear infinite;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.subtitle-wrapper.scanning::after {
  opacity: 1;
}

@keyframes noise-scan {
  0% { top: 0; }
  100% { top: calc(100% - 3px); }
}

/* ---- Film Development Effect (Layer 2: Cards) ---- */
.portfolio-card.developing,
.shop-card.developing {
  filter: brightness(0.05) saturate(0);
  transition: filter 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.portfolio-card.developing.visible,
.shop-card.developing.visible {
  filter: brightness(1) saturate(1);
}

/* Film grain overlay on cards during development */
.portfolio-card.developing::before,
.shop-card.developing::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 1px,
    rgba(108, 92, 231, 0.03) 1px,
    rgba(108, 92, 231, 0.03) 2px
  );
  animation: film-grain 0.15s steps(4) infinite;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.portfolio-card.developing.visible::before,
.shop-card.developing.visible::before {
  opacity: 0;
}

@keyframes film-grain {
  0% { transform: translateY(0); }
  100% { transform: translateY(2px); }
}

/* ---- Parallax Gradient Background (Layer 3) ---- */
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(108, 92, 231, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(253, 121, 168, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 20% 80%, rgba(108, 92, 231, 0.06) 0%, transparent 50%);
  z-index: 0;
  transition: transform 0.1s linear;
  will-change: transform;
}

/* ---- Animations ---- */
[data-animate] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-animate].visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Responsive (880px) — mobile hamburger menu */
@media (max-width: 880px) {
  .mobile-toggle {
    display: flex;
  }

  /* Centered floating card menu */
  .nav-links {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.92);
    width: min(340px, calc(100vw - 48px));
    max-height: 70vh;
    background: rgba(15, 15, 22, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 32px 24px 40px;
    border-radius: 16px;
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease;
    overflow-y: auto;
    z-index: 9998;
  }

  .nav-links.open {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 16px 24px;
    text-align: center;
  }

  /* Hamburger left, logo center, cart right — each at edge */
  .nav-container {
    display: flex;
    align-items: center;
  }
  .mobile-toggle {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
  }
  .nav-logo {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }
  .cart-nav-btn {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
  }
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
  }

  /* Centered floating card menu */
  .nav-links {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.92);
    width: min(340px, calc(100vw - 48px));
    max-height: 70vh;
    background: rgba(15, 15, 22, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 32px 24px 40px;
    border-radius: 16px;
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease;
    overflow-y: auto;
    z-index: 9998;
  }

  .nav-links.open {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 16px 24px;
    text-align: center;
  }

  .mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }

  .mobile-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  /* Hamburger left, logo center, cart right — each at edge */
  .nav-container {
    display: flex;
    align-items: center;
  }
  .mobile-toggle {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
  }
  .nav-logo {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }
  .cart-nav-btn {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
  }

  .hero-title {
    font-size: 2.8rem;
    max-width: 90%;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
    max-width: 100%;
  }
  .portfolio-card {
    max-height: 50vh;
  }
  .portfolio-card .portfolio-info {
    padding: 16px;
  }
  .shop-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
  .plugins-grid {
    grid-template-columns: 1fr;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-right {
    align-items: center;
  }

  .about-stats {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .values-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero {
    padding: 100px 16px 120px;
  }
  .hero-content {
    padding-bottom: 24px;
  }

  .portfolio,
  .shop,
  .plugins,
  .contact,
  .about,
  .featured-preview,
  .featured-products,
  .page-header {
    padding: 60px 0;
  }

  .page-title {
    font-size: 1.8rem;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .hero-title {
    font-size: 2rem;
    max-width: 95%;
  }
}

/* ==========================================================
   Featured Products — match Shop page card appearance (TOP page only)
   Shop page (shop-a24.css) is flat: transparent card, white image tile,
   black title. Top page only loads style.css, so it currently shows the
   dark card "box" (dark bg + border + radius + dark info band). Override
   the card *appearance* (non-hover) here to match shop page. The existing
   hover effects (scale / glow / dim) are untouched and preserved.
   Scope: .featured-products exists only on index.html (NOT on shop page).
   ========================================================== */

/* Card body: dark box -> flat on white */
.featured-products .shop-card {
  background: #ffffff;
  border: none;
  border-radius: 0;
}

/* Image tile: dark + radius -> white + near-square corners (shop style) */
.featured-products .shop-card-image {
  background: #ffffff;
  border-radius: 2px;
}

/* Product title: white (on dark band) -> black (directly on white page) */
.featured-products .shop-card-title {
  color: #16161a;
}

/* ============================================
   Checkout Modal (Inline Stripe Payment)
   ============================================ */

/* Checkout Modal (centered popup, responsive) */
.checkout-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.checkout-modal-content {
  position: relative;
  z-index: 1;
  width: min(900px, 95vw);
  height: auto;
  max-height: 90vh;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  color: #1a1a1a;
  opacity: 0;
  transition: opacity 0.3s ease;
  overflow: hidden;
}

/* Phase 2: Payment+shipping column */
.checkout-modal-content > #checkoutPhasePayment {
  display: flex !important;
  gap: 16px;
  padding: 0 24px;
  flex: 1 1 auto;
  min-height: 0;
}

/* Order Summary — right column, sibling of Phase 2 */
.checkout-modal-content > .checkout-order-summary {
  width: 320px !important;
  max-width: 320px !important;
  flex-shrink: 0;
  display: flex !important;
  flex-direction: column;
  padding: 0 0 8px;
}

.checkout-modal.active {
  pointer-events: auto;
}

.checkout-modal.active .checkout-modal-content {
  opacity: 1;
}

/* Checkout backdrop */
.checkout-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.checkout-modal.active .checkout-modal-backdrop {
  opacity: 1;
  pointer-events: auto;
}

/* Close button */
.checkout-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: #666;
  font-size: 1.1rem;
  cursor: pointer;
  transition: color var(--transition), background var(--transition);
  z-index: 1;
}

.checkout-modal-close:hover {
  color: #000;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 50%;
}

/* Title */
.checkout-modal-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: #1a1a1a;
  padding: 24px 24px 16px;
  border-bottom: 1px solid #e5e5e5;
}

/* ---- Phase 1: Cart Summary ---- */
#checkoutPhaseCart {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.checkout-modal-items {
  flex: 1;
  overflow-y: auto;
  padding: 0 24px;
}

.checkout-modal-footer {
  border-top: 1px solid #e5e5e5;
  padding: 20px 24px;
}

.checkout-modal-total {
  display: flex;
  justify-content: flex-end;
  font-size: 1.1rem;
  font-weight: 600;
  color: #1a1a1a;
}

/* ---- Phase 2: Payment Form ---- */
#checkoutPhasePayment {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow-y: auto;
  padding: 0;
}

/*
  Three-column layout (wide screens >900px):
  left   = Stripe Payment Element (~35%)
  middle = Shipping address form (~25%)
  right  = Order Summary (~40%)

  Two-column layout (≤900px): payment + order summary stacked
*/
#checkoutPhasePayment .checkout-body-layout {
  display: flex;
  gap: 16px;
  flex: 1 1 auto;
  min-height: 0;
}

/* Left column: Stripe Payment Element */
.checkout-payment-col {
  width: 35%;
  min-width: 240px;
  display: flex;
  flex-direction: column;
}

/* Force iframe height constraints for reliable grid layout */
#stripe-payment-element iframe {
  max-height: 100% !important;
  overflow-y: auto !important;
}

/* Middle column: Shipping address form */
.checkout-shipping-col {
  width: 25%;
  min-width: 160px;
  max-width: 200px;
  display: flex;
  flex-direction: column;
}

/* Right column: Order Summary */
.checkout-order-summary {
  width: 40% !important;
  min-width: 200px;
  max-width: 320px;
  display: flex !important;
  flex-direction: column;
  padding: 0 0 8px;
  height: fit-content;
}

/* Payment Element mount point (placeholder until mounted) */
#stripe-payment-element {
  min-height: 320px;
  background: #f8f8fc;
  border: 1px dashed #e0e0e8;
  border-radius: 8px;
}

#stripe-payment-element.mounted {
  min-height: 0;
  background: none;
  border: none;
}

/* Loading indicator while Payment Element is mounting */
.payment-element-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 320px;
  font-size: 14px;
  color: #888;
}

#checkoutPhasePayment.hidden {
  display: none !important;
}

/* Name field (below the Payment Element frame) */
.checkout-form-group {
  margin-top: 16px;
}

.checkout-form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #555;
  margin-bottom: 6px;
}

.checkout-form-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  color: #16161a;
  background: #fff;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.checkout-form-input:focus {
  outline: none;
  border-color: #6c5ce7;
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.checkout-summary-title {
  font-size: 16px;
  font-weight: 600;
  color: #16161a;
  margin: 0 0 12px;
  text-align: right;
}

/* Item: name (line 1) + xN price (line 2), right-aligned */
.checkout-summary-item {
  margin-bottom: 10px;
  text-align: right;
}

.checkout-summary-item-name {
  font-size: 13px;
  color: #16161a;
  line-height: 1.4;
  overflow-wrap: break-word;
}

.checkout-summary-item-price {
  font-size: 12px;
  color: #888;
  margin-top: 1px;
}

#checkoutSummaryItems {
  margin-bottom: 4px;
}

.checkout-summary-divider {
  height: 1px;
  background: #e5e5e5;
  margin: 10px 0;
}

/* Totals: same 2-line rhythm (label over value), right-aligned */
.checkout-summary-row,
.checkout-summary-total {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
  margin-bottom: 8px;
}

.checkout-summary-row > span:first-child,
.checkout-summary-total > span:first-child {
  font-size: 12px;
  color: #888;
}

.checkout-summary-row > span:last-child,
.checkout-summary-total > span:last-child {
  font-size: 13px;
  color: #16161a;
}

.checkout-summary-total {
  margin-top: 4px;
}

.checkout-summary-total > span:last-child {
  font-size: 15px;
  font-weight: 700;
}

/* Confirm button: bottom of the right column */
.btn-checkout-confirm {
  width: 100%;
  margin-top: auto;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
}

.btn-checkout-confirm span {
  display: block;
}

.btn-checkout-confirm:hover {
  background: var(--accent-dark);
}

.btn-checkout-confirm:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-checkout-confirm:active:not(:disabled) {
  transform: scale(0.98);
}

/* ---- Shipping address section (physical/mixed only) ---- */
.shipping-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #e5e7eb;
  position: relative;
  z-index: 2;
}

.shipping-section-title {
  font-size: 13px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 12px;
  letter-spacing: 0.03em;
}

.checkout-form-row {
  display: flex;
  gap: 8px;
}

.checkout-form-group-half {
  flex: 1;
}

/* ---- Cart items inside checkout modal ---- */
.checkout-modal-items .checkout-cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
}

.checkout-modal-items .checkout-cart-item:last-child {
  border-bottom: none;
}

.checkout-modal-items .checkout-cart-item-img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 8px;
  background: #f5f5f5;
}

.checkout-modal-items .checkout-cart-item-info {
  flex: 1;
}

.checkout-modal-items .checkout-cart-item-name {
  font-size: 14px;
  font-weight: 500;
  color: #16161a;
  margin: 0 0 4px;
}

.checkout-modal-items .checkout-cart-item-size {
  font-size: 12px;
  color: #888;
  margin: 0;
}

.checkout-modal-items .checkout-cart-item-price {
  font-size: 15px;
  font-weight: 600;
  color: #16161a;
  white-space: nowrap;
}

.checkout-modal-items .checkout-cart-item-remove {
  background: none;
  border: none;
  color: #ccc;
  font-size: 18px;
  cursor: pointer;
  padding: 4px 8px;
  transition: color 0.2s;
}

.checkout-modal-items .checkout-cart-item-remove:hover {
  color: #e74c3c;
}

/* Empty message */
.checkout-empty-message {
  text-align: center;
  padding: 32px 0;
  color: #888;
  font-size: 14px;
}

/* Scrollbar styling */
.checkout-modal-items::-webkit-scrollbar {
  width: 6px;
}

.checkout-modal-items::-webkit-scrollbar-track {
  background: transparent;
}

.checkout-modal-items::-webkit-scrollbar-thumb {
  background: #ddd;
  border-radius: 3px;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .checkout-modal-content > #checkoutPhasePayment {
    flex-direction: column !important;
  }

  #checkoutPhasePayment .checkout-body-layout {
    flex-direction: column;
  }

  .checkout-payment-col,
  .checkout-shipping-col,
  .checkout-modal-content > .checkout-order-summary {
    width: 100% !important;
    max-width: none !important;
    min-width: 0;
  }

  .checkout-payment-col {
    order: 1;
  }

  .checkout-shipping-col {
    order: 2;
    border-top: 1px solid #e5e7eb;
    padding-top: 16px;
    margin-top: 16px;
  }

  #checkoutPhasePayment .checkout-order-summary {
    order: 3;
    border-top: 1px solid #e5e7eb;
    padding-top: 16px;
    margin-top: 0;
  }

  .btn-checkout-confirm {
    margin-top: 16px;
  }
}

@media (max-width: 600px) {
  .checkout-modal-content {
    width: 100vw;
    max-width: 100vw;
    height: 100vh;
    max-height: 100vh;
    border-radius: 0;
  }

  .checkout-modal-title {
    padding: 16px 16px 12px;
  }
}
/* ============================================
   About Simple & Contact Simple (anchor sections)
   Added 2026-10-18 — separate from about/index.html and contact/index.html styles
   ============================================ */

.about-simple,
.contact-simple {
  position: relative;
  overflow: hidden;
  min-height: 300px;
  padding: 64px 24px 8px;
  text-align: center;
  background: var(--bg-secondary);
}

/* Subtle floating dots as fallback / enhancement */
.about-simple::before,
.contact-cta::before {
  content: '';
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(162, 155, 254, 0.08), transparent 70%);
  top: 30%;
  left: 50%;
  transform: translateX(-50%);
  animation: float-glow 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

.contact-cta::before {
  background: radial-gradient(circle, rgba(162, 155, 254, 0.06), transparent 70%);
  width: 300px;
  height: 300px;
}

@keyframes float-glow {
  0%, 100% { opacity: 0.3; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.7; transform: translateX(-50%) translateY(-20px); }
}

.about-simple .section-tag,
.contact-simple .section-tag {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  color: var(--accent-light);
  margin-bottom: 48px;
  position: relative;
}

.about-simple .section-tag::after,
.contact-simple .section-tag::after {
  content: '';
  display: block;
  width: 60px;
  height: 1px;
  background: var(--accent);
  margin: 24px auto 0;
}

/* Spacing for new h2 section-title in about-simple */
.about-simple .section-title {
  margin-bottom: 48px;
}

/* Ensure content renders above particles */
.about-simple .container,
.contact-cta .container {
  position: relative;
  z-index: 2;
}

.about-text-en,
.about-text-jp {
  max-width: 580px;
  margin: 0 auto 32px;
  line-height: 1.85;
  color: var(--text-primary);
  font-size: 0.95rem;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.about-text-en {
  letter-spacing: 0.02em;
  opacity: 1;
}

.about-text-jp {
  font-size: 0.95rem;
  line-height: 2.0;
  letter-spacing: 0.06em;
  opacity: 1;
}

.contact-info-simple {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.contact-item-simple {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-primary);
  font-size: 0.95rem;
}

.contact-icon-simple {
  font-size: 1.1rem;
  opacity: 0.6;
}

.contact-value-simple {
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--transition);
}

.contact-value-simple:hover,
.contact-value-simple:focus {
  color: var(--accent-light);
}

/* ============================================
   Contact CTA (replaces contact-simple anchor section)
   Added 2026-10-18 — replaces #contact anchor with link to /contact/
   Uses existing .section-title + .text-gradient for header style
   ============================================ */

.contact-cta {
  position: relative;
  overflow: hidden;
  padding: 24px 24px;
  text-align: center;
  background: var(--bg-secondary);
}

/* Extra spacing between subtitle and button in this section */
.contact-cta .section-desc {
  margin-bottom: 56px;
}

/* ============================================
   Gradient divider (between Featured Products and About Us)
   Added 2026-10-18 — vertical gradient from white to bg-secondary
   ============================================ */

.gradient-divider {
  width: 100%;
  height: 80px;
  background: linear-gradient(to bottom, #ffffff, var(--bg-secondary));
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .about-simple,
  .contact-simple {
    padding: 60px 24px;
  }

  .about-text-en,
  .about-text-jp {
    font-size: 0.85rem;
    line-height: 1.7;
  }
}
