:root {
  --bg-color: #000000;
  --text-color: #e0e0e0;
  --accent-color: #ffffff;
  --font-heading: "Playfair Display", serif;
  --font-body: "Roboto", sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

/* Animate SPA sections when they become active */
.page-section {
    display: none;
}

.page-section.active {
    display: block;
    animation: smoothReveal 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
}

/* The fluid, glassy animation */
@keyframes smoothReveal {
    0% {
        opacity: 0;
        transform: translateY(10px);
        filter: blur(5px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

/* Enable native cross-page transitions */
@view-transition {
    navigation: auto;
}

/* Optional: Customize the cross-page animation duration */
::view-transition-old(root),
::view-transition-new(root) {
    animation-duration: 0.3s;
}

#void-background,
.cart-overlay-bg,
.gallery-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
}

#void-background {
  z-index: -1;
  background-color: var(--bg-color);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  color: var(--accent-color);
  font-weight: normal;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

h1 {
  font-size: 2.2rem;
  text-transform: uppercase;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 10px;
  margin-bottom: 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header p {
  color: #aaa;
  font-style: italic;
}

header {
  text-align: center;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: relative;
  z-index: 10;
}

header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo-container {
  margin-bottom: 1.5rem;
}

.logo {
  max-width: 350px;
  width: 100%;
  height: auto;
  filter: grayscale(100%);
  transition: filter 0.4s ease, transform 0.4s ease;
}

.footerlogo {
  max-width: 350px;
  width: 50%;
  height: auto;
  filter: grayscale(100%);
  transition: filter 0.4s ease, transform 0.4s ease;
}

.logo:hover {
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3)) grayscale(100%);
  transform: scale(1.02);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
}

nav a {
  color: #999;
  text-decoration: none;
  text-transform: uppercase;
  font-family: var(--font-heading);
  letter-spacing: 1px;
  font-size: 0.95rem;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

nav a:hover,
nav a.active {
  color: var(--accent-color);
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

.cart-toggle-btn {
  color: var(--accent-color);
  font-weight: bold;
  cursor: pointer;
}

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 4rem 2rem;
  min-height: 65vh;
  position: relative;
  z-index: 10;
}

.page-section {
  display: none;
  animation: fadeIn 0.6s ease forwards;
}

.page-section.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-section,
.card,
.form-container,
.policy-block,
.testimonial,
.product-modal-content,
.cart-sidebar,
.pm-img-container,
.gallery-item {
  background: rgba(10, 10, 10, 0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transform: translateZ(0);
}

.hero-section {
  backdrop-filter: blur(10px);
  text-align: center;
  padding: 5rem 2rem;
  margin-bottom: 3rem;
}

.typewriter-container {
  min-height: 80px;
  margin: 0 auto 2rem auto;
  max-width: 800px;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: #ccc;
  letter-spacing: 0.5px;
}

.cursor {
  display: inline-block;
  width: 8px;
  height: 1.1rem;
  background-color: var(--accent-color);
  animation: blink 1s infinite;
  margin-left: 4px;
  vertical-align: middle;
}

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

.btn {
  display: inline-block;
  background: transparent;
  color: var(--accent-color);
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 12px 24px;
  font-family: var(--font-heading);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 1rem;
  text-align: center;
}

.btn:hover:not(:disabled) {
  background: var(--accent-color);
  color: var(--bg-color);
  border-color: var(--accent-color);
}

.btn:disabled {
  border-color: #333;
  color: #555;
  cursor: not-allowed;
}

.btn-small {
  padding: 8px 16px;
  font-size: 0.8rem;
  margin-top: 0;
}

.full-width {
  width: 100%;
}

.pulse-btn {
  font-size: 1.1rem;
  padding: 15px 40px;
}

.store-categories {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.category-btn.active {
  background: var(--accent-color);
  color: var(--bg-color);
  border-color: var(--accent-color);
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.card {
  padding: 2rem;
  text-align: left;
  transition: transform 0.3s ease, border-color 0.3s ease, background 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.card > div:first-child {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(15, 15, 15, 0.85);
}

.price {
  font-size: 1.3rem;
  font-family: var(--font-heading);
  color: var(--accent-color);
  margin-bottom: 1rem;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
  padding-bottom: 0.5rem;
}

.product-image-container {
  position: relative;
  margin-bottom: 1rem;
  background: radial-gradient(
      circle at top,
      rgba(255, 255, 255, 0.06),
      transparent 55%
    ),
    linear-gradient(180deg, #0b0b0b 0%, #050505 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: stretch;
  justify-content: center;
  flex-shrink: 0;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.35s ease;
}

.card:hover .product-image {
  transform: scale(1.02);
}

.product-thumbs {
  position: absolute;
  left: 50%;
  bottom: 0.6rem;
  transform: translateX(-50%);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  width: max-content;
  max-width: calc(100% - 1rem);
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  z-index: 3;
}

.p-thumb {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  object-fit: cover;
  object-position: center;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.28);
  opacity: 0.88;
  border-radius: 4px;
  background: #080808;
  transition: opacity 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.p-thumb:hover {
  opacity: 1;
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.5);
}

.p-thumb.active {
  border-color: var(--accent-color);
  opacity: 1;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.22),
    0 0 8px rgba(255, 255, 255, 0.16);
}

.stock-indicator {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  margin-top: auto;
  margin-bottom: 1rem;
  color: #888;
}

.text-red {
  color: #666;
  font-style: italic;
}

.loading-text {
  text-align: center;
  grid-column: 1 / -1;
  font-style: italic;
  color: #888;
}

.product-modal-content {
  border-radius: 8px;
  max-width: 1000px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2.5rem;
  position: relative;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
  cursor: default;
}

.product-modal-layout {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

@media (min-width: 768px) {
  .product-modal-layout {
    flex-direction: row;
  }
  .product-modal-image-col {
    flex: 1;
    min-width: 0;
  }
  .product-modal-info-col {
    flex: 1.2;
    text-align: left;
  }
}

.pm-img-container {
  position: relative; 
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 8px;
  overflow: hidden; 
  margin-bottom: 1rem;
  background: radial-gradient(circle at top, rgba(255, 255, 255, 0.06), transparent 55%), linear-gradient(180deg, #0b0b0b 0%, #050505 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.pm-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pm-description {
  color: #ccc;
  margin-bottom: 2rem;
  white-space: pre-line;
  line-height: 1.8;
  font-size: 0.95rem;
}

#product-modal .gallery-modal-close {
  top: 15px;
  right: 25px;
}

#product-modal {
  z-index: 1000;
}

#gallery-modal {
  z-index: 2000;
}

.pm-action-container {
  display: flex;
  gap: 10px;
  margin-top: 1rem;
  align-items: stretch;
}

.qty-input,
.qty-input-small,
.form-group input,
.form-group select,
.form-group textarea,
.shipping-input-group input {
  background: rgba(10, 10, 10, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-color);
  font-family: var(--font-body);
  outline: none;
  border-radius: 4px;
  transition: border-color 0.3s;
}

.qty-input:focus,
.qty-input-small:focus,
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent-color);
}

.qty-input {
  width: 80px;
  padding: 12px;
  font-size: 1.1rem;
  text-align: center;
}

.qty-input-small {
  width: 60px;
  padding: 8px;
  font-size: 1rem;
  text-align: center;
}

.form-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 2.5rem;
}

.form-group {
  margin-bottom: 1.5rem;
  text-align: left;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-family: var(--font-heading);
  color: #ccc;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px;
}

.cart-sidebar {
  position: fixed;
  top: 0;
  right: -450px;
  width: 450px;
  max-width: 100%;
  height: 100vh;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 10000;
  transition: right 0.4s ease;
  display: flex;
  flex-direction: column;
  padding: 2rem;
}

.cart-sidebar.open {
  right: 0;
  box-shadow: -10px 0 50px rgba(0, 0, 0, 0.9);
}

.cart-overlay-bg {
  background: rgba(0, 0, 0, 0.8);
  z-index: 9999;
  display: none;
  backdrop-filter: blur(2px) grayscale(100%);
  -webkit-backdrop-filter: blur(2px) grayscale(100%);
}

.cart-overlay-bg.open {
  display: block;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #333;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
}

.close-btn,
.remove-item-btn {
  background: none;
  border: none;
  cursor: pointer;
  transition: color 0.3s;
}

.close-btn {
  color: #999;
  font-size: 2.5rem;
  line-height: 1;
}

.close-btn:hover,
.remove-item-btn:hover {
  color: #fff;
}

.cart-items {
  flex-grow: 1;
  overflow-y: auto;
  padding-right: 10px;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dashed #333;
  padding: 1.5rem 0;
}

.remove-item-btn {
  color: #555;
  font-size: 1.8rem;
}

.cart-footer {
  border-top: 1px solid #333;
  padding-top: 1.5rem;
  margin-top: 1rem;
}

.subtotal-text {
  color: #aaa;
  font-size: 1rem;
}

.total-text {
  font-size: 1.3rem;
  margin: 1rem 0;
  border-bottom: 1px solid #333;
  padding-bottom: 1rem;
}

.shipping-calculator {
  margin: 1rem 0;
  padding: 1.5rem 0;
  border-top: 1px dashed #333;
  border-bottom: 1px dashed #333;
}

.shipping-calculator label {
  display: block;
  margin-bottom: 10px;
  color: #ccc;
}

.shipping-input-group {
  display: flex;
  gap: 10px;
}

.shipping-input-group input {
  flex: 1;
  padding: 10px;
  text-transform: uppercase;
}

.shipping-result {
  margin-top: 10px;
  font-size: 0.9rem;
  font-style: italic;
  color: #ccc;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.gallery-item {
  height: 250px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #e0e0e0;
  font-family: var(--font-heading);
  transition: border-color 0.3s, transform 0.3s;
  cursor: pointer;
}

.gallery-item:hover {
  border-color: rgba(255, 255, 255, 0.5);
  transform: scale(1.02);
}

.gallery-modal {
  background: rgba(0, 0, 0, 0.95);
  z-index: 20000;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  padding: 2rem;
  cursor: pointer;
}

.gallery-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.gallery-modal img#modal-image {
  max-width: 90%;
  max-height: 70vh;
  object-fit: contain;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
  background: #000;
  transform: scale(0.95);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: default;
}

.gallery-modal.open img#modal-image {
  transform: scale(1);
}

