/* OFC bar — mu-plugins/ofc-bar.php: the top bar of Platforma and Sklep Off Course, and its side menu */
.ofc-bar {
	--ob-bg: #08202f; --ob-ink: #fff; --ob-muted: #9fb6c6; --ob-line: rgba(255,255,255,.14); --ob-accent: #35d07f;
	--ob-btn: rgba(255,255,255,.28); --ob-menu: #0d2a3c; --ob-menu-line: rgba(255,255,255,.18); --ob-hover: rgba(255,255,255,.06);
	position: relative; z-index: 900; background: var(--ob-bg); border-bottom: 1px solid var(--ob-line);
	font-family: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif; line-height: 1.2;
}
.ofc-bar--light {
	--ob-bg: #fff; --ob-ink: #0f202d; --ob-muted: #64748b; --ob-line: #e2e8ed; --ob-accent: #008137;
	--ob-btn: #c9d4dc; --ob-menu: #fff; --ob-menu-line: #e2e8ed; --ob-hover: #f2f6f8;
}
.ofc-bar--clear { background: transparent; }
.ofc-bar--flat { border-bottom: 0; }
.ofc-bar--sticky { position: sticky; top: var(--wp-admin--admin-bar--height, 0px); }
.ofc-bar *, .ofc-drawer * { box-sizing: border-box; }
.ofc-bar__wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; width: 100%; max-width: 1280px; margin: 0 auto; padding: 14px 40px; }

/* the lockup: mark | rule | name */
.ofc-bar .ofc-bar__lockup { display: flex; align-items: center; gap: 18px; flex: none; color: var(--ob-ink); text-decoration: none; }
.ofc-bar .ofc-bar__lockup:hover, .ofc-bar .ofc-bar__lockup:focus { color: var(--ob-ink); }
.ofc-bar__logo, .ofc-bar__mark { display: block; height: 48px; width: auto; flex: none; max-width: none; }
.ofc-bar__rule { width: 1px; height: 40px; background: var(--ob-btn); flex: none; }
.ofc-bar__name { font-size: 20px; font-weight: 700; white-space: nowrap; color: var(--ob-ink); }
.ofc-bar__name span { font-weight: 400; color: var(--ob-muted); }

/* the links */
.ofc-bar__nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.ofc-bar .ofc-bar__item { display: inline-flex; align-items: center; gap: 8px; color: var(--ob-ink); font-family: 'Archivo', system-ui, sans-serif; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; white-space: nowrap; }
.ofc-bar .ofc-bar__item:hover, .ofc-bar .ofc-bar__item:focus-visible { color: var(--ob-accent); }
.ofc-bar .ofc-bar__item.is-accent { color: var(--ob-accent); }
.ofc-bar .ofc-bar__item.is-accent:hover, .ofc-bar .ofc-bar__item.is-accent:focus-visible { color: var(--ob-ink); }
.ofc-bar__icon { display: block; flex: none; }
.ofc-bar__account-btn .ofc-bar__icon { width: 18px; height: 18px; }
/* the shop's look: outlined buttons, the current one filled */
.ofc-bar--buttons .ofc-bar__nav { gap: 10px; }
.ofc-bar--buttons .ofc-bar__item { justify-content: center; min-height: 44px; padding: 0 18px; border: 1px solid var(--ob-btn); }
.ofc-bar--buttons .ofc-bar__item:hover, .ofc-bar--buttons .ofc-bar__item:focus-visible { border-color: var(--ob-ink); color: var(--ob-ink); }
.ofc-bar--buttons .ofc-bar__item.is-active { background: #fff; border-color: #fff; color: #08202f; }
.ofc-bar--buttons .ofc-bar__account, .ofc-bar--buttons .ofc-bar__login { margin-left: 8px; }
.ofc-bar--buttons .ofc-bar__account-btn .ofc-bar__icon { display: none; }

/* "Moje konto" and its menu, on hover or keyboard focus */
.ofc-bar__account { position: relative; display: flex; align-items: center; } /* no line box under the link: level with the others */
.ofc-bar__menu { display: none; position: absolute; top: 100%; right: 0; z-index: 1000; min-width: 240px; max-width: calc(100vw - 32px); margin: 10px 0 0; padding: 8px 0; list-style: none; background: var(--ob-menu); border: 1px solid var(--ob-menu-line); box-shadow: 0 16px 40px rgba(8,32,47,.28); text-align: left; }
.ofc-bar__menu::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; } /* the gap the pointer crosses */
.ofc-bar__account:hover .ofc-bar__menu, .ofc-bar__account:focus-within .ofc-bar__menu { display: block; }
.ofc-bar__account.is-left .ofc-bar__menu { left: 0; right: auto; } /* no room on the left (bar.js) */
.ofc-bar .ofc-bar__menu li { margin: 0; padding: 0; list-style: none; }
.ofc-bar .ofc-bar__menu a { display: block; padding: 10px 18px; color: var(--ob-ink); font-family: 'IBM Plex Sans', system-ui, sans-serif; font-size: 15px; font-weight: 400; letter-spacing: 0; text-transform: none; line-height: 1.4; white-space: nowrap; text-decoration: none; }
.ofc-bar .ofc-bar__menu a:hover, .ofc-bar .ofc-bar__menu a:focus { background: var(--ob-hover); color: var(--ob-accent); outline: none; }
.ofc-bar .ofc-bar__menu .is-sub a { padding: 6px 18px 6px 34px; font-size: 14px; color: var(--ob-muted); }
.ofc-bar .ofc-bar__menu .is-accent a { color: var(--ob-accent); }

