/* root.hr CMS · izgled po uzoru na sweclockers.com, u root.hr narančastoj */
:root {
    --brand: #ff4500;
    --brand-hover: #e63e00;
    --bg: #edeceb;
    --content: #fff;
    --row: #f1efec;
    --row-alt: #e6e4e0;
    --row-offset: #d7d5d1;
    --dark: #1c1c1c;
    --dark-2: #282828;
    --group: #343330;
    --text: #282828;
    --text-2: #424242;
    --muted: #838383;
    --meta: #939393;
    --title: #4a4a4a;
    --on-dark: #ccc;
    --border: #d7d5d1;
    --border-2: #b9afa0;
    --btn: #f7f6f5;
    --green: #4baf4f;
    --blue: #3597da;
    --side: 380px;
    --gap: 16px;
    --surface: #fff;      /* polja, padajući izbornici i ostale plohe na kutijama */
    --btn-hover: #fff;
    color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-y: scroll; }
body {
    margin: 0;
    font-family: "Inter", Arial, Helvetica, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text);
    background: var(--bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul { list-style: none; padding: 0; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
button, input, select { font: inherit; }
/* fokus s tipkovnice: isti narančasti okvir svugdje */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
    outline: 2px solid var(--brand); outline-offset: 2px;
}
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 1270px; margin: 0 auto; padding-left: 16px; padding-right: 16px; }

