/**
 * RevisiNews — Custom Login Page Styles
 *
 * Portal Berita Indonesia | Sistem Redaksi Digital Profesional
 *
 * @package RevisiNews
 * @since   2.1.0
 */

/* ============================================================
   Import Google Fonts
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');

/* ============================================================
   CSS Custom Properties
   ============================================================ */
:root {
	--rn-red:         #c81e1e;
	--rn-red-dark:    #a31818;
	--rn-red-light:   #ef4444;
	--rn-navy:        #0f172a;
	--rn-navy-mid:    #1e293b;
	--rn-slate:       #334155;
	--rn-slate-light: #64748b;
	--rn-gray:        #f1f5f9;
	--rn-white:       #ffffff;
	--rn-shadow:      0 20px 60px rgba(0, 0, 0, 0.45);
	--rn-radius:      12px;
	--rn-transition:  all 0.25s ease;
}

/* ============================================================
   Reset & Base
   ============================================================ */
*,
*::before,
*::after {
	box-sizing: border-box;
}

/* ============================================================
   Body — Background gradient navy → hitam + noise overlay
   ============================================================ */
body.revisinews-login,
body.login.revisinews-login {
	font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	background-color: var(--rn-navy);
	background-image:
		/* subtle diagonal lines pattern — newspaper feel */
		repeating-linear-gradient(
			-45deg,
			transparent,
			transparent 3px,
			rgba(255, 255, 255, 0.015) 3px,
			rgba(255, 255, 255, 0.015) 4px
		),
		/* main gradient */
		linear-gradient(
			155deg,
			#0a0f1e 0%,
			var(--rn-navy) 35%,
			#1a0808 70%,
			#0d0505 100%
		);
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 20px;
	margin: 0;
}

/* ============================================================
   Login form wrapper — hapus padding default WP
   ============================================================ */
body.revisinews-login #login {
	width: 100%;
	max-width: 420px;
	padding: 0;
	margin: 0 auto;
}

/* ============================================================
   Logo area — Logo teks REVISINEWS + tagline
   ============================================================ */
body.revisinews-login #login h1 {
	margin: 0 0 32px;
	text-align: center;
	line-height: 1;
}

body.revisinews-login #login h1 a {
	/* Override WP default: ganti logo gambar dengan teks */
	background-image: none !important;
	width: auto !important;
	height: auto !important;
	display: block;
	text-indent: 0 !important;
	overflow: visible !important;
	font-family: 'Roboto', sans-serif;
	font-size: 36px;
	font-weight: 900;
	letter-spacing: 4px;
	text-transform: uppercase;
	color: var(--rn-red) !important;
	text-decoration: none;
	text-shadow:
		0 0 30px rgba(200, 30, 30, 0.5),
		0 2px 4px rgba(0, 0, 0, 0.6);
	transition: var(--rn-transition);
	outline: none;
}

body.revisinews-login #login h1 a::before {
	content: 'REVISI';
	color: var(--rn-white);
}

body.revisinews-login #login h1 a::after {
	content: 'NEWS';
	color: var(--rn-red);
}

/* Sembunyikan teks asli, tampilkan ::before / ::after */
body.revisinews-login #login h1 a {
	font-size: 0; /* sembunyikan teks node asli */
}

body.revisinews-login #login h1 a::before,
body.revisinews-login #login h1 a::after {
	font-size: 36px;
	font-weight: 900;
	letter-spacing: 3px;
}

body.revisinews-login #login h1 a:hover {
	text-shadow:
		0 0 50px rgba(200, 30, 30, 0.8),
		0 2px 4px rgba(0, 0, 0, 0.6);
}

/* Tagline di bawah logo */
body.revisinews-login #login h1::after {
	content: 'Sistem Redaksi Digital Profesional';
	display: block;
	font-family: 'Roboto', sans-serif;
	font-size: 11px;
	font-weight: 400;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.4);
	margin-top: 10px;
}

