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

:root {
  --bg: #07020f;
  --page-bg: radial-gradient(circle at top left, #3c096c 0%, var(--bg) 38%, #030008 100%);
  --card: rgba(255, 255, 255, 0.08);
  --card-border: rgba(255, 255, 255, 0.14);
  --text: #ffffff;
  --muted: #c8b8dd;
  --purple: #9d4edd;
  --purple-light: #c77dff;
  --pink: #ff4ecd;
  --accent: var(--purple-light);
  --header-bg: rgba(7, 2, 15, 0.72);
  --panel-bg: linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
  --panel-shadow: rgba(0, 0, 0, 0.38);
  --panel-soft: rgba(255, 255, 255, 0.06);
  --panel-strong: rgba(20, 4, 38, 0.96);
  --divider: rgba(255, 255, 255, 0.08);
  --divider-strong: rgba(255, 255, 255, 0.12);
  --glow-opacity: 0.45;
}

[data-theme="light"] {
  --bg: #f6efff;
  --page-bg: radial-gradient(circle at top left, #f3e6ff 0%, #ffffff 38%, #ffffff 100%);
  --card-border: rgba(74, 15, 122, 0.14);
  --text: #3b0764;
  --muted: #7a5599;
  --accent: #7b2cbf;
  --header-bg: rgba(255, 255, 255, 0.82);
  --panel-bg: linear-gradient(145deg, rgba(157, 78, 221, 0.09), rgba(157, 78, 221, 0.03));
  --panel-shadow: rgba(123, 44, 191, 0.18);
  --panel-soft: rgba(157, 78, 221, 0.07);
  --panel-strong: rgba(255, 255, 255, 0.98);
  --divider: rgba(74, 15, 122, 0.12);
  --divider-strong: rgba(74, 15, 122, 0.16);
  --glow-opacity: 0.22;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Neuton", Georgia, "Times New Roman", serif;
  background: var(--page-bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background 0.25s ease, color 0.25s ease;
}

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

.glow {
  position: fixed;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  filter: blur(80px);
  opacity: var(--glow-opacity);
  z-index: -1;
  transition: opacity 0.25s ease;
}

.glow-one {
  background: var(--purple-light);
  top: 80px;
  left: -120px;
}

.glow-two {
  background: var(--pink);
  right: -120px;
  bottom: 100px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--divider);
}

.navbar {
  width: min(1120px, 92%);
  margin: auto;
  height: 78px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  position: relative;
}

.logo {
  grid-column: 2;
  justify-self: center;
  display: flex;
  align-items: center;
}

.logo img {
  height: 75px;
  width: auto;
  display: block;
}

.nav-links {
  display: none;
  list-style: none;
  flex-direction: column;
  gap: 26px;
  color: var(--muted);
  font-weight: 500;
  font-size: 1.2rem;
}

.nav-links a:hover {
  color: var(--text);
  text-shadow: 0 0 12px var(--purple-light);
}

.nav-links.active {
  position: fixed;
  top: 78px;
  left: 24px;
  display: flex;
  min-width: 240px;
  padding: 36px 32px;
  border-radius: 26px;
  background: var(--panel-strong);
  border: 1px solid var(--card-border);
  z-index: 30;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 700;
  transition: 0.25s ease;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 40px rgba(199, 125, 255, 0.65);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.menu-btn {
  display: block;
  position: fixed;
  top: 20px;
  left: 24px;
  z-index: 25;
  padding: 6px;
  background: none;
  border: 0;
  cursor: pointer;
}

.menu-btn span {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--text);
  margin: 7px 0;
  border-radius: 20px;
  transition: 0.25s ease;
}

.menu-btn.active span:nth-child(1) {
  transform: translateY(10px) rotate(45deg);
}

.menu-btn.active span:nth-child(2) {
  opacity: 0;
}

.menu-btn.active span:nth-child(3) {
  transform: translateY(-10px) rotate(-45deg);
}

.header-actions {
  position: fixed;
  top: 18px;
  right: 24px;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 10px;
}

.auth-buttons,
.auth-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cart-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  background: rgba(157, 78, 221, 0.18);
  border: 1px solid rgba(199, 125, 255, 0.45);
  border-radius: 999px;
  color: var(--text);
  cursor: pointer;
  transition: 0.25s ease;
}

.cart-btn svg {
  width: 20px;
  height: 20px;
}

.cart-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 28px rgba(157, 78, 221, 0.25);
}

