/* PRiQ – F5 Creative theme (f5creative.hu look). Loaded after app.css; switch off with 'ui_theme' => 'classic' in config.php.
   Function first: only colours, type, shapes. No motion beyond what app.css already has. */
@font-face { font-family: "Exo 2"; src: url(f5fonts/Exo2-Variable.woff) format("woff"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url(f5fonts/Montserrat-Bold.woff) format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Manrope"; src: url(f5fonts/Manrope-Variable.woff) format("woff"); font-weight: 200 800; font-display: swap; }

:root {
  --ink: #0c101f; --navy: #253454; --lime: #d3d800; --lime-soft: #e6ea5c;
  --bg: #f4f5ee;
  --fg: #0c101f;
  --card: #ffffff;
  --sidebar: #ffffff;
  --muted: #eceee3;
  --muted-fg: #596276;
  --primary: #5f6400;            /* readable olive for text, links, bars on light */
  --primary-fg: #ffffff;
  --accent: #eef0c2;
  --accent-fg: #3f4300;
  --secondary: #eceee3;
  --sidebar-accent: #eef0c2;
  --border: rgba(12, 16, 31, 0.10);
  --input: rgba(12, 16, 31, 0.18);
  --ring: #8a8f00;
  --danger: #b3261e;
  --pending: #8a4f00;
  --approved: #1f7a4d;
  --brand: #253454;
  --brand-soft: #5f6400;
  --f-sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-exo: "Exo 2", "Arial Narrow", system-ui, sans-serif;
  --f-mont: "Montserrat", system-ui, sans-serif;
  --f5-radius: 18px;
}
.dark {
  --bg: #0c101f;
  --fg: #eef0e6;
  --card: #141c33;
  --sidebar: #0f1528;
  --muted: #1a2440;
  --muted-fg: #9aa3b8;
  --primary: #d3d800;
  --primary-fg: #0c101f;
  --accent: rgba(211, 216, 0, 0.14);
  --accent-fg: #e6ea5c;
  --secondary: #1a2440;
  --sidebar-accent: rgba(211, 216, 0, 0.12);
  --border: rgba(238, 240, 230, 0.09);
  --input: rgba(238, 240, 230, 0.18);
  --ring: #d3d800;
  --danger: #ff8a80;
  --pending: #f2b35b;
  --approved: #7ad6a0;
  --brand: #d3d800;
  --brand-soft: #e6ea5c;
}

/* type */
body { font-family: var(--f-sans); font-size: 15px; }
.page-head h1, .page-intro h1, .adm-title, .sf-h1, .empty h1 { font-family: var(--f-exo); font-weight: 800; font-size: 28px; line-height: 1.15; letter-spacing: -0.02em; }
.card-title, .topbar-title, .qcard-total { font-family: var(--f-exo); font-weight: 700; letter-spacing: -0.01em; }
/* the PRiQ wordmark is always Montserrat Bold */
.brand-priq { font-family: var(--f-mont); font-weight: 700; }
.sidebar-label { font-family: var(--f-exo); font-weight: 700; letter-spacing: .22em; color: var(--primary); }
:root:not(.dark) .sidebar-label { color: var(--primary); }
.tnum, .qcard-total { font-variant-numeric: tabular-nums; }

/* surfaces */
.card, .approval-card, .qcard { border-radius: var(--f5-radius); border-color: var(--border); }
.dark .card, .dark .qcard { box-shadow: none; }
.usermenu-panel, .notif-panel, .gsearch-panel { border-radius: var(--f5-radius); }
.thumb, .file-tile, .file-row, .no-design { border-radius: 14px; }

/* buttons: pills, lime is the one action colour */
.btn { border-radius: 999px; font-weight: 700; padding: 0 14px; }
.btn-sm, .btn-xs { border-radius: 999px; }
.btn-primary, .icon-btn.solid, .pub-badge-icon { background: var(--lime); color: var(--ink); }
.btn-primary:hover { background: var(--lime-soft); }
.btn-outline { border-color: var(--input); }
.dark .btn-outline { background: transparent; border-color: rgba(238, 240, 230, 0.22); }
.dark .btn-outline:hover { background: rgba(238, 240, 230, 0.06); }
.icon-btn { border-radius: 999px; }

/* selected states share the lime pill */
.nav-item.is-active, .set-pills a.on, .chip-btn.on, .seg2 button.on, .sf-kind button.on, .cv-acc.on .cv-av, .cat-badge.svc
  { background: var(--lime); border-color: var(--lime); color: var(--ink); box-shadow: none; }
.nav-item { border-radius: 999px; }
.nav-item:hover { background: var(--sidebar-accent); }
.nav-dot { background: var(--danger); box-shadow: 0 0 0 2px var(--sidebar); }
.nav-item.is-active .nav-dot { box-shadow: 0 0 0 2px var(--lime); }
.tabs-list, .fin-tabs, .sf-seg { border-radius: 999px; }
.tabs-list button, .fin-tabs button, .sf-seg button { border-radius: 999px; }
.tabs-list button[aria-selected="true"], .fin-tabs button[aria-selected=true], .sf-seg button[aria-selected=true] { font-weight: 700; }

/* fields */
input, select, textarea { border-radius: 12px; }
.dark input, .dark select, .dark textarea { background: #0f1528; }
input:focus, select:focus, textarea:focus { border-color: var(--ring); box-shadow: 0 0 0 3px color-mix(in srgb, var(--lime) 35%, transparent); }

/* shell */
.sidebar { background: var(--sidebar); }
.topbar { background: color-mix(in srgb, var(--bg) 88%, transparent); }
.avatar, .sidebar-user .av { background: var(--accent); color: var(--accent-fg); font-family: var(--f-exo); font-weight: 700; }
.badge { font-weight: 700; }
.toast { border-radius: 14px; }
.toast { border-left-color: var(--lime); }
:root:not(.dark) .ui-tbl tbody tr:hover td, :root:not(.dark) .tbl tbody tr:hover td { background: #f8f9f2; }

/* client portal on phones: bottom tab bar instead of the drawer */
.cnav { display: none; }
@media (max-width: 900px) {
  .is-client .topbar .icon-btn.md-only[data-toggle-sidebar] { display: none; }
  .is-client .page { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
  .is-client .toasts { bottom: calc(84px + env(safe-area-inset-bottom)); }
  .cnav { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: fixed; z-index: 25; left: 0; right: 0; bottom: 0;
    padding: 6px max(4px, env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(4px, env(safe-area-inset-left));
    background: var(--sidebar); border-top: 1px solid var(--border); }
  .cnav a { position: relative; min-height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    color: var(--muted-fg); text-decoration: none; font-size: 11px; font-weight: 600; }
  .cnav a .pill { width: 44px; height: 28px; border-radius: 999px; display: grid; place-items: center; }
  .cnav a .ico { width: 18px; height: 18px; }
  .cnav a[aria-current] { color: var(--fg); font-weight: 700; }
  .cnav a[aria-current] .pill { background: var(--lime); color: var(--ink); }
  .cnav .nav-dot { position: absolute; top: 6px; left: calc(50% + 12px); margin: 0; box-shadow: 0 0 0 2px var(--sidebar); }
  /* bigger tap targets for the decisions */
  .is-client .quote-actions .btn, .is-client .approval-card .btn, .is-client .decide-grid .btn { height: 44px; font-size: 15px; }
}
