/* ============================================================
   Thikana Archive — Shared Stylesheet
   All shared styles for: homepage, shop, product, checkout, thankyou
   ============================================================ */

/* ------------------------------------------------------------
   1. CSS Variables
   ------------------------------------------------------------ */
:root {
  --bg: #ffffff;
  --bg2: #f7f6f2;
  --bg3: #f0efe9;
  --text: #1a1a18;
  --text2: #6b6a64;
  --text3: #9b9a94;
  --border: rgba(0,0,0,0.11);
  --border2: rgba(0,0,0,0.22);
  --green: #2d7a4f;
  --green-bg: #d4edda;
  --radius: 8px;
  --radius-lg: 12px;
}

/* ------------------------------------------------------------
   2. Reset & Base Styles
   ------------------------------------------------------------ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

img {
  max-width: 100%;
  display: block;
}

ul, ol {
  list-style: none;
}

input, textarea, select, button {
  font-family: inherit;
}

/* ------------------------------------------------------------
   3. Navigation
   ------------------------------------------------------------ */
.nav {
  background: var(--bg);
}

.nav-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 0;
  gap: 16px;
  border-bottom: 0.5px solid var(--border);
}

.nav-logo {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: .06em;
  flex-shrink: 0;
}

.nav-logo span {
  font-size: 10px;
  color: var(--text3);
  font-weight: 400;
  display: block;
  letter-spacing: .04em;
  margin-top: 1px;
}

.nav-search {
  flex: 1;
  max-width: 380px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg2);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 14px;
}

.nav-search svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: .45;
}

.nav-search span {
  font-size: 12px;
  color: var(--text3);
}

.nav-search input {
  border: none;
  background: transparent;
  font-size: 12px;
  color: var(--text);
  outline: none;
  width: 100%;
}

.nav-search input::placeholder {
  color: var(--text3);
}

.nav-icons {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.ibt {
  width: 34px;
  height: 34px;
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color .15s;
}

.ibt:hover {
  border-color: var(--border2);
}

.ibt svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: var(--text2);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cart-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  background: var(--text);
  border-radius: var(--radius);
  font-size: 12px;
  color: #fff;
  cursor: pointer;
  transition: opacity .15s;
}

.cart-btn:hover {
  opacity: .88;
}

.cart-btn svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: #fff;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-links {
  display: flex;
  padding: 0;
  border-bottom: 0.5px solid var(--border);
}

.nl {
  font-size: 12px;
  color: var(--text2);
  padding: 9px 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: color .15s;
}

.nl:first-child {
  padding-left: 0;
}

.nl:hover {
  color: var(--text);
}

.nav-secure {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text3);
}

.nav-secure svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: var(--text3);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ------------------------------------------------------------
   4. Buttons
   ------------------------------------------------------------ */
.btn-primary {
  display: inline-block;
  background: var(--text);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 11px 24px;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  border: none;
  transition: opacity .15s;
}

.btn-primary:hover {
  opacity: .88;
}

.btn-ghost {
  display: inline-block;
  border: 0.5px solid var(--border2);
  color: var(--text2);
  font-size: 13px;
  padding: 11px 24px;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  background: var(--bg);
  transition: background .15s;
}

.btn-ghost:hover {
  background: var(--bg2);
}

.btn-ghost svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: var(--text2);
  stroke-width: 1.5;
}

.btn-buynow {
  padding: 13px;
  background: var(--text);
  color: #fff;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: opacity .15s;
  border: none;
}

.btn-buynow:hover {
  opacity: .88;
}

.btn-cart {
  padding: 12px;
  border: 0.5px solid var(--border2);
  color: var(--text);
  border-radius: var(--radius);
  font-size: 13px;
  text-align: center;
  cursor: pointer;
  background: var(--bg);
  transition: background .15s;
}

.btn-cart:hover {
  background: var(--bg2);
}

.btn-wa {
  padding: 11px;
  border: 0.5px solid var(--border);
  color: var(--text2);
  border-radius: var(--radius);
  font-size: 12px;
  text-align: center;
  cursor: pointer;
  background: var(--bg2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-wa svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: var(--text2);
  stroke-width: 1.5;
}

/* ------------------------------------------------------------
   5. Product Cards
   ------------------------------------------------------------ */
.pgrid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.pc {
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg);
  transition: border-color .15s;
}

.pc:hover {
  border-color: var(--border2);
}

.pt {
  aspect-ratio: 3/4;
  background: var(--bg2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--text3);
  border-bottom: 0.5px solid var(--border);
  position: relative;
  overflow: hidden;
}

/* Badge — supports both .pb (homepage) and .pbadge (shop) */
.pb,
.pbadge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 10px;
  background: var(--bg);
  border: 0.5px solid var(--border2);
  border-radius: 4px;
  padding: 2px 7px;
  color: var(--text2);
}