/* the basket (OFC_Checkout_Minicart) on the light bar */
.ofc-bar--light .ofc-minicart--dark .ofc-minicart__btn { color: var(--ob-ink); border-color: var(--ob-btn); }
.ofc-bar--light .ofc-minicart--dark .ofc-minicart__btn:hover, .ofc-bar--light .ofc-minicart--dark:focus-within .ofc-minicart__btn { color: var(--ob-ink); border-color: var(--ob-ink); }
.ofc-bar--light .ofc-minicart--dark .ofc-minicart__panel { background: #fff; color: #08202f; border-color: #d9e2e8; box-shadow: 0 12px 32px rgba(8,32,47,.18); }
.ofc-bar--light .ofc-minicart--dark .ofc-minicart__head, .ofc-bar--light .ofc-minicart--dark .ofc-minicart__row.is-addon { color: #5d7684; }

/* the menu button — three lines and the word */
.ofc-bar .ofc-bar__toggle { display: none; align-items: center; gap: 10px; min-height: 44px; margin: 0; padding: 0 14px; background: transparent; border: 1px solid var(--ob-btn); border-radius: 0; box-shadow: none; color: var(--ob-ink); font: 700 13px/1 'Archivo', system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.ofc-bar .ofc-bar__toggle:hover, .ofc-bar .ofc-bar__toggle:focus-visible { background: transparent; border-color: var(--ob-ink); color: var(--ob-ink); }

/* narrow screens: the links and the account fold into the side menu (the shop's many items, sooner) */
@media (max-width: 1199px) {
	.ofc-bar--wide .ofc-bar__nav > .ofc-bar__item, .ofc-bar--wide .ofc-bar__account { display: none; }
	.ofc-bar--wide .ofc-bar__toggle { display: inline-flex; }
	.ofc-bar--wide:not(.ofc-bar--cart-phone) .ofc-bar__cart { display: none; }
	.ofc-bar--wide .ofc-bar__nav { gap: 10px; }
}
@media (max-width: 859px) {
	.ofc-bar__nav > .ofc-bar__item, .ofc-bar__account { display: none; }
	.ofc-bar .ofc-bar__toggle { display: inline-flex; }
	.ofc-bar:not(.ofc-bar--cart-phone) .ofc-bar__cart { display: none; }
	.ofc-bar__nav { gap: 10px; }
}
/* phones: the two lockups the same size — the Platforma SVG at the height of the Sklep mark
   (its name then ≈ 17 px, as Sklep's); the menu button the icon alone, in both */
@media (max-width: 600px) {
	.ofc-bar__wrap { padding: 12px 20px; gap: 12px; }
	.ofc-bar .ofc-bar__lockup { gap: 13px; }
	.ofc-bar__logo, .ofc-bar__mark { height: 38px; }
	.ofc-bar__rule { height: 32px; }
	.ofc-bar__name { font-size: 17px; }
	.ofc-bar--sticky { top: 0; } /* the admin bar scrolls away on phones */
	.ofc-bar__toggle-text { display: none; }
	.ofc-bar .ofc-bar__toggle { width: 46px; justify-content: center; padding: 0; }
}
@media (max-width: 380px) {
	.ofc-bar__wrap { padding: 10px 16px; gap: 10px; }
}
@media (max-width: 359px) {
	.ofc-bar__logo, .ofc-bar__mark { height: 32px; }
	.ofc-bar .ofc-bar__lockup { gap: 11px; }
	.ofc-bar__rule { height: 27px; }
	.ofc-bar__name { font-size: 14.5px; }
}

/* the side menu (dark, from the right — as on offcourse.edu.pl) */
.ofc-drawer { position: fixed; inset: 0; z-index: 100000; }
.ofc-drawer[hidden] { display: none; }
.ofc-drawer__overlay { position: absolute; inset: 0; background: rgba(8,32,47,.62); opacity: 0; transition: opacity .25s ease; }
.ofc-drawer.is-open .ofc-drawer__overlay { opacity: 1; }
.ofc-drawer__panel { position: absolute; top: 0; right: 0; bottom: 0; display: flex; flex-direction: column; width: min(340px, 86vw); overflow-y: auto; overscroll-behavior: contain; background: #08202f; color: #fff; box-shadow: -12px 0 40px rgba(0,0,0,.35); transform: translateX(100%); transition: transform .25s ease; font-family: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif; text-align: left; }
.ofc-drawer.is-open .ofc-drawer__panel { transform: none; }
@media (prefers-reduced-motion: reduce) { .ofc-drawer__panel, .ofc-drawer__overlay { transition: none; } }
.ofc-drawer__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px 14px 24px; border-bottom: 1px solid rgba(255,255,255,.12); }
.ofc-drawer__title { font-size: 12px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: #9fb6c6; }
.ofc-drawer .ofc-drawer__close { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin: 0; padding: 0; background: transparent; border: 1px solid rgba(255,255,255,.28); border-radius: 0; box-shadow: none; color: #fff; cursor: pointer; }
.ofc-drawer .ofc-drawer__close:hover, .ofc-drawer .ofc-drawer__close:focus-visible { background: transparent; border-color: #fff; color: #fff; }
.ofc-drawer .ofc-drawer__list { list-style: none; margin: 0; padding: 0; } /* over the page's own list styles (the shop's) */
.ofc-drawer .ofc-drawer__list li { margin: 0; padding: 0; list-style: none; border-bottom: 1px solid rgba(255,255,255,.1); }
.ofc-drawer .ofc-drawer__list a { display: block; padding: 16px 24px; color: rgba(255,255,255,.88); font-family: 'Archivo', system-ui, sans-serif; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; line-height: 1.35; text-decoration: none; }
.ofc-drawer .ofc-drawer__list a:hover, .ofc-drawer .ofc-drawer__list a:focus { background: rgba(255,255,255,.04); color: #35d07f; outline: none; }
.ofc-drawer .ofc-drawer__list .is-active a, .ofc-drawer .ofc-drawer__list .is-accent a { color: #35d07f; }
.ofc-drawer .ofc-drawer__list .is-head a { padding-top: 30px; color: #9fb6c6; font-size: 12px; letter-spacing: .18em; } /* the account's group: space above, one line */
.ofc-drawer .ofc-drawer__list .is-sub { border-bottom: 0; }
.ofc-drawer .ofc-drawer__list .is-sub a { padding: 7px 24px 7px 40px; font-family: 'IBM Plex Sans', system-ui, sans-serif; font-size: 15px; font-weight: 400; letter-spacing: 0; text-transform: none; color: #9fb6c6; }
.ofc-drawer .ofc-drawer__list .is-sub + li:not(.is-sub) { border-top: 1px solid rgba(255,255,255,.1); }
.ofc-drawer__foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: auto; padding: 22px 24px; font-family: 'IBM Plex Sans', system-ui, sans-serif; font-size: 14px; color: #9fb6c6; }
.ofc-drawer .ofc-drawer__foot a { color: #9fb6c6; text-decoration: none; }
.ofc-drawer .ofc-drawer__foot a:hover, .ofc-drawer .ofc-drawer__foot a:focus { color: #35d07f; }
html.ofc-drawer-lock, html.ofc-drawer-lock body { overflow: hidden; }
