:root{
  --bg:#0f1115;
  --panel:#161a22;
  --panel2:#1c2230;
  --line:rgba(255,255,255,.08);

  --text:rgba(229,231,235,.96);
  --muted:rgba(156,163,175,.78);

  --brand:#22c55e;
  --brand2:#16a34a;

  --good:#22c55e;
  --warn:#fbbf24;
  --bad:#fb7185;

  --shadow:0 18px 60px rgba(0,0,0,.45);
  --radius:18px;
}

*{box-sizing:border-box}

html,body{
  width:100%;
  overflow-x:hidden;
}

body{
  margin:0;
  font-family:ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;
  color:var(--text);
  background:
    radial-gradient(900px 500px at 20% -10%, rgba(34,197,94,.14), transparent 60%),
    radial-gradient(800px 500px at 80% 0%, rgba(22,163,74,.10), transparent 55%),
    linear-gradient(180deg, #070a0d, var(--bg));
}

a{
  color:var(--text);
  text-decoration:none;
}

a:hover{
  opacity:.94;
}

img{
  max-width:100%;
  height:auto;
  display:block;
}

.wrap{
  width:min(1100px,92%);
  margin:0 auto;
}

/* =========================
   HEADER / NAV
   ========================= */
.site-header{
  background:rgba(15,17,21,.78);
  backdrop-filter:blur(10px);
  border-bottom:1px solid var(--line);
  position:sticky;
  top:0;
  z-index:50;
}

.nav-row{
  min-height:72px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:12px 0;
  position:relative;
}

.brand{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight:900;
  font-size:22px;
  color:var(--brand2);
  line-height:1; 
}

.brand img{
  height:50px;
  width:auto;
  display:block;
}

.nav-links{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  justify-content:flex-end;
}

.nav-links a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:10px 14px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(255,255,255,.05);
  color:var(--text);
  text-decoration:none;
  transition:background .15s ease,border-color .15s ease,transform .08s ease;
}

.nav-links a:hover{
  background:rgba(255,255,255,.09);
  border-color:rgba(255,255,255,.18);
}

.nav-links a:active{
  transform:translateY(1px);
}

.nav-cta{
  background:linear-gradient(135deg,var(--brand),var(--brand2)) !important;
  color:#03120a !important;
  border-color:transparent !important;
  font-weight:900;
}

.menu-toggle{
  display:none;
  width:46px;
  height:46px;
  border:none;
  border-radius:14px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  cursor:pointer;
  padding:0;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  gap:5px;
}

.menu-toggle span{
  display:block;
  width:20px;
  height:2px;
  background:var(--text);
  border-radius:99px;
  transition:.2s ease;
}

.menu-toggle.is-open span:nth-child(1){
  transform:translateY(7px) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2){
  opacity:0;
}

.menu-toggle.is-open span:nth-child(3){
  transform:translateY(-7px) rotate(-45deg);
}

/* =========================
   MAIN / FOOTER
   ========================= */
.site-main{
  min-height:calc(100vh - 140px);
}

.page-wrap{
  padding:28px 0 54px;
}

.site-footer{
  border-top:1px solid var(--line);
  background:rgba(15,17,21,.9);
  padding:20px 0;
}

.footer-row{
  display:flex;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
}

.footer-links{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}

/* =========================
   HERO
   ========================= */
.hero{
  padding:24px 0 10px;
}

.hero h1{
  font-size:clamp(30px, 5vw, 46px);
  line-height:1.08;
  margin:0 0 14px;
}

.hero p{
  color:var(--muted);
  max-width:760px;
  line-height:1.7;
  font-size:16px;
}

/* =========================
   BUTTONS
   ========================= */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:44px;
  padding:11px 16px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(255,255,255,.06);
  color:var(--text);
  cursor:pointer;
  font-weight:800;
  transition:transform .08s ease, background .15s ease, border-color .15s ease;
}

.btn:hover{
  background:rgba(255,255,255,.10);
  border-color:rgba(255,255,255,.18);
}

.btn:active{
  transform:translateY(1px);
}

.btn.secondary{
  background:rgba(255,255,255,.04);
  color:var(--text);
}

.btn.small{
  min-height:36px;
  padding:8px 12px;
  font-size:14px;
}

.btn:not(.secondary){
  background:linear-gradient(135deg,var(--brand),var(--brand2));
  color:#03120a;
  border-color:transparent;
}

/* =========================
   GRID / CARDS
   ========================= */
.grid{
  display:grid;
  gap:18px;
}

.grid-3{
  grid-template-columns:repeat(3,minmax(0,1fr));
}

.grid-2{
  grid-template-columns:repeat(2,minmax(0,1fr));
}

.card{
  background:linear-gradient(180deg, rgba(22,26,34,.78), rgba(18,22,30,.82));
  border:1px solid var(--line);
  border-radius:var(--radius);
  padding:18px;
  box-shadow:var(--shadow);
  min-width:0;
}

.muted{
  color:var(--muted);
}

