:root {
  --bg: #050d24;
  --bg-2: #0a1a3f;
  --card: rgba(18, 40, 92, 0.55);
  --card-solid: #0f2557;
  --border: rgba(110, 160, 255, 0.18);
  --text: #eaf1ff;
  --muted: #8ea6d6;
  --blue: #2f7bff;
  --blue-2: #1fb6ff;
  --blue-deep: #1450d8;
  --green: #22d39a;
  --amber: #ffbe46;
  --red: #ff5a72;
  --radius: 20px;
  --font: "Noto Sans Lao", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --num: "Inter", "Noto Sans Lao", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  background: radial-gradient(1200px 600px at 10% -10%, #123a8c 0%, transparent 60%),
              radial-gradient(900px 500px at 110% 10%, #0b5fb8 0%, transparent 55%),
              linear-gradient(180deg, var(--bg-2), var(--bg));
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  display: flex; flex-direction: column;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
.bg-grid {
  position: fixed; inset: 0; pointer-events: none; z-index: -1;
  background-image: linear-gradient(rgba(120,170,255,.05) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(120,170,255,.05) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse at top, #000 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at top, #000 20%, transparent 70%);
}
.hidden { display: none !important; }
a { color: var(--blue-2); }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
code, .mono { font-family: ui-monospace, Consolas, monospace; font-size: .88em; }
code { background: rgba(255,255,255,.08); padding: 1px 6px; border-radius: 6px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.num { font-family: var(--num); }
h1, h2, h3 { line-height: 1.3; }

.glass {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 20px 50px -20px rgba(0, 10, 40, .7);
}
.brand { font-family: "Inter", var(--font); font-weight: 800; letter-spacing: .5px; }
.brand span, .grad {
  background: linear-gradient(90deg, var(--blue-2), var(--blue));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 14px; padding: 11px 18px;
  font: 600 15px var(--font); color: var(--text); cursor: pointer;
  transition: transform .15s, box-shadow .2s, background .2s;
  text-decoration: none; white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: linear-gradient(135deg, var(--blue-2), var(--blue) 50%, var(--blue-deep)); box-shadow: 0 10px 25px -8px rgba(47,123,255,.7); color: #fff; }
.btn.primary:hover { box-shadow: 0 12px 30px -6px rgba(47,123,255,.95); }
.btn.ghost { background: rgba(120,170,255,.12); border: 1px solid var(--border); }
.btn.ghost:hover { background: rgba(120,170,255,.2); }
.btn.success { background: linear-gradient(135deg, #2ee6a8, #12a877); color: #032318; }
.btn.danger { background: rgba(255,90,114,.15); color: #ffb3bf; border: 1px solid rgba(255,90,114,.3); }
.btn.sm { padding: 7px 12px; font-size: 13px; border-radius: 10px; }
.btn.lg { padding: 14px 26px; font-size: 17px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.icon-btn {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  border-radius: 12px; border: 1px solid var(--border);
  background: rgba(120,170,255,.1); color: var(--text); cursor: pointer;
}
.icon-btn:hover { background: rgba(120,170,255,.22); }

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 20px 10px;
  background: rgba(5, 13, 36, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.logo { display: flex; align-items: center; gap: 10px; font-size: 21px; color: var(--text); text-decoration: none; }
.logo img { width: 34px; height: 34px; }
.nav { display: flex; align-items: center; gap: 6px; }
.nav a.link { color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: 10px; font-weight: 500; font-size: 15px; }
.nav a.link:hover, .nav a.link.active { color: var(--text); background: rgba(120,170,255,.1); }

.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 24px 16px 48px; flex: 1; }
.banner { max-width: 1100px; margin: 14px auto 0; width: calc(100% - 32px); padding: 10px 16px; border-radius: 14px; font-size: 14px; background: rgba(255,190,70,.12); border: 1px solid rgba(255,190,70,.35); color: #ffd98a; }
.footer { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; padding: 22px 16px calc(22px + env(safe-area-inset-bottom)); border-top: 1px solid var(--border); font-size: 13px; }

/* Landing */
.hero { text-align: center; padding: 40px 0 30px; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; background: rgba(47,123,255,.15); border: 1px solid var(--border); color: #bcd3ff; font-size: 13px; font-weight: 500; }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
.hero h1 { font-size: clamp(32px, 6vw, 56px); margin: 18px 0 12px; font-weight: 700; }
.hero p.lead { font-size: clamp(16px, 2.2vw, 19px); color: #bcd0f5; max-width: 640px; margin: 0 auto 26px; }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.shield-big { width: 120px; height: 120px; margin: 0 auto; position: relative; }
.shield-big .core { position: relative; z-index: 1; width: 100%; height: 100%; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, var(--blue-2), var(--blue-deep)); box-shadow: 0 0 0 8px rgba(47,123,255,.15), 0 20px 45px -10px rgba(47,123,255,.9); }
.shield-big svg { width: 58px; height: 58px; stroke: #fff; stroke-width: 1.8; }
.hero-logo { position: relative; width: 150px; height: 150px; margin: 0 auto; }
.hero-logo img { position: relative; z-index: 1; width: 100%; height: 100%; border-radius: 34px; filter: drop-shadow(0 20px 40px rgba(47,123,255,.7)); animation: float 4s ease-in-out infinite; }
.hero-logo .pulse { border-radius: 40px; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.pulse { position: absolute; inset: 0; border-radius: 50%; background: rgba(47,123,255,.35); animation: pulse 2.4s ease-out infinite; }
@keyframes pulse { 0% { transform: scale(1); opacity: .8; } 100% { transform: scale(1.8); opacity: 0; } }

.section { margin-top: 56px; }
.section-title { text-align: center; margin-bottom: 26px; }
.section-title h2 { font-size: clamp(24px, 4vw, 32px); margin: 0 0 6px; }
.section-title p { margin: 0; color: var(--muted); }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 14px; }
@media (min-width: 640px) and (max-width: 979px) { .features { grid-template-columns: 1fr 1fr; } }
.feature { padding: 22px; }
.feature .ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(135deg, var(--blue-2), var(--blue-deep)); margin-bottom: 12px; }
.feature .ic svg { width: 24px; height: 24px; stroke: #fff; }
.feature h3 { margin: 0 0 6px; font-size: 17px; }
.feature p { margin: 0; color: var(--muted); font-size: 14px; }

.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.plan { padding: 26px 22px; display: flex; flex-direction: column; position: relative; transition: transform .2s, border-color .2s; }
.plan:hover { transform: translateY(-4px); border-color: rgba(110,160,255,.45); }
.plan.featured { border-color: rgba(47,123,255,.7); box-shadow: 0 0 0 1px rgba(47,123,255,.5), 0 25px 60px -20px rgba(47,123,255,.6); }
.plan .tag { position: absolute; top: -12px; right: 18px; background: linear-gradient(135deg, var(--blue-2), var(--blue)); color: #fff; font-size: 12px; font-weight: 600; padding: 3px 12px; border-radius: 99px; }
.plan h3 { margin: 0; font-size: 20px; }
.price { margin: 10px 0 16px; font-family: var(--num); font-size: 34px; font-weight: 800; }
.price small { font-size: 15px; color: var(--muted); font-weight: 500; }
.plan ul { list-style: none; padding: 0; margin: 0 0 22px; flex: 1; }
.plan li { display: flex; gap: 10px; align-items: center; padding: 5px 0; color: #c7d6f5; font-size: 15px; }
.plan li svg { color: var(--green); width: 18px; height: 18px; }

/* Auth */
.auth { max-width: 420px; margin: 20px auto; padding: 32px 26px; }
.auth h2 { margin: 0 0 4px; text-align: center; }
.auth > p { text-align: center; margin: 0 0 22px; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--border); background: rgba(4, 12, 34, .6);
  color: var(--text); font: 16px var(--font); outline: none; transition: border .2s, box-shadow .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(47,123,255,.2); }
.field select option { background: var(--card-solid); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.error { color: var(--red); min-height: 20px; font-size: 14px; margin: 0 0 10px; }
.switch-auth { text-align: center; margin-top: 16px; font-size: 14px; color: var(--muted); }

/* Account */
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.page-head h2 { margin: 0; font-size: 26px; }
.subs { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.sub { padding: 20px; display: flex; flex-direction: column; gap: 14px; animation: rise .35s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.sub-top { display: flex; align-items: center; gap: 12px; }
.avatar { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(135deg, rgba(31,182,255,.3), rgba(20,80,216,.45)); border: 1px solid var(--border); }
.sub-top h3 { margin: 0; font-size: 18px; }
.sub-top p { margin: 0; font-size: 13px; color: var(--muted); }
.sub-top .grow { flex: 1; min-width: 0; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge.active, .badge.paid { color: var(--green); background: rgba(34,211,154,.12); }
.badge.expired, .badge.limit, .badge.rejected, .badge.disabled { color: var(--red); background: rgba(255,90,114,.12); }
.badge.pending, .badge.review, .badge.processing { color: var(--amber); background: rgba(255,190,70,.12); }
.badge.cancelled { color: var(--muted); background: rgba(142,166,214,.12); }
.usage-head { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.usage-head b { color: var(--text); font-family: var(--num); }
.bar { height: 9px; border-radius: 99px; background: rgba(4,12,34,.6); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--blue-2), var(--blue)); transition: width .6s; }
.bar.warn > i { background: linear-gradient(90deg, var(--amber), #ff8a3d); }
.meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.meta { background: rgba(4,12,34,.45); border-radius: 12px; padding: 8px 12px; font-size: 12px; color: var(--muted); }
.meta b { display: block; color: var(--text); font-size: 14px; font-family: var(--num); font-weight: 600; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.actions .btn { flex: 1; }

.empty { text-align: center; padding: 40px 20px; }
.empty svg { width: 48px; height: 48px; color: var(--blue-2); }
.empty h3 { margin: 10px 0 6px; }
.empty p { margin: 0 0 18px; }

/* Tables / lists */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--muted); font-weight: 500; font-size: 13px; padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
td { padding: 12px; border-bottom: 1px solid rgba(110,160,255,.08); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
td .btn + .btn { margin-left: 6px; }
.card-pad { padding: 8px 6px; }

/* Checkout */
.checkout { display: grid; grid-template-columns: 1.1fr 1fr; gap: 18px; align-items: start; }
.pay-box { padding: 24px; }
.pay-box h3 { margin: 0 0 14px; }
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed rgba(110,160,255,.18); font-size: 15px; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }
.kv b { text-align: right; font-family: var(--num); }
.amount { font-size: 30px; font-weight: 800; font-family: var(--num); }
.code-box { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-radius: 14px; background: rgba(47,123,255,.12); border: 1px dashed rgba(47,123,255,.6); margin: 12px 0; }
.code-box b { font-family: var(--num); font-size: 22px; letter-spacing: 2px; }
.payqr { background: #fff; border-radius: 18px; padding: 12px; max-width: 280px; margin: 0 auto 14px; }
.payqr img { width: 100%; display: block; border-radius: 8px; }
.steps { margin: 0; padding-left: 20px; color: #c7d6f5; font-size: 14px; line-height: 2; }
.drop { display: grid; place-items: center; gap: 6px; text-align: center; padding: 26px 16px; border-radius: 16px; border: 2px dashed var(--border); cursor: pointer; transition: border-color .2s, background .2s; color: var(--muted); }
.drop:hover, .drop.over { border-color: var(--blue); background: rgba(47,123,255,.08); }
.drop svg { width: 34px; height: 34px; color: var(--blue-2); }
.drop img { max-width: 100%; max-height: 240px; border-radius: 10px; }
.status-big { text-align: center; padding: 28px 20px; }
.status-big .ring { width: 74px; height: 74px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; }
.status-big .ring svg { width: 36px; height: 36px; }
.ring.wait { background: rgba(255,190,70,.15); color: var(--amber); }
.ring.ok { background: rgba(34,211,154,.15); color: var(--green); }
.ring.bad { background: rgba(255,90,114,.15); color: var(--red); }
.spin { animation: spin 1.4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Guide */
.apps { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 14px; }
.app-card { padding: 22px; }
.app-card h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; }
.app-card h3 .ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(135deg, var(--blue-2), var(--blue-deep)); }
.app-card h3 .ic svg { stroke: #fff; }
.app-card ol { margin: 0 0 14px; padding-left: 20px; color: #c7d6f5; font-size: 14px; line-height: 1.9; }
.app-links { display: flex; flex-wrap: wrap; gap: 8px; }
.note { margin-top: 14px; padding: 14px 18px; font-size: 14px; color: #c7d6f5; }

/* Admin */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 18px; }
.tile { padding: 16px 18px; }
.tile span { font-size: 13px; color: var(--muted); }
.tile b { display: block; font-family: var(--num); font-size: 24px; margin-top: 2px; }
.tabs { display: flex; gap: 6px; padding: 5px; background: rgba(4,12,34,.5); border: 1px solid var(--border); border-radius: 16px; margin-bottom: 16px; overflow-x: auto; }
.tab { border: 0; background: none; color: var(--muted); font: 600 14px var(--font); padding: 9px 16px; border-radius: 12px; cursor: pointer; white-space: nowrap; }
.tab.active { background: linear-gradient(135deg, var(--blue), var(--blue-deep)); color: #fff; }
.slip-thumb { width: 46px; height: 46px; object-fit: cover; border-radius: 8px; cursor: zoom-in; border: 1px solid var(--border); }
.slip-full { width: 100%; border-radius: 12px; }
.count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--red); color: #fff; font-size: 12px; margin-left: 6px; }

/* Switch */
.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex-shrink: 0; vertical-align: middle; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; inset: 0; cursor: pointer; border-radius: 26px; background: #34405e; transition: .25s; }
.slider::before { content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: .25s; }
.switch input:checked + .slider { background: linear-gradient(135deg, var(--blue-2), var(--blue)); }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* Modal */
.modal { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; background: rgba(2,6,20,.72); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: fade .2s; }
@keyframes fade { from { opacity: 0; } }
.modal-card { position: relative; width: 100%; max-width: 440px; padding: 26px 22px 22px; max-height: 92vh; overflow: auto; animation: rise .25s ease; background: #0d1e48; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.modal-close { position: absolute; top: 14px; right: 14px; }
.modal-card h3 { margin: 0 0 6px; font-size: 20px; padding-right: 44px; }
.modal-card > div > p.muted { margin: 0 0 16px; font-size: 14px; }
.modal-actions { display: flex; gap: 10px; margin-top: 10px; }
.modal-actions .btn { flex: 1; }
.qr { background: #fff; border-radius: 18px; padding: 14px; margin: 0 auto 14px; max-width: 280px; }
.qr img { width: 100%; display: block; }
.seg { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: rgba(4,12,34,.6); margin-bottom: 14px; }
.seg button { flex: 1; border: 0; background: none; color: var(--muted); font: 600 13px var(--font); padding: 8px; border-radius: 9px; cursor: pointer; }
.seg button.active { background: var(--blue); color: #fff; }
.copy-line { display: flex; gap: 8px; align-items: center; background: rgba(4,12,34,.6); border: 1px solid var(--border); border-radius: 12px; padding: 6px 6px 6px 12px; margin-bottom: 10px; }
.copy-line code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: none; padding: 0; color: #bcd3ff; }

.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translate(-50%, 30px); opacity: 0; pointer-events: none; z-index: 60; padding: 12px 20px; border-radius: 14px; background: #10275e; border: 1px solid var(--border); box-shadow: 0 10px 30px rgba(0,0,0,.4); font-size: 14px; transition: all .3s; max-width: calc(100% - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: #4a1426; border-color: rgba(255,90,114,.4); }

.loading { display: grid; place-items: center; padding: 60px 0; color: var(--muted); }

@media (max-width: 760px) {
  .checkout { grid-template-columns: 1fr; }
  .nav a.link.hide-sm { display: none; }
}
@media (max-width: 560px) {
  .topbar { padding-left: 14px; padding-right: 14px; }
  .logo { font-size: 18px; }
  .logo img { width: 30px; height: 30px; }
  .nav a.link { padding: 7px 8px; font-size: 14px; }
  .subs { grid-template-columns: 1fr; }
  .row2 { grid-template-columns: 1fr; }
  .hero { padding-top: 24px; }
}

/* ============================================================
   Mobile app screens (after login): Home / Speed Test / Servers
   ============================================================ */
body.app-mode {
  --violet: #6c5cff;
  --violet-2: #8b7dff;
  background:
    radial-gradient(700px 420px at 50% 0%, rgba(108,92,255,.55), transparent 70%),
    linear-gradient(180deg, #2c1f9c 0%, #1e1670 45%, #140e4d 100%);
  background-attachment: fixed;
}
body.app-mode .topbar, body.app-mode .footer, body.app-mode .bg-grid { display: none; }
body.app-mode .banner { margin-top: calc(10px + env(safe-area-inset-top)); }
body.app-mode .container { max-width: 480px; padding: 0 0 110px; }
body.app-mode .glass { background: rgba(255,255,255,.07); border-color: rgba(190,180,255,.18); }
body.app-mode .btn.primary { background: linear-gradient(135deg, var(--violet-2), var(--violet) 55%, #4b3bdb); box-shadow: 0 12px 28px -10px rgba(108,92,255,.9); }
body.app-mode .bar > i { background: linear-gradient(90deg, #a99cff, var(--violet)); }
body.app-mode .page-head, body.app-mode .subs, body.app-mode .empty, body.app-mode .section, body.app-mode .note, body.app-mode .checkout { margin-left: 18px; margin-right: 18px; }
body.app-mode .page-head { padding-top: calc(18px + env(safe-area-inset-top)); }
body.app-mode .subs, body.app-mode .checkout { grid-template-columns: 1fr; }
body.app-mode .modal-card { background: #241a7a; }

.m-shell { padding: calc(14px + env(safe-area-inset-top)) 20px 0; min-height: 100vh; position: relative; }
.m-home::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 560px; pointer-events: none; opacity: .5;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='320' height='260'%3E%3Cg stroke='%238b7dff' stroke-width='3' stroke-linecap='round' opacity='.35'%3E%3Cpath d='M20 60l60-34M150 40l70-40M250 70l50-28M10 170l40-22M90 140l80-46M230 160l60-34M40 240l70-40M180 230l50-28'/%3E%3C/g%3E%3C/svg%3E");
}
.m-top, .m-head { position: relative; display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.m-head h2 { margin: 0; font-size: 19px; font-weight: 500; }
.m-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: #fff; background: rgba(255,255,255,.08); text-decoration: none; }
.m-icon svg { width: 24px; height: 24px; }
.m-top .m-icon { background: none; width: auto; }
.m-top .m-icon svg { width: 34px; height: 34px; stroke-width: 1.8; }
.m-premium { display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; border-radius: 99px; color: #fff; text-decoration: none; font-weight: 600; font-size: 15px;
  background: linear-gradient(135deg, #7d6dff, #5b49f0); box-shadow: 0 10px 25px -8px rgba(108,92,255,.9); max-width: 66%; }
.m-premium span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-premium svg { color: #ffc93c; width: 18px; height: 18px; }

.m-label { position: relative; text-align: center; margin: 14px 0 0; font-size: 17px; color: #e3e0ff; }
.m-timer { position: relative; text-align: center; font-size: clamp(54px, 17vw, 72px); font-weight: 700; letter-spacing: -1px; line-height: 1.1; margin-bottom: 22px; }
.m-rates { position: relative; display: flex; align-items: center; justify-content: center; gap: 22px; margin-bottom: 28px; }
.m-rates > div { display: flex; align-items: flex-start; gap: 8px; }
.m-rates p { margin: 0; font-size: 14px; color: #e3e0ff; }
.m-rates b { display: block; font-size: 20px; color: #fff; font-weight: 700; white-space: nowrap; }
.m-arrow svg { width: 20px; height: 20px; stroke-width: 3; margin-top: 18px; }
.m-sep { width: 1px; height: 46px; background: rgba(255,255,255,.35); }

.m-server { position: relative; display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 22px; text-decoration: none; color: #fff;
  background: linear-gradient(135deg, #6f5fff, #5443e6); box-shadow: 0 18px 40px -16px rgba(80,60,230,.9); }
.m-server .grow { flex: 1; min-width: 0; }
.m-server b { display: block; font-size: 18px; font-weight: 600; }
.m-server small { display: block; color: #d6d1ff; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-go { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: #1b1466; box-shadow: 0 0 0 3px rgba(255,255,255,.12); }
.flag { flex-shrink: 0; border-radius: 50%; box-shadow: 0 0 0 2px rgba(255,255,255,.85); }

.m-power-wrap { position: relative; height: 330px; display: grid; place-items: center; margin-top: 8px; }
.m-map { position: absolute; inset: 20px -20px; opacity: .22;
  background: radial-gradient(circle, #b9b0ff 1.4px, transparent 1.6px) 0 0 / 11px 11px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 55%, #000 40%, transparent 75%); mask-image: radial-gradient(ellipse 70% 60% at 50% 55%, #000 40%, transparent 75%); }
.m-ring { position: absolute; border-radius: 50%; border: 1px solid rgba(160,150,255,.25); }
.m-ring.r1 { width: 290px; height: 290px; }
.m-ring.r2 { width: 236px; height: 236px; border-color: rgba(160,150,255,.35); }
.m-power-wrap.on .m-ring { animation: ringPulse 2.6s ease-out infinite; }
.m-power-wrap.on .m-ring.r2 { animation-delay: .8s; }
@keyframes ringPulse { 0% { transform: scale(.85); opacity: 1; } 100% { transform: scale(1.12); opacity: 0; } }
.m-power { position: relative; width: 200px; height: 200px; border-radius: 50%; border: 10px solid rgba(150,140,255,.55); cursor: pointer; color: #fff;
  background: radial-gradient(circle at 50% 35%, #7a6bff, #5141e0 70%);
  box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 25px 60px -10px rgba(70,50,220,.95), inset 0 -10px 30px rgba(20,10,100,.35);
  display: grid; place-items: center; transition: transform .15s, box-shadow .3s, background .3s; }
.m-power:active { transform: scale(.96); }
.m-power svg { width: 86px; height: 86px; stroke-width: 2.2; }
.m-power.on { background: radial-gradient(circle at 50% 35%, #8f82ff, #5f4ff5 70%); border-color: rgba(200,195,255,.8);
  box-shadow: 0 0 0 10px rgba(108,92,255,.18), 0 0 70px 10px rgba(120,100,255,.65), inset 0 -10px 30px rgba(20,10,100,.3); }
.m-state { text-align: center; color: #d6d1ff; margin: 0 0 18px; font-size: 15px; }
.m-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); margin-right: 4px; }
.m-usage { padding: 16px 18px; margin-bottom: 10px; }
.m-apps { display: grid; gap: 10px; }

/* Speed test */
.m-speed .m-rates { margin: 6px 0 4px; }
.m-gauge { position: relative; width: min(320px, 86vw); margin: 0 auto; }
.m-gauge svg { width: 100%; height: auto; display: block; }
.g-track { fill: none; stroke: #191660; stroke-width: 24; stroke-linecap: round; }
.g-fill { fill: none; stroke: url(#gArc); stroke-width: 24; stroke-linecap: round; }
.g-labels text { fill: #fff; font: 600 12px Inter, sans-serif; text-anchor: middle; }
.g-value { position: absolute; left: 0; right: 0; bottom: 0; text-align: center; line-height: 1.15; }
.g-value b { display: block; font-size: 30px; }
.g-value span { color: #e3e0ff; font-size: 15px; }
.g-value small { display: block; color: #b8b1ff; font-size: 12px; margin-top: 2px; }
.m-metrics { display: flex; justify-content: space-between; gap: 6px; flex-wrap: wrap; font-size: 13px; color: #e3e0ff; margin: 18px 0; }
.m-metrics span { display: inline-flex; align-items: center; gap: 5px; }
.m-metrics i svg { width: 13px; height: 13px; }
.m-metrics b { font-weight: 500; }
.m-chips { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.m-chips > div { display: flex; align-items: center; gap: 10px; }
.m-chips p { margin: 0; line-height: 1.3; }
.m-chips b { display: block; font-weight: 500; font-size: 16px; }
.m-chips small { color: #cfc9ff; font-size: 12px; }
.m-wifi { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: rgba(255,255,255,.06); box-shadow: 0 8px 20px -8px rgba(0,0,0,.4); flex-shrink: 0; }
.m-speed .btn.lg { margin-bottom: 16px; }

/* Servers (dark sheet) */
.m-servers { padding-top: calc(30px + env(safe-area-inset-top)); }
.m-sheet { background: #050414; border-radius: 34px 34px 0 0; margin: 0 -20px; padding: 14px 20px 30px; min-height: calc(100vh - 30px); }
.m-handle { width: 30px; height: 4px; border-radius: 4px; background: #fff; margin: 0 auto 20px; }
.m-promo { display: flex; align-items: center; gap: 16px; padding: 22px 18px; border-radius: 26px; text-decoration: none; color: #fff; margin-bottom: 26px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='120'%3E%3Cg stroke='%23fff' stroke-width='2' stroke-linecap='round' opacity='.18'%3E%3Cpath d='M10 30l40-22M120 20l50-28M150 90l40-22M30 110l50-28'/%3E%3C/g%3E%3C/svg%3E"), #3a3940; }
.m-promo b { display: block; font-size: 19px; font-weight: 600; }
.m-promo small { color: #e6e6ee; font-size: 13px; line-height: 1.4; display: block; }
.m-crown { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: #fff; flex-shrink: 0; color: #ffc21a; }
.m-crown svg { width: 34px; height: 34px; }
.m-list-title { font-size: 14px; color: #8f8aa8; font-weight: 500; margin: 0 0 12px; }
.m-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; }
.m-row .grow { flex: 1; min-width: 0; }
.m-row b { display: block; font-size: 19px; font-weight: 600; }
.m-row small { color: #8f8aa8; font-size: 13px; display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.m-flag-wrap { display: grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; background: #1c1a2c; flex-shrink: 0; }
.m-sig svg { width: 12px; height: 12px; }
.m-connect { border: 1px solid #e8e6ff; background: none; color: #fff; border-radius: 12px; padding: 9px 18px; font: 500 14px var(--font); cursor: pointer; white-space: nowrap; }
.m-connect:hover { background: rgba(255,255,255,.08); }
.m-connect.on { border-color: var(--green); color: var(--green); }

/* Bottom tab bar */
.tabbar { position: fixed; z-index: 30; left: 50%; transform: translateX(-50%); bottom: calc(12px + env(safe-area-inset-bottom));
  width: min(440px, calc(100% - 24px)); display: grid; grid-template-columns: repeat(4, 1fr); padding: 8px; border-radius: 24px;
  background: rgba(18, 12, 70, .82); border: 1px solid rgba(190,180,255,.18); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 18px 40px -12px rgba(0,0,0,.6); }
.tabbar a { display: grid; justify-items: center; gap: 2px; padding: 6px 0; border-radius: 16px; color: #a9a2e6; text-decoration: none; font-size: 11px; font-weight: 500; }
.tabbar a svg { width: 22px; height: 22px; }
.tabbar a.active { color: #fff; background: linear-gradient(135deg, #7d6dff, #5b49f0); }
@media (max-width: 380px) {
  .m-rates { gap: 12px; }
  .m-rates b { font-size: 17px; }
  .m-power { width: 176px; height: 176px; }
}
