/* Időpontom – letisztult, modern felület */
:root {
  color-scheme: light;
  --primary: #4f46e5;
  --primary-ink: #ffffff;
  --primary-soft: color-mix(in srgb, var(--primary) 10%, var(--surface));
  --accent: var(--primary);            /* főszínű szöveg (linkek, kiemelések) – sötét módban világosítva */
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f3f4f6;                /* halvány kitöltés: jelvény, input addon */
  --surface-hover: #f9fafb;
  --row-hover: #fafafa;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --input-bg: #ffffff;
  --input-line: #d1d5db;
  --step-bg: #eef0f5;
  --disabled-ink: #c0c4cc;
  --badge-ink: #374151;
  --header-glass: rgba(255, 255, 255, .85);
  --ok: #059669;
  --ok-soft: #ecfdf5;
  --ok-line: #a7f3d0;
  --ok-ink: #065f46;
  --warn: #b45309;
  --warn-soft: #fffbeb;
  --warn-line: #fde68a;
  --warn-ink: #92400e;
  --bad: #dc2626;
  --bad-soft: #fef2f2;
  --bad-line: #fecaca;
  --bad-ink: #991b1b;
  --info: #2563eb;
  --info-soft: #eff6ff;
  --info-line: #bfdbfe;
  --info-ink: #1e40af;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 16px rgba(16, 24, 40, .06);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ---- Sötét mód ----
   A <head> szkript a mentett választás vagy a rendszerbeállítás alapján data-theme-et tesz a <html>-re.
   JS nélkül a @media ág követi a rendszert. A két blokk értékei egyezzenek! */
:root[data-theme="dark"] {
  color-scheme: dark;
  --primary-soft: color-mix(in srgb, var(--primary) 22%, var(--surface));
  --accent: color-mix(in srgb, var(--primary) 62%, white);
  --bg: #0b1120;
  --surface: #131c2e;
  --surface-2: #1e293b;
  --surface-hover: #1a2539;
  --row-hover: #18233a;
  --ink: #e5e7eb;
  --muted: #94a3b8;
  --line: #26334a;
  --input-bg: #0f172a;
  --input-line: #334155;
  --step-bg: #1e293b;
  --disabled-ink: #475569;
  --badge-ink: #cbd5e1;
  --header-glass: rgba(19, 28, 46, .85);
  --ok: #10b981;
  --ok-soft: rgba(16, 185, 129, .14);
  --ok-line: rgba(52, 211, 153, .35);
  --ok-ink: #a7f3d0;
  --warn: #f59e0b;
  --warn-soft: rgba(245, 158, 11, .14);
  --warn-line: rgba(251, 191, 36, .35);
  --warn-ink: #fde68a;
  --bad: #ef4444;
  --bad-soft: rgba(239, 68, 68, .14);
  --bad-line: rgba(248, 113, 113, .35);
  --bad-ink: #fecaca;
  --info: #3b82f6;
  --info-soft: rgba(59, 130, 246, .14);
  --info-line: rgba(96, 165, 250, .35);
  --info-ink: #bfdbfe;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --primary-soft: color-mix(in srgb, var(--primary) 22%, var(--surface));
    --accent: color-mix(in srgb, var(--primary) 62%, white);
    --bg: #0b1120;
    --surface: #131c2e;
    --surface-2: #1e293b;
    --surface-hover: #1a2539;
    --row-hover: #18233a;
    --ink: #e5e7eb;
    --muted: #94a3b8;
    --line: #26334a;
    --input-bg: #0f172a;
    --input-line: #334155;
    --step-bg: #1e293b;
    --disabled-ink: #475569;
    --badge-ink: #cbd5e1;
    --header-glass: rgba(19, 28, 46, .85);
    --ok: #10b981;
    --ok-soft: rgba(16, 185, 129, .14);
    --ok-line: rgba(52, 211, 153, .35);
    --ok-ink: #a7f3d0;
    --warn: #f59e0b;
    --warn-soft: rgba(245, 158, 11, .14);
    --warn-line: rgba(251, 191, 36, .35);
    --warn-ink: #fde68a;
    --bad: #ef4444;
    --bad-soft: rgba(239, 68, 68, .14);
    --bad-line: rgba(248, 113, 113, .35);
    --bad-ink: #fecaca;
    --info: #3b82f6;
    --info-soft: rgba(59, 130, 246, .14);
    --info-line: rgba(96, 165, 250, .35);
    --info-ink: #bfdbfe;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
  }
}

