/* Site fonts: Apple SF → Prompt → Inter. Anton is only for RED CAMERA wordmark. */
html, body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", Prompt, Inter, sans-serif;
}

.brand-wordmark {
  font-family: Anton, sans-serif;
}

/* Store themes: redcamera (default) | netflix */
html[data-theme="netflix"],
html[data-theme="netflix"] body {
  background: #141414 !important;
  background-color: #141414 !important;
  background-image: none !important;
  color: #fff !important;
  selection-background-color: #e50914;
}

html[data-theme="netflix"] body.bg-gradient-to-br:not(.page-home) {
  background: #141414 !important;
  background-color: #141414 !important;
  background-image: none !important;
}

html[data-theme="netflix"] .glass-nav {
  background: linear-gradient(180deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.55) 70%, transparent 100%) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border-bottom: none !important;
}

html[data-theme="netflix"] .glass-card {
  background: #181818 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid transparent !important;
  border-radius: 6px !important;
  box-shadow: none !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease !important;
}

html[data-theme="netflix"] .glass-card:hover {
  transform: scale(1.06) !important;
  box-shadow: 0 12px 28px rgba(0,0,0,0.55) !important;
  z-index: 5;
}

html[data-theme="netflix"] .fire-border-wrapper {
  padding: 0 !important;
  border-radius: 6px !important;
  background: none !important;
  animation: none !important;
  box-shadow: none !important;
}

html[data-theme="netflix"] .animate-bounce-subtle {
  animation: none !important;
}

html[data-theme="netflix"] .animate-heartbeat {
  animation: none !important;
}

/* Netflix billboard hero */
html[data-theme="netflix"] #nf-billboard {
  display: block !important;
}

html[data-theme="netflix"] #store-classic-header {
  display: none !important;
}

#nf-billboard {
  display: none;
  position: relative;
  width: 100%;
  min-height: 68vw;
  max-height: 78vh;
  overflow: hidden;
  margin-top: 0;
  margin-bottom: 0;
  background: #141414;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

@media (min-width: 768px) {
  #nf-billboard {
    min-height: 56vh;
  }
}

#nf-billboard .nf-billboard-bg {
  position: absolute;
  top: -6%;
  left: -6%;
  width: 112%;
  height: 112%;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  opacity: 1;
  transition: opacity 0.55s ease;
  transform: translate3d(0, 0, 0) scale(1);
  transform-origin: center center;
  will-change: transform, opacity;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

#nf-billboard .nf-billboard-bg.is-kenburns {
  animation: nfBillboardKenBurns 7s linear 1 forwards;
  -webkit-animation: nfBillboardKenBurns 7s linear 1 forwards;
}

#nf-billboard .nf-billboard-bg.is-fading {
  opacity: 0;
}

@keyframes nfBillboardKenBurns {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(-3.5%, -2.2%, 0) scale(1.14); }
}

@-webkit-keyframes nfBillboardKenBurns {
  0% { -webkit-transform: translate3d(0, 0, 0) scale(1); }
  100% { -webkit-transform: translate3d(-3.5%, -2.2%, 0) scale(1.14); }
}

@media (prefers-reduced-motion: reduce) {
  #nf-billboard .nf-billboard-bg.is-kenburns {
    animation: none !important;
    -webkit-animation: none !important;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
  }
}

#nf-billboard .nf-billboard-dim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.55s ease;
}

#nf-billboard .nf-billboard-dim.is-on {
  opacity: 1;
}

#nf-billboard .nf-billboard-fade {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(77deg, rgba(0,0,0,0.75) 0%, transparent 55%),
    linear-gradient(to top, #141414 0%, #141414 22%, rgba(20,20,20,0.92) 38%, transparent 58%);
  pointer-events: none;
}

/* บังรอยต่อขอบล่าง — กันเส้นแดงจากพื้นหลัง body / รูปสินค้า */
#nf-billboard::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 18px;
  z-index: 5;
  background: #141414;
  pointer-events: none;
}

/* บังรอยต่อขอบล่างฮีโร่ — ใช้เฉพาะหน้า store ที่มี #nf-billboard เท่านั้น
   ห้ามจับ main ของหน้าสินค้า/ขายของ เพราะจะทับ pt-32 ที่เผื่อ navbar */
html[data-theme="netflix"] #nf-billboard ~ main {
  position: relative;
  z-index: 2;
  background-color: #141414 !important;
  margin-top: -2px;
  padding-top: 2px;
  box-shadow: 0 -12px 0 0 #141414;
}

#nf-billboard .nf-billboard-content {
  position: relative;
  z-index: 3;
  max-width: 42rem;
  padding: 8rem 1.5rem 4rem;
}

@media (min-width: 768px) {
  #nf-billboard .nf-billboard-content {
    padding: 10rem 3.5rem 5rem;
  }
}

#nf-billboard .nf-title {
  font-size: clamp(2rem, 5vw, 3.75rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.05;
  text-shadow: 0 4px 24px rgba(0,0,0,0.7);
}

