* {
  font-family: "Onest", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
}
html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    background: linear-gradient(to bottom, #000000, #001a33);
    color: #fff;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  }

  .header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #000000;
    padding: 12px 24px;
    color: white;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }
  #headerUserName { cursor: pointer; }
  
  .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.25rem;
    font-weight: 600;
    color: #ffffff;
  }
  
  .logo img {
    height: 40px;
    width: auto;
    border-radius: 6px;
  }
  
  .header-icons {
    display: flex;
    gap: 16px;
    font-size: 1.2rem;
  }
  
  .header-icons span {
    cursor: pointer;
    transition: transform 0.2s, color 0.3s;
  }
  
  .header-icons span:hover {
    color: #ff4081;
    transform: scale(1.2);
  }  

  .search-bar {
    margin: 20px;
    background-color: #1a1a1a;
    padding: 10px 15px;
    border-radius: 12px;
    display: flex;
    align-items: center;
  }

  .search-bar input {
    width: 100%;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 14px;
    outline: none;
  }

  .section-title {
    padding: 0 20px;
  }

  .section-title h2 {
    font-size: 22px;
    margin-bottom: 0;
  }

  .section-title small {
    color: #aaa;
  }

  .product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); /* Was 160px */
    gap: 20px; /* Give it a bit more breathing space */
    padding: 20px;
  }

  .product-card {
    border-radius: 14px;
    overflow: hidden;
    background-color: #111;
    font-family: 'Roboto', sans-serif;
    transition: transform 0.2s ease;
    position: relative;
  }
  
  .product-card:hover {
    transform: translateY(-4px);
  }
  

  .product-image {
    position: relative;
    width: 100%;
    height: 200; /* Slightly taller */
    overflow: hidden;
  }
  
  .product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  

  .tag {
    position: absolute;
    top: 8px;
    left: 8px;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
  }

  .product-info {
    padding: 10px 8px;
  }

  .title {
    color: white;
    font-size: 15px; /* Was 13px */
    font-weight: 600;
    margin-bottom: 6px;
  }
  
  .price {
    font-size: 14px; /* Was 13px */
    display: flex;
    align-items: center;
    flex-wrap: wrap;
  }
  

  .price .new {
    color: #5f9aff;
    font-weight: bold;
  }

  .price .old {
    color: #888;
    text-decoration: line-through;
    margin-left: 6px;
  }

  .old {
    text-decoration: line-through;
    color: #888;
    font-size: 0.9em;
    margin-left: 5px;
  }
  .discount-badge {
    background-color: #ff3e3e;
    color: white;
    font-size: 13px;
    padding: 3px 7px;
    border-radius: 4px;
    margin-left: 8px;
    font-weight: bold;
  }
  
  .product-image img {
  transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.05);
}
.profile-icon {
  background-color: #000000;
}

.profile-icon:hover {
  transform: scale(1.05);
}
.account-popup {
  position: fixed;
  top: 0;
  right: 0;
  background: #0c0c0c;
  width: 100%;
  max-width: 420px;
  height: 100vh;
  overflow-y: auto;
  box-shadow: -4px 0 20px rgba(0,0,0,0.4);
  padding: 20px;
  z-index: 9999;
  display: none;
  animation: slideIn .3s ease;
}

@keyframes slideIn {
  from { right: -100%; opacity: 0; }
  to { right: 0; opacity: 1; }
}

.account-popup-header {
  display: flex;
  align-items: center;
  gap: 20px;
}

.account-popup-header h2 {
  color: white;
  font-size: 20px;
}
.link-row{
  cursor: pointer;
}

.close-btn {
  background: transparent;
  border: 1px solid #888;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  color: white;
  font-size: 18px;
  cursor: pointer;
  padding-left: 4px;
  transition: background 0.3s ease;
}

.user-info {
  text-align: center;
  margin-top: 20px;
}

.user-info .user-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #222;
  object-fit: cover;
  margin-bottom: 10px;
}

#username {
  color: white;
  font-size: 18px;
  margin: 0;
}