/* =========================
   BADGES
   ========================= */
.badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:7px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  margin-right:8px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(255,255,255,.05);
  color:var(--text);
}

.badge.spotlight{
  border-color:rgba(251,191,36,.35);
  background:rgba(251,191,36,.12);
  color:var(--text);
}

.badge.search{
  border-color:rgba(34,197,94,.35);
  background:rgba(34,197,94,.12);
  color:var(--text);
}

/* =========================
   FORMS
   ========================= */
form label{
  display:block;
  margin:14px 0 8px;
  font-weight:800;
  color:var(--text);
}

input,textarea,select{
  width:100%;
  min-width:0;
  padding:12px 14px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(6,10,20,.55);
  color:var(--text);
  outline:none;
  font:inherit;
}

input:focus,textarea:focus,select:focus{
  border-color:rgba(34,197,94,.55);
  box-shadow:0 0 0 4px rgba(34,197,94,.18);
}

textarea{
  min-height:110px;
  resize:vertical;
}

.form-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:16px;
}

/* =========================
   NOTICES
   ========================= */
.notice{
  padding:14px 16px;
  border-radius:14px;
  margin-bottom:16px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(0,0,0,.18);
}

.notice.success{
  border-color:rgba(34,197,94,.35);
  background:rgba(34,197,94,.10);
  color:#d8ffea;
}

.notice.error{
  border-color:rgba(251,113,133,.35);
  background:rgba(251,113,133,.10);
  color:#ffe0e5;
}

/* =========================
   PROFILE
   ========================= */
.profile-hero{
  display:grid;
  grid-template-columns:130px 1fr;
  gap:22px;
  align-items:center;
}

.avatar{
  width:130px;
  height:130px;
  min-width:130px;
  min-height:130px;
  border-radius:50%;
  object-fit:cover;
  border:3px solid rgba(255,255,255,.12);
  background:#0e1530;
  display:block;
}

.link-list{
  display:grid;
  gap:12px;
  margin-top:18px;
}

.link-btn{
  display:block;
  text-align:center;
  background:rgba(255,255,255,.05);
  color:var(--text);
  padding:14px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.10);
  font-weight:800;
  transition:.18s ease;
}

.link-btn:hover{
  border-color:rgba(34,197,94,.35);
  background:rgba(34,197,94,.10);
}

/* =========================
   TEXT / STATS / HELPERS
   ========================= */
.section-title{
  margin:0 0 14px;
}

.stat{
  font-size:28px;
  font-weight:900;
  line-height:1.1;
}

.inline-actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.inline-actions .btn{
  flex:0 0 auto;
}

.top-space{
  margin-top:20px;
}

.hp-field{
  position:absolute;
  left:-9999px;
  width:1px;
  height:1px;
  overflow:hidden;
}

.text-danger{
  color:#ff9aa8;
}

.text-success{
  color:#9ff2bf;
}

textarea[disabled],button[disabled],input[disabled],select[disabled]{
  opacity:.6;
  cursor:not-allowed;
}

.payment-choice.disabled{
  opacity:.5;
  pointer-events:none;
}

.security-code{
  display:inline-flex;
  align-items:center;
  padding:10px 14px;
  border-radius:14px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.10);
  font-weight:900;
  letter-spacing:.5px;
  word-break:break-word;
}

/* =========================
   TABLES
   ========================= */
.table-wrap{
  width:100%;
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
  border-radius:14px;
}

table{
  width:100%;
  min-width:640px;
  border-collapse:collapse;
}

th,td{
  padding:12px;
  border-bottom:1px solid rgba(255,255,255,.08);
  text-align:left;
  vertical-align:top;
}

th{
  color:var(--text);
  font-size:14px;
}

td{
  color:var(--muted);
  font-size:14px;
}

/* =========================
   EXPLORE / Q&A
   ========================= */
.explore-card{
  display:flex;
  gap:14px;
  align-items:center;
  min-width:0;
}

.explore-card .mini-avatar{
  width:60px;
  height:60px;
  min-width:60px;
  min-height:60px;
  border-radius:50%;
  object-fit:cover;
  flex:0 0 auto;
  display:block;
}

.q-item{
  padding:14px;
  border-radius:14px;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.08);
  margin-bottom:12px;
}

/* =========================
   HOMEPAGE MINI CREATOR CARDS
   ========================= */
.creator-mini-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(170px,1fr));
  gap:14px;
}

.creator-mini-card{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:10px;
  padding:16px 14px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.08);
  background:linear-gradient(180deg, rgba(22,26,34,.78), rgba(18,22,30,.82));
  box-shadow:var(--shadow);
  transition:.18s ease;
  text-decoration:none;
  color:var(--text);
  min-height:180px;
}

.creator-mini-card:hover{
  transform:translateY(-2px);
  border-color:rgba(34,197,94,.35);
  background:rgba(34,197,94,.08);
}

