* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary-color: #A599B5;
  --light-color: #acbdba;
  --dark-color: #2E2F2F;
}

body {
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  line-height: 1.5;
  background: #CDDDDD;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: #e7ebff;
  font-weight: bold;
}

ul {
  list-style: none;
}

img {
  max-width: 100px;
}

/* Navbar */
.navbar {
  background: #ACBDBA;
  padding: 20px;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar .main-menu ul {
  display: flex;
}

.navbar ul li a {
  padding: 10px 20px;
  display: block;
  font-weight: 600;
  transition: 0.5s;
}

.navbar ul li a:hover {
  color: var(--primary-color);
}

.navbar ul li a i {
  margin-right: 10px;
}

.navbar ul li:last-child a {
  margin-left: 10px;
}

/* Hero */
.hero {
  margin-bottom: -350px;
}

.hero .container {
  background-size: contain;
  background-position: center bottom;
  height: 550px;
}

.hero .hero-content {
  width: 70%;
}

.hero .hero-text {
  width: 70%;
  margin-bottom: 20px;
}

/* Video */
.video {
  padding: 10px 0 40px;
}

.video .video-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.video .video-preview {
  margin-bottom: 20px;
}

/* Testimonials */
.testimonials {
  padding: 40px 0;
}

.testimonials .testimonials-heading {
  width: 700px;
  margin-bottom: 40px;
}

.testimonials .testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.testimonials .card p:nth-child(2) {
  margin-top: 30px;
  font-weight: bold;
}

/* Pricing */
.pricing .pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  margin-top: 50px;
}

.pricing .pricing-card-subheading {
  margin-bottom: 30px;
}

.pricing .pricing-card-price {
  margin-bottom: 30px;
  padding: 20px 0;
  border-bottom: 1px solid #ccc;
}

.pricing ul {
  margin: 30px 0;
}

.pricing ul li {
  margin-bottom: 20px;
}

.pricing ul li i {
  margin-right: 10px;
}

.pricing .pricing-footer {
  margin: 30px 0;
}

/* FAQ */
.faq {
  padding: 40px 0;
}

.faq .faq-group {
  border-bottom: 1px solid #ccc;
  padding-bottom: 20px;
}

.faq .faq-group .faq-group-header {
  padding: 20px 0;
  margin-bottom: 15px;
  position: relative;
}

.faq .faq-group .faq-group-header h4 {
  font-weight: 600;
  width: 95%;
}

.faq .faq-group .faq-group-header i {
  position: absolute;
  right: 0;
  top: 35px;
  font-size: 1.3rem;
  cursor: pointer;
}

.faq .faq-group .faq-group-body {
  display: none;
}

.faq .faq-group .faq-group-body.open {
  display: block;
}

.faq ul.faq-menu {
  max-width: 400px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ddd;
  padding: 10px 20px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
}

.faq ul.faq-menu li {
  padding: 10px 20px;
  border-radius: 5px;
  text-align: center;
}

.faq ul.faq-menu li.active {
  background: var(--primary-color);
  color: #fff;
}

/* Footer */
.footer {
  padding: 40px 0;
}

.footer h4 {
  margin-bottom: 10px;
}

.footer ul li {
  line-height: 2.5;
}

.footer a {
  color: #ccc;
}

.footer i {
  font-size: 1.5rem;
  margin-right: 10px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 30px;
  justify-content: center;
  align-items: center;
}

.footer .card {
  margin: 20px 30px 30px 0;
}

.footer input[type='email'] {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  margin: 20px 0;
}

/* Utility Classes */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 15px;
}

.container-sm {
  max-width: 98vw;
  margin: 0 auto;
  padding: 0 15px;
}

/* Card */
.card {
  background: #fff;
  color: #2E2F2F;
  border-radius: 10px;
  padding: 20px;
}

/* Buttons */
.btn {
  margin: 10px;
  display: inline-block;
  padding: 10px 20px;
  background: var(--light-color);
  color: #333;
  font-weight: 600;
  text-decoration: none;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  text-align: center;
  transition: 0.5s;
}

.btn:hover {
  opacity: 0.8;
}

.btn-primary {
  background: var(--primary-color);
  color: #fff;
}

.btn-dark {
  background: var(--dark-color);
  color: #fff;
}

.btn-block {
  display: block;
  width: 100%;
}

/* Text Classes */
.text-xxl {
  font-size: 3rem;
  line-height: 1.2;
  font-weight: 600;
  margin: 40px 0 20px;
}