#userTag {
  color: #aaa;
  margin: 0;
  font-size: 14px;
}

.account-alert-box {
  background: #161616;
  border-radius: 12px;
  padding: 14px 16px;
  color: white;
  margin: 20px 0;
  font-size: 14px;
}

.alert-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  color: #aaa;
  font-size: 13px;
}

.alert-icon {
  font-size: 16px;
}

.alert-title {
  margin: 0;
  font-size: 15px;
  color: #ffffff;
}

.alert-subtext {
  font-size: 13px;
  color: #bbb;
}

.account-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.action-card {
  flex: 1;
  background: #1b1b1b;
  border-radius: 14px;
  padding: 12px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.action-card:hover {
  background: #494949;
}

.action-card img {
  width: 30px;
  margin-bottom: 4px;
}

.action-card p {
  margin: 0;
  color: white;
  font-weight: 600;
}

.action-card small {
  color: #aaa;
}

.account-links {
  background: #161616;
  border-radius: 12px;
  padding: 15px;
}

.link-row {
  display: flex;
  align-items: center;
  padding: 10px 0;
  color: white;
  justify-content: space-between;
  border-bottom: 1px solid #222;
}

.link-row img {
  width: 20px;
  margin-right: 12px;
}

.link-row span {
  flex: 1;
  font-size: 15px;
}

.link-row em {
  font-size: 12px;
  color: #ccc;
  font-style: italic;
}

.logout-btn {
  width: 100%;
  background: rgba(255, 0, 0, 0.08);
  color: red;
  border: 1px solid rgba(255, 0, 0, 0.3);
  margin-top: 30px;
  padding: 12px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
}
/* Glassy + gradient effect for account popup */
.account-popup {
  background: rgba(20, 20, 28, 0.75); /* translucent base */
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);

  /* subtle gradient overlay */
  background-image: linear-gradient(
    to bottom right,
    rgba(40, 40, 55, 0.5),
    rgba(15, 15, 25, 0.85)
  );

  border-left: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: -6px 0 24px rgba(0, 0, 0, 0.55);
}

/* Add this to your main CSS file */

/* This is needed for the overlay to position correctly */
.account-popup {
  display: none;
}
.account-popup.show {
  display: block; /* This class will show it */
}

/* This is the new overlay */
.account-login-overlay {
  position: absolute;
  top: 50px; /* Adjust this to sit below your header */
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  display: none; 
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 20px;
}

/* Style for the button on the overlay */
.signin-overlay-btn {
  background-color: #4675bd; /* Your brand color */
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 8px;
  cursor: pointer;
  margin-top: 15px;
}
.account-login-overlay h3 {
  color: #FFFFFF;
  margin: 0;
}
.account-login-overlay p {
  color: #FFFFFF;
  margin-top: 8px;
}

.signin-popup-content {
  padding: 30px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: #fff; /* Assumes dark theme */
}

.signin-popup-content .fa-comments {
  font-size: 48px;
  color: #4675bd; /* Your brand color */
  margin-bottom: 20px;
}

.signin-popup-content h3 {
  margin: 0;
  font-size: 1.3rem;
}

.signin-popup-content p {
  color: #ddd; /* Light text for dark theme */
  font-size: 0.95rem;
  margin-top: 10px;
  margin-bottom: 24px;
  max-width: 300px;
}

/* mobile optimization – disable heavy blur on small screens */
@media (max-width: 768px) {
  .account-popup {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(18, 18, 25, 0.95); /* solid fallback */
  }
}

