/* ============= Base / Layout / Visuals ============= */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: linear-gradient(135deg, #0f1419 0%, #1a2332 35%, #2d4a3e 100%);
  color: #fff;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ============= Header ============= */
.header {
  background: rgba(15, 20, 25, .95);
  backdrop-filter: blur(20px);
  padding: 1rem 2rem;
  border-bottom: 1px solid rgba(45, 74, 62, .3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 8px 32px rgba(0, 0, 0, .2);
}
.logo {
  display: flex;
  align-items: center;
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, #4ade80, #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -.02em;
}
.logo::before { content: "🌱"; margin-right: .5rem; filter: hue-rotate(90deg); }

/* ============= Navigation ============= */
.nav { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.nav a {
  text-decoration: none;
  color: rgba(255, 255, 255, .7);
  font-weight: 600;
  padding: .75rem 1.2rem;
  border-radius: 12px;
  transition: all .3s cubic-bezier(.4, 0, .2, 1);
  position: relative;
  overflow: hidden;
}
.nav a::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #4ade80, #22d3ee);
  opacity: 0;
  transition: opacity .3s;
  border-radius: 12px;
}
.nav a:hover::before,
.nav a.active::before { opacity: .15; }
.nav a:hover,
.nav a.active { color: #fff; transform: translateY(-2px); }

/* ============= User Strip ============= */
.user-strip { display: flex; gap: .75rem; align-items: center; }
.token-badge {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  padding: .6rem 1rem;
  border-radius: 16px;
  font-weight: 700;
  box-shadow: 0 4px 20px rgba(251, 191, 36, .3);
  position: relative;
  overflow: hidden;
}
.token-badge::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .2), transparent);
  animation: shine 3s infinite;
}
@keyframes shine { 0% { left: -100%; } 100% { left: 100%; } }

/* ============= Buttons ============= */
.btn {
  padding: .85rem 1.4rem;
  border: none;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all .3s cubic-bezier(.4, 0, .2, 1);
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: .5px;
  font-size: .9rem;
}
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, .05));
  opacity: 0;
  transition: opacity .3s;
}
.btn:hover::before { opacity: 1; }
.btn-primary {
  background: linear-gradient(135deg, #4ade80, #22d3ee);
  color: #0f1419;
  box-shadow: 0 8px 25px rgba(74, 222, 128, .3);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 12px 35px rgba(74, 222, 128, .4); }
.btn-outline {
  background: rgba(255, 255, 255, .05);
  border: 2px solid rgba(74, 222, 128, .4);
  color: #4ade80;
  backdrop-filter: blur(10px);
}
.btn-outline:hover { background: rgba(74, 222, 128, .1); border-color: #4ade80; transform: translateY(-2px); }

/* ============= Layout ============= */
.main { max-width: 1400px; margin: 0 auto; padding: 2rem; }

/* ============= Cards ============= */
.card {
  background: rgba(15, 20, 25, .7);
  backdrop-filter: blur(20px);
  border-radius: 24px;
  border: 1px solid rgba(45, 74, 62, .3);
  box-shadow: 0 25px 60px rgba(0, 0, 0, .3);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #4ade80, transparent);
  opacity: .6;
}

/* ============= Hero ============= */
.hero { margin-bottom: 3rem; text-align: center; position: relative; }
.hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #fff, #4ade80);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 900;
  letter-spacing: -.02em;
}
.hero p { color: rgba(255, 255, 255, .8); margin-bottom: 2rem; font-size: 1.1rem; }

/* ============= Grid System ============= */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

/* ============= Product Cards ============= */
.product-card {
  position: relative;
  overflow: hidden;
  transition: all .4s cubic-bezier(.4, 0, .2, 1);
}
.product-card:hover { transform: translateY(-8px) scale(1.02); }
.product-card .image {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: #fff;
  border-radius: 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  position: relative;
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.product-card .image::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, .2), transparent);
}
.product-card h3 { margin: 0 0 .5rem; font-size: 1.3rem; font-weight: 700; }
.product-card p { color: rgba(255, 255, 255, .7); margin-bottom: 1.5rem; }
.product-meta { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(74, 222, 128, .15);
  border: 1px solid rgba(74, 222, 128, .3);
  color: #4ade80;
  font-weight: 700;
  border-radius: 20px;
  padding: .5rem 1rem;
  backdrop-filter: blur(10px);
}