/* ============================================================
   Welcome message
   ============================================================ */
body.revisinews-login .revisinews-login-welcome {
	background: rgba(255, 255, 255, 0.07);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-left: 3px solid var(--rn-red);
	border-radius: 6px;
	color: rgba(255, 255, 255, 0.75);
	font-size: 13px;
	padding: 10px 14px;
	margin-bottom: 16px;
	text-align: center;
	font-family: 'Roboto', sans-serif;
}

/* ============================================================
   Form card — putih dengan shadow elegant
   ============================================================ */
body.revisinews-login #loginform,
body.revisinews-login #lostpasswordform,
body.revisinews-login #resetpassform,
body.revisinews-login #setupform {
	background: var(--rn-white);
	border: none;
	border-radius: var(--rn-radius);
	box-shadow: var(--rn-shadow);
	padding: 36px 40px;
	margin: 0 0 20px;
}

/* ============================================================
   Labels
   ============================================================ */
body.revisinews-login #loginform label,
body.revisinews-login #lostpasswordform label {
	font-family: 'Roboto', sans-serif;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	color: var(--rn-slate);
	display: block;
	margin-bottom: 6px;
}

/* ============================================================
   Input fields
   ============================================================ */
body.revisinews-login input[type="text"],
body.revisinews-login input[type="password"],
body.revisinews-login input[type="email"],
body.revisinews-login input[type="search"],
body.revisinews-login input[type="number"],
body.revisinews-login input[type="url"] {
	font-family: 'Roboto', sans-serif;
	font-size: 14px;
	font-weight: 400;
	color: var(--rn-navy);
	background: var(--rn-gray);
	border: 1.5px solid #e2e8f0;
	border-radius: 8px;
	padding: 11px 14px;
	width: 100%;
	transition: var(--rn-transition);
	outline: none;
	box-shadow: none;
}

body.revisinews-login input[type="text"]:focus,
body.revisinews-login input[type="password"]:focus,
body.revisinews-login input[type="email"]:focus {
	border-color: var(--rn-red);
	background: var(--rn-white);
	box-shadow: 0 0 0 3px rgba(200, 30, 30, 0.12);
}

body.revisinews-login input[type="text"]::placeholder,
body.revisinews-login input[type="password"]::placeholder {
	color: #94a3b8;
}

/* ============================================================
   Remember me checkbox
   ============================================================ */
body.revisinews-login .forgetmenot {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 0;
}

body.revisinews-login .forgetmenot label {
	font-size: 13px;
	font-weight: 400;
	text-transform: none;
	letter-spacing: 0;
	color: var(--rn-slate-light);
	cursor: pointer;
}

body.revisinews-login input[type="checkbox"] {
	width: 15px;
	height: 15px;
	accent-color: var(--rn-red);
	cursor: pointer;
}

/* ============================================================
   Submit button
   ============================================================ */
body.revisinews-login #wp-submit,
body.revisinews-login .button.button-primary.button-large,
body.revisinews-login input[type="submit"] {
	font-family: 'Roboto', sans-serif;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	color: var(--rn-white) !important;
	background: var(--rn-red) !important;
	border: none !important;
	border-radius: 8px !important;
	padding: 13px 24px !important;
	width: 100%;
	cursor: pointer;
	transition: var(--rn-transition);
	box-shadow: 0 4px 15px rgba(200, 30, 30, 0.35);
	text-shadow: none;
	outline: none;
}

body.revisinews-login #wp-submit:hover,
body.revisinews-login .button.button-primary.button-large:hover,
body.revisinews-login input[type="submit"]:hover {
	background: var(--rn-red-dark) !important;
	box-shadow: 0 6px 20px rgba(200, 30, 30, 0.5);
	transform: translateY(-1px);
}

body.revisinews-login #wp-submit:active,
body.revisinews-login input[type="submit"]:active {
	transform: translateY(0);
	box-shadow: 0 2px 8px rgba(200, 30, 30, 0.3);
}

