/* RedFly AI Concierge – Gerda widget (fa · barna · bézs) */
.rfac-root, .rfac-root * { box-sizing: border-box; }
.rfac-root {
	--rfac-shadow: 0 18px 50px rgba(59, 42, 26, .28), 0 3px 10px rgba(59, 42, 26, .12);
	font-family: var(--rfac-font, inherit);
	font-size: var(--rfac-fs, 15px);
	line-height: 1.5;
	color: var(--rfac-bot-fg);
	z-index: 2147483000;
}
.rfac-root button { font-family: inherit; cursor: pointer; margin: 0; text-transform: none; letter-spacing: normal; box-shadow: none; min-height: 0; line-height: 1; }
.rfac-root svg { width: 20px; height: 20px; fill: currentColor; display: block; }
.rfac-root [hidden] { display: none !important; }

/* ---------- Lebegő mód ---------- */
.rfac-floating { position: fixed; bottom: var(--rfac-y); }
.rfac-launcher {
	display: flex; align-items: center; gap: 10px; padding: 5px 18px 5px 5px; border: 0;
	background: linear-gradient(135deg, var(--rfac-primary), var(--rfac-secondary));
	color: var(--rfac-head-fg); border-radius: 999px; box-shadow: var(--rfac-shadow);
	transition: transform .2s ease, box-shadow .2s ease; position: relative;
}
.rfac-launcher:hover { transform: translateY(-2px); }
.rfac-launcher:focus { outline: none; }
.rfac-launcher:focus-visible { outline: 3px solid var(--rfac-accent); outline-offset: 3px; }
.rfac-launcher img { width: 52px; height: 52px; border-radius: 50%; background: var(--rfac-bg); border: 2px solid var(--rfac-accent); object-fit: cover; }
.rfac-launcher-label { font-weight: 600; font-size: 15px; white-space: nowrap; }
.rfac-launcher-label:empty { display: none; }
.rfac-launcher:has(.rfac-launcher-label:empty) { padding-right: 5px; }
.rfac-dot { position: absolute; left: 44px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: #5DBB63; border: 2px solid #fff; }
.rfac-pos-left .rfac-launcher { flex-direction: row; }
.rfac-open.rfac-floating .rfac-launcher { transform: scale(.92); }
.rfac-open.rfac-floating .rfac-launcher-label { display: none; }
.rfac-open.rfac-floating .rfac-launcher { padding-right: 5px; }

.rfac-teaser {
	position: absolute; bottom: 74px; width: 260px; padding: 14px 34px 14px 16px; border-radius: var(--rfac-radius);
	background: var(--rfac-bot-bg); color: var(--rfac-bot-fg); box-shadow: var(--rfac-shadow); font-size: 14px; cursor: pointer;
	opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .3s, transform .3s; border: 1px solid rgba(139, 94, 52, .18);
}
.rfac-pos-right .rfac-teaser { right: 0; }
.rfac-pos-left .rfac-teaser { left: 0; }
.rfac-teaser.rfac-show { opacity: 1; transform: none; pointer-events: auto; }
.rfac-teaser-x { position: absolute; top: 6px; right: 8px; border: 0; background: none; font-size: 18px; color: var(--rfac-secondary); padding: 2px 4px; }

.rfac-floating .rfac-panel {
	position: absolute; bottom: 76px; width: var(--rfac-w); height: var(--rfac-h); max-height: calc(100vh - var(--rfac-y) - 96px);
	opacity: 0; transform: translateY(14px) scale(.98); pointer-events: none; transition: opacity .22s ease, transform .22s ease;
}
.rfac-pos-right .rfac-panel { right: 0; transform-origin: bottom right; }
.rfac-pos-left .rfac-panel { left: 0; transform-origin: bottom left; }
.rfac-open.rfac-floating .rfac-panel { opacity: 1; transform: none; pointer-events: auto; }

/* ---------- Beágyazott mód ---------- */
.rfac-inline { position: relative; width: 100%; max-width: 760px; margin: 0 auto; }
.rfac-inline .rfac-panel { position: relative; width: 100%; height: var(--rfac-h, 640px); }

/* ---------- Panel ---------- */
.rfac-panel {
	display: flex; flex-direction: column; overflow: hidden; background: var(--rfac-bg);
	border-radius: var(--rfac-radius); box-shadow: var(--rfac-shadow); border: 1px solid rgba(92, 58, 33, .15);
}
.rfac-head {
	display: flex; align-items: center; gap: 12px; padding: 14px 12px 14px 16px; color: var(--rfac-head-fg); flex: 0 0 auto;
	background-color: var(--rfac-primary);
	background-image:
		repeating-linear-gradient(176deg, rgba(255, 255, 255, .035) 0 2px, transparent 2px 9px),
		repeating-linear-gradient(183deg, rgba(0, 0, 0, .06) 0 1px, transparent 1px 13px),
		linear-gradient(135deg, var(--rfac-primary) 0%, var(--rfac-secondary) 100%);
	border-bottom: 3px solid var(--rfac-accent);
}
.rfac-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--rfac-bg); border: 2px solid var(--rfac-accent); object-fit: cover; flex: 0 0 auto; }
.rfac-title { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.rfac-title strong { font-size: 17px; line-height: 1.2; letter-spacing: .01em; }
.rfac-title span { font-size: 12.5px; opacity: .88; display: block; line-height: 1.3; margin-top: 2px; }
.rfac-title span .rfac-online { display: inline-block; vertical-align: 1px; margin-right: 6px; }
.rfac-online { width: 8px; height: 8px; border-radius: 50%; background: #7ED48A; flex: 0 0 auto; box-shadow: 0 0 0 2px rgba(126, 212, 138, .25); }
.rfac-actions { display: flex; gap: 2px; }
.rfac-ic { border: 0; background: transparent; color: var(--rfac-head-fg); padding: 8px; border-radius: 10px; opacity: .9; }
.rfac-ic:hover { background: rgba(255, 255, 255, .14); opacity: 1; }
.rfac-speaking .rfac-tts { animation: rfac-pulse 1.2s infinite; }

.rfac-body { flex: 1 1 auto; overflow-y: auto; padding: 16px 14px 8px; scroll-behavior: smooth; overscroll-behavior: contain; }
.rfac-body::-webkit-scrollbar { width: 6px; }
.rfac-body::-webkit-scrollbar-thumb { background: rgba(139, 94, 52, .3); border-radius: 6px; }

.rfac-notice {
	display: flex; gap: 10px; align-items: flex-start; font-size: 12.5px; line-height: 1.45; color: var(--rfac-bot-fg);
	background: rgba(200, 162, 122, .18); border: 1px dashed rgba(139, 94, 52, .4); border-radius: calc(var(--rfac-radius) * .6); padding: 10px 12px; margin: 0 0 14px;
}
.rfac-notice p { margin: 0; }
.rfac-ai-badge { flex: 0 0 auto; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; color: #fff; background: var(--rfac-secondary); border-radius: 6px; padding: 3px 6px; margin-top: 1px; }
.rfac-admin-hint { font-size: 12px; background: #fff3cd; color: #6b4e00; border-radius: 8px; padding: 8px 10px; margin-bottom: 12px; }

.rfac-msg { display: flex; gap: 8px; margin: 0 0 12px; align-items: flex-end; animation: rfac-in .25s ease; }
.rfac-user { justify-content: flex-end; }
.rfac-mini { width: 28px; height: 28px; border-radius: 50%; background: var(--rfac-bot-bg); border: 1px solid var(--rfac-accent); flex: 0 0 auto; object-fit: cover; }
.rfac-bubble { position: relative; max-width: 82%; padding: 10px 14px; border-radius: calc(var(--rfac-radius) * .85); word-wrap: break-word; overflow-wrap: anywhere; }
.rfac-bot .rfac-bubble { background: var(--rfac-bot-bg); color: var(--rfac-bot-fg); border-bottom-left-radius: 6px; box-shadow: 0 1px 2px rgba(59, 42, 26, .08); border: 1px solid rgba(139, 94, 52, .12); }
.rfac-user .rfac-bubble { background: var(--rfac-user-bg); color: var(--rfac-user-fg); border-bottom-right-radius: 6px; }
.rfac-bubble p { margin: 0 0 .55em; }
.rfac-bubble p:last-child { margin-bottom: 0; }
.rfac-bubble ul, .rfac-bubble ol { margin: .2em 0 .6em 1.2em; padding: 0; }
.rfac-bubble li { margin: .15em 0; }
.rfac-bubble a { color: var(--rfac-secondary); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.rfac-user .rfac-bubble a { color: inherit; }
.rfac-bubble strong { font-weight: 700; }
.rfac-play { position: absolute; right: -10px; bottom: -10px; width: 26px; height: 26px; border-radius: 50%; border: 1px solid rgba(139, 94, 52, .25); background: var(--rfac-bg); color: var(--rfac-secondary); padding: 4px; opacity: 0; transition: opacity .2s; }
.rfac-play svg { width: 16px; height: 16px; }
.rfac-bot:hover .rfac-play, .rfac-play:focus { opacity: 1; }
@media (hover: none) { .rfac-play { opacity: .8; } }
.rfac-vtag { font-size: .9em; }

.rfac-typing .rfac-bubble { display: flex; align-items: center; gap: 10px; }
.rfac-typing small { font-size: 12px; opacity: .75; }
.rfac-dots { display: inline-flex; gap: 4px; }
.rfac-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--rfac-secondary); animation: rfac-bounce 1.2s infinite ease-in-out; }
.rfac-dots i:nth-child(2) { animation-delay: .15s; }
.rfac-dots i:nth-child(3) { animation-delay: .3s; }

/* Visszakérdező kártya */
.rfac-confirm { background: var(--rfac-bot-bg); border: 2px solid var(--rfac-accent); border-radius: calc(var(--rfac-radius) * .85); padding: 12px 14px; margin: 0 0 12px 36px; animation: rfac-in .25s ease; }
.rfac-confirm-h { font-size: 12.5px; font-weight: 700; color: var(--rfac-secondary); text-transform: uppercase; letter-spacing: .05em; }
.rfac-confirm blockquote { margin: 6px 0 8px; padding: 0 0 0 10px; border-left: 3px solid var(--rfac-accent); font-style: italic; color: var(--rfac-bot-fg); }
.rfac-confirm-i { margin: 0 0 10px; }
.rfac-confirm-b { display: flex; flex-wrap: wrap; gap: 6px; }
.rfac-confirm-b button { border: 1px solid var(--rfac-secondary); background: transparent; color: var(--rfac-secondary); border-radius: 999px; padding: 8px 12px; font-size: 13px; font-weight: 600; }
.rfac-confirm-b .rfac-yes { background: var(--rfac-secondary); color: #fff; }
.rfac-confirm-b button:hover { filter: brightness(1.08); }

/* Gyorsgombok */
.rfac-quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; flex: 0 0 auto; }
.rfac-chip { border: 1px solid rgba(139, 94, 52, .45); background: var(--rfac-bot-bg); color: var(--rfac-primary); border-radius: 999px; padding: 7px 12px; font-size: 13px; line-height: 1.25; text-align: left; transition: background .15s, color .15s; }
.rfac-chip:hover { background: var(--rfac-secondary); color: #fff; border-color: var(--rfac-secondary); }

/* Bevitel */
.rfac-input { display: flex; align-items: flex-end; gap: 6px; padding: 10px 10px 8px; border-top: 1px solid rgba(139, 94, 52, .18); background: var(--rfac-bot-bg); flex: 0 0 auto; margin: 0; }
.rfac-input textarea {
	flex: 1 1 auto; resize: none; border: 1px solid rgba(139, 94, 52, .3); border-radius: 14px; padding: 10px 12px; min-height: 42px; max-height: 120px;
	font: inherit; font-size: 16px; color: var(--rfac-bot-fg); background: #fff; outline: none; box-shadow: none; margin: 0; line-height: 1.35;
}
.rfac-input textarea:focus { border-color: var(--rfac-secondary); box-shadow: 0 0 0 3px rgba(139, 94, 52, .15); }
.rfac-mic, .rfac-send { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%; border: 0; display: grid; place-items: center; padding: 0; transition: transform .15s, background .15s; }
.rfac-mic { background: rgba(200, 162, 122, .25); color: var(--rfac-primary); }
.rfac-mic:hover { background: var(--rfac-accent); color: #fff; }
.rfac-send { background: var(--rfac-secondary); color: #fff; }
.rfac-send:hover { background: var(--rfac-primary); }
.rfac-send:disabled { opacity: .5; cursor: default; }
.rfac-mic:active, .rfac-send:active { transform: scale(.94); }

/* Felvétel sáv */
.rfac-rec { display: flex; align-items: center; gap: 10px; padding: 10px; border-top: 1px solid rgba(139, 94, 52, .18); background: var(--rfac-bot-bg); flex: 0 0 auto; }
.rfac-rec-cancel, .rfac-rec-done { width: 42px; height: 42px; border-radius: 50%; border: 0; display: grid; place-items: center; padding: 0; flex: 0 0 auto; }
.rfac-rec-cancel { background: rgba(200, 162, 122, .25); color: var(--rfac-primary); }
.rfac-rec-done { background: #B5452E; color: #fff; }
.rfac-rec-mid { flex: 1 1 auto; display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 13px; }
.rfac-rec-dot { width: 10px; height: 10px; border-radius: 50%; background: #D9452B; animation: rfac-pulse 1s infinite; flex: 0 0 auto; }
.rfac-rec-time { font-variant-numeric: tabular-nums; font-weight: 600; flex: 0 0 auto; }
.rfac-rec-live { flex: 1 1 auto; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; opacity: .8; }
.rfac-wave { display: inline-flex; gap: 3px; align-items: center; height: 20px; flex: 0 0 auto; }
.rfac-wave i { width: 3px; height: 6px; background: var(--rfac-secondary); border-radius: 2px; animation: rfac-wave 0.9s infinite ease-in-out; }
.rfac-wave i:nth-child(2) { animation-delay: .1s; } .rfac-wave i:nth-child(3) { animation-delay: .2s; } .rfac-wave i:nth-child(4) { animation-delay: .3s; } .rfac-wave i:nth-child(5) { animation-delay: .4s; }

.rfac-foot { font-size: 11px; text-align: center; padding: 0 10px 8px; background: var(--rfac-bot-bg); color: rgba(59, 42, 26, .6); flex: 0 0 auto; }
.rfac-foot a { color: inherit; text-decoration: underline; }

@keyframes rfac-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes rfac-bounce { 0%, 80%, 100% { transform: scale(.6); opacity: .5; } 40% { transform: scale(1); opacity: 1; } }
@keyframes rfac-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes rfac-wave { 0%, 100% { height: 5px; } 50% { height: 18px; } }

/* Mobil: teljes képernyő */
@media (max-width: 520px) {
	.rfac-floating .rfac-panel { position: fixed; inset: 0; width: 100%; height: 100%; max-height: none; border-radius: 0; bottom: 0; }
	.rfac-pos-right .rfac-panel, .rfac-pos-left .rfac-panel { left: 0; right: 0; }
	.rfac-open.rfac-floating .rfac-launcher, .rfac-open .rfac-teaser { display: none; }
	.rfac-launcher-label { display: none; }
	.rfac-launcher { padding: 5px; }
	.rfac-teaser { width: 220px; }
	.rfac-head { padding-top: max(14px, env(safe-area-inset-top)); }
	.rfac-foot { padding-bottom: max(8px, env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) {
	.rfac-root * { animation: none !important; transition: none !important; }
}