.slider {
  position: relative;
  width: 100%;
  max-width: 1200px;        /* Desktop size limit */
  margin: 0 auto;           /* Centered on page */
  aspect-ratio: 1920 / 672; /* Maintain correct banner ratio */
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.slides {
  display: flex;
  transition: transform 0.5s ease-in-out;
  height: 100%;
}

.slide {
  min-width: 100%;
  height: 100%;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Navigation dots */
.dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #ccc;
  transition: background-color 0.3s;
  cursor: pointer;
}

.dot.active {
  background-color: #fff;
}

/* ✅ Mobile & small screen optimization */
@media (max-width: 768px) {
  .slider {
    max-width: 100%;
    height: auto;
    aspect-ratio: auto;
  }

  .slide img {
    width: 100%;
    height: auto;
    object-fit: fill;
  }
  .slider, .slide {
  width: 100%;
  height: auto;
}

}


@media (max-width: 480px) {
  .slider {
    aspect-ratio: 16 / 9;     /* Typical widescreen feel on phones */
    border-radius: 0;
  }
}
.search-container {
  position: relative;
  margin: 20px;
}

.search-bar input {
  width: 100%;
  padding: 10px 16px;
  background: #121212;
  border: 1px solid #333;
  border-radius: 10px;
  font-size: 14px;
  color: white;
}

.search-results, .recent-searches {
  position: absolute;
  top: 100%;
  width: 100%;
  background: #1b1b1b;
  z-index: 100;
  border: 1px solid #333;
  border-top: none;
  border-radius: 0 0 10px 10px;
  max-height: 350px;
  overflow-y: auto;
}

.search-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-bottom: 1px solid #2a2a2a;
  cursor: pointer;
}

.search-item img {
  height: 50px;
  border-radius: 6px;
}

.search-info {
  display: flex;
  flex-direction: column;
  color: white;
}

.search-info .title {
  font-size: 15px;
  font-weight: bold;
}