/* ============= Category Tags ============= */
.category-tag {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, .7);
  color: #fff;
  padding: .4rem .8rem;
  border-radius: 12px;
  font-size: .8rem;
  font-weight: 600;
  backdrop-filter: blur(10px);
}
.category-indoor { background: linear-gradient(135deg, #8b5cf6, #a855f7); }
.category-greenhouse { background: linear-gradient(135deg, #10b981, #059669); }
.category-preroll { background: linear-gradient(135deg, #f59e0b, #d97706); }

/* ============= Section Titles ============= */
.section-title {
  font-size: 2.2rem;
  background: linear-gradient(135deg, #fff, #4ade80);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 2.5rem 0 1.5rem;
  text-align: center;
  font-weight: 800;
}

/* ============= Tabs ============= */
.tabs { display: flex; gap: .5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.tab {
  padding: .8rem 1.2rem;
  border-radius: 12px;
  border: 1px solid rgba(74, 222, 128, .3);
  background: rgba(255, 255, 255, .05);
  color: rgba(255, 255, 255, .7);
  cursor: pointer;
  transition: all .3s;
  backdrop-filter: blur(10px);
}
.tab.active {
  background: linear-gradient(135deg, #4ade80, #22d3ee);
  color: #0f1419;
  border-color: transparent;
}

/* ============= Transaction Table ============= */
.table { display: grid; gap: .75rem; }
.row {
  display: grid;
  grid-template-columns: 160px 1fr 110px;
  gap: 1rem;
  align-items: center;
  background: rgba(255, 255, 255, .03);
  border: 1px solid rgba(45, 74, 62, .2);
  border-radius: 16px;
  padding: 1rem 1.25rem;
  transition: all .3s;
}
.row:hover { background: rgba(255, 255, 255, .05); transform: translateX(4px); }
.amount.credit { color: #4ade80; font-weight: 700; }
.amount.debit { color: #f87171; font-weight: 700; }

/* ============= Forms ============= */
.form { display: grid; gap: 1.5rem; }
label { font-weight: 600; color: rgba(255, 255, 255, .9); }
input,
select {
  width: 100%;
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid rgba(45, 74, 62, .3);
  background: rgba(255, 255, 255, .05);
  color: #fff;
  backdrop-filter: blur(10px);
  transition: all .3s;
}
input:focus,
select:focus {
  outline: none;
  border-color: #4ade80;
  box-shadow: 0 0 0 3px rgba(74, 222, 128, .1);
}
input::placeholder { color: rgba(255, 255, 255, .5); }

/* ============= Notices & Payment ============= */
.notice {
  padding: 1.25rem;
  border-radius: 16px;
  background: rgba(251, 191, 36, .1);
  border: 1px solid rgba(251, 191, 36, .3);
  backdrop-filter: blur(10px);
}
.payment-method { border: 2px solid rgba(45, 74, 62, .3); transition: all .3s; cursor: pointer; }
.payment-method.selected { border-color: #4ade80; background: rgba(74, 222, 128, .05); }
.payment-method:hover { border-color: rgba(74, 222, 128, .6); }

/* ============= Chips ============= */
.chips { display: flex; gap: .75rem; flex-wrap: wrap; }
.chip {
  padding: .6rem 1rem;
  border: 1.5px solid rgba(74, 222, 128, .3);
  border-radius: 20px;
  cursor: pointer;
  user-select: none;
  transition: all .3s;
  background: rgba(255, 255, 255, .03);
  backdrop-filter: blur(10px);
}
.chip.selected {
  background: linear-gradient(135deg, #4ade80, #22d3ee);
  color: #0f1419;
  border-color: transparent;
}
.chip:hover { border-color: #4ade80; transform: translateY(-2px); }

/* ============= Utility ============= */
.muted { color: rgba(255, 255, 255, .6); }
.small { font-size: .9rem; }
.page { display: none; }
.page.active { display: block; }

/* ============= Chat ============= */
.chat { display: grid; gap: 1.5rem; }
.chat-box {
  height: 300px;
  overflow: auto;
  border: 1px solid rgba(45, 74, 62, .3);
  border-radius: 16px;
  background: rgba(255, 255, 255, .02);
  padding: 1.25rem;
  backdrop-filter: blur(10px);
}
.msg { margin: .5rem 0; padding: .5rem 0; }
.msg.you { font-weight: 700; color: #4ade80; }
.msg.bot { color: rgba(255, 255, 255, .8); }

/* ============= Loading / Spinner ============= */
.loading { opacity: .6; pointer-events: none; }
.spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, .3);
  border-top: 2px solid #4ade80;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* ============= Special Effects ============= */
.glass { background: rgba(255, 255, 255, .08); backdrop-filter: blur(20px); border: 1px solid rgba(255, 255, 255, .1); }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.floating { animation: float 6s ease-in-out infinite; }
.glow { box-shadow: 0 0 30px rgba(74, 222, 128, .2); }
.glow:hover { box-shadow: 0 0 50px rgba(74, 222, 128, .3); }

/* ============= Responsive ============= */
@media (max-width: 768px) {
  .header { padding: .75rem 1rem; flex-wrap: wrap; gap: .5rem; }
  .nav { order: 3; width: 100%; justify-content: center; margin-top: .5rem; }
  .main { padding: 1rem; }
  .hero h1 { font-size: 2.2rem; }
  .card { padding: 1.5rem; }
  .row { grid-template-columns: 1fr; text-align: center; }
  .product-meta { flex-direction: column; align-items: stretch; }
  .grid-4 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
}