.creator-mini-avatar{
  width:60px !important;
  height:60px !important;
  min-width:60px !important;
  min-height:60px !important;
  max-width:60px !important;
  max-height:60px !important;
  border-radius:50% !important;
  object-fit:cover !important;
  border:2px solid rgba(255,255,255,.12);
  background:#0e1530;
  display:block;
  flex:0 0 auto;
}

.creator-mini-name{
  font-weight:800;
  font-size:14px;
  line-height:1.3;
  word-break:break-word;
  text-align:center;
}

.creator-mini-card .badge{
  font-size:11px;
  padding:5px 8px;
  margin-right:0;
}

.badge.warn{
  border-color:rgba(251,191,36,.35);
  background:rgba(251,191,36,.12);
  color:var(--text);
}

.credit-pack-list{
  display:flex;
  flex-direction:column;
  gap:14px;
}

.credit-pack-item{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:14px;
  border:1px solid rgba(255,255,255,.10);
  border-radius:16px;
  background:rgba(255,255,255,.04);
}

.credit-pack-left{
  min-width:0;
  flex:1;
}

.credit-pack-left .title{
  font-weight:900;
}

.credit-pack-left .sub{
  margin-top:6px;
  font-size:13px;
  color:var(--muted);
}

.credit-pack-form{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  flex:0 0 auto;
}

.provider-select{
  width:auto !important;
  min-width:145px;
  max-width:180px;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(255,255,255,.05);
  color:var(--text);
  outline:none;
}

.provider-select:focus{
  border-color:rgba(34,197,94,.55);
  box-shadow:0 0 0 4px rgba(34,197,94,.18);
}

.payment-choice.disabled{
  opacity:.5;
  pointer-events:none;
}

.payment-choice.coming-soon{
  opacity:.5;
  pointer-events:auto;
}

@media (max-width:640px){
  .credit-pack-item{
    flex-direction:column;
    align-items:flex-start;
  }

  .credit-pack-form{
    width:100%;
    justify-content:flex-start;
  }

  .provider-select{
    min-width:140px;
  }
}
/* =========================
   MOBILE
   ========================= */
@media (max-width: 980px){
  .grid-3{
    grid-template-columns:1fr 1fr;
  }
}

@media (max-width: 860px){
  .grid-3,
  .grid-2,
  .form-row{
    grid-template-columns:1fr;
  }

  .profile-hero{
    grid-template-columns:1fr;
    text-align:center;
  }

  .avatar{
    margin:0 auto;
  }

  .hero{
    padding-top:12px;
  }

  .page-wrap{
    padding:20px 0 42px;
  }

  .card{
    padding:16px;
    border-radius:16px;
  }

  .menu-toggle{
    display:flex;
  }

  .nav-links{
    display:none;
    width:100%;
    flex-direction:column;
    align-items:stretch;
    gap:10px;
    padding-top:12px;
  }

  .nav-links.is-open{
    display:flex;
  }

  .nav-links a{
    width:100%;
    justify-content:center;
  }

  .nav-row{
    align-items:center;
    flex-wrap:wrap;
  }
}

@media (max-width: 640px){
  .wrap{
    width:min(100%, 100%);
    padding-left:14px;
    padding-right:14px;
  }

  .brand{
    font-size:20px;
  }

  .hero h1{
    font-size:30px;
  }

  .hero p{
    font-size:15px;
  }

  .inline-actions{
    flex-direction:column;
    align-items:stretch;
  }

  .inline-actions .btn{
    width:100%;
  }

  .stat{
    font-size:24px;
  }

  .section-title{
    font-size:22px;
  }

  input,textarea,select,.btn{
    font-size:16px;
  }

  .explore-card{
    align-items:flex-start;
  }

  .explore-card .mini-avatar{
    width:52px;
    height:52px;
    min-width:52px;
    min-height:52px;
  }

  .notice{
    padding:12px 14px;
  }

  .q-item{
    padding:12px;
  }

  .creator-mini-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .creator-mini-card{
    min-height:160px;
    padding:14px 12px;
  }

  .creator-mini-avatar{
    width:54px !important;
    height:54px !important;
    min-width:54px !important;
    min-height:54px !important;
    max-width:54px !important;
    max-height:54px !important;
  }

  .creator-mini-name{
    font-size:13px;
  }
}

@media (max-width: 460px){
  .brand{
    font-size:18px;
  }

  .hero h1{
    font-size:27px;
  }

  .card{
    padding:14px;
  }

  .profile-hero{
    gap:14px;
  }

  .avatar{
    width:110px;
    height:110px;
    min-width:110px;
    min-height:110px;
  }

  th,td{
    padding:10px;
  }
}

@media (max-width: 420px){
  .creator-mini-grid{
    grid-template-columns:1fr 1fr;
    gap:12px;
  }

  .creator-mini-card{
    min-height:150px;
    padding:12px 10px;
  }

  .creator-mini-avatar{
    width:50px !important;
    height:50px !important;
    min-width:50px !important;
    min-height:50px !important;
    max-width:50px !important;
    max-height:50px !important;
  }
}