/* ULTRA Time - korisničko uputstvo. Tokeni i tipografija iz ULTRA dizajn sistema (/ultra/tokens.css). */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; background: var(--surface); color: var(--ink); font: 400 16px/24px var(--font-sans); -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
code, kbd { font-family: var(--font-mono); font-size: 13px; background: var(--surface-alt); border: 1px solid var(--hairline); border-radius: var(--radius-xs); padding: 1px 6px; color: var(--ink); }
kbd { font-weight: 500; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--ink); margin: 0; letter-spacing: -0.02em; }
h1 { font-size: 32px; line-height: 40px; font-weight: 700; }
h2 { font-size: 24px; line-height: 32px; font-weight: 700; padding-top: 48px; margin-bottom: 8px; }
h3 { font-size: 20px; line-height: 28px; font-weight: 600; padding-top: 32px; margin-bottom: 8px; }
h4 { font-family: var(--font-sans); font-size: 16px; line-height: 24px; font-weight: 600; padding-top: 16px; margin-bottom: 4px; }
p { margin: 0 0 12px; max-width: 68ch; }
ul, ol { margin: 0 0 12px; padding-left: 22px; max-width: 68ch; }
li { margin: 4px 0; }
li::marker { color: var(--ink-muted); }
.overline { font: 600 12px/16px var(--font-sans); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.lead { font-size: 18px; line-height: 28px; color: var(--ink-secondary); max-width: 64ch; }
.muted { color: var(--ink-muted); }
.small { font-size: 14px; line-height: 20px; }

/* zaglavlje */
.top { position: sticky; top: 0; z-index: 100; height: 56px; background: var(--surface-raised); border-bottom: 1px solid var(--hairline); display: flex; align-items: center; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.lockup { display: flex; align-items: center; gap: 12px; color: var(--ink); font-weight: 500; }
.lockup img { height: 28px; width: auto; }
.lockup .sep { width: 1px; height: 22px; background: var(--hairline-strong); }
.lockup span { font: 500 17px/24px var(--font-sans); }
.top nav { display: flex; gap: 8px; }
.top nav a { display: inline-flex; align-items: center; height: 36px; padding: 0 12px; border-radius: var(--radius-sm); font-size: 14px; font-weight: 500; color: var(--ink-secondary); }
.top nav a:hover { background: var(--surface-hover); text-decoration: none; color: var(--ink); }
.top .u-btn { height: 36px; }

/* raspored */
.wrap { width: min(1280px, 100% - 48px); margin: 0 auto; }
.layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 48px; padding: 32px 0 96px; }
.toc { position: sticky; top: 72px; align-self: start; max-height: calc(100vh - 88px); overflow: auto; padding-right: 8px; }
.toc .group { font: 600 12px/16px var(--font-sans); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); margin: 16px 0 6px; }
.toc a { display: block; padding: 6px 10px; border-radius: var(--radius-sm); color: var(--ink-secondary); font-size: 14px; line-height: 20px; }
.toc a:hover { background: var(--surface-hover); text-decoration: none; color: var(--ink); }
.toc a[aria-current="true"] { background: var(--surface-selected); color: var(--accent); font-weight: 600; }
.toc a.sub { padding-left: 22px; font-size: 13px; }
main { min-width: 0; }
section { scroll-margin-top: 72px; }

/* hero uputstva */
.hero { padding: 8px 0 24px; border-bottom: 1px solid var(--hairline); margin-bottom: 8px; }
.hero h1 { margin: 8px 0 12px; }
.meta { display: flex; flex-wrap: wrap; gap: 8px 16px; color: var(--ink-muted); font-size: 14px; }

/* kartice uloga */
.roles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 16px 0 8px; }
.role { background: var(--surface-raised); border: 1px solid var(--hairline); border-radius: var(--radius-lg); padding: 16px; }
.role b { display: block; font-size: 15px; margin-bottom: 4px; }
.role p { font-size: 14px; line-height: 20px; color: var(--ink-secondary); margin: 0 0 8px; }
.role a { font-size: 14px; font-weight: 600; }

/* koraci */
ol.steps { list-style: none; padding: 0; counter-reset: s; max-width: 68ch; }
ol.steps > li { counter-increment: s; position: relative; padding-left: 40px; margin: 10px 0; }
ol.steps > li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-soft-ink); font: 600 13px/26px var(--font-sans); text-align: center; }
ol.steps b { font-weight: 600; }