.modal-thumbnails {
  display: flex;
  gap: 10px;
  margin-top: 15px;
  max-width: 90%;
  overflow-x: auto;
  padding-bottom: 5px;
  cursor: default;
}

.modal-thumb {
  width: 60px;
  height: 60px;
  object-fit: cover;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.6;
  transition: all 0.3s ease;
}

.modal-thumb:hover,
.modal-thumb.active {
  border-color: var(--accent-color);
  opacity: 1;
}

.gallery-modal-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 3rem;
  cursor: pointer;
  transition: color 0.3s;
  z-index: 20001;
}

.gallery-modal-close:hover {
  color: #888;
}

.gallery-modal-caption {
  margin-top: 1rem;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: #e0e0e0;
  text-align: center;
}

.testimonial-container,
.policy-block {
  max-width: 800px;
  margin: 0 auto;
}

.testimonial {
  margin-bottom: 2.5rem;
  padding: 2rem;
  border-left: 2px solid #555;
  font-style: italic;
  color: #ccc;
  transition: border-color 0.3s;
}

.testimonial:hover {
  border-color: var(--accent-color);
}

.testimonial span {
  display: block;
  margin-top: 1rem;
  font-weight: bold;
  font-family: var(--font-heading);
  font-style: normal;
  color: #fff;
}