/* ---------- Gumbi ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 6px 12px;
    font-size: 13px; font-weight: 700; line-height: 1.4; white-space: nowrap;
    color: var(--text-2); background: var(--btn);
    border: 1px solid var(--border); border-radius: 3px;
    cursor: pointer;
}
.btn:hover { background: var(--btn-hover); text-decoration: none; }
.btn-orange { color: #fff; background: var(--brand); border-color: var(--brand); }
.btn-orange:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
.btn-dark { color: #fff; background: var(--dark-2); border-color: var(--dark-2); }
.btn-dark:hover { background: #3b3b3b; }
.btn-sm { padding: 3px 8px; font-size: 12px; }
.btn-sm i { font-size: 11px; }
.btn-lg { padding: 9px 16px; font-size: 15px; }
.btn-block { width: 100%; }

/* ---------- Zaglavlje ---------- */
/* bez overflow: hidden, jer bi odrezao izbornik računa; z-index iznad trake s izbornikom (5) */
.top { position: relative; z-index: 10; background: var(--bg); }
.matrix { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.top-in { position: relative; z-index: 1; height: 72px; display: flex; align-items: center; justify-content: space-between; }
.logo { position: relative; display: block; }
.logo::before {
    /* mirna podloga ispod loga da animacija ne ide preko slova */
    content: ""; position: absolute; inset: -16px -48px -16px -40px; z-index: -1;
    background: radial-gradient(closest-side, var(--bg) 72%, transparent);
}
.logo img { display: block; height: 44px; width: auto; }
.logo .logo-d { display: none; }
.top-actions { display: flex; gap: 8px; }
.top-actions .btn { padding: 8px 14px; font-size: 14px; }
/* Prijava i Registracija iste širine, da nijedan gumb ne djeluje veći */
.top-actions.guest { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; }
.top-actions .count {
    display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px;
    font-size: 11px; font-weight: 700; color: #fff; background: var(--brand); border-radius: 9px;
}
.btn-orange .count { color: var(--brand); background: #fff; }
.acct { position: relative; }
.acct-btn span { max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-btn .chev { font-size: 10px; color: var(--muted); }
.acct-menu {
    position: absolute; top: calc(100% + 6px); right: 0; z-index: 30; display: none; min-width: 220px; padding: 6px 0;
    background: var(--surface); border: 1px solid var(--border); border-radius: 6px; box-shadow: 0 8px 20px rgba(0, 0, 0, .12);
}
.acct.open .acct-menu { display: block; }
.acct-menu a, .acct-menu button {
    display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 14px;
    font: inherit; font-size: 14px; color: var(--text); text-align: left; background: none; border: 0; cursor: pointer;
}
.acct-menu a:hover, .acct-menu button:hover { background: var(--row); text-decoration: none; }
.acct-menu i { width: 16px; color: var(--muted); text-align: center; }
.acct-menu form { margin: 4px 0 0; padding-top: 4px; border-top: 1px solid var(--row); }
.acct-menu .count { margin-left: auto; }

.nav { position: relative; z-index: 5; background: var(--content); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.nav-in { display: flex; align-items: center; height: 44px; }
.nav-menu { display: flex; height: 100%; }
.nav-menu > li { position: relative; display: flex; }
.nav-link {
    display: flex; align-items: center; gap: 6px; height: 100%; padding: 0 12px;
    font-size: 15px; color: var(--text); background: none; border: 0; cursor: pointer;
}
.nav-link:hover { background: var(--row); text-decoration: none; }
.nav-link .fa-chevron-down { font-size: 10px; color: var(--muted); }
.nav-menu > li.is-active > .nav-link { box-shadow: inset 0 -3px var(--brand); font-weight: 600; }
.sub {
    position: absolute; top: 100%; left: 0; z-index: 20; display: none; min-width: 210px;
    background: var(--content); border: 1px solid var(--border); border-radius: 0 0 6px 6px; overflow: hidden;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .08);
}
.sub a { display: flex; align-items: center; gap: 10px; padding: 9px 14px; color: var(--text); }
.sub a:hover { background: var(--row); text-decoration: none; }
.sub i { width: 16px; color: var(--muted); text-align: center; }
.has-sub:hover .sub, .has-sub.open .sub { display: block; }
/* strelica se okrene kad je izbornik otvoren (isto kao na forumu) */
.has-sub > .nav-link .fa-chevron-down, .acct-btn .chev { transition: transform .2s; }
.has-sub:hover > .nav-link .fa-chevron-down, .has-sub.open > .nav-link .fa-chevron-down, .acct.open .acct-btn .chev { transform: rotate(180deg); }
.nav-toggle { display: none; }
.nav-icons { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.nav-icon {
    display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 36px; height: 36px;
    border-radius: 3px;
}
.nav-icon:hover { background: var(--row); text-decoration: none; }
.nav-discord { font-size: 21px; color: #5865f2; }
/* prekidač tamne/svijetle teme (kapsula s kružićem, kao na sweclockers.com) */
.theme-switch {
    position: relative; flex: 0 0 auto; width: 40px; height: 22px; margin: 0 6px 0 8px; padding: 0;
    background: var(--border); border: 0; border-radius: 11px; cursor: pointer; transition: background-color .25s;
}
.theme-switch:hover { background: var(--border-2); }
.theme-switch-knob {
    position: absolute; top: 2px; left: 2px; display: flex; align-items: center; justify-content: center;
    width: 18px; height: 18px; font-size: 11px; background: #fff; border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .25s;
}
.theme-switch .fa-sun { color: var(--brand); }
.theme-switch .fa-moon { display: none; color: #1c1c1c; }
@media (prefers-reduced-motion: reduce) { .theme-switch, .theme-switch-knob { transition: none; } }
.nav-search {
    display: flex; align-items: center; flex: 0 1 270px; margin-left: 8px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 4px;
}
.nav-search { min-width: 0; }
.nav-search input { flex: 1; min-width: 0; width: 100%; padding: 6px 10px; border: 0; background: none; color: var(--text); outline: none; font-size: 14px; }
.nav-search input::placeholder { color: var(--muted); }
.nav-search button { padding: 6px 10px; border: 0; background: none; color: var(--text); cursor: pointer; }
.nav-search:focus-within { border-color: var(--border-2); }

/* ---------- Raspored ---------- */
.page { flex: 1 0 auto; padding-top: var(--gap); padding-bottom: 28px; }
.row-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) var(--side); gap: var(--gap); margin-bottom: var(--gap); }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) var(--side); gap: var(--gap); align-items: start; }
.col-side { display: flex; flex-direction: column; gap: var(--gap); }
.col-side.sticky { position: sticky; top: var(--gap); }

/* ---------- Tamni widgeti ---------- */
.widget { display: flex; flex-direction: column; padding: 16px; color: var(--on-dark); background: var(--dark); border-radius: 10px; min-width: 0; }
.widget-title { display: flex; align-items: center; gap: 9px; margin-bottom: 8px; font-size: 19px; font-weight: 700; line-height: 1.2; color: #fff; }
.widget-title i { color: var(--brand); font-size: 17px; }
.widget-title a { display: inline-block; padding: 2px 0; color: inherit; }
.widget-sub { margin: -2px 0 8px; color: #fff; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.widget-text { color: var(--on-dark); font-size: 14px; line-height: 1.55; }
.wlist li { display: flex; align-items: center; gap: 10px; min-height: 30px; }
.wlist li[hidden] { display: none; }
.wl-logo {
    flex: 0 0 auto; display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; padding: 2px;
    overflow: hidden; background: #fff; border-radius: 4px;
}
.wl-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.wl-logo.mono { font-size: 12px; font-weight: 800; color: #fff; background: #3b3b3b; }
.wl-link { flex: 1 1 auto; min-width: 0; padding: 3px 0; color: var(--on-dark); font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wl-link:hover { color: #fff; }
.wl-badge {
    flex: 0 0 auto; min-width: 48px; padding: 2px 6px; text-align: center;
    font-size: 13px; font-weight: 600; color: #fff; background: var(--brand); border-radius: 3px;
}
.wl-meta { flex: 0 0 auto; max-width: 45%; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wl-pre { flex: 0 0 82px; padding: 2px 6px; text-align: center; font-size: 13px; font-weight: 600; color: #fff; border-radius: 3px; background: var(--brand); }
.badge-stable { background: var(--green); }
.badge-longterm { background: var(--blue); }
.widget-more { margin-top: auto; padding: 8px 0 2px; align-self: flex-start; color: #fff; font-weight: 700; }
.widget-empty { color: var(--on-dark); font-style: italic; }
.widget-cta .ticks { margin: 4px 0 14px; }
.widget-cta .ticks li { display: flex; align-items: center; gap: 10px; padding: 4px 0; color: var(--on-dark); font-size: 14.5px; }
.widget-cta .ticks i { color: var(--green); }
.widget-cta .btn { padding: 10px; font-size: 15px; }
.cta-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

/* Desni stupac: svijetli widgeti (gornji red ostaje taman) */
.col-side .widget { color: var(--text-2); background: var(--content); }
.col-side .widget-title { color: var(--title); }
.col-side .widget-sub { color: var(--text-2); }
.col-side .widget-text, .col-side .widget-empty { color: var(--text-2); }
.col-side .widget-text a { color: var(--brand); }
.col-side .wl-link { color: var(--text); }
.col-side .wl-link:hover { color: var(--brand); }
.col-side .wl-meta { color: var(--text-2); font-weight: 600; }
.col-side .wl-logo { border: 1px solid var(--border); }
.col-side .widget-more { color: var(--text); }
.col-side .widget-more:hover { color: var(--brand); }
.col-side .widget-cta .ticks li { color: var(--text-2); }
.col-side .company-facts li { color: var(--text-2); }
.col-side .company-facts a { color: var(--brand); }
.col-side .apply-form label { color: var(--text); }
.col-side .apply-form textarea { background: var(--surface); }

/* ---------- Bijeli sadržaj ---------- */
.box { background: var(--content); border-radius: 10px; padding: 12px 16px 16px; min-width: 0; }
.box-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0 12px; }
.box-head h1 { font-size: 24px; line-height: 1.2; color: var(--title); }
.box-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 4px 0; font-weight: 700; }
.empty { padding: 24px 0; color: var(--muted); text-align: center; }

/* Kartice tema (naslovnica) */
.cards { margin: 0 -16px; }
.card { display: flex; gap: 16px; padding: 16px; border-top: 1px solid var(--border-2); }
.card:first-child { border-top: 0; padding-top: 4px; }
.card-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.card-meta { margin-bottom: 4px; font-size: 13px; color: var(--meta); }
.card-meta .cat { margin-right: 4px; font-weight: 700; color: var(--brand); }
.card-title { margin-bottom: 6px; font-size: 22px; line-height: 1.25; color: var(--title); }
.card-title a { color: inherit; }
.card-text { font-size: 15px; color: var(--text); }
.card-engage { display: flex; align-items: center; gap: 12px; margin-top: 10px; }
.card-engage .by { font-size: 13px; color: var(--muted); }
.card-engage .by strong { color: var(--text-2); font-weight: 600; }
.card-lead { flex-direction: column; gap: 12px; }
.card-lead .card-title { font-size: 30px; }
.card-banner { display: block; }
.card-thumb { flex: 0 0 180px; align-self: flex-start; margin-top: 4px; order: -1; }

/* Slike s foruma se nikad ne režu: zamućena kopija puni prazan prostor */
.frame { position: relative; display: block; overflow: hidden; background: var(--dark); border-radius: 6px; }
.frame::before {
    content: ""; position: absolute; inset: -24px;
    background: var(--img) center / cover no-repeat;
    filter: blur(20px) brightness(.75);
}
.frame img { position: relative; display: block; width: 100%; height: 100%; object-fit: contain; }
.frame-wide { aspect-ratio: 16 / 7; }
.frame-thumb { aspect-ratio: 3 / 2; }
/* avatar autora kad tema nema sliku: cijeli kvadrat u sredini okvira */
.frame-avatar { display: flex; align-items: center; justify-content: center; }
.frame-avatar img { width: auto; height: 78%; aspect-ratio: 1; border-radius: 15%; box-shadow: 0 2px 10px rgba(0, 0, 0, .25); }

/* Forumski indeks */
.ftable, .jtable { width: 100%; border-collapse: separate; border-spacing: 0; }
.ftable thead th, .jtable thead th {
    padding: 9px 14px; text-align: left; font-size: 15px; font-weight: 700; color: #fff; background: var(--brand); white-space: nowrap;
}
.ftable thead th:first-child, .jtable thead th:first-child { border-radius: 6px 0 0 0; }
.ftable thead th:last-child, .jtable thead th:last-child { border-radius: 0 6px 0 0; }
.fgroup-head th { padding: 0; background: var(--group); }
.fgroup-head button {
    display: flex; align-items: center; justify-content: space-between; width: 100%;
    padding: 10px 24px; font-size: 15px; font-weight: 700; color: #fff; background: none; border: 0; cursor: pointer; text-align: left;
}
.fgroup-head i { color: var(--muted); transition: transform .15s; }
.fgroup.is-collapsed tr:not(.fgroup-head) { display: none; }
.fgroup.is-collapsed .fgroup-head i { transform: rotate(180deg); }
.ftable td, .jtable td { padding: 12px 14px; vertical-align: middle; background: var(--row); border-bottom: 1px solid var(--border); }
.ftable tbody tr:nth-child(odd):not(.fgroup-head) td,
.jtable tbody tr:nth-child(even) td { background: var(--row-alt); }
.ftable tbody:last-child tr:last-child td, .jtable tbody tr:last-child td { border-bottom: 0; }
.fcat-name { display: inline-flex; align-items: center; gap: 8px; padding: 2px 0; font-size: 15.5px; font-weight: 700; color: var(--text); }
.fcat-name .dot { width: 10px; height: 10px; border-radius: 2px; flex: 0 0 auto; }
.fcat p { margin-top: 2px; color: var(--text-2); font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ftable td.fcat { max-width: 0; }
.ftable .col-last { width: 36%; }
.flast { display: block; font-weight: 700; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fby { display: block; margin-top: 2px; color: var(--muted); font-size: 14px; }
.fby a { color: var(--muted); }
.fby time { color: var(--brand); }
.ftable td.col-last { max-width: 0; }

/* Oglasi */
.filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; padding: 10px; background: var(--row); border-radius: 6px; }
.filters label { display: flex; align-items: center; }
.filters .f-q { flex: 1 1 260px; position: relative; }
.filters .f-q i { position: absolute; left: 10px; color: var(--muted); font-size: 13px; }
.filters input, .filters select {
    width: 100%; padding: 6px 10px; font-size: 14px; color: var(--text-2);
    background: var(--surface); border: 1px solid var(--border); border-radius: 4px; outline: none;
}
.filters .f-q input { padding-left: 30px; }
.filters select { min-width: 170px; }
.filters input:focus, .filters select:focus { border-color: var(--border-2); }
.filters .reset { padding: 4px 0; font-weight: 600; }
.jtable td { padding: 10px 14px; }
.jtable .j-logo { width: 72px; padding-right: 0; }
.logo-box {
    display: flex; align-items: center; justify-content: center; width: 56px; height: 56px; padding: 5px;
    background: #fff; border: 1px solid var(--border); border-radius: 6px; overflow: hidden;
}
.logo-box img { width: 100%; height: 100%; object-fit: contain; }
.logo-box.mono { font-size: 22px; font-weight: 800; color: #fff; background: var(--dark-2); border-color: var(--dark-2); }
.j-title a { display: block; font-size: 15.5px; font-weight: 700; color: var(--text); }
.j-title span { color: var(--muted); }
.jtable td.col-date { color: var(--muted); }
.jtable td:not(.j-title) { white-space: nowrap; }

/* Oglas */
.crumbs { display: flex; flex-wrap: wrap; margin: -4px 0 10px; color: var(--muted); }
.crumbs a { color: var(--text-2); }
.crumbs > * + *::before { content: "/"; margin: 0 6px; color: var(--muted); }
.crumbs span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 60ch; }
.job { padding: 20px 24px 24px; }
.job-head { display: flex; align-items: center; gap: 18px; margin-bottom: 14px; }
.logo-lg { width: 96px; height: 96px; padding: 8px; flex: 0 0 auto; }
.logo-lg.mono { font-size: 40px; }
.job-title { font-size: 30px; line-height: 1.2; color: var(--title); }
.facts { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.facts li { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; font-weight: 600; color: var(--text-2); background: var(--btn); border: 1px solid var(--border); border-radius: 3px; }
.facts i { color: var(--brand); }
.prose { font-size: 15.5px; line-height: 1.65; color: var(--text); word-break: break-word; }
.prose > * + * { margin-top: 12px; }
.prose h2, .prose h3, .prose h4 { color: var(--title); line-height: 1.3; }
.prose h2 { font-size: 20px; margin-top: 22px; }
.prose h3 { font-size: 17px; margin-top: 18px; }
.prose ul, .prose ol { padding-left: 24px; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li[data-list="bullet"] { list-style-type: disc; }
.prose li + li { margin-top: 4px; }
.prose blockquote { padding: 10px 14px; background: var(--row); border-left: 3px solid var(--brand); border-radius: 4px; }
.job-apply { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; padding-top: 18px; border-top: 1px dashed var(--border-2); }

/* Moja IP adresa */
.mono { font-family: "JetBrains Mono", Consolas, monospace; }
.ip-lead { margin: -6px 0 14px; font-size: 15px; color: var(--text-2); }
.ip-hero { padding: 24px 20px; text-align: center; color: #fff; background: var(--dark); border-radius: 6px; }
.ip-hero-box { display: inline-flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 12px; max-width: 100%; }
.ip-hero-badge { padding: 3px 8px; font-size: 13px; font-weight: 700; color: #fff; background: var(--brand); border-radius: 3px; }
.ip-hero-address { font-size: 34px; font-weight: 600; line-height: 1.2; color: #fff; word-break: break-all; }
.ip-hero-meta { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 10px; color: var(--on-dark); font-size: 15px; }
.ip-hero-meta[hidden], .ip-hero-meta [hidden] { display: none; }
.ip-copy {
    display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; flex: 0 0 auto;
    color: var(--on-dark); background: transparent; border: 1px solid #4b4b4b; border-radius: 3px; cursor: pointer;
}
.ip-copy:hover { color: #fff; border-color: var(--brand); }
.ip-copy.copied { color: var(--green); border-color: var(--green); }
.ip-copy[hidden] { display: none; }
.sub-title { display: flex; align-items: center; gap: 8px; margin: 22px 0 10px; font-size: 18px; color: var(--title); }
.sub-title i { color: var(--brand); font-size: 16px; }
.ip-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ip-card { position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 12px 14px; background: var(--row); border: 1px solid var(--border); border-radius: 6px; }
.ip-card .ip-copy { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; color: var(--text-2); border-color: var(--border); background: var(--surface); }
.ip-card .ip-copy:hover { color: var(--brand); border-color: var(--brand); }
.ip-label { font-size: 12.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.ip-label i { margin-right: 4px; color: var(--brand); }
.ip-value { padding-right: 40px; font-size: 16px; font-weight: 600; color: var(--text); word-break: break-all; }
.ip-value.is-empty { font-weight: 400; color: var(--muted); }
.ip-flag { width: 24px; height: 18px; margin-right: 8px; vertical-align: -3px; border-radius: 2px; object-fit: cover; }
.ip-meta { font-size: 13px; color: var(--muted); }
.ip-meta:empty { display: none; }
.terminal { overflow: hidden; background: #101010; border-radius: 6px; }
.terminal-bar { display: flex; gap: 6px; padding: 10px 12px; background: var(--dark-2); }
.terminal-bar span { width: 10px; height: 10px; border-radius: 50%; background: #4b4b4b; }
.terminal-bar span:first-child { background: var(--brand); }
.terminal-body { padding: 12px 16px 14px; font-family: "JetBrains Mono", Consolas, monospace; font-size: 13.5px; }
.terminal-comment { margin-top: 12px; color: #7d7e7e; }
.terminal-comment:first-child { margin-top: 0; }
.terminal-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.terminal-line code { min-width: 0; overflow-x: auto; white-space: nowrap; color: #e0e0e0; font-family: inherit; }
.terminal-line .prompt { margin-right: 10px; color: var(--brand); user-select: none; }
.terminal-line .ip-copy { width: 30px; height: 30px; }
.ip-faq > div { padding: 10px 0; border-bottom: 1px solid var(--border); }
.ip-faq > div:last-child { border-bottom: 0; }
.ip-faq dt { font-weight: 700; color: var(--text); }
.ip-faq dd { margin: 2px 0 0; color: var(--text-2); }
.ip-note { margin-top: 10px; padding: 10px 14px; font-size: 13.5px; color: var(--text-2); background: var(--row); border-radius: 6px; }
.ip-note i { margin-right: 4px; color: var(--brand); }

/* Oglas: prijava, tvrtka, dijeljenje */
.flash { margin-bottom: var(--gap); padding: 10px 16px; font-weight: 600; color: #fff; background: var(--blue); border-radius: 6px; }
.flash-success { background: var(--green); }
.flash-error { background: #de2a57; }
.flash-warning { color: var(--text); background: #f2d269; }
.facts li.closed { color: #de2a57; }
.share { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 20px; padding-top: 14px; border-top: 1px dashed var(--border-2); }
.share span { margin-right: 4px; font-weight: 700; color: var(--text-2); }
.share a { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; color: var(--text-2); background: var(--btn); border: 1px solid var(--border); border-radius: 3px; }
.share a:hover { color: #fff; background: var(--brand); border-color: var(--brand); text-decoration: none; }
.widget .btn-block { display: flex; width: 100%; }
.widget-text a { color: #fff; text-decoration: underline; }
.widget-text + .btn, .widget-text + .widget-text { margin-top: 10px; }
.widget-text.small { margin: 8px 0 12px; font-size: 13px; }
.apply-form label { display: block; margin: 2px 0 6px; font-weight: 600; color: #fff; }
.apply-form textarea {
    width: 100%; padding: 8px 10px; font: inherit; font-size: 14px; color: var(--text); background: var(--surface);
    border: 1px solid var(--border); border-radius: 4px; resize: vertical;
}
.save-form { margin-top: 10px; }
.company-facts { margin-top: 10px; }
.company-facts li { display: flex; align-items: center; gap: 10px; padding: 3px 0; color: var(--on-dark); }
.company-facts i { width: 16px; color: var(--brand); text-align: center; }
.company-facts a { color: #fff; }

/* Prijatelji zajednice, kontakt i Ko-fi (naslovnica) */
.friends { margin-top: var(--gap); }
.friends .box-head h2 { font-size: 24px; line-height: 1.2; color: var(--title); }
.friends-logos { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.friends-logos a {
    display: flex; align-items: center; justify-content: center; height: 88px; padding: 18px 20px;
    background: #fff; border: 1px solid var(--border); border-radius: 6px;
}
.friends-logos a:hover { border-color: var(--border-2); background: var(--row); }
.friends-logos img { display: block; max-width: 100%; max-height: 38px; width: auto; height: auto; object-fit: contain; }
.contact {
    display: flex; flex-direction: column; align-items: center; gap: 12px;
    margin-top: 16px; text-align: center; padding-top: 16px; border-top: 1px dashed var(--border-2);
}
.contact p { font-size: 15px; color: var(--text-2); }
.contact .mail { font-weight: 700; }
.kofi { display: block; line-height: 0; }
.kofi img { display: block; height: 36px; width: auto; border: 0; }

/* Kontakt obrazac (polja kao filteri na Poslovima) */
.contact-lead { margin-bottom: 14px; color: var(--text-2); }
.contact-box .flash div + div { margin-top: 2px; }
.cform { display: grid; gap: 14px; }
.cform-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cform label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--text-2); }
.cform .req { color: var(--brand); }
.cform input, .cform select, .cform textarea {
    width: 100%; padding: 8px 10px; font: inherit; font-size: 14px; color: var(--text-2);
    background: var(--surface); border: 1px solid var(--border); border-radius: 4px;
}
.cform textarea { min-height: 170px; resize: vertical; }
.cform input:focus, .cform select:focus, .cform textarea:focus { border-color: var(--border-2); }
.cform .btn { justify-self: start; padding: 10px 18px; font-size: 15px; }
.form-note { font-size: 13px; color: var(--muted); }
.hp-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 560px) {
    .cform-row { grid-template-columns: 1fr; }
    .cform .btn { justify-self: stretch; justify-content: center; }
}

.notfound { padding: 48px 24px; text-align: center; }
.notfound .code { font-size: 72px; font-weight: 800; line-height: 1; color: var(--brand); }
.notfound h1 { margin: 10px 0 6px; font-size: 26px; color: var(--title); }
.notfound p { color: var(--text-2); }
.notfound .actions { display: flex; justify-content: center; gap: 8px; margin-top: 18px; }

/* ---------- Podnožje ---------- */
.footer { flex-shrink: 0; padding: 14px 0; font-size: 13px; color: var(--muted); background: var(--dark); }
.footer-in { display: flex; align-items: center; justify-content: space-between; gap: 8px 20px; flex-wrap: wrap; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; }
.footer-links a, .footer-links button { padding: 4px 0; font: inherit; font-weight: 600; color: #fff; background: none; border: 0; cursor: pointer; }
.footer-links a:hover, .footer-links button:hover { color: #fff; text-decoration: underline; }
.footer-credit a { color: inherit; text-decoration: underline; }

.back-to-top {
    /* uz desni rub sadržaja (1270 px), a ne uz rub ekrana, pa na širokim i 4K ekranima ostaje kod sadržaja */
    position: fixed; right: max(18px, calc((100vw - 1270px) / 2 - 58px)); bottom: 18px; z-index: 40;
    display: flex; align-items: center; justify-content: center; width: 42px; height: 42px;
    color: #fff; background: var(--brand); border: 0; border-radius: 3px; cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
    opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .2s, transform .2s, visibility .2s;
}
.back-to-top:hover { background: var(--brand-hover); }
.back-to-top.show { opacity: 1; visibility: visible; transform: none; }
body.cookie-open .back-to-top { bottom: 96px; }

.cookie-banner {
    position: fixed; left: 50%; bottom: 16px; z-index: 50; transform: translateX(-50%);
    display: none; align-items: center; gap: 16px; width: calc(100% - 32px); max-width: 900px; padding: 12px 16px;
    color: var(--on-dark); background: var(--dark); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .25);
}
.cookie-banner.visible { display: flex; }
.cookie-banner p { flex: 1; font-size: 13.5px; }
.cookie-banner a { color: #fff; text-decoration: underline; }
.cookie-banner i { color: var(--brand); margin-right: 4px; }

/* ---------- Prilagodbe ---------- */
@media (max-width: 1200px) {
    :root { --side: 320px; }
}
@media (max-width: 992px) {
    .nav-link { padding: 0 9px; font-size: 14.5px; }
    .nav-search { margin-left: 6px; }
    .layout { grid-template-columns: minmax(0, 1fr); }
    .col-side.sticky { position: static; }
    .row-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .row-top > :last-child { grid-column: 1 / -1; }
    .col-side { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
}
@media (max-width: 768px) {
    :root { --gap: 10px; }
    .container { padding-left: 10px; padding-right: 10px; }
    .filters { display: grid; grid-template-columns: 1fr 1fr; }
    .filters .f-q, .filters .btn, .filters .reset { grid-column: 1 / -1; }
    .filters select { min-width: 0; }
    .top-in { height: 58px; }
    .logo img { height: 34px; }
    .top-actions .btn { padding: 6px 10px; font-size: 13px; }
    .nav-toggle {
        display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 10px 0 2px;
        font-weight: 600; color: var(--text); background: none; border: 0; cursor: pointer;
    }
    .nav-menu {
        position: absolute; top: 100%; left: 0; right: 0; display: none; flex-direction: column; height: auto;
        background: var(--content); border-bottom: 1px solid var(--border); box-shadow: 0 8px 16px rgba(0, 0, 0, .08);
    }
    .nav.open .nav-menu { display: flex; }
    .nav-menu > li { flex-direction: column; border-top: 1px solid var(--row); }
    .nav-link { height: 44px; padding: 0 16px; }
    .nav-menu > li.is-active > .nav-link { box-shadow: inset 3px 0 var(--brand); }
    .sub { position: static; display: block; border: 0; border-radius: 0; box-shadow: none; background: var(--row); }
    .has-sub > .nav-link { display: none; }
    .sub a { padding-left: 16px; }
    .nav-search { flex: 1 1 auto; }
    .row-top, .col-side { grid-template-columns: minmax(0, 1fr); display: grid; }
    .widget, .box { border-radius: 8px; }
    .card { flex-direction: column; }
    .card-lead { flex-direction: column; }
    .card-thumb { flex: 0 0 auto; width: 100%; margin: 0; }
    .card-lead .card-title { font-size: 24px; }
    .card-title { font-size: 20px; }
    .ftable .col-last { display: none; }
    .ftable thead th:first-child { border-radius: 6px 6px 0 0; }
    .jtable thead { display: none; }
    .jtable, .jtable tbody { display: block; }
    .jtable tr { display: grid; grid-template-columns: 66px 1fr; border-bottom: 1px solid var(--border); }
    .jtable tbody tr:nth-child(even) td { background: var(--row); }
    .jtable td { border: 0; padding: 4px 12px; background: var(--row); }
    .jtable .j-logo { grid-row: span 4; padding: 12px 0 12px 12px; width: auto; }
    .jtable .j-title { padding-top: 12px; }
    .jtable td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); }
    .jtable td:last-child { padding-bottom: 12px; }
    .job { padding: 16px; }
    .job-head { align-items: flex-start; }
    .logo-lg { width: 64px; height: 64px; }
    .job-title { font-size: 23px; }
    .friends-logos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ip-grid { grid-template-columns: minmax(0, 1fr); }
    .ip-hero-address { font-size: 22px; }
    .ip-hero { padding: 18px 12px; }
    .friends .box-head h2 { font-size: 20px; }
    .cookie-banner { flex-direction: column; align-items: stretch; }
    .footer-in { flex-direction: column; text-align: center; }
    body.cookie-open .back-to-top { bottom: 150px; }
}
@media (max-width: 768px) {
    .acct-msg span, .acct-new span { display: none; }
    .acct-btn span { max-width: 90px; }
}
@media (max-width: 359px) {
    .top-actions .btn:first-child { display: none; }
}

/* ---------- Tamna tema (gumb u traci; svijetla je zadana) - iste boje kao tamna tema foruma ---------- */
html[data-theme="dark"] {
    color-scheme: dark;
    --bg: #141414;
    --content: #1f1f1f;
    --row: #2b2b2b;
    --row-alt: #262626;
    --row-offset: #353535;
    --dark: #1f1f1f;
    --dark-2: #2b2b2b;
    --group: #333;
    --text: #f0f0f0;
    --text-2: #d8d8d8;
    --muted: #9c9c9c;
    --meta: #8f8f8f;
    --title: #f0f0f0;
    --border: #353535;
    --border-2: #4a4a4a;
    --btn: #2b2b2b;
    --btn-hover: #353535;
    --surface: #262626;
}
html[data-theme="dark"] .logo .logo-l { display: none; }
html[data-theme="dark"] .logo .logo-d { display: block; }
html[data-theme="dark"] .theme-switch { background: #4a4a4a; }
html[data-theme="dark"] .theme-switch:hover { background: #5a5a5a; }
html[data-theme="dark"] .theme-switch-knob { transform: translateX(18px); }
html[data-theme="dark"] .theme-switch .fa-sun { display: none; }
html[data-theme="dark"] .theme-switch .fa-moon { display: inline-block; }
html[data-theme="dark"] .footer { background: #1c1c1c; }
html[data-theme="dark"] .ip-hero { background: #141414; }
/* logotipi tvrtki i partnera ostaju na svijetloj podlozi da se vide */
html[data-theme="dark"] .friends-logos a:hover { background: #f1f1f1; }

/* ---------- Račun za poslove (2026-11-21): gumbi po ulozi + "Uđi", namjerno drugačiji od
   Prijava/Registracija u headeru (to je račun na forumu) ---------- */
.btn-job i { font-size: 13px; }
.widget-cta .ticks { margin: 2px 0 10px; }
.widget-cta .ticks li { padding: 3px 0; }
.widget-cta .btn { padding: 9px 10px; }
.widget-cta .cta-login { margin-top: 6px; line-height: 1.35; }
.cta-login { margin: 10px 0 0; text-align: center; font-size: 14px; color: var(--text-2); }
.cta-login a { font-weight: 700; white-space: nowrap; }
.cta-login a i { margin-left: 2px; font-size: 11px; }
.jobs-strip { display: none; }
@media (max-width: 992px) {
    /* traka iznad popisa oglasa: kutija "Račun za poslove" je tada ispod svih oglasa */
    .jobs-strip { display: block; margin: 0 0 12px; padding: 12px 14px; background: var(--row); border-left: 3px solid var(--brand); border-radius: 3px; }
    .jobs-strip-q { margin: 0 0 10px; font-weight: 700; color: var(--text); }
    .jobs-strip-q i { margin-right: 6px; color: var(--brand); }
    .jobs-strip-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
    .jobs-strip .btn { padding: 9px 8px; font-size: 14px; }
    .jobs-strip .cta-login { margin-top: 8px; }
}
html[data-theme="dark"] .btn-job { background: #3a3a3a; border-color: #4a4a4a; }
html[data-theme="dark"] .btn-job:hover { background: #454545; }