.search-info .edition {
  font-size: 12px;
  color: #aaa;
}
.search-bar-popup {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

.search-bar {
  flex-grow: 1;
  position: relative;
}

.search-popup-corner {
  width: 40px;
  height: 40px;
  background: #1e1e1e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 4px rgba(255, 255, 255, 0.1);
}

.search-popup-corner img {
  width: 24px;
  height: 24px;
}

.category-explore {
  padding: 10px;
  background: #101010;
  color: #ccc;
  font-size: 15px;
  cursor: pointer;
  border-top: 1px solid #222;
  border-bottom: 1px solid #222;
}

.category-explore:hover {
  background: #1a1a1a;
}

.category-products {
  margin-top: 10px;
  padding: 10px;
}

.category-filter-tag {
  background: #333;
  color: white;
  display: inline-block;
  padding: 5px 10px;
  margin-bottom: 10px;
  border-radius: 12px;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.category-filter-tag .clear {
  background: #ff4444;
  color: white;
  padding: 0 6px;
  border-radius: 50%;
  cursor: pointer;
}
.search-container {
  position: relative;
}

.search-results {
  position: absolute;
  top: 105%;
  left: 0;
  width: 100%;
  background: #101010;
  border-radius: 12px;
  max-height: 70vh;
  overflow-y: auto;
  z-index: 1000;
  box-shadow: 0 0 10px #000;
}

.search-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-bottom: 1px solid #222;
  cursor: pointer;
  transition: background 0.2s ease;
}

.search-item:hover {
  background: #1a1a1a;
}

.search-item img {
  width: auto;
  height: 40px;
  object-fit: contain;
  border-radius: 4px;
}

.search-info {
  display: flex;
  flex-direction: column;
}

.result-group {
  padding: 12px;
  color: #aaa;
  font-size: 14px;
}
.auth-container {
  max-width: 360px;
  margin: 80px auto;
  background: #1a1a1a;
  padding: 24px;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
  text-align: center;
}

.auth-container input {
  width: 100%;
  padding: 10px 14px;
  margin-bottom: 12px;
  font-size: 15px;
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  color: #fff;
}

.auth-container button {
  width: 100%;
  padding: 12px;
  background: #4675bd;
  border: none;
  border-radius: 8px;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.auth-container h2 {
  color: white;
  margin-bottom: 20px;
}

.site-header {
  background: #1f1f1f;
  border-bottom: 1px solid #333;
  padding: 0 20px;
}
.site-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  height: 60px;
}
.site-header__logo img {
  height: 32px;
}
.site-header__nav {
  flex: 1;
  display: flex;
  gap: 24px;
  justify-content: center;
}
.site-header__nav a {
  color: #eaeaea;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: .5px;
}
.site-header__actions {
  display: flex;
  gap: 12px;
  align-items: center;
}
.icon-btn {
  background: transparent;
  border: none;
  font-size: 18px;
  color: #eaeaea;
  cursor: pointer;
}
.icon-btn:hover {
  color: #fff;
}
.site-header__user {
  display: flex;
  gap: 8px;
  align-items: center;
}
.user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}
.btn {
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
}
.btn--outline {
  background: transparent;
  border: 1px solid #4574ba;
  color: #b4c4e5;
}
.btn--outline:hover {
  background:linear-gradient(135deg, #4574ba, #b4c4e5);
  color: #fff;
}

/* MOBILE: logo+user on row-1, nav on row-2 */
@media (max-width: 600px) {
  .site-header__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 4px 8px;
    height: auto;
  }

  /* Row 1: logo (left) & actions (right) */
  .site-header__logo {
    order: 1;
    flex: 1 1 auto;
  }
  .site-header__actions {
    order: 1;
    flex: 0 1 auto;
    justify-content: flex-end;
    gap: 6px;
  }

  /* Row 2: nav full width, centered */
  .site-header__nav {
    order: 2;
    flex: 1 1 100%;
    justify-content: center;
    gap: 12px;
    margin-top: 4px;
    border-top: 1px solid #333;
    padding-top: 4px;
  }

  /* shrink logo */
  .site-header__logo img {
    height: 24px;
  }

  /* shrink nav text */
  .site-header__nav a {
    font-size: 12px;
    padding: 0 6px;
  }

  /* shrink icons & avatar */
  .icon-btn {
    font-size: 16px;
  }
  .user-avatar {
    width: 20px;
    height: 20px;
  }

  /* shrink buttons */
  .btn, .btn--outline, .btn--ghost {
    font-size: 11px;
    padding: 4px 8px;
  }
}
/* Chat Popup — Desktop */
.chat-popup {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 500px;
  height: 580px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.5);
  z-index: 1001;
  opacity: 0;
  transform: scale(0.95);
  pointer-events: none;
  transition: all 0.3s ease;
}
.chat-popup.open {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

/* Chat Iframe */
.chat-popup iframe {
  width: 100%;
  height: 100%;
  border: none;
}
.android-button:active,
.chat-button:active {
  transform: scale(0.95);
  transition: transform 0.1s ease;
}


/* Chat Button (unchanged, maybe slightly refined) */
.android-button {
  position: fixed;
  bottom: 20px;
  right: auto;
  background: #4675bd;
  color: white;
  padding: 10px 16px;
  border-radius: 20px;
  font-weight: bold;
  cursor: pointer;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}
.chat-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #4675bd;
  color: white;
  padding: 10px 16px;
  border-radius: 20px;
  font-weight: bold;
  cursor: pointer;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
  .chat-popup {
    bottom: 0;
    right: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    border-radius: 0;
  }

  .chat-button {
    bottom: 16px;
    right: 16px;
    font-size: 14px;
    padding: 8px 12px;
  }
}
  .announcement-banner {
    background: #222;
    color: #f1f1f1;
    padding: 12px 20px;
    text-align: center;
    font-size: 12px;
    border-bottom: 1px solid #444;
    display: flex;
    justify-content: left;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
  }

  .announcement-banner .material-icons {
    font-size: 20px;
    color: #ffa726;
    vertical-align: middle;
  }

  .announcement-banner i {
    color: #ffa726;
    margin-right: 4px;
  }

  .announcement-banner a {
    margin-left: 6px;
    color: #6fa9ff;
    text-decoration: underline;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
  }

  .announcement-banner a:hover {
    color: #a6c8ff;
  }
  .product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  padding: 20px;
}
@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 480px) {
  body {
    font-size: 14px;
  }

  .title {
    font-size: 13px;
  }

  .price {
    font-size: 13px;
  }

  .section-title h2 {
    font-size: 18px;
  }
}
@media (max-width: 480px) {
  .product-grid {
    gap: 12px;
    padding: 10px;
  }

  .product-info {
    padding: 8px 6px;
  }

  .section-title {
    padding: 0 12px;
  }

  .search-bar {
    margin: 10px;
    padding: 8px 10px;
  }
}
@media (max-width: 480px) {
  .product-image {
    height: auto;
  }
}
@media (max-width: 480px) {
  .announcement-banner {
    font-size: 11px;
    padding: 8px 12px;
    gap: 6px;
    flex-wrap: nowrap;
    overflow-x: auto; /* Allow scroll if content overflows */
    white-space: nowrap;
  }

  .announcement-banner i,
  .announcement-banner .material-icons {
    font-size: 16px;
  }

  .announcement-banner a {
    font-size: 11px;
    gap: 4px;
    flex-shrink: 0;
  }
}
@media (max-width: 480px) {
  .account-popup {
    width: 100vw;
    height: 100vh;
    max-width: 100%;
    padding: 16px;
    border-radius: 0;
    box-sizing: border-box;
  }

  .account-popup-header h2 {
    font-size: 18px;
  }

  .close-btn {
    width: 28px;
    height: 28px;
    font-size: 16px;
  }

  .user-info .user-avatar {
    width: 60px;
    height: 60px;
  }

  #username {
    font-size: 16px;
  }

  #userTag {
    font-size: 12px;
  }

  .account-alert-box {
    font-size: 13px;
    padding: 12px;
  }

  .account-actions {
    margin-top: 10px;
    gap: 10px;
  }

  .action-card {
    padding: 10px;
  }

  .logout-btn {
    font-size: 14px;
    padding: 10px;
  }
}
@media (max-width: 480px) {
  .chat-popup {
    width: 100vw;
    height: 100vh;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 0;
    padding: 0;
  }

  .chat-button {
    bottom: 12px;
    right: 12px;
    font-size: 13px;
    padding: 6px 10px;
    border-radius: 16px;
  }

  .chat-popup iframe {
    height: 100%;
    width: 100%;
  }

  /* Optional: smaller close button if you use one */
  .chat-popup .close-btn {
    top: 10px;
    right: 10px;
    font-size: 18px;
  }
}

