/* VistaVault — shared stylesheet */
/* Design tokens match mockup/index.html */

:root {
  --brand-dark:    #0d1117;
  --brand-mid:     #161b22;
  --brand-surface: #1c2128;
  --brand-border:  #30363d;
  --brand-accent:  #2563eb;
  --brand-accent2: #7c3aed;
  --brand-success: #16a34a;
  --brand-danger:  #dc2626;
  --brand-warn:    #d97706;
  --text-primary:  #e6edf3;
  --text-secondary:#8b949e;
  --text-muted:    #484f58;
  --radius:        8px;
  --shadow:        0 4px 20px rgba(0,0,0,.4);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--brand-dark);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

a { color: var(--brand-accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Navigation ──────────────────────────────────────────────────────────── */
nav {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 2rem; height: 60px;
  background: rgba(13,17,23,.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--brand-border);
}
.nav-logo {
  font-size: 1.2rem; font-weight: 700; letter-spacing: -.5px;
  background: linear-gradient(135deg,#60a5fa,#a78bfa);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  text-decoration: none;
}
.nav-links { display: flex; gap: 1.5rem; }
.nav-links a { color: var(--text-secondary); font-size: .9rem; transition: color .2s; }
.nav-links a:hover { color: var(--text-primary); text-decoration: none; }
.nav-actions { display: flex; gap: .6rem; }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .5rem 1.1rem; border-radius: var(--radius);
  font-size: .875rem; font-weight: 500; cursor: pointer;
  border: 1px solid transparent; transition: all .18s; white-space: nowrap;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn-primary  { background: var(--brand-accent); color: #fff; border-color: var(--brand-accent); }
.btn-primary:hover { background: #1d4ed8; border-color: #1d4ed8; }
.btn-ghost    { border-color: var(--brand-border); color: var(--text-secondary); background: transparent; }
.btn-ghost:hover { color: var(--text-primary); border-color: #6b7280; }
.btn-outline  { border-color: var(--brand-accent); color: var(--brand-accent); background: transparent; }
.btn-outline:hover { background: var(--brand-accent); color: #fff; }
.btn-danger   { background: var(--brand-danger); border-color: var(--brand-danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-success  { background: var(--brand-success); border-color: var(--brand-success); color: #fff; }
.btn-sm       { padding: .3rem .75rem; font-size: .8rem; }
.btn-lg       { padding: .7rem 1.5rem; font-size: 1rem; }
.btn-block    { width: 100%; justify-content: center; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ── Forms ───────────────────────────────────────────────────────────────── */
.form-card {
  background: var(--brand-mid);
  border: 1px solid var(--brand-border);
  border-radius: 12px; padding: 2rem;
  max-width: 460px; width: 100%;
  box-shadow: var(--shadow);
}
.form-card.wide { max-width: 560px; }

.form-header { text-align: center; margin-bottom: 1.75rem; }
.form-header h1 { font-size: 1.6rem; font-weight: 700; }
.form-header p  { color: var(--text-secondary); margin-top: .4rem; font-size: .9rem; }

.form-group { margin-bottom: 1.1rem; }
.form-group label {
  display: block; margin-bottom: .4rem;
  font-size: .875rem; color: var(--text-secondary); font-weight: 500;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: .6rem .85rem;
  background: var(--brand-surface); color: var(--text-primary);
  border: 1px solid var(--brand-border); border-radius: var(--radius);
  font-size: .95rem; transition: border-color .18s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none; border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(37,99,235,.18);
}
.form-group input.field-valid   { border-color: var(--brand-success); }
.form-group input.field-invalid { border-color: var(--brand-danger); }

.form-hint { font-size: .78rem; color: var(--text-muted); margin-top: .3rem; }

/* Password requirements checklist */
.pw-requirements { list-style: none; margin: .5rem 0 0; padding: 0; font-size: .8rem; }
.pw-requirements li { color: var(--text-muted); padding: 1px 0; transition: color .2s; }
.pw-requirements li::before { content: '○ '; }
.pw-requirements li.req-met   { color: var(--brand-success); }
.pw-requirements li.req-met::before   { content: '✓ '; }
.pw-requirements li.req-unmet { color: var(--brand-danger); }
.pw-requirements li.req-unmet::before { content: '✗ '; }

.confirm-status { font-size: .8rem; margin-top: .3rem; min-height: 1.1em; }
.confirm-status.match    { color: var(--brand-success); }
.confirm-status.no-match { color: var(--brand-danger); }

.form-links {
  text-align: center; margin-top: 1.25rem;
  padding-top: 1.25rem; border-top: 1px solid var(--brand-border);
  font-size: .85rem; color: var(--text-secondary);
  display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1rem;
}
.form-links a { color: var(--brand-accent); }

/* ── Alerts ──────────────────────────────────────────────────────────────── */
.alert {
  padding: .75rem 1rem; border-radius: var(--radius);
  font-size: .9rem; margin-bottom: 1.25rem; border: 1px solid transparent;
}
.alert-error   { background: rgba(220,38,38,.12); border-color: var(--brand-danger);   color: #fca5a5; }
.alert-success { background: rgba(22,163,74,.12);  border-color: var(--brand-success); color: #86efac; }
.alert-info    { background: rgba(37,99,235,.12);  border-color: var(--brand-accent);  color: #93c5fd; }
.alert-warn    { background: rgba(217,119,6,.12);  border-color: var(--brand-warn);    color: #fcd34d; }

/* ── Page layout helpers ─────────────────────────────────────────────────── */
.page-center {
  min-height: calc(100vh - 60px);
  display: flex; align-items: center; justify-content: center;
  padding: 2rem 1rem;
}
.container { max-width: 1080px; margin: 0 auto; padding: 0 1.5rem; }
.section    { padding: 2.5rem 0; }

/* ── Dashboard layout ────────────────────────────────────────────────────── */
.dash-wrap   { max-width: 900px; margin: 0 auto; padding: 2rem 1.5rem; }
.dash-header { margin-bottom: 2rem; }
.dash-header h1  { font-size: 1.5rem; font-weight: 700; }
.dash-header p   { color: var(--text-secondary); margin-top: .3rem; font-size: .9rem; }

.dash-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
  gap: 1rem; margin-bottom: 2rem;
}
.stat-card {
  background: var(--brand-mid); border: 1px solid var(--brand-border);
  border-radius: var(--radius); padding: 1.25rem;
}
.stat-card .label { font-size: .78rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; }
.stat-card .value { font-size: 1.6rem; font-weight: 700; margin-top: .2rem; }
.stat-card .sub   { font-size: .8rem;  color: var(--text-secondary); margin-top: .1rem; }

/* ── Dashboard two-column full-page layout ───────────────────────────────── */
body.dash-page { height: 100vh; overflow: hidden; display: flex; flex-direction: column; }
body.dash-page nav { flex-shrink: 0; }
.dash-layout { flex: 1; display: flex; overflow: hidden; min-height: 0; }

.dash-main { flex: 1; overflow-y: auto; min-width: 0; }
.dash-tours-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: .85rem 1.25rem;
  border-bottom: 1px solid var(--brand-border);
  position: sticky; top: 0; z-index: 10;
  background: rgba(13,17,23,.95); backdrop-filter: blur(6px);
}
.dash-tours-header h2 { font-size: .95rem; font-weight: 600; margin: 0 0 .1rem; }
.dash-site-link { font-size: .72rem; color: var(--text-muted); text-decoration: none; }
.dash-site-link:hover { color: var(--text-secondary); text-decoration: none; }
.dash-empty { padding: 4rem 2rem; text-align: center; color: var(--text-muted); font-size: .9rem; line-height: 1.6; }

.dash-sidebar {
  width: 265px; min-width: 265px;
  border-left: 1px solid var(--brand-border);
  overflow-y: auto;
  padding: 1rem 1.1rem;
  background: var(--brand-surface);
  display: flex; flex-direction: column;
}
.sidebar-stat { padding: .85rem 0; border-bottom: 1px solid var(--brand-border); }
.sidebar-stat:last-of-type { border-bottom: none; }
.sidebar-label { font-size: .65rem; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--text-muted); margin-bottom: .3rem; }
.sidebar-refreshed { font-weight: 400; text-transform: none; letter-spacing: 0; font-size: .65rem; }
.sidebar-value { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); line-height: 1.1; }
.sidebar-value-sm { font-size: 1.05rem; font-weight: 700; color: var(--text-primary); line-height: 1.3; }
.sidebar-of { font-size: .72rem; font-weight: 400; color: var(--text-muted); }
.sidebar-sub { font-size: .72rem; color: var(--text-secondary); margin-top: .25rem; }
.sidebar-bw-meta { display: flex; justify-content: space-between; }
.sidebar-bar-wrap { background: var(--brand-border); border-radius: 3px; height: 5px; overflow: hidden; margin-top: .5rem; }
.sidebar-bar { height: 100%; border-radius: 3px; transition: width .6s ease; }
.sidebar-spacer { flex: 1; min-height: .5rem; }
.sidebar-admin-btn { width: 100%; text-align: center; margin-top: .5rem; }
.sidebar-upload .upload-name-input { font-size: .75rem; padding: .3rem .55rem; margin-bottom: .45rem; width: 100%; box-sizing: border-box; }
.sidebar-upload .upload-file-label { cursor: pointer; display: block; text-align: center; }
.sidebar-upload .upload-filename   { margin-top: .3rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-upload .upload-btn        { margin-top: .45rem; }
.sidebar-upload .upload-phase      { margin-bottom: .4rem; }
.sidebar-upload .upload-pct        { margin-top: .25rem; }
.sidebar-upload .upload-file-disp  { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-muted); }
.sidebar-upload .upload-error-msg  { color: var(--brand-danger); margin-top: .4rem; }
@keyframes vv-bar-slide {
  0%   { transform: translateX(-200%); }
  100% { transform: translateX(500%); }
}
.sidebar-bar-indeterminate { width: 25% !important; animation: vv-bar-slide 1.4s ease-in-out infinite; transition: none; }

@media (max-width: 768px) {
  body.dash-page { height: auto; overflow: auto; }
  .dash-layout { flex-direction: column; overflow: visible; }
  .dash-sidebar { width: 100%; min-width: 0; border-left: none; border-top: 1px solid var(--brand-border); }
  .dash-main { overflow-y: visible; }
  .dash-tours-header { position: static; }
}

.card {
  background: var(--brand-mid); border: 1px solid var(--brand-border);
  border-radius: var(--radius); margin-bottom: 1.25rem;
}
.card-header {
  padding: 1rem 1.25rem; border-bottom: 1px solid var(--brand-border);
  display: flex; align-items: center; justify-content: space-between;
}
.card-header h2 { font-size: 1rem; font-weight: 600; }
.card-body  { padding: 1.25rem; }
.card-empty { text-align: center; padding: 2.5rem 1rem; color: var(--text-secondary); font-size: .9rem; }

/* VM status badge */
.badge {
  display: inline-block; padding: .18rem .6rem;
  border-radius: 99px; font-size: .75rem; font-weight: 600;
}
.badge-active       { background: rgba(22,163,74,.18);  color: #86efac; }
.badge-provisioning { background: rgba(37,99,235,.18);  color: #93c5fd; }
.badge-pending      { background: rgba(217,119,6,.18);  color: #fcd34d; }
.badge-error        { background: rgba(220,38,38,.18);  color: #fca5a5; }
.badge-suspended    { background: rgba(100,100,100,.18);color: #9ca3af; }
.badge-terminated   { background: rgba(100,100,100,.18);color: #9ca3af; }

/* ── Admin table ─────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
table  { width: 100%; border-collapse: collapse; font-size: .875rem; }
th, td { padding: .65rem 1rem; text-align: left; border-bottom: 1px solid var(--brand-border); }
th     { color: var(--text-muted); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,.02); }

/* ── Misc ─────────────────────────────────────────────────────────────────── */
.text-muted   { color: var(--text-muted); }
.text-sec     { color: var(--text-secondary); }
.text-sm      { font-size: .85rem; }
.text-xs      { font-size: .75rem; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem;  }
.mt-3 { margin-top: 1.5rem; }
.mb-3 { margin-bottom: 1.5rem; }
.text-danger   { color: var(--brand-danger); }
.text-optional { color: var(--text-muted); font-weight: 400; }
.label-overline { text-transform: uppercase; letter-spacing: .05em; margin-bottom: .2rem; }
.field-label  { display: block; font-size: .82rem; font-weight: 600; color: var(--text-secondary); margin-bottom: .35rem; }
.field-input  { width: 100%; padding: .5rem .85rem; background: var(--brand-surface); color: var(--text-primary); border: 1px solid var(--brand-border); border-radius: var(--radius); font-size: .875rem; box-sizing: border-box; transition: border-color .18s; }
.field-input:focus { outline: none; border-color: var(--brand-accent); box-shadow: 0 0 0 3px rgba(37,99,235,.18); }
.dash-wrap-sm { max-width: 640px; }
.flex { display: flex; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
hr.divider { border: none; border-top: 1px solid var(--brand-border); margin: 1.5rem 0; }

/* ── Share modal ─────────────────────────────────────────────────────────── */
.modal-backdrop {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,.65); backdrop-filter: blur(4px);
  align-items: center; justify-content: center; padding: 1rem;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--brand-mid); border: 1px solid var(--brand-border);
  border-radius: 12px; padding: 1.75rem 1.75rem 1.5rem;
  width: 100%; max-width: 520px; box-shadow: var(--shadow);
}
.modal-header {
  display: flex; justify-content: space-between; align-items: flex-start;
  margin-bottom: 1.25rem; gap: 1rem;
}
.modal-header h3 { font-size: 1rem; font-weight: 600; line-height: 1.4; }
.modal-close {
  background: none; border: none; color: var(--text-secondary);
  font-size: 1.5rem; line-height: 1; cursor: pointer; padding: 0;
  flex-shrink: 0;
}
.modal-close:hover { color: var(--text-primary); }
.share-field { margin-bottom: 1rem; }
.share-field label {
  display: block; margin-bottom: .35rem;
  font-size: .75rem; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .06em; font-weight: 600;
}
.copy-row { display: flex; gap: .5rem; align-items: flex-start; }
.copy-row input[type="text"],
.copy-row textarea {
  flex: 1; background: var(--brand-surface); color: var(--text-secondary);
  border: 1px solid var(--brand-border); border-radius: var(--radius);
  padding: .5rem .75rem; font-size: .8rem; font-family: monospace;
  resize: none; line-height: 1.5;
}
.copy-row textarea { height: 68px; }
.copy-row .btn { flex-shrink: 0; align-self: flex-start; }
.modal-divider { border: none; border-top: 1px solid var(--brand-border); margin: 1.1rem 0; }
.modal-actions { display: flex; justify-content: space-between; align-items: center; gap: .5rem; flex-wrap: wrap; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  nav { padding: 0 1rem; }
  .nav-links { display: none; }
  .form-card { padding: 1.5rem 1rem; }
  .dash-wrap { padding: 1.25rem 1rem; }
}

/* ── Utility: inline form (logout / action buttons in nav) ───────────────── */
.form-inline { display: inline; margin: 0; }

/* ── Utility: nav display name + back links ──────────────────────────────── */
.nav-username { color: var(--text-secondary); font-size: .875rem; }
.link-back    { color: var(--text-secondary); font-size: .875rem; }

/* ── Public footer (index, pricing) ─────────────────────────────────────── */
footer {
  border-top: 1px solid var(--brand-border);
  padding: 2rem 1rem; text-align: center;
  color: var(--text-muted); font-size: .85rem; margin-top: 3rem;
}

/* ── Home page ───────────────────────────────────────────────────────────── */
.hero { padding: 5rem 1rem 4rem; text-align: center; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; line-height: 1.15; margin-bottom: 1.25rem; }
.hero h1 span { background: linear-gradient(135deg, #60a5fa, #a78bfa); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { font-size: 1.15rem; color: var(--text-secondary); max-width: 560px; margin: 0 auto 2rem; line-height: 1.7; }
.hero-actions { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }
.features { padding: 3rem 0; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.feature-card { background: var(--brand-mid); border: 1px solid var(--brand-border); border-radius: var(--radius); padding: 1.5rem; }
.feature-card .icon { font-size: 1.75rem; margin-bottom: .75rem; }
.feature-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: .4rem; }
.feature-card p { font-size: .875rem; color: var(--text-secondary); line-height: 1.6; }

/* ── Pricing page ────────────────────────────────────────────────────────── */
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.25rem; margin: 2.5rem 0; }
.plan-card { background: var(--brand-mid); border: 1px solid var(--brand-border); border-radius: 12px; padding: 1.75rem; display: flex; flex-direction: column; }
.plan-card.featured { border-color: var(--brand-accent); box-shadow: 0 0 0 1px var(--brand-accent); }
.plan-name { font-size: .8rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); margin-bottom: .5rem; }
.plan-price { font-size: 2.25rem; font-weight: 800; line-height: 1; margin-bottom: .25rem; }
.plan-price span { font-size: 1rem; font-weight: 400; color: var(--text-secondary); }
.plan-desc { font-size: .875rem; color: var(--text-secondary); margin-bottom: 1.5rem; min-height: 2.5rem; }
.plan-features { list-style: none; margin: 0 0 1.5rem; padding: 0; flex: 1; }
.plan-features li { font-size: .875rem; padding: .35rem 0; border-bottom: 1px solid var(--brand-border); color: var(--text-secondary); display: flex; align-items: center; gap: .5rem; }
.plan-features li:last-child { border-bottom: none; }
.plan-features li::before { content: '✓'; color: var(--brand-success); font-weight: 700; flex-shrink: 0; }
.plan-features li.unavail { color: var(--text-muted); }
.plan-features li.unavail::before { content: '—'; color: var(--text-muted); }

/* ── Onboarding page ─────────────────────────────────────────────────────── */
.ob-wrap {
  min-height: calc(100vh - 60px);
  display: flex; align-items: center; justify-content: center;
  padding: 2rem 1rem;
}
.ob-card {
  background: var(--brand-mid); border: 1px solid var(--brand-border);
  border-radius: 14px; padding: 2.5rem 2rem;
  max-width: 560px; width: 100%;
  box-shadow: 0 8px 32px rgba(0,0,0,.45);
}
.ob-hero { text-align: center; margin-bottom: 2rem; }
.ob-icon {
  width: 56px; height: 56px; border-radius: 14px;
  background: linear-gradient(135deg,#2563eb,#7c3aed);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin: 0 auto 1rem;
}
.ob-hero h1 { font-size: 1.5rem; font-weight: 700; margin-bottom: .4rem; }
.ob-hero p  { color: var(--text-secondary); font-size: .9rem; line-height: 1.5; }

.region-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: .5rem; margin-bottom: 1.5rem;
  max-height: 280px; overflow-y: auto; padding-right: .25rem;
}
.region-grid::-webkit-scrollbar { width: 5px; }
.region-grid::-webkit-scrollbar-track { background: var(--brand-surface); border-radius: 3px; }
.region-grid::-webkit-scrollbar-thumb { background: var(--brand-border); border-radius: 3px; }
.region-card {
  display: flex; flex-direction: column; padding: .65rem .75rem;
  background: var(--brand-surface); border: 1.5px solid var(--brand-border);
  border-radius: 8px; cursor: pointer;
  transition: border-color .15s, background .15s;
  user-select: none; position: relative;
}
.region-card input[type="radio"] { position: absolute; left: -9999px; }
.region-card:hover { border-color: #4b80e8; background: #1d2535; }
.region-card.selected,
.region-card:has(input[type="radio"]:checked) {
  border-color: var(--brand-accent); background: rgba(37,99,235,.1);
}
.region-name { font-size: .82rem; font-weight: 600; color: var(--text-primary); }
.region-id   { font-size: .72rem; color: var(--text-muted); font-family: monospace; margin-top: .15rem; }

.prov-steps {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin: 1.75rem 0 1.5rem; position: relative;
}
.prov-step { display: flex; flex-direction: column; align-items: center; flex: 1; position: relative; z-index: 1; }
.prov-step:not(:last-child)::after {
  content: ''; position: absolute; top: 18px;
  left: calc(50% + 20px); right: calc(-50% + 20px);
  height: 2px; background: var(--brand-border); z-index: -1; transition: background .4s;
}
.prov-step.step-done:not(:last-child)::after   { background: #22c55e; }
.prov-step.step-active:not(:last-child)::after { background: var(--brand-border); }

.prov-circle {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; margin-bottom: .5rem;
  transition: background .3s, border-color .3s;
}
.step-done   .prov-circle { background: #22c55e; color: #fff; }
.step-active .prov-circle {
  background: var(--brand-accent); color: #fff;
  box-shadow: 0 0 0 0 rgba(37,99,235,.4);
  animation: ob-pulse 1.8s ease-in-out infinite;
}
.step-pending .prov-circle {
  background: var(--brand-surface); border: 2px solid var(--brand-border); color: var(--text-muted);
}
.prov-label { font-size: .72rem; text-align: center; max-width: 62px; line-height: 1.3; transition: color .3s; }
.step-done   .prov-label { color: #4ade80; }
.step-active .prov-label { color: #60a5fa; font-weight: 600; }
.step-pending .prov-label { color: var(--text-muted); }

.prov-msg { text-align: center; padding: 1rem 0 .5rem; }
.prov-msg-text { font-size: .95rem; color: var(--text-primary); min-height: 1.5em; }
.prov-msg-sub  { font-size: .78rem; color: var(--text-muted); margin-top: .35rem; }

.prov-dots { display: flex; align-items: center; justify-content: center; gap: 5px; margin: 1rem 0; }
.prov-dot  { width: 7px; height: 7px; border-radius: 50%; background: var(--brand-accent); animation: ob-dot .9s ease-in-out infinite; }
.prov-dot:nth-child(2) { animation-delay: .15s; }
.prov-dot:nth-child(3) { animation-delay: .30s; }

.activate-wrap {
  margin-top: 1.5rem; opacity: 0; transform: translateY(8px);
  transition: opacity .4s, transform .4s; pointer-events: none;
}
.activate-wrap.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.activate-wrap p { text-align: center; font-size: .82rem; color: var(--text-secondary); margin-top: .5rem; }

@keyframes ob-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(37,99,235,.4); }
  70%  { box-shadow: 0 0 0 10px rgba(37,99,235,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,99,235,0); }
}
@keyframes ob-dot {
  0%, 80%, 100% { transform: scale(.6); opacity: .5; }
  40%           { transform: scale(1);  opacity: 1; }
}
@keyframes ob-pulse-spin { to { transform: rotate(360deg); } }

@media (max-width: 480px) {
  .ob-card { padding: 1.75rem 1.25rem; }
  .region-grid { grid-template-columns: 1fr 1fr; }
  .prov-label { font-size: .65rem; max-width: 52px; }
  .prov-circle { width: 30px; height: 30px; font-size: 13px; }
  .prov-step:not(:last-child)::after { top: 15px; left: calc(50% + 17px); right: calc(-50% + 17px); }
}

/* ── Tour card grid ──────────────────────────────────────────────────────── */
.tour-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: .75rem;
  padding: 1rem;
}
.tour-card {
  position: relative; height: 180px;
  border-radius: 6px; overflow: hidden;
  background: var(--brand-surface);
  background-size: cover; background-position: center;
}
.tour-card-no-thumb { background: linear-gradient(135deg,#1a2235,#0d1320); }
.tour-card-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.82) 0%, rgba(0,0,0,.15) 55%, transparent 100%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: .7rem .85rem; pointer-events: none;
}
.tour-card-meta { font-size: .65rem; color: rgba(255,255,255,.55); letter-spacing: .02em; margin-bottom: .25rem; }
.tour-card-name {
  font-size: .875rem; font-weight: 600; color: #fff; line-height: 1.3;
  overflow: hidden; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.tour-card-actions {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; gap: .6rem;
  background: rgba(0,0,0,.52);
  opacity: 0; transition: opacity .18s;
}
.tour-card:hover .tour-card-actions { opacity: 1; }
.tour-card-actions form { display: contents; }
.tour-action-btn {
  width: 42px; height: 42px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.7);
  background: rgba(15,20,30,.55);
  color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0; padding: 0; line-height: 0;
  transition: background .15s, transform .15s, border-color .15s;
  text-decoration: none;
}
.tour-action-btn:hover {
  background: rgba(255,255,255,.18); transform: scale(1.1);
  border-color: #fff; text-decoration: none;
}
.tour-action-btn.share-btn { background: rgba(37,99,235,.6); border-color: rgba(147,197,253,.8); }
.tour-action-btn.share-btn:hover { background: rgba(37,99,235,.9); border-color: #93c5fd; }
.tour-action-delete { border-color: rgba(252,165,165,.65); }
.tour-action-delete:hover { background: rgba(220,38,38,.55); border-color: #fca5a5; }
@media (max-width: 1080px) {
  .tour-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 900px) {
  .tour-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 640px) {
  .tour-grid { grid-template-columns: repeat(auto-fill, minmax(150px,1fr)); gap: .5rem; padding: .75rem; }
  .tour-card { height: 145px; }
}

/* ── Bandwidth card ──────────────────────────────────────────────────────── */
.bw-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 1.5rem; padding: 1rem 1.25rem 1.25rem; }
.bw-col-side { border-left: 1px solid var(--brand-border); padding-left: 1.5rem; display: flex; flex-direction: column; justify-content: center; }
.bw-value { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); line-height: 1.1; margin: .25rem 0 .1rem; }
.bw-value-sm { font-size: 1.25rem; }
.bw-of { font-size: .75rem; color: var(--text-muted); }
@media (max-width: 480px) {
  .bw-grid { grid-template-columns: 1fr; gap: 1rem; }
  .bw-col-side { border-left: none; border-top: 1px solid var(--brand-border); padding-left: 0; padding-top: 1rem; }
}

/* ── Admin: VM provisioning panel ────────────────────────────────────────── */
@keyframes vv-spin { to { transform: rotate(360deg); } }
#vv-mark-active-btn.vv-ready { outline: 3px solid #22c55e; outline-offset: 2px; }

/* ── Confirm modal ───────────────────────────────────────────────────────── */
#vv-confirm-backdrop {
  display: none;
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(0,0,0,.6);
  align-items: center; justify-content: center;
  padding: 1rem;
}
#vv-confirm-backdrop.vv-confirm-open {
  display: flex;
  animation: vv-confirm-fade .15s ease;
}
#vv-confirm-backdrop.vv-confirm-open #vv-confirm-dialog {
  animation: vv-confirm-scale .15s ease;
}
#vv-confirm-dialog {
  background: var(--brand-surface);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  max-width: 420px;
  width: 100%;
}
#vv-confirm-msg {
  color: var(--text-primary);
  font-size: .95rem;
  line-height: 1.55;
  white-space: pre-line;
  margin-bottom: 1.25rem;
}
#vv-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: .6rem;
}
@keyframes vv-confirm-fade  { from { opacity: 0; }                        to { opacity: 1; } }
@keyframes vv-confirm-scale { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: scale(1); } }

/* ── Tour URL copy button: copied feedback state ─────────────────────── */
/* Double-class specificity overrides .tour-action-btn:hover border-color */
.tour-action-btn.tour-action-copy-ok,
.tour-action-btn.tour-action-copy-ok:hover { border-color: #22c55e; color: #22c55e; }

/* ── Tour lock button: active (protected) state ──────────────────────── */
.tour-action-btn.tour-action-lock-active,
.tour-action-btn.tour-action-lock-active:hover { border-color: #f59e0b; color: #f59e0b; }

/* ── Lock badge in tour card overlay ─────────────────────────────────── */
.tour-lock-badge {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  margin-left: .3rem;
  color: #f59e0b;
  opacity: .9;
}

/* ── Password modal description text ─────────────────────────────────── */
.pw-modal-desc {
  color: var(--text-secondary);
  font-size: .9rem;
  line-height: 1.55;
  margin-bottom: 1.25rem;
}

/* ── Password mismatch error ─────────────────────────────────────────── */
.pw-match-error {
  color: var(--brand-danger);
  font-size: .85rem;
  margin-top: -.5rem;
  margin-bottom: .75rem;
}
