/* verify.css — public PO verification. Dark-glass aesthetic ported from the app's
   style.css (same tokens, same raised/sunken vocabulary). Fully self-contained:
   system font stack, no external assets, no CDN — this page is internet-facing. */

:root {
	--glass: rgba(20, 20, 20, 0.35);
	--glass-blur: blur(24px) saturate(180%);
	--bevel: 1px solid rgba(255, 255, 255, 0.1);
	--bevel-top: rgba(255, 255, 255, 0.25);
	--bevel-left: rgba(255, 255, 255, 0.15);

	--ink: rgba(255, 255, 255, 0.9);
	--ink-muted: rgba(255, 255, 255, 0.45);
	--ink-faint: rgba(255, 255, 255, 0.25);

	/* verdict tints — the app's state RGB triples (po-approved / po-rejected / po-todo) */
	--tint-verified: 70, 200, 130;
	--tint-altered:  225, 95, 95;
	--tint-pending:  240, 185, 80;
	--tint-neutral:  150, 160, 175;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }

body {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
	color: var(--ink);
	background-color: #101014;
	background-image:
		radial-gradient(60vw 60vh at 15% 10%, rgba(60, 80, 170, 0.18), transparent 60%),
		radial-gradient(50vw 50vh at 85% 20%, rgba(150, 60, 140, 0.14), transparent 60%),
		radial-gradient(70vw 70vh at 50% 100%, rgba(40, 120, 130, 0.12), transparent 60%);
	background-attachment: fixed;
	-webkit-font-smoothing: antialiased;
}
body::before {
	content: "";
	position: fixed;
	inset: 0;
	z-index: -1;
	pointer-events: none;
	opacity: 0.04;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* the card — richer glass, same recipe as the app's .modal */
.card {
	width: 100%;
	max-width: 660px;
	padding: 40px;
	border-radius: 16px;
	background: rgba(20, 20, 22, 0.7);
	backdrop-filter: var(--glass-blur);
	-webkit-backdrop-filter: var(--glass-blur);
	border: var(--bevel);
	border-top-color: var(--bevel-top);
	border-left-color: var(--bevel-left);
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.brand { text-align: center; margin-bottom: 32px; }
.brand h1 { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; color: rgba(255, 255, 255, 0.95); }
.brand p { margin-top: 6px; color: var(--ink-muted); font-size: 14px; }

.brand-logo {
	display: block;
	height: 64px;
	margin: 0 auto 18px;
}
/* horizontal wordmark instead of an icon mark */
.brand-logo--wide {
	width: auto;
	height: 44px;
	max-width: 280px;
}

/* dropzone — sunken well (the app's text-entry vocabulary: dark top edge, inset shadow) */
.dropzone {
	display: block;
	padding: 44px 24px;
	text-align: center;
	cursor: pointer;
	border-radius: 14px;
	background: rgba(0, 0, 0, 0.22);
	border: 2px dashed rgba(255, 255, 255, 0.12);
	box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.4);
	transition: border-color 0.2s ease, background 0.2s ease;
}
.dropzone:hover,
.dropzone.dragover {
	border-color: rgba(120, 170, 255, 0.5);
	background: rgba(120, 170, 255, 0.08);
}
.dropzone svg { width: 40px; height: 40px; stroke: var(--ink-muted); margin-bottom: 12px; }
.dropzone .dz-main { font-weight: 550; color: rgba(255, 255, 255, 0.85); }
.dropzone .dz-sub { color: var(--ink-muted); font-size: 13px; margin-top: 4px; }
.dz-main.dz-chosen { color: rgba(150, 190, 255, 0.95); word-break: break-all; }

#file-input { display: none; }

.upload-error { color: rgba(235, 120, 120, 0.9); font-size: 13px; text-align: center; margin-top: 12px; min-height: 16px; }

/* primary button — raised glass pill (the app's .button-primary, verified tint) */
.btn {
	display: block;
	width: 100%;
	margin-top: 18px;
	padding: 14px;
	border: 1px solid rgba(90, 175, 130, 0.5);
	border-top-color: rgba(120, 230, 160, 0.7);
	border-radius: 14px;
	background: rgba(70, 200, 130, 0.22);
	color: rgba(255, 255, 255, 0.95);
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}
.btn:hover { background: rgba(70, 200, 130, 0.32); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(40, 160, 90, 0.3); }
.btn:active { transform: translateY(0); }
.btn:disabled {
	background: rgba(255, 255, 255, 0.06);
	border-color: rgba(255, 255, 255, 0.12);
	border-top-color: rgba(255, 255, 255, 0.2);
	color: var(--ink-faint);
	cursor: not-allowed;
	transform: none;
	box-shadow: none;
}

.link-btn {
	display: inline-block;
	margin-top: 24px;
	background: none;
	border: none;
	color: rgba(130, 180, 235, 0.95);
	font-size: 14px;
	font-weight: 550;
	cursor: pointer;
}
.link-btn:hover { text-decoration: underline; }

/* loading */
.loading { text-align: center; padding: 32px 0; }
.spinner {
	width: 38px; height: 38px;
	border: 3px solid rgba(255, 255, 255, 0.12);
	border-top-color: rgba(130, 180, 235, 0.95);
	border-radius: 50%;
	margin: 0 auto 14px;
	animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading p { color: var(--ink-muted); }

/* verdict — icon disc tinted via --tint, same glow recipe as the app's counters/pills */
.verdict { text-align: center; padding: 8px 0 4px; }
.verdict-icon {
	width: 64px; height: 64px;
	border-radius: 50%;
	display: flex; align-items: center; justify-content: center;
	margin: 0 auto 16px;
	font-size: 34px; font-weight: 700; line-height: 1;
	color: rgb(var(--tint, 150, 160, 175));
	background: rgba(var(--tint, 150, 160, 175), 0.18);
	border: 1px solid rgba(var(--tint, 150, 160, 175), 0.45);
	box-shadow: 0 0 18px rgba(var(--tint, 150, 160, 175), 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
.verdict h2 { font-size: 24px; letter-spacing: -0.01em; color: rgba(255, 255, 255, 0.95); margin-bottom: 6px; }
.verdict-sub { color: var(--ink-muted); max-width: 440px; margin: 0 auto; }

.verdict-verified { --tint: var(--tint-verified); }
.verdict-altered  { --tint: var(--tint-altered); }
.verdict-pending  { --tint: var(--tint-pending); }
.verdict-neutral  { --tint: var(--tint-neutral); }

/* advisory — raised panel, tinted by verdict */
.advisory {
	margin-top: 24px;
	padding: 16px 18px;
	border-radius: 12px;
	font-size: 14px;
	color: rgba(255, 255, 255, 0.85);
	background: rgba(var(--tint, 150, 160, 175), 0.1);
	border: 1px solid rgba(var(--tint, 150, 160, 175), 0.3);
	border-top-color: rgba(var(--tint, 150, 160, 175), 0.45);
}
.advisory strong { display: block; margin-bottom: 4px; color: rgba(255, 255, 255, 0.95); }
.advisory-altered { --tint: var(--tint-altered); }
.advisory-pending { --tint: var(--tint-pending); }

/* verified detail — raised card */
.detail {
	margin-top: 26px;
	border-radius: 14px;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-top-color: rgba(255, 255, 255, 0.2);
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.detail-po {
	padding: 14px 18px;
	text-align: center;
	font-weight: 700;
	font-size: 17px;
	letter-spacing: 0.02em;
	color: rgb(var(--tint-verified));
	background: rgba(var(--tint-verified), 0.15);
	border-bottom: 1px solid rgba(var(--tint-verified), 0.3);
}
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: rgba(255, 255, 255, 0.08); }
.detail-grid > div { background: rgba(20, 20, 22, 0.6); padding: 12px 18px; display: flex; flex-direction: column; }
.detail-grid .k { font-size: 12px; color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.detail-grid .v { font-weight: 550; margin-top: 2px; word-break: break-word; color: rgba(255, 255, 255, 0.9); }

.lines { width: 100%; border-collapse: collapse; font-size: 14px; }
.lines th, .lines td { padding: 10px 14px; text-align: left; border-top: 1px solid rgba(255, 255, 255, 0.08); color: rgba(255, 255, 255, 0.85); }
.lines th { background: rgba(255, 255, 255, 0.04); font-size: 12px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--ink-muted); font-weight: 600; }
.lines td.num, .lines th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

.grand-total {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 16px 18px;
	border-top: 2px solid rgba(255, 255, 255, 0.12);
	font-weight: 700;
	font-size: 17px;
	color: rgba(255, 255, 255, 0.95);
}

.foot { margin-top: 28px; text-align: center; font-size: 12px; color: var(--ink-faint); }
.hidden { display: none; }

@media (max-width: 480px) {
	.card { padding: 26px 20px; }
	.detail-grid { grid-template-columns: 1fr; }
	.lines th.desc, .lines td.desc { display: none; }
}


.ap-mail-link {
	color: rgba(130, 180, 235, 0.95);
	text-decoration: none;
	font-weight: 700;
}
.ap-mail-link:hover {
	text-decoration: underline;
}