.auth-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: inherit;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.25s ease;
}

.account-menu-wrap {
  position: relative;
}

.auth-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  background: rgba(157, 78, 221, 0.18);
  border: 1px solid rgba(199, 125, 255, 0.45);
  border-radius: 999px;
  color: var(--text);
  cursor: pointer;
  transition: 0.25s ease;
}

.auth-icon-btn svg {
  width: 19px;
  height: 19px;
}

.auth-icon-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 28px rgba(157, 78, 221, 0.25);
}

.account-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 170px;
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
  background: var(--panel-strong);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  z-index: 40;
}

.account-menu.open {
  display: flex;
}

.account-menu button {
  background: none;
  border: 0;
  padding: 10px 12px;
  border-radius: 10px;
  text-align: left;
  font: inherit;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
}

.account-menu button:hover {
  background: rgba(199, 125, 255, 0.14);
  color: var(--accent);
}

.auth-btn-logout {
  background: none;
  border: 1px solid var(--card-border);
  color: var(--muted);
  padding: 7px 14px;
  font-size: 0.8rem;
}

.auth-btn-logout:hover {
  border-color: var(--purple-light);
  color: var(--text);
}

.auth-user-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

@media (max-width: 640px) {
  .auth-user-name {
    display: none;
  }

  .auth-btn-logout {
    padding: 7px 10px;
  }

  /* Logo size on phones — change this value to resize the logo */
  .logo img {
    height: 40px;
  }
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.theme-toggle:hover {
  color: var(--text);
  text-shadow: 0 0 12px var(--purple-light);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.theme-toggle .icon-moon {
  display: none;
}

[data-theme="light"] .theme-toggle .icon-sun {
  display: none;
}

[data-theme="light"] .theme-toggle .icon-moon {
  display: block;
}

.cart-count {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: white;
  background: linear-gradient(135deg, var(--purple), var(--pink));
  border-radius: 999px;
}

.hero {
  width: 100%;
  min-height: calc(100vh - 78px);
  display: flex;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(8, 1, 19, 0.55) 0%, rgba(22, 3, 48, 0.4) 38%, rgba(10, 0, 20, 0.2) 68%, rgba(10, 0, 20, 0.05) 100%),
    url("pic /heroSec.PNG") center / 92% no-repeat;
  --text: #ffffff;
  --muted: #c8b8dd;
  --accent: #c77dff;
  --card-border: rgba(255, 255, 255, 0.14);
  --panel-soft: rgba(255, 255, 255, 0.06);
  --divider-strong: rgba(255, 255, 255, 0.12);
}

.hero-inner {
  width: min(1120px, 92%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 70px 0;
}

.hero-content,
.hero-features {
  grid-column: 2;
}

.eyebrow {
  color: var(--accent);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  margin-bottom: 12px;
}

h1 {
  font-family: "Tangerine", cursive;
  font-size: clamp(2.7rem, 7vw, 5.8rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

.hero-text,
.about p,
.product-card p,
.review-card p,
.cta p {
  color: var(--muted);
  line-height: 1.8;
}

.hero-text {
  max-width: 620px;
  font-size: 1.08rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 34px 0;
}

.btn {
  padding: 15px 24px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--purple), var(--pink));
  box-shadow: 0 0 28px rgba(199, 125, 255, 0.42);
  color: #ffffff;
}

.btn-secondary {
  border: 1px solid var(--card-border);
  background: var(--panel-soft);
  color: var(--text);
}

.btn-secondary:hover {
  border-color: var(--purple-light);
  background: rgba(199, 125, 255, 0.12);
}

.hero-features {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: flex-end;
  justify-self: end;
  width: 100%;
  max-width: 100%;
  gap: 20px;
}

.feature {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 0;
}

.feature + .feature {
  border-left: 1px solid var(--divider-strong);
  padding-left: 20px;
}

.feature-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(199, 125, 255, 0.4);
  color: var(--accent);
}

.feature-icon svg {
  width: 16px;
  height: 16px;
}

.feature-text {
  display: flex;
  flex-direction: column;
}

.feature-text strong {
  font-size: 0.95rem;
}

.feature-text span {
  color: var(--muted);
  font-size: 0.86rem;
}

.product-card,
.review-card,
.cta,
.about {
  background: var(--panel-bg);
  border: 1px solid var(--card-border);
  box-shadow: 0 24px 80px var(--panel-shadow);
  backdrop-filter: blur(18px);
}

.section {
  width: min(1120px, 92%);
  margin: 0 auto;
  padding: 90px 0;
}

.section-heading {
  text-align: center;
  margin-bottom: 42px;
}

.section-heading h2,
.about h2,
.cta h2 {
  font-size: clamp(2rem, 4vw, 3.4rem);
  letter-spacing: -0.025em;
}

.products-grid,
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.product-card,
.review-card {
  border-radius: 8px;
  padding: 20px;
  transition: 0.25s ease;
}

.product-card:hover,
.review-card:hover {
  transform: translateY(-8px);
  border-color: rgba(199, 125, 255, 0.6);
  box-shadow: 0 0 44px rgba(157, 78, 221, 0.28);
}

.product-image {
  height: 250px;
  width: 100%;
  border-radius: 0px;
  margin-bottom: 18px;
  object-fit: cover;
  display: block;
}

.image-one {
  background: radial-gradient(circle, #e0aaff, #7b2cbf 55%, #240046);
}

.image-two {
  background: radial-gradient(circle at top, #ff4ecd, #5a189a 55%, #10002b);
}

.image-three {
  background: radial-gradient(circle at 70% 30%, #ffffff, #c77dff 25%, #3c096c 70%);
}

.product-card h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.product-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 20px;
  gap: 12px;
}

.product-footer span {
  font-weight: 800;
}

.product-footer a {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(199, 125, 255, 0.14);
  border: 1px solid rgba(199, 125, 255, 0.42);
  font-weight: 700;
}

.about {
  width: min(1120px, 92%);
  margin: 40px auto;
  border-radius: 18px;
  padding: 42px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  align-items: center;
}

.review-card {
  padding: 30px;
}

.review-card strong {
  display: block;
  margin-top: 18px;
}

.cta {
  width: min(900px, 92%);
  margin: 80px auto;
  text-align: center;
  border-radius: 10px;
  padding: 56px 24px;
}

.cta p {
  margin: 12px auto 26px;
}

footer {
  text-align: center;
  color: var(--muted);
  padding: 26px;
  border-top: 1px solid var(--divider);
}

.admin-link {
  display: block;
  margin-top: 8px;
  font-size: 0.82rem;
  color: var(--muted);
}

.admin-link:hover {
  color: var(--accent);
}

.product-footer .buy-now-btn {
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(199, 125, 255, 0.14);
  border: 1px solid rgba(199, 125, 255, 0.42);
  font-weight: 700;
  color: var(--text);
  font-family: inherit;
  cursor: pointer;
  font-size: 0.92rem;
}

.product-footer .buy-now-btn:hover {
  border-color: var(--purple-light);
  background: rgba(72, 16, 115, 0.24);
}

/* Product card redesign — scoped overrides so review-card/cta/about keep their original rules */
.products-grid .product-card {
  overflow: hidden;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 340px;
  justify-self: center;
}

.products-grid .product-image {
  width: calc(100% + 40px);
  height: 230px;
  margin: -20px -20px 20px -20px;
  border-radius: 10px 10px 0 0;
  transition: transform 0.4s ease;
}

.products-grid .product-card:hover .product-image {
  transform: scale(1.06);
}

.products-grid .product-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.products-grid .product-card h3 {
  font-size: 1.3rem;
  letter-spacing: -0.01em;
}

.products-grid .product-price {
  flex-shrink: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--accent);
}

.products-grid .product-card p {
  font-size: 0.95rem;
}

.products-grid .product-footer {
  justify-content: center;
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--divider);
}

.products-grid .product-footer .buy-now-btn {
  padding: 10px 20px;
  border: none;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  color: #ffffff;
  background: linear-gradient(135deg, var(--purple), var(--pink));
  box-shadow: 0 8px 20px rgba(157, 78, 221, 0.35);
  transition: 0.25s ease;
}

.products-grid .product-footer .buy-now-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(157, 78, 221, 0.5);
}