/* --- Google Fonts for Flash Sale --- */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@500;700;900&family=Rajdhani:wght@500;600;700&display=swap');

/* --- Flash Sale Container & Wrapper (Scroll Fixes) --- */
.flash-sale-wrapper {
  background: radial-gradient(circle at 50% 50%, #1a2236 0%, #000000 100%);
  padding: 30px 0px; /* Reduced vertical padding */
  overflow: hidden; /* Hide main scroll, handle inner */
}

#flash-sale-container {
  display: flex;
  gap: 20px; /* Reduced gap */
  padding: 10px 20px; /* Side padding for scroll ease */
  overflow-x: auto;
  scroll-snap-type: x mandatory; /* Snapping effect */
  scroll-behavior: smooth;
  
  /* Custom Scrollbar Styling */
  scrollbar-width: thin;
  scrollbar-color: #4675bd #111;
}

/* Webkit Scrollbar (Chrome/Safari/Edge) */
#flash-sale-container::-webkit-scrollbar {
  height: 6px; /* Thinner scrollbar */
}

#flash-sale-container::-webkit-scrollbar-track {
  background: #111;
  border-radius: 10px;
  margin: 0 20px; /* Indent scrollbar track */
}

#flash-sale-container::-webkit-scrollbar-thumb {
  background: #4675bd; /* Your brand color */
  border-radius: 10px;
}

#flash-sale-container::-webkit-scrollbar-thumb:hover {
  background: #5f9aff;
}

