/* NJx Hackathon Site Kit — polish layered on top of Elementor settings.
   Colors and fonts come from Elementor Global Colors / Global Fonts;
   anything set in the Elementor panel overrides these rules. */

:root {
	--njx-ink: var(--e-global-color-primary, #14161A);
	--njx-orange: var(--e-global-color-accent, #E8471C);
	--njx-paper: var(--e-global-color-njxpaper, #F4F1EA);
	--njx-line: var(--e-global-color-njxline, #D8D0BE);
	--njx-ember: var(--e-global-color-njxember, #B9360F);
	--njx-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

html { scroll-behavior: smooth; }
body.njx-site { background: var(--njx-paper); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body.njx-site ::selection { background: var(--njx-orange); color: var(--njx-ink); }
.njx-site :focus-visible { outline: 2px solid var(--njx-orange); outline-offset: 3px; border-radius: 2px; }
.njx-site .elementor-widget-text-editor p:last-child { margin-bottom: 0; }
.njx-site .elementor-widget-heading .elementor-heading-title { text-wrap: balance; }
.njx-site .elementor-widget-text-editor p { text-wrap: pretty; }
.njx-break .elementor-heading-title { overflow-wrap: anywhere; }

/* Skip link */
.njx-skip { position: absolute; left: -9999px; top: 8px; z-index: 1000; background: var(--njx-ink); color: var(--njx-paper); padding: 10px 16px; font-weight: 600; }
.njx-skip:focus { left: 8px; }

/* ---------- Sticky header ---------- */
.njx-site-header { position: sticky; top: 0; z-index: 100; }
.admin-bar .njx-site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .njx-site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .njx-site-header { top: 0; } }
.njx-site-header .njx-header { transition: box-shadow .3s var(--njx-ease); }
.njx-site-header.is-scrolled .njx-header { box-shadow: 0 1px 0 var(--njx-line), 0 8px 24px -16px rgba(20,22,26,.35); }

/* ---------- Logo ---------- */
.njx-logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; line-height: 1; }
.njx-logo__mark { height: 30px; width: auto; flex: none; color: var(--njx-ink); display: block; }
.njx-logo__word { font-family: "Bricolage Grotesque", "Instrument Sans", sans-serif; font-weight: 700; font-size: 20px; letter-spacing: -0.02em; color: var(--njx-ink); white-space: nowrap; }

/* ---------- Nav menu ---------- */
.njx-nav { position: relative; font-family: "Instrument Sans", sans-serif; }
.njx-nav__list { list-style: none; margin: 0; padding: 0; display: flex; }
.njx-nav__list a { text-decoration: none; font-size: 15px; font-weight: 500; transition: color .2s ease; }
.njx-nav--light .njx-nav__list a { color: var(--njx-ink); }
.njx-nav--dark .njx-nav__list a { color: var(--njx-paper); }
.njx-nav--light .njx-nav__list > li > a:hover,
.njx-nav--light .njx-nav__list > li.current-menu-item > a,
.njx-nav--light .njx-nav__list > li.current-menu-ancestor > a { color: var(--njx-ember); }
.njx-nav--dark .njx-nav__list a:hover { color: var(--e-global-color-njxglow, #FF8A5C); }

.njx-nav--vertical .njx-nav__list { flex-direction: column; gap: 10px; }
.njx-nav--vertical .sub-menu { display: none; }

.njx-nav--horizontal .njx-nav__list { flex-direction: row; align-items: center; gap: 28px; }
.njx-nav--horizontal .njx-nav__list > li { position: relative; }
.njx-nav--horizontal .njx-nav__list > li > a { display: inline-flex; align-items: center; gap: 6px; padding: 10px 0; }
.njx-nav--horizontal .menu-item-has-children > a::after { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(45deg); }
.njx-nav--horizontal .sub-menu { list-style: none; margin: 0; padding: 8px; position: absolute; top: 100%; left: -12px; min-width: 230px; background: #fff; border: 1px solid var(--njx-line); border-radius: 4px; box-shadow: 0 16px 40px -20px rgba(20,22,26,.4); opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .2s ease, transform .2s var(--njx-ease), visibility .2s; z-index: 20; }
.njx-nav--horizontal .menu-item-has-children:hover > .sub-menu,
.njx-nav--horizontal .menu-item-has-children:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.njx-nav--horizontal .sub-menu a { display: block; padding: 10px 12px; border-radius: 2px; }
.njx-nav--horizontal .sub-menu a:hover { background: var(--njx-paper); color: var(--njx-ember); }

body .njx-nav .njx-nav__toggle { display: none; align-items: center; gap: 10px; background: transparent; border: 1px solid var(--njx-ink); color: var(--njx-ink); border-radius: 2px; padding: 9px 14px; font: 600 14px/1 "Instrument Sans", sans-serif; cursor: pointer; }
body .njx-nav .njx-nav__toggle { -webkit-tap-highlight-color: transparent; }
body .njx-nav .njx-nav__toggle:hover, body .njx-nav .njx-nav__toggle:focus, body .njx-nav .njx-nav__toggle:focus-visible, body .njx-nav.is-open .njx-nav__toggle { background: var(--njx-ink) !important; color: var(--njx-paper) !important; border-color: var(--njx-ink); }
body .njx-nav .njx-nav__toggle:not(:hover):not(:focus-visible):focus { background: transparent !important; color: var(--njx-ink) !important; }
body .njx-nav.is-open .njx-nav__toggle:focus { background: var(--njx-ink) !important; color: var(--njx-paper) !important; }
.njx-nav__bars, .njx-nav__bars::before, .njx-nav__bars::after { display: block; width: 16px; height: 1.5px; background: currentColor; position: relative; transition: transform .25s var(--njx-ease), opacity .2s; }
.njx-nav__bars::before, .njx-nav__bars::after { content: ""; position: absolute; left: 0; }
.njx-nav__bars::before { top: -5px; }
.njx-nav__bars::after { top: 5px; }
.njx-nav.is-open .njx-nav__bars { background: transparent; }
.njx-nav.is-open .njx-nav__bars::before { transform: translateY(5px) rotate(45deg); }
.njx-nav.is-open .njx-nav__bars::after { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 1024px) {
	body .njx-nav--horizontal .njx-nav__toggle { display: inline-flex; }
	.njx-nav--horizontal .njx-nav__list { display: none; position: fixed; left: 0; right: 0; top: var(--njx-header-h, 64px); bottom: 0; overflow-y: auto; flex-direction: column; align-items: stretch; gap: 0; padding: 12px 24px 40px; background: var(--njx-paper); border-top: 1px solid var(--njx-line); z-index: 90; }
	.njx-nav--horizontal.is-open .njx-nav__list { display: flex; }
	.njx-nav--horizontal .njx-nav__list > li > a { display: flex; padding: 16px 0; font-size: 22px; font-family: "Bricolage Grotesque", sans-serif; font-weight: 700; letter-spacing: -0.01em; border-bottom: 1px solid var(--njx-line); }
	.njx-nav--horizontal .menu-item-has-children > a::after { display: none; }
	.njx-nav--horizontal .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; background: transparent; padding: 4px 0 8px 16px; min-width: 0; }
	.njx-nav--horizontal .sub-menu a { font-size: 17px; padding: 10px 0; }
	body.njx-menu-open { overflow: hidden; }
}
@media (max-width: 767px) {
	.njx-header-cta { display: none; }
}

/* ---------- Labels ---------- */
.njx-label .elementor-heading-title { display: inline-flex; align-items: center; gap: 10px; }
.njx-clockline .elementor-heading-title::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--njx-orange); box-shadow: 0 0 0 4px rgba(232,71,28,.18); animation: njx-pulse 2.4s ease-in-out infinite; }
@keyframes njx-pulse { 50% { box-shadow: 0 0 0 7px rgba(232,71,28,.05); } }

/* ---------- Buttons ---------- */
.njx-btn .elementor-button { transition: background-color .25s var(--njx-ease), color .25s var(--njx-ease), transform .25s var(--njx-ease); letter-spacing: .01em; }
.njx-btn .elementor-button:hover { transform: translateY(-1px); }
.njx-btn .elementor-button:active { transform: none; }

/* ---------- Images ---------- */
.njx-img img { display: block; width: 100%; height: auto; }
.njx-img--hero img { aspect-ratio: 4 / 5; object-fit: cover; object-position: 78% center; }
@media (max-width: 767px) { .njx-img--hero img { aspect-ratio: 4 / 3; } }
.njx-img--tall img { aspect-ratio: 4 / 5; object-fit: cover; object-position: center 40%; }
.njx-img--card img { aspect-ratio: 16 / 10; object-fit: cover; object-position: center 35%; border-radius: 4px 4px 0 0 !important; }
.njx-event-card { overflow: hidden; transition: transform .35s var(--njx-ease), box-shadow .35s var(--njx-ease); }
.njx-event-card:hover { transform: translateY(-3px); box-shadow: 0 24px 48px -32px rgba(20,22,26,.45); }
.njx-event-card .njx-img img { transition: transform .6s var(--njx-ease); }
.njx-event-card:hover .njx-img img { transform: scale(1.02); }
@media (max-width: 767px) {
	.njx-img--tall img { aspect-ratio: 4 / 3; }
}

/* ---------- Cards, steps, facts ---------- */
.njx-card { height: 100%; }
.njx-step-num .elementor-heading-title { font-variant-numeric: tabular-nums; }
.njx-fact .elementor-heading-title { overflow-wrap: anywhere; }
.njx-partner { transition: border-color .25s ease, background-color .25s ease; }
.njx-partner:hover { border-color: var(--njx-ink) !important; background-color: #fff; }
.njx-winner .njx-label--school .elementor-heading-title { letter-spacing: .04em; }

/* ---------- Counters ---------- */
.njx-counter .elementor-counter { flex-direction: column; align-items: flex-start; gap: 6px; }
.njx-counter .elementor-counter-number-wrapper { font-variant-numeric: tabular-nums; justify-content: flex-start; }
.njx-counter .elementor-counter-title { text-align: left; }

/* ---------- Lists ---------- */
.njx-list .elementor-icon-list-icon i { transform: translateY(1px); }

/* ---------- Quote ---------- */
.njx-quote p { margin: 0; }

/* ---------- Names ---------- */
.njx-names p:first-child { font-size: 18px; line-height: 1.9; color: var(--njx-ink); }

/* ---------- Prose (policies) ---------- */
.njx-prose h2 { font-family: "Bricolage Grotesque", sans-serif; font-weight: 700; font-size: 26px; letter-spacing: -0.015em; color: var(--njx-ink); margin: 40px 0 12px; }
.njx-prose h2:first-child { margin-top: 0; }
.njx-prose ul { padding-left: 20px; margin: 0 0 16px; }
.njx-prose li { margin-bottom: 8px; }
.njx-prose a { color: var(--njx-ember); }

/* ---------- Footer ---------- */
.njx-footer a { color: var(--njx-paper); }
.njx-footer a:hover { color: var(--e-global-color-njxglow, #FF8A5C); }
.njx-footer-sponsor p { padding: 14px 16px; border: 1px solid var(--e-global-color-njxinkline, #34383F); border-radius: 4px; }

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.njx-nowrap { white-space: nowrap; }

.njx-role .elementor-widget-button { margin-top: auto; padding-top: 6px; }
.njx-winner .elementor-widget-divider { margin: 4px 0; }

/* Partner logo tiles */
.njx-partner { background-color: #fff; }
.njx-partner__logo, .njx-partner__logo .elementor-widget-container { display: flex; align-items: center; justify-content: flex-start; min-height: 64px; }
.njx-partner__logo img { max-height: 56px !important; max-width: min(190px, 100%) !important; width: auto !important; height: auto; object-fit: contain; border-radius: 0 !important; }
.njx-partner__logo--mark img { max-height: 48px !important; }
.njx-partner__logo a { display: inline-flex; }
.njx-partner:hover { background-color: #fff; }
/* Optical balance between wide and compact partner logos */
.njx-partner__logo--lovable img { max-width: min(150px, 100%) !important; }
.njx-partner__logo--mtap img { max-height: 46px !important; }
.njx-partner__logo--nekey img { max-height: 44px !important; }
.njx-partner__logo--startup-grind img { max-width: min(210px, 100%) !important; }
@media (max-width: 767px) {
	.njx-partner__logo, .njx-partner__logo .elementor-widget-container { min-height: 48px; }
	.njx-partner__logo img { max-height: 40px !important; }
	.njx-partner__logo--mark img { max-height: 36px !important; }
	.njx-partner .elementor-heading-title { font-size: 15px !important; line-height: 1.25 !important; }
}
