@import url('https://fonts.googleapis.com/css?family=Poppins');

:root{
  /* ---------- Brand / Theme tokens (LIGHT) ---------- */
  color-scheme: light;
  /* Base */
  --bg: #f6f8fb;
  --surface: #ffffff;
  --surface-2: #fbfcff;

  --text: #0f172a;
  --muted: #586277;

  /* Brand */
  --green: #2e6654;
  --orange: #e8782f;

  /* “Primary” in light theme: bright + subtle tinting */
  --primary: #ffffff;
  --primary-tint: rgba(46, 102, 84, .06);  /* green tint */
  --accent-tint: rgba(232, 120, 47, .10);  /* orange tint */
  --accent-tint-2: rgba(232, 120, 47, .16);
  --success-tint: rgba(46, 102, 84, .14);

  /* Lines / shadows */
  --line: rgba(15, 23, 42, .12);
  --line-strong: rgba(46, 102, 84, .26);
  --line-accent: rgba(232, 120, 47, .34);

  --shadow: 0 16px 45px rgba(15, 23, 42, .10);
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, .08);

  /* Rounding */
  --r: 18px;
  --r2: 14px;
}

/* Base */
.template, .template *{
  box-sizing: border-box;
  font-family: 'Poppins';
}

.template{
  width: 100%;
  color: var(--text);

  /* More brand integration: green as structure, orange as spark */
  background:
    radial-gradient(1100px 700px at 10% 6%, rgba(46, 102, 84, .18), transparent 58%),
    radial-gradient(900px 520px at 92% 18%, rgba(232, 120, 47, .20), transparent 60%),
    radial-gradient(850px 650px at 50% 110%, rgba(46, 102, 84, .12), transparent 55%),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 60%, #ffffff 100%);

  border-radius: 16px;
  overflow: hidden;
}

.template-container{
  max-width: 1100px;
  margin: 0 auto;
  padding: 22px;
}

/* Brand images */
.brand-header{
  width: 100%;
  display: block;
  border-bottom: 1px solid var(--line);
  background: rgba(46, 102, 84, .04);
}

.footer-image{
  width: 100%;
  display: block;
  border-top: 1px solid var(--line);
  background: rgba(46, 102, 84, .04);
  margin-top: 16px;
}

/* Topbar */
.topbar{
  margin-top: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;

  padding: 14px 16px;

  /* green as “secondary structure” */
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(180deg, rgba(255,255,255,.95), rgba(255,255,255,.80)),
    radial-gradient(900px 300px at 8% 30%, rgba(46, 102, 84, .10), transparent 60%);
  border-radius: var(--r);
  box-shadow: var(--shadow);
}

.brand{
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.topbar-logo{ height: 100px; }

.topbar-logo img{
  height: 100%;
  border-radius: 12px;
  max-width: 400px;
  flex: 0 0 auto;
  filter: brightness(0) saturate(100%) invert(0%) sepia(93%) saturate(7497%) hue-rotate(178deg) brightness(90%) contrast(101%);
}

.topbar-logo span{
  font-weight: 900;
  font-size: 13px;
  color: var(--text);
  letter-spacing: .5px;
}

.topbar-badges{
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Badges: integrate brand colors more clearly */
.badge{
  font-size: 12px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.92);
  color: var(--text);
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
}

.badge-quality{
  border-color: rgba(46, 102, 84, .42);
  background: linear-gradient(135deg, rgba(46, 102, 84, .18), rgba(46, 102, 84, .10));
}

.badge-shipping{
  border-color: rgba(232, 120, 47, .45);
  background: linear-gradient(135deg, rgba(232, 120, 47, .20), rgba(232, 120, 47, .10));
}

/* Layout */
.layout{
  margin-top: 16px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.layout-main{ flex: 1 1 620px; min-width: 0; }
.layout-sidebar{ flex: 1 1 300px; min-width: 0; }

/* Cards */
.card{
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, var(--surface), var(--surface-2));
  border-radius: var(--r);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card + .card{ margin-top: 16px; }

/* Header: green structure line + subtle tint */
.card-header{
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(46, 102, 84, .06), rgba(255,255,255,.0));
  position: relative;
}

.card-header::before{
  content:"";
  position:absolute;
  left:0;
  top:0;
  height:4px;
  width:100%;
  background: linear-gradient(90deg, rgba(46, 102, 84, .75), rgba(232, 120, 47, .70));
}

.card-body{ padding: 16px; }

.product-title{
  margin: 0;
  font-size: 26px;
  font-weight: 950;
  line-height: 1.15;
  letter-spacing: .2px;
}

.section-subtitle{
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}

/* Utilities (HTML-size saver) */
.section-title{ font-weight: 950; font-size: 18px; }
.section-subtitle-spaced{ margin-top: 6px; }
.footer-label{ color: var(--text); }

/* Gallery */
.gallery input{ display: none; }
.gallery input + .gallery-panel{ display: none; }
.gallery input:checked + .gallery-panel{ display: flex; }

.gallery-panel{
  width: 100%;
  aspect-ratio: 1/1;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r2);
}

.gallery-image{
  width: 100%;
  display: block;
}

.gallery-thumbs{
  display: flex;
  gap: 10px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.gallery-thumb{
  width: calc(25% - 7.5px);
  min-width: 120px;

  border-radius: 12px;
  border: 1px solid var(--line);
  overflow: hidden;

  background: #ffffff;
  cursor: pointer;
  position: relative;

  display: block;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;

  max-width: 180px;
  box-shadow: var(--shadow-soft);
}

.gallery-thumb img{ width: 100%; display: block; }

.gallery-thumb:after{
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 12px;
  box-shadow: inset 0 0 0 0 rgba(0,0,0,0);
  transition: box-shadow .15s ease, transform .15s ease;
}

.gallery-thumb:hover:after{
  box-shadow: inset 0 0 0 2px rgba(46, 102, 84, .25);
}

/* Tabs */
.tabs input{ display: none; }

.tabs-bar{
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px;

  border: 1px solid var(--line-strong);
  border-radius: var(--r2);
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.78)),
    radial-gradient(900px 220px at 10% 20%, rgba(46, 102, 84, .10), transparent 60%);
  box-shadow: var(--shadow-soft);
}