/* Product box size on phones — change max-width and image height here.
   Placed after the base .products-grid .product-card rule above so it
   actually wins (same selector specificity — CSS order decides ties). */
@media (max-width: 640px) {
  .products-grid .product-card {
    max-width: 220px;
  }

  .products-grid .product-image {
    height: 140px;
  }
}

/* Contact form */
.contact-form-wrap {
  margin-top: 30px;
  padding-top: 30px;
  border-top: 1px solid var(--divider-strong);
  text-align: left;
}

.contact-form-wrap h3 {
  text-align: center;
  margin-bottom: 18px;
  font-size: 1.2rem;
}

.contact-form {
  max-width: 420px;
  margin: 0 auto;
}

.contact-form label,
#checkoutForm label,
#signupForm label,
#loginForm label {
  display: block;
  font-size: 0.86rem;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 14px;
}

.contact-form input,
.contact-form textarea,
#checkoutForm input,
#checkoutForm textarea,
#signupForm input,
#loginForm input {
  width: 100%;
  margin-top: 6px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--card-border);
  background: var(--panel-soft);
  color: var(--text);
  font-family: inherit;
  font-size: 0.94rem;
}

.contact-form input:focus,
.contact-form textarea:focus,
#checkoutForm input:focus,
#checkoutForm textarea:focus,
#signupForm input:focus,
#loginForm input:focus {
  outline: none;
  border-color: var(--purple-light);
}