.policy-block {
  padding: 2rem;
}

.policy-block h3 {
  margin-top: 2rem;
  font-size: 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 5px;
  color: #fff;
}

.policy-block h3:first-child {
  margin-top: 0;
}

.policy-block p {
  margin-top: 1rem;
  color: #aaa;
}

/* Updated & Fixed Footer Styles */
footer {
  padding: 4rem 2rem 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  font-family: var(--font-body);
  background: rgba(5, 5, 5, 0.8);
  position: relative;
  z-index: 10;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-col h3,
.footer-col h4 {
  font-family: var(--font-heading);
  color: var(--accent-color);
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.footer-col h3 {
  font-size: 1.3rem;
}

.footer-col p {
  margin-bottom: 0.8rem;
  color: #999;
  font-size: 0.95rem;
  line-height: 1.5;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li {
  margin-bottom: 0.5rem;
}

.footer-col ul li a {
  color: #999;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.3s;
}

.footer-col ul li a:hover {
  color: var(--accent-color);
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  text-align: center;
}

.footer-bottom p {
  color: #666;
  font-size: 0.85rem;
  font-family: var(--font-body);
}

.hover-glow {
  color: #aaa;
  text-decoration: none;
  transition: color 0.3s;
}

.hover-glow:hover {
  color: #fff;
}

.social-links {
  margin-top: 0.5rem;
  color: #666;
}

.split-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (max-width: 767px) {
  .card {
    padding: 1.4rem;
  }
  .product-thumbs {
    bottom: 0.45rem;
    gap: 6px;
    max-width: calc(100% - 0.75rem);
  }
  .p-thumb {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
  }
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (min-width: 768px) {
  .split-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