/* Téma váltó gomb (☀️/🌙) */
.theme-toggle { display: inline-grid; place-items: center; width: 36px; height: 36px; flex: none; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--ink); cursor: pointer; padding: 0; }
.theme-toggle:hover { background: var(--surface-hover); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .theme-toggle .i-sun { display: block; }
  :root:not([data-theme]) .theme-toggle .i-moon { display: none; }
}
.auth-theme { position: fixed; top: calc(14px + env(safe-area-inset-top, 0px)); right: 14px; z-index: 30; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 15px; line-height: 1.55; color: var(--ink); background: var(--bg); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .6em; letter-spacing: -.01em; }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.08rem; }
p { margin: 0 0 1em; }
small, .muted { color: var(--muted); }
hr { border: 0; border-top: 1px solid var(--line); margin: 1.5rem 0; }
[hidden] { display: none !important; }

.container { width: 100%; max-width: 1080px; margin: 0 auto; padding-inline: 20px; }
.container.narrow { max-width: 720px; }
.stack > * + * { margin-top: 1rem; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.spacer { flex: 1; }
/* robotcsapda mező (BotGuard) – embernek láthatatlan */
.hp-field { position: absolute !important; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.text-right { text-align: right; }
.nowrap { white-space: nowrap; }

/* ---- Kártyák ---- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; }
.card + .card { margin-top: 16px; }
.grid > .card, .grid > * > .card:first-child { margin-top: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; }
.stat { padding: 18px 20px; }
.stat .num { font-size: 1.9rem; font-weight: 700; line-height: 1.1; }
.stat .label { color: var(--muted); font-size: .88rem; }

/* ---- Gombok ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid transparent; border-radius: var(--radius-sm);
  padding: 10px 16px; font: inherit; font-weight: 600; cursor: pointer; background: var(--primary); color: var(--primary-ink); text-decoration: none; transition: filter .15s, background .15s; white-space: nowrap; }
.btn:hover { filter: brightness(1.07); text-decoration: none; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { background: var(--surface-hover); filter: none; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.danger { background: var(--bad); color: #fff; }
.btn.ok { background: var(--ok); color: #fff; }
.btn.sm { padding: 6px 11px; font-size: .85rem; }
.btn.lg { padding: 13px 22px; font-size: 1.02rem; }
.btn.block { width: 100%; }
.inline-form { display: inline; margin: 0; }

/* ---- Űrlapok ---- */
.form { display: grid; gap: 16px; }
.field label, .label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.field .hint { color: var(--muted); font-size: .82rem; margin-top: 5px; }
input:not([type]), input[type=text], input[type=url], input[type=email], input[type=password], input[type=tel], input[type=number], input[type=date], input[type=time], input[type=search], select, textarea {
  width: 100%; font: inherit; color: inherit; background: var(--input-bg); border: 1px solid var(--input-line); border-radius: var(--radius-sm); padding: 10px 12px; transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
textarea { min-height: 90px; resize: vertical; }
input[type=color] { width: 54px; height: 40px; padding: 3px; border: 1px solid var(--input-line); border-radius: var(--radius-sm); background: var(--input-bg); }
input[type=time] { width: auto; min-width: 110px; }
.check { display: flex; gap: 9px; align-items: flex-start; font-weight: 500; cursor: pointer; }
.check input { margin-top: 4px; width: 17px; height: 17px; accent-color: var(--primary); flex: none; }
.field-error { color: var(--bad); font-size: .84rem; margin-top: 5px; }
.input-group { display: flex; align-items: stretch; }
.input-group input { border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.input-group .addon { display: flex; align-items: center; padding: 0 12px; background: var(--surface-2); border: 1px solid var(--input-line); border-left: 0; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; color: var(--muted); white-space: nowrap; font-size: .9rem; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin: 0; }
legend { font-weight: 700; padding: 0 6px; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; padding-top: 4px; }

/* ---- Üzenetek ---- */
.alert { border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 14px; border: 1px solid; font-size: .94rem; word-break: break-word; }
.alert.success { background: var(--ok-soft); border-color: var(--ok-line); color: var(--ok-ink); }
.alert.error { background: var(--bad-soft); border-color: var(--bad-line); color: var(--bad-ink); }
.alert.info { background: var(--info-soft); border-color: var(--info-line); color: var(--info-ink); }
.alert.warn { background: var(--warn-soft); border-color: var(--warn-line); color: var(--warn-ink); }

/* ---- Jelvények ---- */
.badge { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: .78rem; font-weight: 600; background: var(--surface-2); color: var(--badge-ink); white-space: nowrap; }
.badge.pending { background: var(--warn-soft); color: var(--warn); }
.badge.confirmed, .badge.active, .badge.completed { background: var(--ok-soft); color: var(--ok); }
.badge.rejected, .badge.cancelled, .badge.blocked, .badge.suspended, .badge.no_show { background: var(--bad-soft); color: var(--bad); }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; vertical-align: middle; margin-right: 6px; }

/* ---- Táblázatok ---- */
.table-wrap { overflow-x: auto; margin: 0 -22px; padding: 0 22px; }
table.table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.table th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; padding: 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tr.clickable { cursor: pointer; }
.table tr.clickable:hover td { background: var(--row-hover); }
.empty { text-align: center; color: var(--muted); padding: 30px 10px; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 12px 0; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.list li:last-child { border-bottom: 0; }
.dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 0; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; font-weight: 500; }

/* ---- Nyilvános (cég) oldal ---- */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; }
.site-header .container { display: flex; align-items: center; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.08rem; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img { height: 38px; width: auto; border-radius: 8px; }
.brand .mark { width: 34px; height: 34px; border-radius: 10px; background: var(--primary); color: #fff; display: grid; place-items: center; font-weight: 800; }
.site-nav { display: flex; gap: 6px; margin-left: auto; align-items: center; flex-wrap: wrap; }
.site-nav a { color: var(--ink); padding: 8px 12px; border-radius: 8px; font-weight: 500; }
.site-nav a:hover, .site-nav a.active { background: var(--primary-soft); color: var(--accent); text-decoration: none; }
.site-main { padding-block: 32px 56px; }
.site-footer { text-align: center; color: var(--muted); font-size: .85rem; padding: 26px 0 40px; }
.hero { background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--primary) 60%, #000)); color: #fff; border-radius: 20px; padding: 40px 34px; margin-bottom: 28px; }
.hero h1 { font-size: 2rem; margin-bottom: .3em; }
.hero p { opacity: .92; max-width: 640px; }
.hero .btn { background: #fff; color: var(--primary); }
/* Banner kép a színátmenet helyett: a kép a keretet kitölti, a fókuszpont és nagyítás inline stílusból jön */
.hero.has-banner { position: relative; overflow: hidden; isolation: isolate; background: #1f2937; min-height: 220px; text-shadow: 0 1px 3px rgba(0, 0, 0, .35); }
.hero.has-banner .hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; user-select: none; pointer-events: none; }
.hero.has-banner::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(0, 0, 0, var(--ov, .35)); }
.hero.has-banner .btn { text-shadow: none; }
/* Admin: banner igazító előnézet */
.banner-preview { margin-bottom: 0; cursor: grab; touch-action: none; outline-offset: 3px; }
.banner-preview.dragging { cursor: grabbing; }
.banner-preview.removed { opacity: .35; filter: grayscale(1); }
.banner-preview .btn { pointer-events: none; }
.service-card { display: flex; flex-direction: column; gap: 6px; }
.service-card .meta { display: flex; gap: 12px; flex-wrap: wrap; color: var(--muted); font-size: .88rem; }
.service-card .price { font-weight: 700; color: var(--ink); }
.service-card .btn { margin-top: auto; align-self: flex-start; }
.hours-table td { padding: 4px 14px 4px 0; vertical-align: top; white-space: nowrap; }
.hours-table tr.today td { font-weight: 700; color: var(--accent); }

/* ---- Auth kártya ---- */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 30px 16px; }
.auth-card { width: 100%; max-width: 420px; }
.auth-card .brand { justify-content: center; margin-bottom: 18px; }
.auth-links { display: flex; justify-content: space-between; gap: 10px; font-size: .9rem; margin-top: 14px; flex-wrap: wrap; }

/* ---- Foglalási varázsló ---- */
.steps { display: flex; gap: 8px; margin-bottom: 22px; flex-wrap: wrap; }
.steps .step { flex: 1; min-width: 110px; padding: 10px 12px; border-radius: 10px; background: var(--step-bg); color: var(--muted); font-size: .86rem; font-weight: 600; }
.steps .step.on { background: var(--primary); color: #fff; }
.steps .step.done { background: var(--primary-soft); color: var(--accent); cursor: pointer; }
.choice-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.choice { text-align: left; background: var(--surface); border: 2px solid var(--line); border-radius: var(--radius); padding: 16px; cursor: pointer; font: inherit; color: inherit; transition: border-color .15s, transform .1s; }
.choice:hover { border-color: color-mix(in srgb, var(--primary) 50%, var(--surface)); }
.choice.on { border-color: var(--primary); background: var(--primary-soft); }
.choice strong { display: block; margin-bottom: 3px; }
.choice .meta { color: var(--muted); font-size: .86rem; }
.picker { display: grid; grid-template-columns: minmax(260px, 340px) 1fr; gap: 22px; align-items: start; }
.cal { user-select: none; }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; font-weight: 700; }
.cal-head button { background: none; color: inherit; border: 1px solid var(--line); border-radius: 8px; width: 34px; height: 34px; cursor: pointer; font-size: 1rem; }
.cal-head button:disabled { opacity: .3; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-grid .dow { text-align: center; font-size: .75rem; color: var(--muted); font-weight: 600; padding: 4px 0; }
.cal-grid button { aspect-ratio: 1; border: 0; border-radius: 9px; font: inherit; font-size: .92rem; background: transparent; color: var(--disabled-ink); cursor: default; position: relative; }
.cal-grid button.avail { background: var(--primary-soft); color: var(--accent); font-weight: 700; cursor: pointer; }
.cal-grid button.avail:hover { filter: brightness(.96); }
.cal-grid button.today { outline: 2px solid var(--line); }
.cal-grid button.sel { background: var(--primary); color: #fff; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
.slot { border: 1px solid var(--line); background: var(--surface); color: inherit; border-radius: 9px; padding: 10px 6px; font: inherit; font-weight: 600; cursor: pointer; text-align: center; }
.slot small { display: block; font-weight: 500; font-size: .72rem; }
.slot:hover { border-color: var(--primary); }
.slot.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.slot.on small { color: #fff; }
.agenda-day { padding: 14px 0; border-top: 1px solid var(--line); }
.agenda-day:first-child { border-top: 0; padding-top: 4px; }
.agenda-day h3 { margin: 0 0 10px; font-size: 1rem; }
.agenda-more:empty { display: none; }
.agenda .slot:hover { background: var(--primary-soft); }
/* Főoldal: szolgáltatásonkénti foglalható napok, kattintható időpontokkal */
.svc-days { display: flex; flex-direction: column; gap: 10px; margin: 4px 0 10px; }
.svc-day { border-top: 1px solid var(--line); padding-top: 8px; }
.svc-day-label { font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.svc-slots { display: flex; flex-wrap: wrap; gap: 6px; }
a.slot { display: inline-block; text-decoration: none; color: inherit; padding: 6px 10px; font-size: .88rem; min-width: 58px; }
a.slot:hover { background: var(--primary-soft); color: var(--accent); }
.summary { background: var(--primary-soft); border-radius: var(--radius); padding: 16px 18px; }
.loading { color: var(--muted); padding: 14px 0; }

/* ---- Admin elrendezés ---- */
.admin { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.sidebar { background: #0f172a; color: #cbd5e1; border-right: 1px solid var(--line); padding: 20px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; }
.sidebar .brand { color: #fff; padding: 4px 8px 18px; }
.sidebar nav a { display: flex; align-items: center; gap: 10px; color: #cbd5e1; padding: 9px 12px; border-radius: 9px; font-weight: 500; margin-bottom: 2px; }
.sidebar nav a:hover { background: rgba(255, 255, 255, .06); color: #fff; text-decoration: none; }
.sidebar nav a.active { background: var(--primary); color: #fff; }
.sidebar nav .sep { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #64748b; padding: 16px 12px 6px; }
.sidebar .count { margin-left: auto; background: #f59e0b; color: #111; border-radius: 99px; font-size: .72rem; font-weight: 700; padding: 1px 7px; }
.sidebar .side-foot { margin-top: auto; padding: 14px 8px 0; font-size: .84rem; border-top: 1px solid rgba(255, 255, 255, .08); }
.sidebar .side-foot a, .sidebar .side-foot button { color: #94a3b8; background: none; border: 0; font: inherit; cursor: pointer; padding: 0; }
.ico { width: 18px; height: 18px; flex: none; }
.admin-main { min-width: 0; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 14px 28px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.topbar h1 { font-size: 1.2rem; margin: 0; min-width: 0; overflow-wrap: anywhere; }
.top-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.menu-btn { display: none; background: none; color: inherit; border: 1px solid var(--line); border-radius: 8px; padding: 6px 9px; cursor: pointer; }
.admin-content { padding: 26px 28px 60px; max-width: 1240px; }
.setup-list li { justify-content: space-between; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 16px; }
.filters .field { min-width: 140px; }
.filters .field.grow { flex: 1; min-width: 200px; }

/* nyitvatartás szerkesztő */
.hours-editor .day { display: grid; grid-template-columns: 140px 1fr; gap: 12px; align-items: start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.hours-editor .day:last-child { border-bottom: 0; }
.hours-editor .ranges { display: flex; flex-direction: column; gap: 8px; }
.hours-editor .range { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.hours-editor .day.closed .ranges { opacity: .4; pointer-events: none; }

/* FullCalendar finomhangolás */
.fc { --fc-border-color: var(--line); --fc-today-bg-color: var(--primary-soft); --fc-button-bg-color: var(--surface); --fc-button-text-color: var(--ink);
  --fc-page-bg-color: var(--surface); --fc-neutral-bg-color: var(--surface-2); --fc-list-event-hover-bg-color: var(--row-hover);
  --fc-button-border-color: var(--line); --fc-button-hover-bg-color: var(--surface-2); --fc-button-hover-border-color: var(--line);
  --fc-button-active-bg-color: var(--primary); --fc-button-active-border-color: var(--primary); font-size: .9rem; }
.fc .fc-button-primary:not(:disabled).fc-button-active, .fc .fc-button-primary:not(:disabled):active { color: #fff; }
.fc .fc-toolbar-title { font-size: 1.15rem; text-transform: capitalize; }
.fc-event { cursor: pointer; border-radius: 6px; padding: 1px 3px; }
.fc-event.ev-pending { background-image: repeating-linear-gradient(45deg, rgba(255, 255, 255, .25) 0 6px, transparent 6px 12px); }
.fc-event.ev-cancelled, .fc-event.ev-rejected { opacity: .45; text-decoration: line-through; }
.fc-event.ev-completed { opacity: .75; }

/* ---- Platform (marketing) ---- */
.pf-header { background: var(--header-glass); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; }
.pf-header .container { display: flex; align-items: center; min-height: 66px; gap: 16px; flex-wrap: wrap; }
.pf-hero { padding: 80px 0 60px; text-align: center; }
.pf-hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); max-width: 820px; margin: 0 auto .4em; letter-spacing: -.025em; }
.pf-hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 640px; margin: 0 auto 1.8em; }
.gradient-text { background: linear-gradient(90deg, #4f46e5, #0ea5e9); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pf-section { padding: 56px 0; }
.pf-section h2 { text-align: center; font-size: 1.8rem; margin-bottom: .3em; }
.pf-section .sub { text-align: center; color: var(--muted); margin-bottom: 2rem; }
.feature .icon { width: 44px; height: 44px; border-radius: 12px; background: var(--primary-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 12px; font-size: 1.35rem; }
.feature p { color: var(--muted); margin: 0; font-size: .95rem; }
.how { counter-reset: step; }
.how .card::before { counter-increment: step; content: counter(step); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 700; margin-bottom: 12px; }
.mock { max-width: 900px; margin: 40px auto 0; border-radius: 18px; border: 1px solid var(--line); box-shadow: 0 20px 60px rgba(79, 70, 229, .15); background: var(--surface); padding: 18px; text-align: left; }
.cta { background: linear-gradient(135deg, #4f46e5, #0ea5e9); color: #fff; border-radius: 22px; padding: 46px 30px; text-align: center; }
.cta .btn { background: #fff; color: #4f46e5; }

/* ---- Hibaoldal ---- */
.error-page { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 30px; }
.error-page .code { font-size: 4rem; font-weight: 800; color: var(--accent); line-height: 1; }

/* ---- Mobil ---- */
@media (max-width: 860px) {
  .admin { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 260px; z-index: 50; transform: translateX(-100%); transition: transform .2s; padding-top: calc(20px + env(safe-area-inset-top, 0px)); }
  body.nav-open .sidebar { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .35); }
  .menu-btn { display: inline-flex; }
  .topbar { padding: 12px 16px; top: env(safe-area-inset-top, 0px); flex-wrap: wrap; row-gap: 10px; }
  /* keskeny kijelzőn a műveletgombok külön sorba kerülnek, a témaváltó a cím mellett marad */
  .top-actions { order: 10; flex-basis: 100%; }
  .top-actions .btn { flex: 1 1 auto; justify-content: center; }
  .admin-content { padding: 18px 16px 50px; }
  .picker { grid-template-columns: 1fr; }
  .hours-editor .day { grid-template-columns: 1fr; }
  .hero { padding: 28px 22px; }
  .card { padding: 18px; }
  .table-wrap { margin: 0 -18px; padding: 0 18px; }
  .site-nav { margin-left: 0; width: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 8px; }
  .fc .fc-toolbar { flex-direction: column; gap: 8px; }
}

/* Szolgáltatás: rögzített kezdési időpontok */
.mode-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.mode-choice .check { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px; cursor: pointer; }
.mode-choice .check:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.times-editor { margin-top: 14px; display: grid; gap: 4px; }
.times-day { display: grid; grid-template-columns: 90px 1fr auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.times-list { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.time-chip { display: inline-flex; align-items: center; border: 1px solid var(--input-line); border-radius: 999px; background: var(--input-bg); padding-left: 4px; }
.time-chip input[type=time] { border: 0; padding: 5px 4px 5px 8px; width: auto; background: transparent; box-shadow: none; }
.time-chip:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.chip-x { border: 0; background: transparent; color: var(--muted); font-size: 1.1rem; line-height: 1; padding: 4px 10px 4px 4px; cursor: pointer; }
.chip-x:hover { color: var(--bad); }
.times-day .copy-btn { color: var(--muted); }
.times-day:not([data-day="1"]):not([data-day="2"]):not([data-day="3"]):not([data-day="4"]):not([data-day="5"]) .copy-btn { display: none; }
.fixed-times { font-size: .85rem; color: var(--muted); }
@media (max-width: 560px) { .times-day { grid-template-columns: 1fr; gap: 6px; } .times-day .copy-btn { justify-self: start; } }
.times-editor .hint { color: var(--muted); font-size: .82rem; margin-top: 8px; }
/* órarend munkatárssal / helyszínnel: soronként egy időpont */
.times-editor.rich .time-chip { border-radius: var(--radius-sm); flex-wrap: wrap; }
.time-chip select { border: 0; border-left: 1px solid var(--line); border-radius: 0; background: transparent; box-shadow: none; padding: 5px 6px; width: auto; max-width: 160px; font-size: .88rem; }
.time-chip select:focus { box-shadow: none; outline: none; }
@media (max-width: 560px) { .times-editor.rich .time-chip { width: 100%; } .time-chip select { flex: 1; max-width: none; } }
/* helyszín-szűrő a foglalási varázslóban */
.loc-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.loc-filter button { border: 1px solid var(--line); background: var(--surface); color: inherit; border-radius: 999px; padding: 7px 14px; font: inherit; font-size: .9rem; cursor: pointer; }
.loc-filter button.on { border-color: var(--primary); background: var(--primary-soft); color: var(--accent); font-weight: 600; }
.loc-tag { font-size: .82rem; color: var(--muted); }

/* ÁSZF-oldalak és lábléc-linkek */
.footer-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 16px; margin-top: 6px; font-size: .85rem; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: inherit; }
.auth-foot { margin-top: 16px; }
.legal-wrap { max-width: 820px; margin: 0 auto; }
.legal { line-height: 1.6; overflow-wrap: anywhere; }
.legal h1 { font-size: 1.55rem; margin-bottom: .2em; }
.legal h2, .pf-section .legal h2 { text-align: left; font-size: 1.15rem; margin: 1.6em 0 .5em; }
.legal h3 { font-size: 1rem; margin: 1.2em 0 .4em; }
.legal ol, .legal ul { padding-left: 1.4em; }
.legal li + li { margin-top: .35em; }
.legal .small { font-size: .85rem; }
.legal-head { border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.legal-meta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; font-size: .9rem; color: var(--muted); }
.legal-data { border-collapse: collapse; width: 100%; font-size: .93rem; }
.legal-data th, .legal-data td { text-align: left; padding: 6px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.legal-data th { width: 34%; color: var(--muted); font-weight: 500; }
.legal-foot { margin-top: 2em; font-size: .9rem; }
.check a { text-decoration: underline; }
@media print {
  .site-header, .pf-header, .site-footer, .no-print, .theme-toggle, [data-theme-toggle] { display: none !important; }
  body { background: #fff; color: #000; }
  .legal.card { border: 0; box-shadow: none; padding: 0; }
  .pf-section { padding: 0; }
  .legal a { color: #000; }
}
.legal-table { border-collapse: collapse; width: 100%; font-size: .88rem; margin: .4em 0 1em; }
.legal-table th, .legal-table td { text-align: left; padding: 8px 10px; border: 1px solid var(--line); vertical-align: top; }
.legal-table thead th { background: var(--primary-soft); font-weight: 600; }
.legal-note { border-left: 4px solid var(--primary); background: var(--primary-soft); border-radius: var(--radius-sm); padding: 12px 14px; margin: 1em 0; font-size: .93rem; }
@media (max-width: 640px) {
  .legal-table thead { display: none; }
  .legal-table, .legal-table tbody, .legal-table tr, .legal-table td { display: block; width: 100%; }
  .legal-table tr { border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: 10px; }
  .legal-table td { border: 0; border-bottom: 1px solid var(--line); }
  .legal-table td:last-child { border-bottom: 0; }
  .legal-table td:first-child { font-weight: 600; }
}

/* ---- Statisztika: oszlop- és sávdiagramok (saját CSS, külső könyvtár nélkül) ---- */
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: .82rem; color: var(--muted); margin-bottom: 12px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.colchart { display: flex; align-items: stretch; gap: 3px; height: 200px; padding-top: 4px; }
.colchart.small { height: 140px; }
.colchart .col { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: flex-end; }
.colchart .stack-bar { display: flex; flex-direction: column; border-radius: 4px 4px 0 0; overflow: hidden; min-height: 0; }
.colchart .stack-bar span { display: block; min-height: 2px; }
.colchart .x { height: 18px; font-size: .7rem; color: var(--muted); text-align: center; white-space: nowrap; overflow: visible; border-top: 1px solid var(--line); padding-top: 3px; }
.hbar { position: relative; height: 22px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.hbar span { position: absolute; inset: 0 auto 0 0; background: var(--primary-soft); border-right: 2px solid var(--primary); }
.hbar b { position: relative; padding-left: 8px; font-size: .85rem; line-height: 22px; font-weight: 600; }

/* ---- Előfizetés / díjcsomagok ---- */
.feature-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: .92rem; }
.feature-list .on { color: var(--ok-ink); }
.feature-list .off { color: var(--muted); }
:root[data-theme="dark"] .feature-list .on { color: var(--ok); }
.plans-table th.current { color: var(--accent); }
.plans-table td:not(:first-child), .plans-table th:not(:first-child) { text-align: center; }
.plans-table .yes { color: var(--ok); font-weight: 700; }
.sub-banner { margin: 0 0 16px; }
.sub-banner a { font-weight: 600; }