#nf-billboard .nf-desc {
  margin-top: 1rem;
  color: rgba(255,255,255,0.85);
  font-size: 0.95rem;
  line-height: 1.55;
  max-width: 32rem;
}

#nf-billboard .nf-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

#nf-billboard .nf-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: 4px;
  background: #fff;
  color: #141414;
  font-weight: 700;
  font-size: 0.95rem;
}

#nf-billboard .nf-btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: 4px;
  background: rgba(109,109,110,0.7);
  color: #fff;
  font-weight: 650;
  font-size: 0.95rem;
}

html[data-theme="netflix"] nav a.text-2xl,
html[data-theme="netflix"] #loading-spinner-group .text-2xl {
  color: #e50914 !important;
}

html[data-theme="netflix"] .bg-red-600,
html[data-theme="netflix"] .bg-red-600\/80 {
  --tw-gradient-from: #e50914 !important;
}

html[data-theme="netflix"] :not(body).from-red-600 {
  --tw-gradient-from: #e50914 !important;
}

html[data-theme="netflix"] footer {
  background: #000 !important;
  border-color: #222 !important;
}

html[data-theme="netflix"] #section-recommended,
html[data-theme="netflix"] #section-available,
html[data-theme="netflix"] #section-coming-soon {
  margin-bottom: 2rem !important;
}

html[data-theme="netflix"] #grid-recommended,
html[data-theme="netflix"] #grid-available,
html[data-theme="netflix"] #grid-coming-soon {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
  gap: 0.5rem !important;
}

html[data-theme="netflix"] #grid-available > *,
html[data-theme="netflix"] #grid-coming-soon > *,
html[data-theme="netflix"] #grid-recommended > * {
  width: 48.3vw !important;
  max-width: 276px;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  html[data-theme="netflix"] #grid-available > *,
  html[data-theme="netflix"] #grid-coming-soon > *,
  html[data-theme="netflix"] #grid-recommended > * {
    width: 18.4vw !important;
    max-width: 253px;
  }
}

html[data-theme="netflix"] .glass-card .aspect-square {
  border-radius: 4px !important;
  border: none !important;
  margin-bottom: 0.5rem !important;
}

html[data-theme="netflix"] .glass-card h3 {
  font-size: 0.85rem !important;
  font-weight: 600 !important;
}

/* Home / landing Netflix */
html[data-theme="netflix"] body.page-home {
  background: #000 !important;
  background-image: none !important;
  position: relative;
  overflow: hidden;
}

html[data-theme="netflix"] body.page-home::before {
  content: "";
  position: fixed;
  top: -6%;
  left: -6%;
  width: 112%;
  height: 112%;
  z-index: 0;
  pointer-events: none;
  background-image: url("../images/themes/netflix-bg-mobile.jpg") !important;
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  opacity: 0.5;
  transform: translate3d(0, 0, 0) scale(1);
  transform-origin: center center;
  will-change: transform;
  animation: nfHomeBgKenBurns 5s linear 1 forwards;
  -webkit-animation: nfHomeBgKenBurns 5s linear 1 forwards;
}

@media (min-width: 768px) {
  html[data-theme="netflix"] body.page-home::before {
    background-image: url("../images/themes/netflix-bg-desktop.jpg") !important;
  }
}

html[data-theme="netflix"] body.page-home::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0) 35%,
    rgba(0, 0, 0, 0.35) 70%,
    rgba(0, 0, 0, 0.72) 100%
  );
}

html[data-theme="netflix"] body.page-home #home-brand-title {
  font-family: Anton, sans-serif !important;
  font-weight: 400 !important;
  font-style: normal;
  letter-spacing: 0.02em;
  animation: nfHomeBrandGrow 5s linear 1 forwards !important;
  -webkit-animation: nfHomeBrandGrow 5s linear 1 forwards !important;
  transform-origin: center center;
  will-change: transform;
}

@keyframes nfHomeBrandGrow {
  0% { transform: scale(1); }
  100% { transform: scale(1.2); }
}

@-webkit-keyframes nfHomeBrandGrow {
  0% { -webkit-transform: scale(1); }
  100% { -webkit-transform: scale(1.2); }
}

@keyframes nfHomeBgKenBurns {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(-3.5%, -2.2%, 0) scale(1.14); }
}

@-webkit-keyframes nfHomeBgKenBurns {
  0% { -webkit-transform: translate3d(0, 0, 0) scale(1); }
  100% { -webkit-transform: translate3d(-3.5%, -2.2%, 0) scale(1.14); }
}

@media (prefers-reduced-motion: reduce) {
  html[data-theme="netflix"] body.page-home::before,
  html[data-theme="netflix"] body.page-home #home-brand-title {
    animation: none !important;
    -webkit-animation: none !important;
    transform: none !important;
  }
}

html[data-theme="netflix"] #btn-buy {
  background: #e50914 !important;
  color: #fff !important;
  border-radius: 4px !important;
}

html[data-theme="netflix"] #btn-sell {
  background: rgba(109,109,110,0.55) !important;
  border-radius: 4px !important;
  border-color: transparent !important;
}