/* --- Card Structure (Compact UI) --- */
.flash-card-wrapper {
  flex: 0 0 auto;
  position: relative;
  width: 280px; /* REDUCED from 380px */
  border-radius: 20px;
  padding: 1px; /* Thinner gradient border */
  background: linear-gradient(135deg, #0066ff 0%, #ff6b00 50%, #00ccff 100%);
  box-shadow: 0 0 15px rgba(0, 102, 255, 0.2);
  font-family: 'Inter', sans-serif;
  scroll-snap-align: center; /* Centers card on stop */
}

.flash-card-content {
  background: linear-gradient(to bottom, #0f1623 0%, #080a0f 100%);
  border-radius: 19px;
  padding: 16px; /* Reduced padding */
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Circuit Background Overlay */
.circuit-bg {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 100px; /* Smaller bg height */
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 10 L30 10 L30 30' stroke='%232a3b55' stroke-width='1' fill='none'/%3E%3Cpath d='M70 10 L90 10 L90 30' stroke='%232a3b55' stroke-width='1' fill='none'/%3E%3Ccircle cx='30' cy='30' r='2' fill='%232a3b55'/%3E%3Ccircle cx='90' cy='30' r='2' fill='%232a3b55'/%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
  z-index: 0;
}

/* --- Header Section --- */
.fs-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px; /* Reduced margin */
  position: relative;
  z-index: 10;
}

.fs-logo {
  display: flex;
  align-items: center;
}

.lightning-icon {
  width: 24px; /* Smaller icon */
  height: 24px;
  filter: drop-shadow(0 0 6px #ff4d00);
  margin-right: 6px;
}

.fs-title span {
  font-family: 'Orbitron', sans-serif;
  font-style: italic;
  font-weight: 900;
  color: white;
  font-size: 1rem; /* Smaller text */
  letter-spacing: -0.5px;
  text-transform: uppercase;
  transform: skewX(-5deg);
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
  line-height: 1;
}

.status-badge {
  padding: 3px 10px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  font-weight: bold;
  font-size: 0.75rem; /* Smaller text */
  letter-spacing: 0.05em;
  color: white;
}

.status-badge.live { background: linear-gradient(90deg, #ff8800 0%, #ff2200 100%); box-shadow: 0 0 10px rgba(255, 60, 0, 0.5); }
.status-badge.upcoming { background: linear-gradient(90deg, #ffd24d 0%, #d6a10b 100%); }
.status-badge.ended { background: linear-gradient(90deg, #ff5a7d 0%, #cc0033 100%); }

.blink-dot {
  width: 6px; height: 6px; /* Smaller dot */
  background-color: white;
  border-radius: 50%;
  margin-right: 6px;
  animation: blink 1.5s infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* --- Timer Section (Compact) --- */
.timer-container {
  background: rgba(15, 23, 42, 0.6); 
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 8px 12px; /* Tighter padding */
  margin-bottom: 14px;
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.timer-label {
  color: #94a3b8;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 8px;
}

.timer-values {
  display: flex;
  align-items: center;
  gap: 8px;
}

.time-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
  min-width: 24px;
}

.time-num {
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem; /* Smaller numbers */
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.text-white { color: #ffffff; }
.text-orange { color: #ff9100; }

.time-unit {
  font-size: 0.55rem;
  color: #64748b;
  font-weight: 600;
  margin-top: 2px;
  text-transform: uppercase;
}

.v-line {
  width: 1px;
  height: 20px;
  background-color: #334155;
  opacity: 0.5;
}

/* --- Product Image (3D) --- */
.banner {
  width: 100%;
  height: 140px; /* REDUCED height from 200px */
  border-radius: 12px;
  margin-bottom: 12px;
  perspective: 1000px; 
  position: relative;
  z-index: 5;
}

.banner-inner {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
  will-change: transform;
  border-radius: 12px;
  overflow: hidden; 
}

.banner img {
  width: 100%; height: 100%;  display: block;
}

.img-gradient {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
  pointer-events: none;
}

.save-badge {
  position: absolute;
  bottom: 10px; left: 0;
  background: linear-gradient(90deg, #ff2200 0%, #ff8800 100%);
  clip-path: polygon(0 0, 100% 0, 85% 100%, 0% 100%);
  padding: 4px 24px 4px 10px; /* Smaller padding */
  color: white;
  font-weight: bold;
  font-size: 0.7rem; /* Smaller text */
  box-shadow: 3px 3px 10px rgba(0,0,0,0.5);
  z-index: 2;
}

.shine-layer {
  position: absolute;
  top: 0; left: -100%;
  width: 200%; height: 100%;
  background: linear-gradient(120deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 3;
}

/* --- Info Section --- */
.fs-info {
  margin-bottom: 12px;
}

.fs-prod-title {
  color: white;
  font-weight: 600;
  font-size: 0.85rem; /* Smaller title */
  line-height: 1.3;
  margin: 0 0 8px 0;
  height: 36px; /* Fixed height for 2 lines */
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.fs-stats {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: #9ca3af;
  font-weight: 500;
  margin-bottom: 5px;
}
.fs-stats span strong { color: white; }

/* Progress Bar */
.fs-progress-bg {
  background: #1e293b;
  width: 100%; height: 4px; /* Thinner bar */
  border-radius: 999px;
  position: relative;
}

.fs-progress-fill {
  background: linear-gradient(90deg, #0066ff 0%, #a3bdff 100%);
  height: 100%;
  border-radius: 999px;
  box-shadow: 0 0 6px #0066ff;
  position: relative;
  transition: width 0.5s ease;
}

.fs-progress-thumb {
  position: absolute; right: -3px; top: 50%; transform: translateY(-50%);
  width: 8px; height: 8px;
  background: white; border-radius: 50%;
  box-shadow: 0 0 6px white, 0 0 12px #0066ff;
}

/* --- Footer (Price & Button) --- */
.fs-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-top: auto;
}

.price-group { display: flex; flex-direction: column; }

.price-curr {
  font-weight: bold;
  font-size: 1.2rem; /* Smaller price */
  color: white;
  line-height: 1;
}

.price-old-wrap {
  display: flex; align-items: center; gap: 6px; margin-top: 2px;
}

.price-old {
  color: #6b7280; font-size: 0.7rem; text-decoration: line-through;
}

.discount-badge-sm {
  background: linear-gradient(135deg, #ff4d00 0%, #ff2200 100%);
  color: white; font-size: 0.6rem; font-weight: bold;
  padding: 1px 5px; border-radius: 3px;
}

.buy-btn-neon {
  background: linear-gradient(180deg, #00aeff 0%, #0066ff 100%);
  box-shadow: 0 4px 10px rgba(0, 102, 255, 0.3), inset 0 1px 0 rgba(255,255,255,0.3);
  color: white; font-weight: bold;
  padding: 8px 16px; /* Smaller button */
  border-radius: 6px; border: none;
  font-size: 0.75rem; letter-spacing: 0.025em;
  cursor: pointer; transition: all 0.2s;
}

.buy-btn-neon:hover { filter: brightness(1.1); transform: translateY(-1px); }
.buy-btn-neon:active { transform: scale(0.98); box-shadow: 0 2px 6px rgba(0, 102, 255, 0.4); }
.buy-btn-neon.disabled { background: #334155; box-shadow: none; color: #94a3b8; cursor: not-allowed; }

/* Mobile Adjustments */
@media (max-width: 600px) {
  .flash-card-wrapper { width: 240px; } /* Even smaller on mobile */
  .banner { height: 120px; }
  .time-num { font-size: 1rem; }
}

.site-header__inner {
  display: flex;
  align-items: center;
  height: 60px;
  padding: 0 15px;
}

/* Fixed sticky header state */
.site-header__wrapper.fixed {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  margin: 0 auto;
  max-width: 100%;

  /* darker glass when fixed */
  background: rgba(20, 20, 28, 0.8);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);

  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.6);
  z-index: 9999;
}
/* --- HEADER WRAPPER (Always Fixed) --- */
.site-header__wrapper {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 9999;
  
  /* Initial State (At the top of the page) */
  border-bottom: 1px solid #333;
  transition: all 0.3s ease-in-out; /* Smooth transition for background/height */
}

/* --- SCROLLED STATE (Glassy Effect) --- */
/* This class is added by JS when you scroll down */
/* --- SCROLLED STATE (Heavy Liquid Glass) --- */
.site-header__wrapper.scrolled {
  /* 1. Dark Glass Background */
  background-color: color-mix(in srgb, #000 60%, transparent);

  /* 2. Heavy Liquid Filter */
  backdrop-filter: blur(6px) url(#heavy-liquid) saturate(160%);
  -webkit-backdrop-filter: blur(6px) url(#heavy-liquid) saturate(160%);

  /* 3. Your Premium Shadows */
  box-shadow: 
    inset 0 1px 0 0 rgba(255, 255, 255, 0.35),   /* Top Highlight */
    inset 0 -1px 0 0 rgba(0, 0, 0, 0.3),         /* Bottom Bevel */
    inset 0 0 20px rgba(0, 102, 255, 0.15),      /* Blue Glow */
    0 4px 20px rgba(0, 0, 0, 0.6);               /* Drop Shadow */

  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* --- APPLE FIX (iOS/Safari) --- */
@supports (-webkit-touch-callout: none) {
  .site-header__wrapper.scrolled {
    background: rgba(15, 22, 35, 0.4);
    /* Remove SVG filter to prevent invisible glitch */
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    backdrop-filter: blur(20px) saturate(160%);
  }
}

/* --- INNER LAYOUT --- */
.site-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  height: 70px; /* Default height */
  padding: 0 20px;
  transition: height 0.3s ease;
}

/* Reduce height slightly when scrolled for a sleeker look */
.site-header__wrapper.scrolled .site-header__inner {
  height: 60px; 
}

.mobile-toggle {
  display: none; /* Hidden on desktop */
}

/* --- MOBILE OPTIMIZATION (Updated) --- */
/* --- MOBILE MENU STYLES (Keep this OUTSIDE the media query) --- */
/* This ensures the menu is hidden on Desktop too */
.mobile-menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 10000;
  
  /* Hidden by default */
  visibility: hidden;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
}

/* When active (clicked), show it */
.mobile-menu-overlay.active {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.mobile-menu-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 250px;
  height: 100%;
  background: #0f0f13;
  box-shadow: 2px 0 10px rgba(0,0,0,0.5);
  transform: translateX(-100%);
  transition: transform 0.3s ease;
  padding: 20px;
  display: flex;
  flex-direction: column;
  z-index: 10002;
}

.mobile-menu-overlay.active .mobile-menu-content {
  transform: translateX(0);
}

.mobile-menu-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.7);
  z-index: 10001;
}

.mobile-close {
  background: none;
  border: none;
  color: white;
  font-size: 30px;
  align-self: flex-end;
  cursor: pointer;
  margin-bottom: 20px;
}

.mobile-nav-links a {
  display: block;
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  padding: 15px 0;
  border-bottom: 1px solid #333;
  text-decoration: none;
  text-transform: uppercase;
}

.mobile-nav-links a:hover {
  color: #4675bd;
}

/* --- MOBILE OPTIMIZATION (Media Query) --- */
@media (max-width: 600px) {
  
  /* Reset height for spacer */
  .header-spacer { height: 60px !important; }

  /* 1. Layout: Hamburger - Logo - Actions */
  .site-header__inner {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    padding: 0 15px;
    height: 60px !important;
    gap: 10px;
  }

  /* 2. Hide Desktop Nav */
  .site-header__nav {
    display: none !important;
  }

  /* 3. Hamburger Icon Styling */
  .mobile-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 100;
  }

  .mobile-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #ffffff;
    border-radius: 2px;
  }

  /* 4. Logo Positioning */
  .site-header__logo {
    margin-right: auto;
    margin-left: 10px;
  }
  
  .site-header__logo img {
    height: 22px;
    width: auto;
  }

  /* 5. User Actions */
  #headerUserName { display: none !important; }
  
  .site-header__actions {
    display: flex;
    gap: 10px;
  }
}
.header-spacer {
  height: 70px;
}