.rrf {
	--rrf-bar: #2b2f31;
	--rrf-accent: #4B2C67;
	--rrf-accent-soft: #e6dfeb;
	--rrf-line: #bebebe;
	--rrf-ink: #212121;
	--rrf-mute: #5d6669;
	--rrf-err: #b3261e;
	max-width: 1100px;
	margin: 0 auto;
	color: var(--rrf-ink);
	font: inherit;
}
.rrf *, .rrf *::before, .rrf *::after { box-sizing: border-box; }
.rrf [hidden] { display: none !important; }

/* Step bar */
.rrf-steps {
	list-style: none;
	margin: 0;
	padding: 12px 18px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px 28px;
	background: var(--rrf-bar);
	color: #fff;
}
.rrf-step { display: flex; align-items: center; gap: 10px; font-size: 14px; opacity: .55; }
.rrf-step.is-active, .rrf-step.is-done { opacity: 1; }
.rrf-num {
	width: 30px; height: 30px; border-radius: 50%;
	display: grid; place-items: center;
	background: #565c5f; font-weight: 600; font-size: 14px;
}
.rrf-step.is-active .rrf-num { background: #fff; color: var(--rrf-bar); }
.rrf-step.is-done .rrf-num { background: var(--rrf-accent); }

/* Sections */
.rrf-form { padding: 20px 4px 8px; }
.rrf-head {
	display: flex; flex-wrap: wrap; align-items: center;
	justify-content: space-between; gap: 12px; margin-bottom: 16px;
}
.rrf-h { margin: 0; font-size: 1.15rem; font-weight: 700 !important; }
.rrf-h:focus { outline: none; }
.rrf-search {
	flex: 1 1 260px; max-width: 500px; min-height: 36px;
	padding: 5px 12px !important; border: 1px solid var(--rrf-line) !important; background: #fff; font: inherit; color: #212121; font-size: 14px; border-radius: 5px;
}
.rrf-search::placeholder {
    color: #212121;
}

/* Icon grid */
.rrf-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.rrf-tile {
	display: flex; flex-direction: column; align-items: center; justify-content: center;
	gap: 14px; min-height: 120px; padding: 18px 8px 16px;
	background-color: #fff !important; border: 1px solid var(--rrf-line) !important; border-radius: 0;
	color: var(--rrf-ink) !important; font: inherit; font-size: 12px; text-align: center; cursor: pointer;
	transition: all .2s ease-in-out; overflow: hidden;
}

.rrf-grid {
    max-height: 560px;
    overflow-y: auto;
    padding: 4px 15px 4px 4px;
}

.rrf-tile:hover .rrf-tile-label{
	color: #212121;
}

.rrf-tile:hover { box-shadow: 0 1px 10px rgba(0,0,0,.1); transform: scale(1.02); }
.rrf-tile:focus-visible { outline: 3px solid var(--rrf-accent); outline-offset: 2px; }
.rrf-tile:active { background: var(--rrf-accent-soft); }
.rrf-icon { font-size: 84px; line-height: 1; }
.rrf-icon-img { width: 56px; height: 56px; object-fit: contain; }
.rrf-empty { color: var(--rrf-mute); }

.rrf-tile .rrf-tile-label{
	white-space: normal;
}

/* Fields */
.rrf-notice {
	margin: 0 0 16px; padding: 12px 14px;
	background: #fdf1f0; border-left: 4px solid var(--rrf-err); font-size: 14px;
}
.rrf-fields { display: grid; gap: 18px; max-width: 640px; }
.rrf-field label, .rrf-pills legend { display: block; margin-bottom: 6px; font-weight: 600; font-size: 14px; }
.rrf-field input[type="text"], .rrf-field input[type="email"], .rrf-field input[type="tel"],
.rrf-field input[type="file"], .rrf-field select, .rrf-field textarea {
	width: 100%; min-height: 44px; padding: 9px 12px;
	border: 1px solid var(--rrf-line); background: #fff; color: var(--rrf-ink); font: inherit; border-radius: 4px;
}
.rrf-field textarea { resize: vertical; }
.rrf-field input:focus, .rrf-field select:focus, .rrf-field textarea:focus {
	outline: 3px solid var(--rrf-accent); outline-offset: 0; border-color: var(--rrf-accent);
}
.rrf-field.has-error input, .rrf-field.has-error select, .rrf-field.has-error textarea { border-color: var(--rrf-err); }
.rrf-err { margin: 6px 0 0; color: var(--rrf-err); font-size: 13px; }
.rrf-hint { margin: 6px 0 0; color: var(--rrf-mute); font-size: 13px; word-break: break-word; }

/* Radio pills */
.rrf-pills { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.rrf-pills legend { width: 100%; padding: 0; }
.rrf-pill { position: relative; margin: 0 !important; }
.rrf-pill input { position: absolute; opacity: 0; }
.rrf-pill span {
	display: inline-block; padding: 6px 16px; border: 1px solid var(--rrf-line);
	background: #fff; font-weight: 400; cursor: pointer; border-radius: 5px;
}
.rrf-pill input:checked + span { border-color: var(--rrf-accent); background: var(--rrf-accent-soft); box-shadow: 0 0 0 1px var(--rrf-accent); }
.rrf-pill input:focus-visible + span { outline: 3px solid var(--rrf-accent); outline-offset: 2px; }

/* Navigation */
.rrf-nav {
	display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
	margin-top: 24px; padding: 14px 16px; background: #fff; border: 1px solid #e8e8e8; border-radius: 4px;
}
.rrf-nav-hint { font-weight: 600; font-size: 14px; }
.rrf-msg { flex: 1 1 100%; margin: 0; color: var(--rrf-err); font-size: 14px; order: 5; }
.rrf-btn {
	padding: 6px 12px; border: 1px solid var(--rrf-accent);
	background: var(--rrf-accent); color: #fff; font: inherit; font-weight: 600; cursor: pointer; border-radius: 4px; font-size: 14px;
}
.rrf-btn:hover { filter: brightness(1.12); }
.rrf-btn:focus-visible { outline: 3px solid var(--rrf-bar); outline-offset: 2px; }
.rrf-btn:disabled { opacity: .6; cursor: wait; }
.rrf-btn-ghost { background: #fff !important; color: var(--rrf-accent) !important; border: 1px solid var(--rrf-accent) !important; }

/* Honeypot: off-screen, not display:none */
.rrf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Done */
.rrf-done { padding: 32px 8px; max-width: 640px; }
.rrf-done p { margin: 12px 0 20px; }

@media (min-width: 640px) { .rrf-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .rrf-grid { grid-template-columns: repeat(5, 1fr); } }
@media (prefers-reduced-motion: reduce) { .rrf-tile { transition: none; } }



/* ---------- popup shown before continuing (optional per category / subcategory) ---------- */
.rrf-modal-bg {
	--rrf-bar: #2b2f31; --rrf-accent: #0e5c47; --rrf-line: #d6dad9; --rrf-ink: #1f2426;
	position: fixed; inset: 0; z-index: 99999; display: flex; align-items: center; justify-content: center;
	padding: 16px; background: rgba(0, 0, 0, .55); font-family: inherit; color: var(--rrf-ink);
}
.rrf-modal {
	position: relative; display: flex; flex-direction: column; width: 100%; max-width: 640px;
	max-height: 86vh; background: #fff; box-shadow: 0 10px 40px rgba(0, 0, 0, .35);
}
.rrf-modal-x {
	position: absolute; top: 6px; right: 8px; width: 32px; height: 32px; padding: 0; border: 0;
	background: transparent; color: #666; font-size: 26px; line-height: 1; cursor: pointer;
}
.rrf-modal-x:hover { color: #000; }
.rrf-modal-body {
	flex: 1 1 auto; min-height: 0; overflow-y: auto; margin: 40px 16px 8px 24px; padding-right: 12px;
	font-size: 14px; line-height: 1.5; scrollbar-width: thin;
}
.rrf-modal-body p { margin: 0 0 12px; }
.rrf-modal-body ul, .rrf-modal-body ol { margin: 0 0 12px 20px; padding: 0; }
.rrf-modal-body li { margin-bottom: 8px; }
.rrf-modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 24px 16px; }
.rrf-modal-foot .rrf-btn { min-height: 38px; padding: 8px 18px; border-radius: 3px; }
.rrf-modal-open { overflow: hidden; }
@media (max-width: 480px) { .rrf-modal-foot .rrf-btn { flex: 1 1 0; } }