.text-xl {
  font-size: 2.2rem;
  line-height: 1.4;
  font-weight: normal;
  margin: 40px 0 20px;
}

.text-lg {
  font-size: 1.8rem;
  line-height: 1.4;
  font-weight: normal;
  margin: 30px 0 20px;
}

.text-md {
  font-size: 1.2rem;
  line-height: 1.4;
  font-weight: normal;
  margin: 20px 0 10px;
}

.text-sm {
  font-size: 0.9rem;
  line-height: 1.4;
  font-weight: normal;
  margin: 10px 0 5px;
}

.text-center {
  text-align: center;
}

/* Background */
.bg-primary {
  background: var(--primary-color);
  color: #fff;
}

.bg-light {
  background: var(--light-color);
  color: #333;
}

.bg-dark {
  background: var(--dark-color);
  color: #fff;
}

.bg-black {
  background: #2E2F2F;
  color: #fff;
}

/* Hamburger Button */
.hamburger-button {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1000;
}

.hamburger-button .hamburger-line {
  width: 30px;
  height: 3px;
  background: #333;
  margin: 6px 0;
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  right: -300px;
  width: 250px;
  height: 100%;
  z-index: 100;
  background: #fff;
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.2);
  transition: right 0.3s ease-in-out;
}

.mobile-menu.active {
  right: 0;
}

.mobile-menu ul {
  margin-top: 100px;
  padding-right: 10px;
}

.mobile-menu ul li {
  margin: 10px 0;
}

.mobile-menu ul li a {
  font-size: 20px;
  transition: 0.3s;
}

/* Media Queries */
@media (max-width: 960px) {
  .text-xxl {
    font-size: 2.5rem;
  }
}

@media (max-width: 670px) {
  .navbar .main-menu {
    display: none;
  }

  .navbar .hamburger-button {
    display: block;
  }

  .hero .container {
    background-size: 350px 400px;
    background-position: bottom;
    height: 770px;
  }

  .hero .hero-content,
  .hero .hero-text {
    width: 100%;
    text-align: center;
  }

  .hero .hero-buttons .btn {
    margin-bottom: 10px;
    display: block;
    width: 100%;
  }

  .testimonials .testimonials-heading {
    max-width: 100%;
    text-align: center;
  }

  .testimonials .testimonials-grid,
  .pricing .pricing-grid,
  .footer .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer .card {
    margin-right: 0;
  }

  .footer .footer-grid > div {
    text-align: center;
  }

  /* Text */
  .text-xl {
    font-size: 1.9rem;
  }

  .text-lg {
    font-size: 1.5rem;
  }

  .text-md {
    font-size: 1.1rem;
  }
}

@media (max-width: 500px) {
  .text-xxl {
    font-size: 2rem;
  }
}

table {
  display: inline-table; /* Important: allows centering inline */
  border-collapse: collapse;
  min-width: 800px; /* Or however wide you want */
  margin: 20px 0;
  width: auto;
}
#tableContainer {
  width: 100%;
  overflow-x: auto;
  text-align: center; /* Center the table inside the container */
}

th, td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center; 
}
.csv-button {
  margin: 5px 10px;
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;

  border-radius: 8px;
  transition: background-color 0.2s ease;
}

.csv-button:hover {
  background-color: #acbdba;
}

.csv-button.active {
  background-color: #6c75a5;
  color: white;
  border-color: rgb(34, 68, 131);
}


#minWattage {
  width: 100px;          /* fixed width */
  padding: 12px 15px;
  font-size: 1rem;
  border: 2px solid #6c75a5; /* blue border */
  border-radius: 6px;    /* rounded corners */
  outline: none;         /* remove default outline */
  transition: border-color 0.3s ease;
  margin-bottom: 10px;
}

#searchBar {
  width: 400px;
  padding: 12px 15px;
  font-size: 1rem;
  border: 2px solid #6c75a5;
  border-radius: 6px;
  outline: none;
  transition: border-color 0.3s ease;
  text-align: center;
}

#filters {
  display: flex;
  justify-content: center; /* centers horizontally */
  align-items: center;     /* aligns vertically */
  gap: 10px;               /* space between items */
  margin-bottom: 10px;     /* space below filters */
}

#minWattage:focus {
  border-color: #6c75a5; /* darker blue on focus */
  box-shadow: 0 0 5px #6c75a5; /* subtle glow */
}
label{
  font-size: small;
  margin: 10px;
}

