/* Yellowhammer Trader — modal login (ODT / XenForo-style popup).
   Loaded from overall_header_headerbar_before.html on every phpBB page.
   The form + OAuth pills are scraped live from ucp.php?mode=login by
   yh_login_modal.js, so this file only styles the shell + injected markup. */

.yh-login-modal[hidden] { display: none !important; }

.yh-login-modal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding: 8vh 16px 16px;
	background: rgba(6, 12, 22, 0.72);
	backdrop-filter: blur(2px);
	overflow-y: auto;
}

.yh-login-card {
	width: 100%;
	max-width: 400px;
	background: #12233a;
	border: 1px solid #2f4763;
	border-top: 3px solid #d97a2c;
	border-radius: 10px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
	color: #f5e6c8;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	animation: yh-login-in 0.14s ease-out;
}

@keyframes yh-login-in {
	from { opacity: 0; transform: translateY(-8px); }
	to   { opacity: 1; transform: translateY(0); }
}

.yh-login-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 16px;
	border-bottom: 1px solid #243447;
}
.yh-login-head h2 {
	margin: 0;
	font-size: 1.05em;
	color: #f5d178;
}
.yh-login-close {
	background: none;
	border: none;
	color: #c9b88a;
	font-size: 1.5em;
	line-height: 1;
	cursor: pointer;
	padding: 0 4px;
}
.yh-login-close:hover { color: #f5d178; }

.yh-login-body { padding: 16px; }
.yh-login-body.is-loading { text-align: center; color: #c9b88a; padding: 40px 16px; }

/* --- normalise the scraped phpBB login form --- */
.yh-login-body #login .panel,
.yh-login-body #login .inner { background: none; border: 0; padding: 0; margin: 0; box-shadow: none; }
.yh-login-body #login h2.login-title { display: none; }
.yh-login-body #login .content + .content { margin-top: 4px; }

.yh-login-body #login fieldset.fields1 { padding: 0; border: 0; }
.yh-login-body #login dl { margin: 0 0 12px; }
.yh-login-body #login dt {
	float: none;
	width: auto;
	text-align: left;
	padding: 0 0 4px;
	font-size: 0.85em;
	color: #c9b88a;
	border: 0;
}
.yh-login-body #login dd {
	margin-left: 0;
	border: 0;
	padding: 0 0 2px;
}
.yh-login-body #login input.inputbox,
.yh-login-body #login input[type="text"],
.yh-login-body #login input[type="password"] {
	width: 100%;
	box-sizing: border-box;
	background: #0e1a2c;
	border: 1px solid #3d5265;
	border-radius: 6px;
	color: #f5e6c8;
	padding: 11px 12px;
	font-size: 1em;
}
.yh-login-body #login input.inputbox:focus { outline: 2px solid #d97a2c; outline-offset: 0; }

.yh-login-body #login dd label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 0.9em;
	color: #c9b88a;
}
.yh-login-body #login .error {
	background: #5a1a1a;
	border: 1px solid #8b2c2c;
	color: #ffd0d0;
	padding: 9px 11px;
	border-radius: 6px;
	margin-bottom: 12px;
	font-size: 0.9em;
}
.yh-login-body #login input[type="submit"].button1 {
	width: 100%;
	background: #d97a2c;
	color: #fff;
	border: 0;
	border-radius: 6px;
	padding: 12px;
	font-weight: 700;
	font-size: 1em;
	cursor: pointer;
	margin-top: 2px;
}
.yh-login-body #login input[type="submit"].button1:hover { background: #e6b53d; color: #0e1a2c; }

.yh-login-body #login a { color: #f5d178; text-decoration: none; }
.yh-login-body #login a:hover { text-decoration: underline; }
/* the "Login" heading — the modal header already says "Log in" */
.yh-login-body #login h2.login-title,
.yh-login-body #login h3 { display: none; }

/* --- OAuth pills (scraped .button2 links from login_body_oauth) --- */
.yh-login-oauth {
	margin-top: 4px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.yh-login-sep {
	text-align: center;
	color: #8b9bb0;
	font-size: 0.8em;
	text-transform: uppercase;
	letter-spacing: 1px;
	margin: 14px 0 10px;
	position: relative;
}
.yh-login-sep::before,
.yh-login-sep::after {
	content: "";
	position: absolute;
	top: 50%;
	width: 38%;
	height: 1px;
	background: #243447;
}
.yh-login-sep::before { left: 0; }
.yh-login-sep::after { right: 0; }

.yh-login-oauth a,
a.yh-oauth-pill {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	background: #0e1a2c;
	border: 1px solid #3d5265;
	border-radius: 6px;
	color: #f5e6c8 !important;
	padding: 11px 14px;
	font-weight: 600;
	text-decoration: none !important;
	font-size: 0.95em;
}
.yh-login-oauth a:hover,
a.yh-oauth-pill:hover { border-color: #d97a2c; background: #16283f; }

.yh-login-foot {
	margin-top: 14px;
	padding-top: 12px;
	border-top: 1px solid #243447;
	font-size: 0.88em;
	color: #c9b88a;
	text-align: center;
}
.yh-login-foot a { color: #f5d178; text-decoration: none; font-weight: 600; }
.yh-login-foot a:hover { text-decoration: underline; }

@media (max-width: 480px) {
	.yh-login-modal { padding: 0; align-items: stretch; }
	.yh-login-card { max-width: none; min-height: 100%; border-radius: 0; border-top-width: 3px; }
}