/* slike */
figure { margin: 16px 0 20px; }
figure img { border: 1px solid var(--hairline); border-radius: var(--radius-lg); background: var(--surface-alt); width: 100%; height: auto; aspect-ratio: 1600 / 1000; object-fit: cover; object-position: top; }
figure.full img { aspect-ratio: auto; }
figure.tablet img { aspect-ratio: 1280 / 960; }
figure.phone { display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-start; }
figure.phone img { width: 300px; max-width: 100%; border-radius: 24px; border: 6px solid var(--navy); aspect-ratio: 390 / 844; }
figcaption { font-size: 13px; line-height: 18px; color: var(--ink-muted); margin-top: 8px; flex-basis: 100%; }

/* ostalo */
.u-alert { margin: 12px 0 16px; max-width: 68ch; }
.tip { border-left: 3px solid var(--accent); background: var(--accent-soft); color: var(--accent-soft-ink); padding: 10px 14px; border-radius: 0 var(--radius-md) var(--radius-md) 0; margin: 12px 0 16px; max-width: 68ch; font-size: 15px; line-height: 22px; }
.warn { border-left: 3px solid var(--warning); background: var(--warning-soft); color: var(--ink); padding: 10px 14px; border-radius: 0 var(--radius-md) var(--radius-md) 0; margin: 12px 0 16px; max-width: 68ch; font-size: 15px; line-height: 22px; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 20px; margin: 12px 0 20px; }
table.t th { text-align: left; font: 600 12px/16px var(--font-sans); letter-spacing: .04em; text-transform: uppercase; color: var(--ink-secondary); background: var(--surface-alt); border-bottom: 1px solid var(--navy); padding: 8px 10px; }
table.t td { padding: 8px 10px; border-bottom: 1px solid var(--hairline); vertical-align: top; }
.st { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: var(--radius-pill); font: 600 12px/1 var(--font-sans); white-space: nowrap; }
.st i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.st.ok { background: var(--success-soft); color: var(--success); }
.st.warn { background: var(--warning-soft); color: var(--warning); }
.st.bad { background: var(--danger-soft); color: var(--danger); }
.st.info { background: var(--info-soft); color: var(--info); }
.st.neutral { background: var(--neutral-soft); color: var(--neutral); }
.faq details { border-bottom: 1px solid var(--hairline); padding: 10px 0; max-width: 68ch; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::after { content: '+'; color: var(--ink-muted); font-weight: 400; }
.faq details[open] summary::after { content: '-'; }
.faq details p { margin-top: 8px; }
footer.end { border-top: 1px solid var(--hairline); margin-top: 64px; padding-top: 24px; color: var(--ink-muted); font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
footer.end img { height: 24px; }

@media (max-width: 1024px) {
  .layout { grid-template-columns: 1fr; gap: 0; }
  .toc { position: static; max-height: none; border: 1px solid var(--hairline); border-radius: var(--radius-lg); padding: 12px 16px; margin-bottom: 24px; }
  .roles { grid-template-columns: 1fr; }
  .top nav { display: none; }
}
@media (max-width: 640px) {
  .wrap { width: min(1280px, 100% - 32px); }
  h1 { font-size: 26px; line-height: 32px; }
  h2 { font-size: 22px; line-height: 28px; }
}

/* štampa / PDF (A4) */
@media print {
  @page { size: A4; margin: 16mm 14mm 18mm; }
  html { scroll-padding-top: 0; }
  body { font-size: 10.5pt; line-height: 1.5; color: #162129; background: #fff; }
  .top, .toc, .no-print { display: none !important; }
  .layout { display: block; padding: 0; }
  .wrap { width: 100%; }
  h2 { page-break-before: always; break-before: page; padding-top: 0; font-size: 20pt; }
  h2.first { page-break-before: avoid; break-before: avoid; }
  h3 { font-size: 14pt; padding-top: 18pt; break-after: avoid; }
  h4 { break-after: avoid; }
  figure { break-inside: avoid; margin: 10pt 0 14pt; }
  figure img { max-height: 120mm; width: auto; max-width: 100%; border-color: #B6BDBF; }
  figure.phone img { width: 62mm; border-width: 4px; }
  ol.steps > li { break-inside: avoid; }
  table.t { break-inside: auto; font-size: 9.5pt; }
  tr { break-inside: avoid; }
  a { color: #162129; }
  .tip, .warn { break-inside: avoid; }
  .faq details { display: block; }
  .faq summary::after { content: ''; }
  .faq details > *:not(summary) { display: block; }
  .roles { display: grid; grid-template-columns: repeat(3, 1fr); }
  footer.end { display: none; }
}