.tabs-bar label{
  cursor: pointer;
  user-select: none;

  padding: 10px 12px;
  border-radius: 999px;

  border: 1px solid rgba(46, 102, 84, .22);
  background: rgba(255,255,255,.92);
  color: var(--muted);

  font-size: 13px;
  font-weight: 950;

  display: flex;
  gap: 8px;
  align-items: center;
  white-space: nowrap;

  transition: transform .12s ease, border-color .12s ease, color .12s ease, background .12s ease;
}

.tabs-bar label:hover{
  transform: translateY(-1px);
  border-color: rgba(46, 102, 84, .34);
  color: var(--text);
  background: linear-gradient(135deg, rgba(46, 102, 84, .10), rgba(255,255,255,.92));
}

.tabs-bar label img{ height: 12px; width: auto; opacity: .85; }

.tabs-panes{
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.82));
  box-shadow: var(--shadow-soft);
}

.tabs-pane{
  display: none;
  padding: 16px;
}

/* Right info blocks */
.info-block{
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255,255,255,.94), rgba(255,255,255,.82));
  border-radius: 16px;
  padding: 14px;
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.info-block::before{
  content:"";
  position:absolute;
  left:0;
  top:0;
  width: 5px;
  height: 100%;
  background: rgba(46, 102, 84, .55);
}

.info-block + .info-block{ margin-top: 12px; }

.info-block h4{
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 950;
  color: var(--text);
}

.info-block p{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

/* Make “Support” pop a bit more with orange accent.
   (No HTML changes required; this targets the common inline link already present.) */
.info-block a{
  color: var(--orange);
  text-decoration: underline;
  text-decoration-color: rgba(232, 120, 47, .45);
}

/* HTML content */
.html-content{
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}

.html-content strong{ color: var(--text); }

.html-content a{
  color: var(--orange);
  text-decoration: underline;
  text-decoration-color: rgba(232, 120, 47, .45);
}

.html-content ul{ margin: 10px 0 0 18px; padding: 0; }
.html-content li{ margin: 6px 0; }

/* Footer */
.footer-box{
  margin-top: 16px;
  padding: 18px 16px;
  border-top: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(46, 102, 84, .06), rgba(255,255,255,.70));
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

/* Responsive */
@media (max-width:784px){
  .topbar-logo{
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  .topbar{ flex-direction: column; align-items: flex-start; }
  .topbar-badges{ justify-content: flex-start; }
}

@media (max-width:720px){
  .template-container{ padding: 16px; }
  .product-title{ font-size: 22px; }

  .gallery-thumb{
    width: calc(50% - 5px);
    min-width: 0;
    max-width: 120px;
  }

  .tabs-bar label{
    flex: 1 1 auto;
    justify-content: center;
  }
}

@media (max-width:500px){
  .topbar-logo{ width: 100%; }
  .topbar-logo img{ width: 100%; height: auto; }
  .topbar-badges{ display: none; }
}

@media (max-width:400px){
  .gallery-thumb{ max-width: 100px; }
}

/* Selected thumb outline:
   green as “secondary”, orange as “accent ring” */
#g-1:checked ~ .gallery-thumbs label[for="g-1"]::after,
#g-2:checked ~ .gallery-thumbs label[for="g-2"]::after,
#g-3:checked ~ .gallery-thumbs label[for="g-3"]::after,
#g-4:checked ~ .gallery-thumbs label[for="g-4"]::after,
#g-5:checked ~ .gallery-thumbs label[for="g-5"]::after,
#g-6:checked ~ .gallery-thumbs label[for="g-6"]::after,
#g-7:checked ~ .gallery-thumbs label[for="g-7"]::after,
#g-8:checked ~ .gallery-thumbs label[for="g-8"]::after,
#g-9:checked ~ .gallery-thumbs label[for="g-9"]::after,
#g-10:checked ~ .gallery-thumbs label[for="g-10"]::after{
  box-shadow:
    inset 0 0 0 2px rgba(46, 102, 84, .85),
    inset 0 0 0 4px rgba(232, 120, 47, .35);
}

/* Active tab:
   green = selected background, orange = accent highlight */
#i-desc:checked ~ .tabs-bar label[for="i-desc"],
#i-faq:checked  ~ .tabs-bar label[for="i-faq"],
#i-bat:checked  ~ .tabs-bar label[for="i-bat"]{
  color: var(--text);
  border-color: rgba(46, 102, 84, .55);
  background:
    linear-gradient(135deg, rgba(46, 102, 84, .18), rgba(255,255,255,.92));
}

#i-desc:checked ~ .tabs-bar label[for="i-desc"]::after,
#i-faq:checked  ~ .tabs-bar label[for="i-faq"]::after,
#i-bat:checked  ~ .tabs-bar label[for="i-bat"]::after{
  content:"";
  position:absolute;
  right: 8px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  transform: translateY(-50%);
}

/* Pane switching */
#i-desc:checked ~ .tabs-panes #pane-desc{ display: block; }
#i-faq:checked  ~ .tabs-panes #pane-faq{ display: block; }
#i-bat:checked  ~ .tabs-panes #pane-bat{ display: block; }

/* Minor polish */
.badge, .tabs-bar label, .gallery-thumb, .info-block{
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}