:root{
  --bg1:#070A1A; --bg2:#120C2E;
  --card: rgba(255,255,255,.06);
  --card2: rgba(255,255,255,.09);
  --text:#EAF0FF; --muted: rgba(234,240,255,.72);
  --line: rgba(255,255,255,.12);
  --accent:#B46CFF; --accent2:#4AC7FF;
  --shadow: 0 12px 30px rgba(0,0,0,.35);
  --radius: 18px;
}
html,body{height:100%;}
body{
  background: radial-gradient(1200px 600px at 20% 10%, rgba(180,108,255,.35), transparent 60%),
              radial-gradient(900px 450px at 85% 30%, rgba(74,199,255,.25), transparent 60%),
              linear-gradient(160deg,var(--bg1),var(--bg2));
  color:var(--text);
}
a{color:inherit;text-decoration:none}
a:hover{opacity:.9}
.navbar{
  backdrop-filter: blur(10px);
  background: rgba(10,10,22,.55)!important;
  border-bottom: 1px solid var(--line);
}
.brand-dot{
  display:inline-block;width:10px;height:10px;border-radius:50%;
  background: linear-gradient(135deg,var(--accent),var(--accent2));
  margin-right:.5rem; box-shadow: 0 0 16px rgba(180,108,255,.35);
}
.hero{
  border:1px solid var(--line);
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
}
.hero h1{font-weight:800;letter-spacing:.2px}
.hero p{color:var(--muted)}
.glass{
  border:1px solid var(--line);
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.cardx{padding:18px}

/*
  Bootstrap's `.h-100` is handy, but on pages using `.row` (flex) it can force cards
  to stretch to the tallest column and leave huge empty areas.
  We keep layouts natural by default.
*/
.glass.cardx.h-100{height:auto !important;}
.badge-soft{
  border:1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  border-radius: 999px;
  padding: .25rem .6rem;
  font-size: .78rem;
}
.btn-accent{
  background: linear-gradient(135deg,var(--accent),var(--accent2));
  border:0; color:#0b0b16; font-weight:700;
}
.btn-accent:hover{filter:brightness(1.05)}
.btn-ghost{
  border:1px solid var(--line);
  background: rgba(255,255,255,.06);
  color:var(--text);
}
.btn-ghost:hover{background: rgba(255,255,255,.09)}
.small-muted{color:var(--muted); font-size:.92rem}
hr{border-color:var(--line);opacity:1}
.table{color:var(--text);}
.table thead th{color:rgba(234,240,255,.86);border-bottom:1px solid var(--line);}
.table td,.table th{border-color:var(--line)}
.form-control,.form-select,textarea{
  background: rgba(255,255,255,.06)!important;
  border:1px solid var(--line)!important;
  color:var(--text)!important;
  border-radius: 14px!important;
}
.form-control::placeholder{color:rgba(234,240,255,.55)}
.form-label{color:rgba(234,240,255,.78)}
.alert{
  border:1px solid var(--line);
  border-radius: 16px;
  backdrop-filter: blur(10px);
}
.locked{position:relative;overflow:hidden;}
.locked::after{content:"";position:absolute; inset:0;backdrop-filter: blur(6px);background: rgba(0,0,0,.35);}
.locked .locked-overlay{position:absolute; inset:0;display:flex; align-items:center; justify-content:center; text-align:center;padding:16px; z-index:2;}
.locked .locked-overlay .box{border:1px solid var(--line);background: rgba(10,10,22,.65);border-radius: 16px;padding: 14px 16px;}
.watermark{
  pointer-events:none;position:fixed; inset:0;z-index:9999;opacity:.14;
  display:flex;align-items:center;justify-content:center;transform: rotate(-22deg);
  font-weight:800;letter-spacing:1px;font-size: clamp(24px, 4vw, 58px);
  text-transform: uppercase;color: rgba(255,255,255,.9);mix-blend-mode: overlay;
}

.pill{
  display:inline-flex; align-items:center; gap:10px;
  padding:8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: rgba(234,240,255,.86);
  font-size: .95rem;
}
.step{
  display:flex; gap:12px; align-items:flex-start;
  padding:12px 0;
  border-top: 1px solid rgba(255,255,255,.10);
}
.step:first-of-type{border-top:none;padding-top:0}
.step .n{
  width:32px; height:32px; border-radius: 12px;
  display:flex; align-items:center; justify-content:center;
  background: linear-gradient(135deg, rgba(180,108,255,.25), rgba(74,199,255,.18));
  border: 1px solid rgba(180,108,255,.25);
  color: rgba(234,240,255,.95);
  font-weight: 800;
}

@media print{ body{display:none!important} }

select option{background: var(--optionBg, #0b0b16)!important; color: var(--fieldText, var(--text))!important;}
.form-select,.form-control,textarea{background: var(--fieldBg)!important; color: var(--fieldText, var(--text))!important; border-color: var(--line)!important;}
.dropdown-menu{background: var(--optionBg, #0b0b16)!important; border:1px solid var(--line)!important;}
.dropdown-item{color: var(--fieldText, var(--text))!important;}
.dropdown-item:hover{background: rgba(255,255,255,.08)!important;}
input:-webkit-autofill,textarea:-webkit-autofill,select:-webkit-autofill{
  -webkit-text-fill-color: var(--fieldText, var(--text))!important;
  -webkit-box-shadow: 0 0 0px 1000px var(--fieldBg) inset!important;
  transition: background-color 9999s ease-in-out 0s;
}
/* NOTE: legacy chat styles removed (they conflicted with the new support chat bubble) */

/* PDF viewer */
.pdf-toolbar{
  display:flex; align-items:center; justify-content:space-between;
  gap:12px; padding:10px 12px; margin-bottom:10px;
  border:1px solid var(--line); border-radius:16px;
  background: rgba(255,255,255,.06);
  backdrop-filter: blur(10px);
}
.pdf-toolbar-left{ display:flex; align-items:center; gap:8px; }
.pdf-zoom-label{
  display:inline-flex; align-items:center; justify-content:center;
  min-width:64px; padding:6px 10px; border-radius:999px;
  border:1px solid var(--line);
  background: rgba(0,0,0,.22);
  color: rgba(234,240,255,.9);
  font-weight:700;
}
.pdf-canvas-wrap{
  height:72vh;
  overflow:auto;
  padding:12px;
  background: rgba(0,0,0,.25);
  border:1px solid var(--line);
  border-radius: 18px;
}
@media (max-width: 520px){
  .pdf-toolbar{ flex-wrap:wrap; }
  .pdf-toolbar-right{ width:100%; text-align:left; }
}

.border-accent{border:1px solid rgba(120,170,255,.9)!important; box-shadow:0 0 0 1px rgba(120,170,255,.35) inset;}


/* Support chat bubble */
.chat-fab{
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.10);
  backdrop-filter: blur(12px);
  color: rgba(240,246,255,.95);
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow: 0 18px 45px rgba(0,0,0,.35);
  z-index: 9999;
  cursor:pointer;
}
.chat-fab:hover{ transform: translateY(-1px); }
.chat-panel{
  position: fixed;
  right: 18px;
  bottom: 86px;
  width: min(420px, calc(100vw - 36px));
  height: min(560px, calc(100vh - 140px));
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(12,16,28,.78);
  backdrop-filter: blur(16px);
  box-shadow: 0 28px 80px rgba(0,0,0,.50);
  z-index: 9999;
  display:none;
  overflow:hidden;
}
.chat-panel.open{ display:flex; flex-direction:column; }
.chat-head{
  display:flex; align-items:center; justify-content:space-between;
  padding: 12px 12px;
  border-bottom: 1px solid rgba(255,255,255,.10);
}
.chat-title{ display:flex; align-items:center; gap:10px; }
.chat-dot{
  width:10px; height:10px; border-radius:999px;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(90,120,255,.15);
}
.chat-close{
  width:36px; height:36px; border-radius:10px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: rgba(240,246,255,.95);
}

.chat-head-link{
  width:36px; height:36px; border-radius:10px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: rgba(240,246,255,.95);
  display:flex; align-items:center; justify-content:center;
  text-decoration:none;
}
.chat-tools{
  display:flex; align-items:center; justify-content:space-between;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.03);
}
.chat-more{
  border:1px solid rgba(255,255,255,.14);
  background: rgba(0,0,0,.22);
  color: rgba(240,246,255,.95);
  border-radius: 12px;
  padding: 6px 10px;
  font-size: 12px;
}
.chat-link{
  font-size: 12px;
  opacity: .85;
  text-decoration:none;
  color: rgba(240,246,255,.95);
}
.chat-link:hover{ opacity: 1; text-decoration: underline; }
.chat-body{ flex:1; overflow:auto; padding: 12px; }
.chat-msgs{ display:flex; flex-direction:column; gap:10px; }
.chat-bubble{
  max-width: 85%;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.06);
}
.chat-bubble.you{ align-self:flex-end; background: rgba(90,120,255,.18); }
.chat-meta{ font-size:12px; opacity:.75; margin-bottom:4px; }
.chat-form{
  display:flex; gap:10px;
  padding: 10px 10px;
  border-top: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.04);
}
.chat-input{
  flex:1;
  border-radius: 12px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(0,0,0,.25);
  color: rgba(240,246,255,.95);
  padding: 10px 12px;
  outline:none;
}
.chat-send{
  width:44px; height:44px;
  border-radius: 12px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(90,120,255,.22);
  color: rgba(240,246,255,.95);
}

/* Styled file picker (subscribe.php proof upload) */
.filepick{
  display:flex;
  align-items:center;
  gap:12px;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px dashed rgba(255,255,255,.18);
  background: rgba(0,0,0,.22);
}
.filepick-input{
  position:absolute;
  left:-9999px;
  width:1px;
  height:1px;
  overflow:hidden;
}
.filepick-btn{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(90,120,255,.22);
  color: rgba(240,246,255,.95);
  cursor:pointer;
  user-select:none;
  white-space:nowrap;
}
.filepick-btn:hover{ filter: brightness(1.05); }
.filepick-name{
  flex:1;
  min-width: 0;
  font-size: 14px;
  color: rgba(240,246,255,.90);
  overflow:hidden;
  text-overflow: ellipsis;
  white-space:nowrap;
}