.custom-dropdown {
  /* width: 250px; */
  padding: 12px 15px;
  font-size: 1rem;
  border: 2px solid var(--primary-color);
  border-radius: 10px;
  background-color: #fff;
  color: var(--dark-color);
  font-family: 'Poppins', sans-serif;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  /* appearance: none;  */

}
#cheapestCountInput {
  width: 70px;          /* fixed width */
  padding: 2px 10px;
  font-size: 1rem;
  border: 2px solid #6c75a5; /* blue border */
  border-radius: 6px;    /* rounded corners */
  outline: none;         /* remove default outline */
  transition: border-color 0.3s ease;
  margin-bottom: 10px;
}

#cheapestCountInput:focus {
  border-color: #6c75a5; /* darker blue on focus */
  box-shadow: 0 0 5px #6c75a5; /* subtle glow */
}
.custom-dropdown:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 5px var(--primary-color);
  outline: none;
}

/* === Tier Gradient for White Text === */

/* D Tiers - Dark Orange to Green Gradient Segment */
/* D Tiers - Deep Orange to Amber */
.tier-F { background-color: #7b2e00; color: white; }  /* D- */
.tier-E  { background-color: #a84300; color: white; }  /* D  */
.tier-D { background-color: #d65a00; color: white; }  /* D+ */

/* C Tiers - Amber to Mustard */
.tier-Cm { background-color: #e07c00; color: white; }  /* C- */
.tier-C  { background-color: #e89f00; color: white; }  /* C  */
.tier-Cp { background-color: #f2c200; color: white; }  /* C+ */

/* B Tiers - Mustard to Olive Green */
.tier-Bm { background-color: #c4d400; color: white; }  /* B- */
.tier-B  { background-color: #8fcf00; color: white; }  /* B  */
.tier-Bp { background-color: #5ac800; color: white; }  /* B+ */

/* A Tiers - Vibrant Greens */
.tier-Am { background-color: #2fc100; color: white; }  /* A- */
.tier-A  { background-color: #00b84f; color: white; }  /* A  */
.tier-Ap { background-color: #00a86b; color: white; }  /* A+ */

td.tier-cell {
      position: relative;
      cursor: help;
    }
    td.tier-cell::after {
      content: attr(data-model);
      position: absolute;
      left: 50%;
      bottom: 115%;
      transform: translateX(-50%);
      background: #111;
      color: #fff;
      font-size: 0.85rem;
      line-height: 1.2;
      padding: 6px 8px;
      border-radius: 6px;
      box-shadow: 0 6px 16px rgba(0,0,0,.25);
      max-width: 280px;
      white-space: normal;
      opacity: 0;
      /* visibility: hidden; */
      pointer-events: none;
      transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
      z-index: 3000;
    }
    td.tier-cell::before {
      content: "";
      position: absolute;
      left: 50%;
      bottom: 105%;
      transform: translateX(-50%);
      border: 6px solid transparent;
      border-top-color: #111;
      opacity: 0;
      visibility: hidden;
      transition: opacity .18s ease, visibility 0s linear .18s;
      z-index: 3000;
    }
    td.tier-cell:hover::after,
    td.tier-cell:hover::before,
    td.tier-cell:focus-visible::after,
    td.tier-cell:focus-visible::before {
      opacity: 1;
      visibility: visible;
      transform: translateX(-50%) translateY(-2px);
      transition-delay: 0s;
    }
.deal{
  color:#2c5f5f;
}












@media (max-width: 600px) {
  #tableContainer table thead { display: table-header-group; } /* keep header */
  #tableContainer table tr > *:nth-child(n+5) { display: none; } /* hide cols 5+ */
  #tableContainer table { width: 100%; min-width: 0; display: table; }
}



/* ---------- Responsive Table Base ---------- */
#tableContainer {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  text-align: center;
}

/* Override the global table rule for YOUR generated table only */
.psu-table {
  display: table;         /* override inline-table */
  width: 100%;
  min-width: auto;        /* let it shrink on small screens */
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.95rem;
}

.psu-table th,
.psu-table td {
  border: 1px solid #ddd;
  padding: 8px 10px;
  text-align: center;
  vertical-align: middle;
}

.psu-table img {
  max-width: 80px;
  height: auto;
  display: block;
  margin: 0 auto;
}

/* Keep the header sticky on wider viewports */
@media (min-width: 601px) {
  .psu-table thead th {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 1;
  }
}

/* Tablet: allow horizontal scroll but trim low-priority columns if you add classes (see JS patch) */
@media (max-width: 900px) {
  .psu-table img { max-width: 60px; }
  /* Optional if you add column classes:
  .psu-table .col-image-url,
  .psu-table .col-color,
  .psu-table .col-modularity,
  .psu-table .col-atxver,
  .psu-table .col-matched-tier-model,
  .psu-table .col-matched-tier-model-info { display: none; }
  */
}

/* Phone: stacked "card" layout */
@media (max-width: 600px) {
  .psu-table { border-collapse: separate; border-spacing: 0 10px; }
  .psu-table thead { display: none; }
  .psu-table, .psu-table tbody, .psu-table tr, .psu-table td { display: block; width: 100%; }
  .psu-table tr {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(0,0,0,.04);
    padding: 0; margin: 10px 0;
    overflow: hidden;
  }
  .psu-table td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;         /* easier to read labels/value */
    padding: 10px 12px;
    border: none;             /* we separate cells by border-bottom instead */
    border-bottom: 1px solid #f1f5f9;
  }
  .psu-table td:last-child { border-bottom: none; }

  /* Show field label before the value using data-label from JS patch */
  .psu-table td::before {
    content: attr(data-label);
    font-weight: 600;
    margin-right: 12px;
    flex: 1 1 50%;
    color: #2E2F2F;
  }
  .psu-table td > *:not(img) {
    max-width: 50%;
    margin-left: auto;
    text-align: right;
  }

  /* Tooltips still appear above cells */
  .psu-table td.tier-cell { position: relative; }

  /* Optional: hide lower-priority fields on phones if you add column classes */
  /* Keep Remove (if present), Tier, Name, Price, Wattage visible; hide the rest. */
  .psu-table .col-efficiency,
  .psu-table .col-modularity,
  .psu-table .col-atxver,
  .psu-table .col-size,
  .psu-table .col-color,
  .psu-table .col-matched-tier-model,
  .psu-table .col-matched-tier-model-info,
  .psu-table .col-image-url { display: none; }
}

/* Better touch targets */
@media (pointer: coarse) {
  .remove-btn { min-width: 36px; min-height: 36px; }
}

/* ---------- Filters wrap nicely on mobile ---------- */
#filters {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;            /* NEW: wrap on small screens */
}

#minWattage,
#cheapestCountInput,
.custom-dropdown {
  max-width: 100%;
}

/* On very narrow screens, let the generic table rule relax */
@media (max-width: 600px) {
  table { min-width: 0 !important; width: 100% !important; }
}

/* Optional: smaller images globally on tiny screens */
@media (max-width: 600px) {
  img { max-width: 70px; }
}

.tier-range {
    --track-h: 8px;
    --track-bg: #eee;
    --fill-bg: #7c3aed;
    --thumb-size: 22px;
    --thumb-ring: 3px;
    --tick-size: 6px;

    position: relative;
    width: 100%;
    max-width: 640px;
    margin: 12px 0 8px;
    user-select: none;
    touch-action: none;
  }
  .tr-track {
    position: relative;
    height: var(--track-h);
    background: var(--track-bg);
    border-radius: 999px;
  }
  .tr-fill {
    position: absolute;
    height: 100%;
    left: 0; top: 0;
    width: 0%;
    background: var(--fill-bg);
    border-radius: 999px;
    pointer-events: none;
  }
  .tr-thumb {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: var(--thumb-size);
    height: var(--thumb-size);
    background: #fff;
    border-radius: 50%;
    box-shadow:
      0 1px 2px rgba(0,0,0,.15),
      0 0 0 var(--thumb-ring) var(--fill-bg);
  }
  .tr-thumb:focus-visible {
    outline: 3px solid #94a3b8;
    outline-offset: 2px;
  }
  /* Make the active thumb sit on top when overlapping */
  .tr-thumb.active { z-index: 2; }

  .tr-ticks {
    position: relative;
    height: 14px;
    margin-top: 6px;
  }
  .tr-tick {
    position: absolute;
    top: 0;
    width: 0;
    height: var(--tick-size);
    border-left: 2px solid #d4d4d8;
    transform: translateX(-1px);
  }
  .tr-label {
    margin-top: 10px;
    font: 600 14px/1.2 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial;
    color: #e7ebff;
  }
  .tr-sub {
    font: 12px/1.2 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial;
    color: #6b7280;
    margin-left: 6px;
    font-weight: 500;
  }
  .tier-range-wrapper {
    margin-top: 15px;
    text-align: center;
  }

  .tier-range {
    max-width: 600px;               /* control slider width */
    width: 80%;                     /* responsive shrink */
    margin: 0 auto;
  }