.full-width {
  width: 100%;
  cursor: pointer;
  border: none;
  font-family: inherit;
  font-size: 0.96rem;
}

.form-success {
  text-align: center;
  color: var(--accent);
  font-weight: 600;
  margin-top: 14px;
}

.form-success.error {
  color: var(--pink);
}

.modal-switch {
  text-align: center;
  font-size: 0.86rem;
  color: var(--muted);
  margin-top: 18px;
}

.modal-switch button {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: var(--accent);
  font-weight: 700;
  cursor: pointer;
}

/* Modals (checkout) */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(3, 0, 8, 0.72);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}

.modal-overlay.open {
  display: flex;
}

.modal-box {
  width: min(480px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  background: linear-gradient(160deg, #240046, #10002b);
  border: 1px solid var(--card-border);
  border-radius: 26px;
  padding: 32px;
  position: relative;
  --text: #ffffff;
  --muted: #c8b8dd;
  --accent: #c77dff;
  --card-border: rgba(255, 255, 255, 0.14);
  --panel-soft: rgba(255, 255, 255, 0.06);
  --divider: rgba(255, 255, 255, 0.08);
  --divider-strong: rgba(255, 255, 255, 0.12);
}

#reviewsModal .modal-box {
  width: min(560px, 100%);
}

.modal-reviews-grid {
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 22px;
}

.modal-box h3 {
  margin-bottom: 8px;
  font-size: 1.3rem;
}

.modal-sub {
  color: var(--muted);
  font-size: 0.86rem;
  margin-bottom: 18px;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  background: rgba(255, 255, 255, 0.06);
  color: white;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}

.cart-items {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-height: 320px;
  overflow-y: auto;
  margin-bottom: 18px;
}

.cart-empty {
  color: var(--muted);
  text-align: center;
  padding: 20px 0;
}

.cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--divider);
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cart-item-info span {
  color: var(--muted);
  font-size: 0.82rem;
}

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cart-qty-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  background: var(--panel-soft);
  color: var(--text);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
}

.cart-qty-btn:hover {
  border-color: var(--purple-light);
}

.cart-item-remove {
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.cart-item-remove:hover {
  color: var(--pink);
}

.cart-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 800;
  font-size: 1.1rem;
  padding-top: 14px;
  margin-bottom: 18px;
  border-top: 1px solid var(--divider-strong);
}

@media (max-width: 820px) {
  .nav-links.active {
    right: 24px;
  }

  .hero-inner,
  .about {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    padding-top: 42px;
  }

  .hero-content,
  .hero-features {
    grid-column: 1;
  }

  .hero-features {
    justify-self: stretch;
    justify-content: flex-start;
    max-width: 100%;
    margin-top: 12px;
  }

  .products-grid,
  .reviews-grid {
    grid-template-columns: 1fr;
  }
}