body.revisinews-login #wp-submit:focus,
body.revisinews-login input[type="submit"]:focus {
	box-shadow: 0 0 0 3px rgba(200, 30, 30, 0.3), 0 4px 15px rgba(200, 30, 30, 0.35) !important;
}

/* ============================================================
   Submit + remember row
   ============================================================ */
body.revisinews-login .submit {
	margin-top: 20px;
}

body.revisinews-login #loginform .submit {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* ============================================================
   Nav links (Lupa password, kembali ke situs)
   ============================================================ */
body.revisinews-login #nav,
body.revisinews-login #backtoblog {
	text-align: center;
	padding: 0;
	margin: 0 0 10px;
}

body.revisinews-login #nav a,
body.revisinews-login #backtoblog a {
	font-family: 'Roboto', sans-serif;
	font-size: 13px;
	color: rgba(255, 255, 255, 0.5);
	text-decoration: none;
	transition: color 0.2s ease;
}

body.revisinews-login #nav a:hover,
body.revisinews-login #backtoblog a:hover {
	color: var(--rn-red-light);
}

/* ============================================================
   Error & success messages
   ============================================================ */
body.revisinews-login .login-error,
body.revisinews-login #login_error {
	background: #fff5f5;
	border: 1px solid #fecaca;
	border-left: 4px solid var(--rn-red);
	border-radius: 8px;
	color: #991b1b;
	font-family: 'Roboto', sans-serif;
	font-size: 13px;
	padding: 12px 16px;
	margin: 0 0 16px;
}

body.revisinews-login .message,
body.revisinews-login .updated {
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	border-left: 4px solid #16a34a;
	border-radius: 8px;
	color: #15803d;
	font-family: 'Roboto', sans-serif;
	font-size: 13px;
	padding: 12px 16px;
	margin: 0 0 16px;
}

/* ============================================================
   Privacy policy link
   ============================================================ */
body.revisinews-login .privacy-policy-page-link {
	text-align: center;
	margin: 0 0 10px;
}

body.revisinews-login .privacy-policy-page-link a {
	font-family: 'Roboto', sans-serif;
	font-size: 12px;
	color: rgba(255, 255, 255, 0.4);
	text-decoration: none;
}

body.revisinews-login .privacy-policy-page-link a:hover {
	color: rgba(255, 255, 255, 0.7);
}

/* ============================================================
   Footer kustom
   ============================================================ */
body.revisinews-login .revisinews-login-footer {
	font-family: 'Roboto', sans-serif;
}

/* ============================================================
   Hide default WP login logo (kita pakai CSS text logo)
   ============================================================ */
body.revisinews-login #login h1 a {
	background-image: none !important;
}

/* ============================================================
   Loading state
   ============================================================ */
body.revisinews-login .login .spinner {
	float: none;
	margin: 0 auto;
}

/* ============================================================
   Responsive — Mobile First
   ============================================================ */
@media (max-width: 480px) {
	body.revisinews-login {
		padding: 16px;
		justify-content: flex-start;
		padding-top: 40px;
	}

	body.revisinews-login #login {
		max-width: 100%;
	}

	body.revisinews-login #loginform,
	body.revisinews-login #lostpasswordform {
		padding: 28px 24px;
	}

	body.revisinews-login #login h1 a::before,
	body.revisinews-login #login h1 a::after {
		font-size: 28px;
	}
}

@media (max-width: 360px) {
	body.revisinews-login #loginform,
	body.revisinews-login #lostpasswordform {
		padding: 24px 18px;
	}

	body.revisinews-login #login h1 a::before,
	body.revisinews-login #login h1 a::after {
		font-size: 24px;
		letter-spacing: 2px;
	}
}

/* ============================================================
   High DPI / Retina
   ============================================================ */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
	body.revisinews-login {
		-webkit-font-smoothing: antialiased;
		-moz-osx-font-smoothing: grayscale;
	}
}

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition: none !important;
		animation: none !important;
	}
}