/* Wishlist — supports both .pw (homepage) and .pwish (shop) */
.pw,
.pwish {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  background: var(--bg);
  border: 0.5px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color .15s;
}

.pw:hover,
.pwish:hover {
  border-color: var(--border2);
}

.pw svg,
.pwish svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: var(--text3);
  stroke-width: 1.5;
}

.pwish:hover svg {
  stroke: var(--text);
}

.popular-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  font-size: 10px;
  background: var(--text);
  color: #fff;
  border-radius: 4px;
  padding: 2px 8px;
  font-weight: 500;
}

.pi {
  padding: 11px 13px 14px;
}

/* Name — supports both .pn (homepage) and .pname (shop) */
.pn,
.pname {
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 4px;
  line-height: 1.4;
}

/* Price — supports both .pp (homepage) and .pprice (shop) */
.pp,
.pprice {
  font-size: 12px;
  color: var(--text2);
  margin-bottom: 8px;
}

.pp s,
.pprice s {
  color: var(--text3);
  font-size: 11px;
}

.order-count {
  font-size: 11px;
  color: var(--text3);
  margin-bottom: 7px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-count svg {
  width: 11px;
  height: 11px;
  fill: none;
  stroke: var(--text3);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Gift tags — supports both .gt (homepage) and .gtag (shop) */
.gtags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.gt,
.gtag {
  font-size: 10px;
  color: var(--text3);
  border: 0.5px solid var(--border);
  border-radius: 3px;
  padding: 2px 6px;
  background: var(--bg2);
}

/* ------------------------------------------------------------
   6. Section Headers
   ------------------------------------------------------------ */
.sh {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 18px;
}

.st {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.ss {
  font-size: 12px;
  color: var(--text3);
  margin-top: 3px;
}

.sl {
  font-size: 12px;
  color: var(--text3);
  text-decoration: none;
  cursor: pointer;
  transition: color .15s;
}

.sl:hover {
  color: var(--text2);
}

.sec {
  padding: 36px 48px;
  border-bottom: 0.5px solid var(--border);
}

/* ------------------------------------------------------------
   7. Footer
   ------------------------------------------------------------ */

/* Full footer (homepage, shop, product) */
.footer {
  padding: 22px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg2);
  border-top: 0.5px solid var(--border);
}

.fl {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.flinks {
  display: flex;
  gap: 20px;
  list-style: none;
}

.flinks li {
  font-size: 12px;
  color: var(--text3);
  cursor: pointer;
  transition: color .15s;
}

.flinks li:hover {
  color: var(--text2);
}

.fc {
  font-size: 11px;
  color: var(--text3);
}

/* Minimal footer (thankyou page) */
.footer-min {
  padding: 18px 32px;
  border-top: 0.5px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg2);
}

/* Checkout footer */
.co-footer {
  padding: 14px 32px;
  border-top: 0.5px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg);
}

.co-footer-links {
  display: flex;
  gap: 16px;
  list-style: none;
}

.co-footer-links li {
  font-size: 11px;
  color: var(--text3);
  cursor: pointer;
  transition: color .15s;
}

.co-footer-links li:hover {
  color: var(--text2);
}

.co-footer-copy {
  font-size: 11px;
  color: var(--text3);
}

/* ------------------------------------------------------------
   8. Form Styles
   ------------------------------------------------------------ */
.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.field label {
  font-size: 12px;
  color: var(--text2);
  font-weight: 500;
}

.field-req {
  color: #c0392b;
}

.field-input {
  background: var(--bg2);
  border: 0.5px solid var(--border2);
  border-radius: var(--radius);
  padding: 10px 13px;
  font-size: 13px;
  color: var(--text);
  transition: border-color .15s;
  width: 100%;
}

.field-input::placeholder {
  color: var(--text3);
}

.field-input:focus {
  outline: none;
  border-color: var(--text);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.form-grid.full {
  grid-template-columns: 1fr;
}

.form-section {
  margin-bottom: 28px;
}

.form-section:last-child {
  margin-bottom: 0;
}

.fs-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 0.5px solid var(--border);
}

/* ------------------------------------------------------------
   9. Chirokut Cards
   ------------------------------------------------------------ */
.chc {
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg);
}

.chimg {
  height: 170px;
  background: var(--bg2);
  border-bottom: 0.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.chpaper {
  width: 112px;
  height: 134px;
  background: var(--bg);
  border: 0.5px solid var(--border2);
  border-radius: 4px;
  padding: 13px 12px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.chpaper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--border);
  border-radius: 4px 4px 0 0;
}

.chl {
  height: 1px;
  background: var(--border);
  border-radius: 1px;
  width: 100%;
}

.chl.s { width: 62%; }
.chl.m { width: 80%; }
.chl.x { width: 42%; }

.chh {
  position: absolute;
  bottom: 9px;
  right: 9px;
}

.chh svg {
  width: 11px;
  height: 11px;
  fill: var(--border2);
}

