/*!
 * vamvault.com — project override for the shared Canvas 8 theme.
 *
 * Canvas ships light by default; the vault is a dark, dense, catalog-style UI,
 * so this file re-grounds the page and then styles the components Canvas has no
 * equivalent for: the asset grid, the file table, the chunked uploader, and the
 * 18+ interstitial.
 *
 * Everything is scoped under .vv-* or a plain element inside #content so a
 * Canvas upgrade can't be broken by, and can't break, these rules.
 */

:root {
	--vv-bg:        #0e1116;
	--vv-surface:   #161b23;
	--vv-surface-2: #1d2430;
	--vv-line:      #2a3342;
	--vv-line-soft: #212936;
	--vv-text:      #e6ebf2;
	--vv-muted:     #8f9bad;
	--vv-dim:       #6b7688;
	--vv-accent:    #4c8dff;
	--vv-accent-dk: #2f6fd6;
	--vv-warn:      #f0a33c;
	--vv-danger:    #e5544b;
	--vv-ok:        #3fbf7f;
	--vv-radius:    10px;
	--vv-mono:      'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ---------------------------------------------------------------- base --- */

body.vv-body {
	background: var(--vv-bg);
	color: var(--vv-text);
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	font-size: 15px;
	line-height: 1.65;
}

.vv-body #content { background: var(--vv-bg); }
.vv-body h1, .vv-body h2, .vv-body h3,
.vv-body h4, .vv-body h5, .vv-body h6 { color: #fff; font-weight: 600; letter-spacing: -.015em; }
.vv-body h1 { font-size: 2rem; }
.vv-body h2 { font-size: 1.5rem; }
.vv-body h3 { font-size: 1.2rem; }
.vv-body p  { color: var(--vv-text); }
.vv-body a  { color: var(--vv-accent); }
.vv-body a:hover { color: #7fb0ff; }
.vv-body .lead { color: var(--vv-muted); font-size: 1.05rem; font-weight: 400; }

.vv-muted { color: var(--vv-muted) !important; }
.vv-dim   { color: var(--vv-dim)   !important; }
.vv-mono  { font-family: var(--vv-mono); font-size: .85em; }

/* ------------------------------------------------------------- header ---- */

.vv-body #header.dark, .vv-body #header.dark #header-wrap {
	background: rgba(14,17,22,.92);
	border-bottom: 1px solid var(--vv-line);
	backdrop-filter: blur(8px);
}

.vv-wordmark {
	font-weight: 700; font-size: 22px; letter-spacing: -.02em;
	color: #fff !important; text-decoration: none;
}
.vv-wordmark span { color: var(--vv-accent); }
.vv-wordmark-footer { font-size: 20px; margin-bottom: 10px; }

.vv-body .primary-menu .menu-link { color: var(--vv-muted); font-weight: 500; font-size: 14px; }
.vv-body .primary-menu .menu-item:hover > .menu-link,
.vv-body .primary-menu .menu-item.current > .menu-link { color: #fff; }
.vv-body .primary-menu .sub-menu-container { background: var(--vv-surface-2); border: 1px solid var(--vv-line); }
.vv-body .primary-menu .sub-menu-container .menu-link { color: var(--vv-muted); }
.vv-body .primary-menu .sub-menu-container .menu-link:hover { color: #fff; background: rgba(76,141,255,.1); }

.vv-cta { color: var(--vv-accent) !important; }

.vv-badge {
	display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 5px;
	background: var(--vv-danger); color: #fff; border-radius: 9px;
	font-size: 11px; font-weight: 600; line-height: 18px; text-align: center;
}

/* Header search */
.vv-navsearch { position: relative; margin-right: 18px; }
.vv-navsearch input {
	width: 230px; height: 36px; padding: 0 34px 0 12px;
	background: var(--vv-surface-2); border: 1px solid var(--vv-line);
	border-radius: 18px; color: var(--vv-text); font-size: 13px;
}
.vv-navsearch input::placeholder { color: var(--vv-dim); }
.vv-navsearch input:focus { outline: none; border-color: var(--vv-accent); background: var(--vv-surface); }
.vv-navsearch button {
	position: absolute; right: 4px; top: 3px; width: 30px; height: 30px;
	background: none; border: 0; color: var(--vv-muted); cursor: pointer;
}
.vv-navsearch button:hover { color: #fff; }

/* -------------------------------------------------------------- layout --- */

.vv-page { padding: 42px 0 72px; }
.vv-page-head { margin-bottom: 26px; padding-bottom: 18px; border-bottom: 1px solid var(--vv-line); }
.vv-page-head h1 { margin-bottom: 6px; }
.vv-page-head p  { margin-bottom: 0; color: var(--vv-muted); }

.vv-panel {
	background: var(--vv-surface); border: 1px solid var(--vv-line);
	border-radius: var(--vv-radius); padding: 22px; margin-bottom: 22px;
}
.vv-panel h3 { margin-bottom: 14px; font-size: 1.05rem; }
.vv-panel-tight { padding: 16px 18px; }

/* --------------------------------------------------------- asset grid ---- */

.vv-grid {
	display: grid; gap: 18px;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}

.vv-card {
	background: var(--vv-surface); border: 1px solid var(--vv-line);
	border-radius: var(--vv-radius); overflow: hidden;
	display: flex; flex-direction: column;
	transition: border-color .15s ease, transform .15s ease;
}
.vv-card:hover { border-color: var(--vv-accent); transform: translateY(-2px); }

.vv-card-thumb {
	display: block; position: relative; aspect-ratio: 4 / 3;
	background: var(--vv-surface-2); overflow: hidden;
}
.vv-card-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vv-card-thumb .vv-noimg {
	display: flex; align-items: center; justify-content: center; height: 100%;
	color: var(--vv-dim); font-size: 34px;
}

.vv-card-body { padding: 12px 14px 14px; flex: 1; display: flex; flex-direction: column; }
.vv-card-title {
	font-size: 14px; font-weight: 600; color: #fff; margin: 0 0 4px;
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.vv-card-title a { color: #fff; text-decoration: none; }
.vv-card-title a:hover { color: var(--vv-accent); }
.vv-card-sub { font-size: 12px; color: var(--vv-dim); margin-bottom: 10px; }
.vv-card-sub a { color: var(--vv-muted); }

.vv-card-meta {
	margin-top: auto; padding-top: 10px; border-top: 1px solid var(--vv-line-soft);
	display: flex; gap: 14px; font-size: 11.5px; color: var(--vv-dim);
}
.vv-card-meta i { margin-right: 3px; }

/* Corner flags on a card */
.vv-chip-abs { position: absolute; top: 8px; left: 8px; z-index: 2; }
.vv-chip {
	display: inline-block; padding: 2px 8px; border-radius: 20px;
	background: rgba(14,17,22,.82); border: 1px solid var(--vv-line);
	color: var(--vv-muted); font-size: 11px; font-weight: 500; line-height: 1.6;
}
.vv-chip-cat    { color: #cfe0ff; border-color: rgba(76,141,255,.4); }
.vv-chip-hidden { color: var(--vv-warn); border-color: rgba(240,163,60,.45); }
.vv-chip-removed{ color: var(--vv-danger); border-color: rgba(229,84,75,.45); }

/* ---------------------------------------------------------------- tags --- */

.vv-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.vv-tag {
	display: inline-block; padding: 3px 10px; border-radius: 20px;
	background: var(--vv-surface-2); border: 1px solid var(--vv-line);
	color: var(--vv-muted); font-size: 12px; text-decoration: none;
}
.vv-tag:hover { border-color: var(--vv-accent); color: #fff; }
.vv-tag.active { background: rgba(76,141,255,.15); border-color: var(--vv-accent); color: #fff; }

/* ------------------------------------------------------------- toolbar --- */

.vv-toolbar {
	display: flex; flex-wrap: wrap; gap: 12px; align-items: center;
	justify-content: space-between; margin-bottom: 20px;
}
.vv-toolbar .vv-count { color: var(--vv-muted); font-size: 13px; }

.vv-select, .vv-input, .vv-textarea {
	background: var(--vv-surface-2); border: 1px solid var(--vv-line);
	border-radius: 8px; color: var(--vv-text); padding: 9px 12px;
	font-size: 14px; font-family: inherit; width: 100%;
}
.vv-select:focus, .vv-input:focus, .vv-textarea:focus {
	outline: none; border-color: var(--vv-accent); background: var(--vv-surface);
}
.vv-select { width: auto; padding-right: 30px; }
.vv-textarea { min-height: 130px; resize: vertical; }
.vv-input::placeholder, .vv-textarea::placeholder { color: var(--vv-dim); }

.vv-field { margin-bottom: 18px; }
.vv-field label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 500; color: var(--vv-text); }
.vv-field .vv-help { display: block; margin-top: 5px; font-size: 12px; color: var(--vv-dim); }
.vv-req { color: var(--vv-danger); }

/* -------------------------------------------------------------- buttons --- */

.vv-btn {
	display: inline-block; padding: 10px 20px; border-radius: 8px;
	background: var(--vv-accent); border: 1px solid var(--vv-accent);
	color: #fff !important; font-size: 14px; font-weight: 600;
	text-decoration: none; cursor: pointer; transition: background .15s ease;
}
.vv-btn:hover:not(:disabled) { background: var(--vv-accent-dk); border-color: var(--vv-accent-dk); }
.vv-btn:disabled { opacity: .5; cursor: not-allowed; }
.vv-btn-ghost {
	background: transparent; border-color: var(--vv-line); color: var(--vv-text) !important;
}
.vv-btn-ghost:hover:not(:disabled) { background: var(--vv-surface-2); border-color: var(--vv-muted); }
.vv-btn-danger { background: var(--vv-danger); border-color: var(--vv-danger); }
.vv-btn-danger:hover:not(:disabled) { background: #c8433b; border-color: #c8433b; }
.vv-btn-sm { padding: 6px 13px; font-size: 13px; }
.vv-btn-block { display: block; width: 100%; text-align: center; }

/* --------------------------------------------------------- asset detail --- */

.vv-detail-head { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; justify-content: space-between; }
.vv-detail-head h1 { margin-bottom: 8px; }
.vv-byline { color: var(--vv-muted); font-size: 13.5px; }
.vv-byline a { color: var(--vv-text); }

.vv-gallery { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); margin-bottom: 20px; }
.vv-gallery-main {
	grid-column: 1 / -1; aspect-ratio: 16 / 9; background: var(--vv-surface-2);
	border: 1px solid var(--vv-line); border-radius: var(--vv-radius); overflow: hidden;
}
.vv-gallery-main img { width: 100%; height: 100%; object-fit: contain; display: block; }
.vv-gallery-thumb {
	aspect-ratio: 4 / 3; border: 1px solid var(--vv-line); border-radius: 6px;
	overflow: hidden; cursor: pointer; background: var(--vv-surface-2);
}
.vv-gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vv-gallery-thumb.active { border-color: var(--vv-accent); }

/* Key/value strip under the title */
.vv-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1px; background: var(--vv-line); border: 1px solid var(--vv-line); border-radius: var(--vv-radius); overflow: hidden; margin-bottom: 22px; }
.vv-fact { background: var(--vv-surface); padding: 14px 16px; }
.vv-fact-k { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--vv-dim); margin-bottom: 3px; }
.vv-fact-v { font-size: 15px; font-weight: 600; color: #fff; }

/* File list */
.vv-files { border: 1px solid var(--vv-line); border-radius: var(--vv-radius); overflow: hidden; }
.vv-file {
	display: flex; align-items: center; gap: 14px; padding: 13px 16px;
	background: var(--vv-surface); border-bottom: 1px solid var(--vv-line-soft);
}
.vv-file:last-child { border-bottom: 0; }
.vv-file-icon { font-size: 20px; color: var(--vv-muted); }
.vv-file-name { flex: 1; min-width: 0; }
.vv-file-name strong { display: block; font-size: 14px; font-weight: 500; color: #fff; word-break: break-all; }
.vv-file-name span  { font-size: 12px; color: var(--vv-dim); font-family: var(--vv-mono); }
.vv-hash { font-family: var(--vv-mono); font-size: 11px; color: var(--vv-dim); word-break: break-all; }

/* Dependencies */
.vv-dep { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--vv-line-soft); font-size: 13.5px; }
.vv-dep:last-child { border-bottom: 0; }
.vv-dep code { font-family: var(--vv-mono); font-size: 12.5px; color: var(--vv-text); background: none; padding: 0; }
.vv-dep-here { color: var(--vv-ok); font-size: 12px; }
.vv-dep-away { color: var(--vv-dim); font-size: 12px; }

/* -------------------------------------------------------------- uploader -- */

.vv-drop {
	border: 2px dashed var(--vv-line); border-radius: var(--vv-radius);
	background: var(--vv-surface); padding: 40px 24px; text-align: center;
	cursor: pointer; transition: border-color .15s ease, background .15s ease;
}
.vv-drop:hover, .vv-drop.dragover { border-color: var(--vv-accent); background: var(--vv-surface-2); }
.vv-drop i { font-size: 40px; color: var(--vv-muted); display: block; margin-bottom: 10px; }
.vv-drop strong { display: block; color: #fff; font-size: 15px; margin-bottom: 4px; }
.vv-drop span { color: var(--vv-dim); font-size: 13px; }

.vv-queue { margin-top: 16px; }
.vv-q {
	display: flex; align-items: center; gap: 14px; padding: 12px 14px;
	background: var(--vv-surface); border: 1px solid var(--vv-line);
	border-radius: 8px; margin-bottom: 8px;
}
.vv-q-name { flex: 1; min-width: 0; }
.vv-q-name strong { display: block; font-size: 13.5px; color: #fff; word-break: break-all; font-weight: 500; }
.vv-q-name span  { font-size: 12px; color: var(--vv-dim); font-family: var(--vv-mono); }
.vv-q-state { font-size: 12px; color: var(--vv-muted); min-width: 92px; text-align: right; }
.vv-q.done   .vv-q-state { color: var(--vv-ok); }
.vv-q.failed .vv-q-state { color: var(--vv-danger); }

.vv-bar { height: 5px; background: var(--vv-surface-2); border-radius: 3px; overflow: hidden; margin-top: 6px; }
.vv-bar-fill { height: 100%; width: 0; background: var(--vv-accent); transition: width .2s ease; }
.vv-q.done   .vv-bar-fill { background: var(--vv-ok); }
.vv-q.failed .vv-bar-fill { background: var(--vv-danger); }

.vv-quota { font-size: 12.5px; color: var(--vv-dim); margin-top: 12px; }
.vv-quota-bar { height: 6px; background: var(--vv-surface-2); border-radius: 3px; overflow: hidden; margin: 6px 0; }
.vv-quota-bar div { height: 100%; background: var(--vv-accent); }
.vv-quota-bar.warn div { background: var(--vv-warn); }

/* ------------------------------------------------------------- age gate --- */

.vv-agegate {
	position: fixed; inset: 0; z-index: 9999;
	background: rgba(8,10,14,.97);
	display: flex; align-items: center; justify-content: center; padding: 24px;
}
.vv-agegate-box {
	max-width: 480px; width: 100%; text-align: center;
	background: var(--vv-surface); border: 1px solid var(--vv-line);
	border-radius: 14px; padding: 40px 32px;
}
.vv-agegate-box .vv-wordmark { font-size: 26px; display: block; margin-bottom: 18px; }
.vv-agegate-box h2 { font-size: 1.25rem; margin-bottom: 12px; }
.vv-agegate-box p { color: var(--vv-muted); font-size: 14px; margin-bottom: 22px; }
.vv-agegate-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* --------------------------------------------------------------- tables --- */

.vv-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.vv-table th {
	text-align: left; padding: 10px 12px; font-size: 11px; font-weight: 600;
	text-transform: uppercase; letter-spacing: .06em; color: var(--vv-dim);
	border-bottom: 1px solid var(--vv-line);
}
.vv-table td { padding: 12px; border-bottom: 1px solid var(--vv-line-soft); color: var(--vv-text); vertical-align: middle; }
.vv-table tr:last-child td { border-bottom: 0; }
.vv-table tr:hover td { background: var(--vv-surface-2); }
.vv-table-wrap { overflow-x: auto; }

/* --------------------------------------------------------------- alerts --- */

.vv-body .alert { border: 1px solid var(--vv-line); border-radius: 8px; background: var(--vv-surface-2); color: var(--vv-text); padding: 12px 16px; font-size: 14px; }
.vv-body .alert-success { border-color: rgba(63,191,127,.4); color: #b6f0d2; }
.vv-body .alert-danger  { border-color: rgba(229,84,75,.4);  color: #ffc4c0; }
.vv-body .alert-warning { border-color: rgba(240,163,60,.4); color: #ffdca8; }
.vv-body .alert-info    { border-color: rgba(76,141,255,.4); color: #cfe0ff; }
.vv-flash { margin-bottom: 18px; }

/* --------------------------------------------------------------- pager ---- */

.vv-pager { margin-top: 34px; gap: 4px; }
.vv-pager .page-link {
	background: var(--vv-surface); border: 1px solid var(--vv-line);
	color: var(--vv-muted); border-radius: 6px; padding: 7px 13px; font-size: 13.5px;
}
.vv-pager .page-item.active .page-link { background: var(--vv-accent); border-color: var(--vv-accent); color: #fff; }
.vv-pager .page-item.disabled .page-link { opacity: .4; }
.vv-pager .page-link:hover { color: #fff; border-color: var(--vv-muted); }

/* --------------------------------------------------------------- empty ---- */

.vv-empty { text-align: center; padding: 64px 20px; color: var(--vv-muted); }
.vv-empty i { font-size: 46px; color: var(--vv-dim); display: block; margin-bottom: 14px; }
.vv-empty h3 { color: var(--vv-text); margin-bottom: 8px; }

/* -------------------------------------------------------------- landing --- */

.vv-hero { padding: 96px 0 76px; text-align: center; border-bottom: 1px solid var(--vv-line); }
.vv-hero .vv-wordmark { font-size: 40px; display: inline-block; margin-bottom: 20px; }
.vv-hero h1 { font-size: 2.4rem; margin-bottom: 16px; }
.vv-hero p { max-width: 620px; margin: 0 auto 30px; color: var(--vv-muted); font-size: 1.05rem; }
.vv-hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.vv-feature-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); padding: 56px 0; }
.vv-feature i { font-size: 28px; color: var(--vv-accent); display: block; margin-bottom: 12px; }
.vv-feature h3 { font-size: 1rem; margin-bottom: 6px; }
.vv-feature p { color: var(--vv-muted); font-size: 13.5px; margin: 0; }

/* --------------------------------------------------------------- forms ---- */

.vv-form-narrow { max-width: 440px; margin: 0 auto; }
.vv-form-wide   { max-width: 780px; }
.vv-form-foot { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--vv-line); font-size: 13.5px; color: var(--vv-muted); text-align: center; }

.vv-check { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: var(--vv-muted); }
.vv-check input { margin-top: 3px; flex-shrink: 0; }
.vv-check label { margin: 0; font-weight: 400; }

/* -------------------------------------------------------------- footer ---- */

.vv-body .vv-footer { background: #0a0d12; border-top: 1px solid var(--vv-line); padding: 40px 0 30px; }
.vv-footer-row { display: flex; flex-wrap: wrap; gap: 34px; justify-content: space-between; }
.vv-footer-row > div:first-child { max-width: 540px; }
.vv-footer-note { color: var(--vv-dim); font-size: 12.5px; line-height: 1.75; margin: 0; }
.vv-footer-links { font-size: 13px; color: var(--vv-muted); }
.vv-footer-links a { color: var(--vv-muted); }
.vv-footer-links a:hover { color: #fff; }
.vv-footer-copy { margin-top: 12px; font-size: 12px; color: var(--vv-dim); }

/* ------------------------------------------------------------ responsive -- */

@media (max-width: 991px) {
	.vv-body .primary-menu .menu-container { background: var(--vv-surface); }
	.vv-navsearch { display: none; }
}
@media (max-width: 575px) {
	.vv-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
	.vv-hero { padding: 64px 0 52px; }
	.vv-hero h1 { font-size: 1.8rem; }
	.vv-page { padding: 28px 0 52px; }
	.vv-panel { padding: 16px; }
}
