/* Bedoott Resources — modal de captura de lead + descarga */

.rd-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: grid;
	place-items: center;
}
.rd-modal[hidden] { display: none; }

.rd-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(26, 37, 51, 0.55);
	backdrop-filter: blur(2px);
}

.rd-modal-card {
	position: relative;
	background: var(--paper, #FAF8F3);
	border-radius: var(--r-lg, 22px);
	box-shadow: 0 24px 60px -20px rgba(26, 37, 51, 0.35);
	padding: 32px;
	max-width: 520px;
	width: calc(100% - 24px);
	max-height: calc(100vh - 48px);
	overflow: auto;
	font-family: inherit;
	color: var(--ink, #1A2533);
}

.rd-modal-close {
	position: absolute;
	top: 14px; right: 16px;
	width: 32px; height: 32px;
	border-radius: 999px;
	background: transparent;
	border: 1px solid var(--line, #E5E0D4);
	font-size: 20px; line-height: 1;
	cursor: pointer;
	color: inherit;
	padding: 0;
}
.rd-modal-close:hover { background: var(--paper-warm, #F2EEE4); }

.rd-modal-eyebrow {
	font-family: var(--font-mono, ui-monospace, monospace);
	font-size: 11px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--muted, #6B6A67);
	margin-bottom: 8px;
}
.rd-modal-pane h3 {
	margin: 0 0 6px;
	font-size: 24px;
	font-weight: 800;
	letter-spacing: -0.01em;
	color: var(--ink, #1A2533);
	line-height: 1.2;
}
.rd-modal-sub {
	margin: 0 0 22px;
	color: var(--ink-soft, #4A4846);
	font-size: 14px;
	line-height: 1.55;
}

/* Form: reusa los estilos .rd-field globales del tema, pero los redefinimos aquí
   para que el modal no dependa del CSS del tema (puede usarse en cualquier sitio). */
.rd-modal-form { display: grid; gap: 14px; margin: 0; }
.rd-modal-form .rd-field { display: grid; gap: 6px; min-width: 0; }
.rd-modal-form .rd-field label {
	font-size: 13px; font-weight: 600;
	color: var(--ink, #1A2533);
}
.rd-modal-form .rd-field label span { color: #C0392B; }
.rd-modal-form .rd-field input {
	width: 100%; box-sizing: border-box;
	height: 44px;
	padding: 0 14px;
	border: 1px solid var(--line, #E5E0D4);
	border-radius: 10px;
	background: #fff;
	color: var(--ink, #1A2533);
	font: inherit;
	font-size: 15px;
	line-height: 1.4;
	-webkit-appearance: none;
	appearance: none;
	transition: border-color .15s ease, box-shadow .15s ease;
}
.rd-modal-form .rd-field input:focus {
	outline: none;
	border-color: var(--ink, #1A2533);
	box-shadow: 0 0 0 3px rgba(26, 37, 51, 0.12);
}
.rd-modal-form .rd-field--invalid input {
	border-color: #C0392B;
	box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.12);
}
.rd-modal-form .rd-hp {
	position: absolute !important;
	left: -10000px; top: auto;
	width: 1px; height: 1px;
	overflow: hidden;
}
.rd-modal-form .rd-error {
	margin: 0;
	color: #C0392B;
	font-size: 14px;
	font-weight: 600;
}
.rd-modal-form [data-rd-modal-submit] {
	margin: 4px 0 0;
	padding: 13px 22px;
	min-height: 44px;
	border: 0;
	border-radius: 12px;
	background: var(--ink, #1A2533);
	color: #fff;
	font: inherit;
	font-weight: 700;
	font-size: 15px;
	cursor: pointer;
	transition: transform .12s ease, opacity .15s ease;
	justify-self: start;
}
.rd-modal-form [data-rd-modal-submit]:hover { transform: translateY(-1px); }
.rd-modal-form [data-rd-modal-submit][disabled] { opacity: .6; cursor: progress; transform: none; }
.rd-modal-form .rd-legal {
	margin: 4px 0 0;
	font-size: 12px;
	line-height: 1.5;
	color: var(--muted, #6B6A67);
}

/* Pane de éxito */
.rd-modal-pane--ok { text-align: center; padding: 8px 0 4px; }
.rd-modal-pane--ok .rd-check { color: #2E7D32; display: inline-block; margin-bottom: 6px; }
.rd-modal-pane--ok h3 { margin: 0 0 8px; }
.rd-modal-pane--ok p { color: var(--ink-soft, #4A4846); font-size: 15px; margin: 0 0 14px; }
.rd-modal-pane--ok .btn {
	display: inline-block;
	padding: 11px 20px;
	border-radius: 10px;
	border: 1px solid var(--line, #E5E0D4);
	background: transparent;
	color: var(--ink, #1A2533);
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	transition: background .15s ease;
}
.rd-modal-pane--ok .btn:hover { background: var(--paper-warm, #F2EEE4); }

/* Cursor pointer en las tarjetas que abren modal (visual hint). */
.resource-card[data-rd-card] { cursor: pointer; }

@media (max-width: 480px) {
	.rd-modal-card { padding: 24px 22px; }
	.rd-modal-pane h3 { font-size: 20px; }
}