.chtrow {
  position: absolute;
  bottom: 9px;
  left: 9px;
  display: flex;
  gap: 4px;
}

.chtag {
  font-size: 10px;
  color: var(--text3);
  background: var(--bg);
  border: 0.5px solid var(--border);
  border-radius: 3px;
  padding: 2px 5px;
}

.chbody {
  padding: 13px 15px 14px;
}

.chocc {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 5px;
}

.chnote {
  font-size: 12px;
  color: var(--text2);
  line-height: 1.65;
  font-style: italic;
}

.chfrom {
  font-size: 11px;
  color: var(--text3);
  margin-top: 7px;
}

.chfoot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 15px;
  border-top: 0.5px solid var(--border);
  background: var(--bg2);
}

.chcity {
  font-size: 11px;
  color: var(--text3);
}

.chst {
  font-size: 11px;
  color: var(--text2);
}

/* Subscription strip */
.substrip {
  margin-top: 18px;
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 15px 20px;
  background: var(--bg2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.subtxt {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.6;
}

.subtxt strong {
  font-weight: 600;
  color: var(--text);
  display: block;
  margin-bottom: 2px;
}

.subbtn {
  font-size: 12px;
  color: var(--text2);
  border: 0.5px solid var(--border2);
  border-radius: var(--radius);
  padding: 8px 16px;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  text-decoration: none;
  transition: background .15s;
}

.subbtn:hover {
  background: var(--bg2);
}

/* ------------------------------------------------------------
   10. Divider
   ------------------------------------------------------------ */
.divider {
  height: 0.5px;
  background: var(--border);
  margin: 14px 0;
}

/* ------------------------------------------------------------
   11. Tabs
   ------------------------------------------------------------ */

/* Pill tabs (homepage gift collection) */
.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.tab {
  padding: 7px 16px;
  border: 0.5px solid var(--border);
  border-radius: 20px;
  font-size: 12px;
  color: var(--text2);
  cursor: pointer;
  background: var(--bg);
  transition: all .15s;
}

.tab:hover {
  border-color: var(--border2);
  color: var(--text);
}

.tab.act {
  background: var(--text);
  border-color: var(--text);
  color: #fff;
  font-weight: 500;
}

.panel {
  display: none;
}

.panel.act {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

/* Underline tabs (product details) */
.dtab {
  font-size: 13px;
  color: var(--text2);
  padding: 10px 20px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color .15s;
}

.dtab:first-child {
  padding-left: 0;
}

.dtab:hover {
  color: var(--text);
}

.dtab.act {
  color: var(--text);
  font-weight: 600;
  border-bottom-color: var(--text);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

/* ------------------------------------------------------------
   12. Trust Strip
   ------------------------------------------------------------ */
.trust-strip {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 12px;
  border-top: 0.5px solid var(--border);
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  color: var(--text2);
}

.trust-item svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: var(--green);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

/* ------------------------------------------------------------
   13. Pagination
   ------------------------------------------------------------ */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 24px;
  border-top: 0.5px solid var(--border);
  margin-top: 20px;
}

.page-btn {
  width: 32px;
  height: 32px;
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--text2);
  cursor: pointer;
  transition: all .15s;
}

.page-btn:hover {
  border-color: var(--border2);
  color: var(--text);
}

.page-btn.active {
  background: var(--text);
  color: #fff;
  border-color: var(--text);
}

.page-btn svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ------------------------------------------------------------
   14. Responsive
   ------------------------------------------------------------ */
@media (max-width: 768px) {

  /* Nav: hide search on mobile */
  .nav-search {
    display: none;
  }

  .nav-top {
    padding: 13px 16px;
  }

  .nav-links {
    padding: 0 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Product grids: 2 columns */
  .pgrid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .panel.act {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  /* Category grid: 4 columns */
  .cat-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  /* Sections: reduce padding */
  .sec {
    padding: 24px 16px;
  }

  .sh {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  /* Footer stacks */
  .footer {
    flex-direction: column;
    gap: 12px;
    padding: 20px 16px;
    text-align: center;
  }

  .footer-min {
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    text-align: center;
  }

  /* Form grids go single column */
  .form-grid {
    grid-template-columns: 1fr;
  }

  /* Chirokut images shorter */
  .chimg {
    height: 130px;
  }

  /* Tab panel single column on product details */
  .tab-panel.active {
    grid-template-columns: 1fr;
  }

  /* Substrip stacks */
  .substrip {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
}

@media (max-width: 480px) {

  /* Product grids: single column for cart items in checkout */
  .cart-items .cart-item {
    flex-direction: column;
  }

  /* Pagination smaller */
  .page-btn {
    width: 28px;
    height: 28px;
    font-size: 11px;
  }

  /* Buttons full width */
  .btn-primary,
  .btn-ghost {
    width: 100%;
    text-align: center;
  }

  .co-footer {
    flex-direction: column;
    gap: 8px;
    text-align: center;
    padding: 12px 16px;
  }
}
