/* ─────────────────────────────────────────────────────────────
 * medpotencija.rs
 *
 * Namerno drugačije od turskimed.rs i macunmed.rs:
 *   boja      — duboka zelena (biljno), a ne medena ni crvena
 *   raspored  — centriran uvod, cene kao SPISAK a ne kartice,
 *               korpa kao plutajuće dugme dole desno
 *   tipografija — jedan sans, teži kontrast veličina
 *
 * Bez framework-a.
 * ───────────────────────────────────────────────────────────── */

:root {
    --bg:        #fdfcf9;
    --surface:   #ffffff;
    --ink:       #16211b;
    --muted:     #5d6b63;
    --line:      #dde5df;
    --green:     #1f6b4a;
    --green-dk:  #16513a;
    --green-lt:  #eaf4ee;
    --warn:      #8a6a1f;
    --r:         6px;
    --wrap:      1080px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3 { margin: 0 0 14px; line-height: 1.25; font-weight: 700; }
h1 { font-size: clamp(36px, 6vw, 58px); letter-spacing: -0.02em; }
h2 { font-size: clamp(23px, 3vw, 30px); }
h3 { font-size: 18px; }
p  { margin: 0 0 16px; }

a { color: var(--green-dk); }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }
.narrow { max-width: 740px; }

:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

.skip { position: absolute; left: -9999px; z-index: 100; padding: 10px 16px; background: var(--green); color: #fff; }
.skip:focus { left: 0; top: 0; }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ── Dugmad ─────────────────────────────────────────────── */
.btn {
    display: inline-block;
    padding: 13px 26px;
    border: 2px solid transparent;
    border-radius: var(--r);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    font-family: inherit;
}
.btn.primary { background: var(--green); color: #fff; }
.btn.primary:hover { background: var(--green-dk); text-decoration: none; }
.btn.primary:disabled { background: #a9b5ae; cursor: not-allowed; }
.btn.plain { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.plain:hover { border-color: var(--green); text-decoration: none; }
.btn.wide { display: block; width: 100%; }
.btn.small { padding: 9px 18px; font-size: 15px; }

/* ── Traka ──────────────────────────────────────────────── */
.bar { border-bottom: 1px solid var(--line); background: var(--surface); }
.bar-in { display: flex; align-items: center; gap: 26px; min-height: 62px; }
.mark { font-size: 19px; font-weight: 700; color: var(--ink); text-decoration: none; }
.mark em { font-style: normal; color: var(--green); }
.bar nav { display: flex; gap: 20px; }
.bar nav a { color: var(--muted); font-size: 15px; text-decoration: none; }
.bar nav a:hover { color: var(--green); }
.tel { margin-left: auto; font-weight: 700; white-space: nowrap; text-decoration: none; }

/* ── Uvod ───────────────────────────────────────────────── */
.opener { text-align: center; padding: 64px 0 52px; }
.kicker {
    font-size: 13px; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--green); margin-bottom: 12px;
}
.opener .sub { max-width: 620px; margin: 0 auto 32px; font-size: 19px; color: var(--muted); }

.quick {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--r);
    overflow: hidden;
    max-width: 700px;
    margin: 0 auto 30px;
}
.quick-item { background: var(--surface); padding: 16px 12px; }
.quick-item b { display: block; font-size: 21px; color: var(--green-dk); }
.quick-item span { font-size: 13px; color: var(--muted); }

.cta-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin: 0; }

/* ── Dve kolone ─────────────────────────────────────────── */
.split { border-block: 1px solid var(--line); background: var(--green-lt); padding: 44px 0; }
.split-in { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; }
.pane h2 { font-size: 21px; }

ul.dash { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
ul.dash li { padding-left: 20px; position: relative; font-size: 16px; }
ul.dash li::before {
    content: ""; position: absolute; left: 0; top: 13px;
    width: 10px; height: 2px; background: var(--green);
}

/* ── Sekcije ────────────────────────────────────────────── */
.section { padding: 52px 0; }
.section.alt { background: var(--surface); border-block: 1px solid var(--line); }
.sec-head { margin-bottom: 26px; }
.sec-head p { color: var(--muted); margin: 0; }

/* ── Cene kao spisak ────────────────────────────────────── */
.prices { padding: 52px 0; }
.list {
    display: grid;
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--r);
    overflow: hidden;
}

.row { background: var(--surface); display: grid; grid-template-columns: 92px 1fr; gap: 18px; padding: 18px 20px; }
.row-img { border-radius: 4px; overflow: hidden; background: var(--green-lt); align-self: start; }
.row-main { display: flex; flex-direction: column; gap: 10px; min-width: 0; }

.row-top { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.row-top h3 { margin: 0; }
.row-top .tag {
    font-size: 11px; font-weight: 700; letter-spacing: 0.05em;
    padding: 2px 9px; border-radius: 20px;
    background: var(--green-lt); color: var(--green-dk);
}
.row-top .short { font-size: 14px; color: var(--muted); }
.row-desc { font-size: 15px; color: var(--muted); margin: 0; }

.packs { display: flex; flex-direction: column; gap: 4px; }
.pack {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 14px;
    align-items: center;
    padding: 7px 0;
    border-top: 1px solid var(--line);
}
.pack .name { font-size: 15px; }
.pack .price {
    font-size: 16px; font-weight: 700;
    font-variant-numeric: tabular-nums; white-space: nowrap;
}
.pack button {
    background: transparent; border: 1.5px solid var(--green); color: var(--green-dk);
    padding: 6px 15px; border-radius: 4px; font-size: 14px; font-weight: 600;
    cursor: pointer; white-space: nowrap; font-family: inherit;
}
.pack button:hover { background: var(--green); color: #fff; }
.pack button.done { background: var(--green); color: #fff; border-color: var(--green); }

/* ── Koraci ─────────────────────────────────────────────── */
ol.steps { list-style: none; counter-reset: s; padding: 0; margin: 0 0 18px; display: grid; gap: 18px; }
ol.steps li { counter-increment: s; display: grid; grid-template-columns: 38px 1fr; gap: 16px; }
ol.steps li::before {
    content: counter(s);
    width: 34px; height: 34px;
    display: grid; place-items: center;
    border: 2px solid var(--green); border-radius: 50%;
    color: var(--green-dk); font-weight: 700; font-size: 15px;
}
ol.steps li b { display: block; }
ol.steps li span { color: var(--muted); font-size: 16px; }
.after { color: var(--muted); font-size: 15px; }

.note {
    background: var(--green-lt);
    border-left: 3px solid var(--warn);
    padding: 14px 18px;
    border-radius: 0 var(--r) var(--r) 0;
    font-size: 15px;
    color: var(--muted);
}

/* ── Pitanja ────────────────────────────────────────────── */
.q { border-bottom: 1px solid var(--line); }
.q > summary { cursor: pointer; list-style: none; padding: 13px 0; display: flex; align-items: center; }
.q > summary::-webkit-details-marker { display: none; }
.q > summary h3 { margin: 0; font-size: 17px; }
.q > summary::after { content: "+"; margin-left: auto; color: var(--green); font-weight: 700; font-size: 20px; }
.q[open] > summary::after { content: "–"; }
.q p { color: var(--muted); padding-bottom: 6px; margin: 0; }

/* ── Podnožje ───────────────────────────────────────────── */
.foot { background: var(--ink); color: #c7d2cb; padding: 38px 0 18px; }
.foot a { color: #7fd0a6; }
.foot-in { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.foot p { margin: 0 0 5px; font-size: 15px; }
.fine { border-top: 1px solid rgba(255,255,255,.12); margin-top: 24px; padding-top: 15px; font-size: 14px; color: #8b988f; }

/* ── Korpa: plutajuće dugme vodi na zasebnu stranicu ─────── */
.cart-fab {
    position: fixed; right: 20px; bottom: 20px; z-index: 45;
    background: var(--green); color: #fff;
    border: 0; border-radius: 40px;
    padding: 14px 24px;
    font-size: 16px; font-weight: 700; font-family: inherit;
    cursor: pointer; text-decoration: none;
    box-shadow: 0 4px 16px rgba(22,81,58,.32);
}
.cart-fab:hover { background: var(--green-dk); color: #fff; text-decoration: none; }
.cart-fab span {
    display: inline-block; min-width: 22px;
    background: rgba(255,255,255,.25); border-radius: 11px;
    padding: 0 7px; margin-left: 6px; text-align: center;
}

/* ── Traka posle dodavanja ───────────────────────────────── */
.added-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 46;
    background: var(--ink); color: #fff; padding: 12px 0;
    box-shadow: 0 -3px 18px rgba(0,0,0,.2);
}
.added-in { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.added-txt { font-size: 15px; }
.added-txt b { color: #7fd0a6; }
.added-bar .btn { margin-left: auto; }
.added-x {
    background: none; border: 0; color: rgba(255,255,255,.6);
    font-size: 26px; line-height: 1; cursor: pointer; padding: 0 4px;
}
.added-x:hover { color: #fff; }
/* Kad je traka otvorena, plutajuće dugme bi joj smetalo. */
body:has(#added-bar:not([hidden])) .cart-fab { display: none; }

/* ── Stranica korpe ──────────────────────────────────────── */
.panel-note {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r);
    padding: 34px 30px;
    max-width: 600px;
}
.panel-note h2 { margin-top: 0; }

.cart-two { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: start; }
.lab {
    font-size: 13px; font-weight: 700; letter-spacing: .09em;
    text-transform: uppercase; color: var(--muted);
    margin: 0 0 12px; padding-bottom: 9px; border-bottom: 1px solid var(--line);
}

.citems { display: flex; flex-direction: column; }
.citem {
    display: grid; grid-template-columns: 70px 1fr auto auto;
    gap: 15px; align-items: center;
    padding: 15px 0; border-bottom: 1px solid var(--line);
}
.citem-img { border-radius: 4px; overflow: hidden; background: var(--green-lt); }
.citem-main { min-width: 0; }
.citem-main b { display: block; font-size: 16px; }
/* Naziv pakovanja u svom redu — inače se dugme „Ukloni" zalepi uz njega. */
.citem-main span { display: block; font-size: 14px; color: var(--muted); }
.citem-drop {
    background: none; border: 0; padding: 4px 0 0;
    font-size: 13px; color: var(--muted); cursor: pointer;
    text-decoration: underline; font-family: inherit;
}
.citem-drop:hover { color: var(--green-dk); }
.citem-qty { display: flex; align-items: center; gap: 9px; }
.citem-qty button {
    width: 30px; height: 30px;
    border: 1px solid var(--line); background: var(--surface);
    border-radius: 5px; cursor: pointer; font-size: 17px; line-height: 1;
}
.citem-qty button:hover { border-color: var(--green); }
.citem-sum {
    font-weight: 700; white-space: nowrap; font-size: 16px;
    font-variant-numeric: tabular-nums; min-width: 92px; text-align: right;
}

.cart-sum { margin: 20px 0 4px; font-size: 18px; text-align: right; }
.cart-sum b {
    color: var(--green-dk); font-size: 25px;
    font-variant-numeric: tabular-nums; margin-left: 8px;
}

.terms { margin: 18px 0; font-size: 14px; color: var(--muted); }

#order-form label { display: block; font-size: 14px; margin: 12px 0 4px; }
#order-form input, #order-form textarea {
    width: 100%; padding: 10px 12px;
    border: 1px solid var(--line); border-radius: var(--r);
    font-size: 16px; font-family: inherit;
}
#order-form input:focus, #order-form textarea:focus { border-color: var(--green); }
.pair { display: grid; grid-template-columns: 2fr 1fr; gap: 10px; }

/* Klopka za robote — nevidljiva, ali ne display:none */
.trap { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

.fineprint { font-size: 13px; color: var(--muted); }

.msg { padding: 11px 14px; border-radius: var(--r); margin: 12px 0; font-size: 15px; }
.msg-ok { background: var(--green-lt); border: 1px solid #b6dcc6; color: var(--green-dk); }
.msg-err, .msg-error { background: #fdecea; border: 1px solid #f0bcb6; color: #a3261a; }

/* ── Tabela poređenja proizvoda (index.html, SEO tekst) ──── */
.table-scroll { overflow-x: auto; margin: 18px 0 6px; -webkit-overflow-scrolling: touch; }
.cmp { width: 100%; min-width: 480px; border-collapse: collapse; margin: 0; font-size: 15px; }
.cmp th, .cmp td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); }
.cmp th { background: var(--green); color: #fff; font-weight: 700; }
.cmp td:last-child, .cmp th:last-child {
    text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap;
}
.cmp tbody tr:hover { background: var(--green-lt); }

/* ── Mobilni ────────────────────────────────────────────── */
@media (max-width: 860px) {
    .cart-two { grid-template-columns: 1fr; gap: 30px; }
    .split-in { grid-template-columns: 1fr; gap: 28px; }
    .foot-in { grid-template-columns: 1fr; }
    .bar nav { display: none; }
}

@media (max-width: 560px) {
    body { font-size: 16px; }
    .opener { padding: 44px 0 36px; }
    .section, .prices { padding: 38px 0; }
    .row { grid-template-columns: 1fr; }
    .row-img { max-width: 120px; }
    .pack { grid-template-columns: 1fr auto; row-gap: 6px; }
    .pack button { grid-column: 1 / -1; justify-self: start; }
    .tel { display: none; }
    .cart-fab { left: 16px; right: 16px; border-radius: var(--r); text-align: center; }

    /* Korpa: naziv dobija punu širinu, iznos ide u drugi red */
    .citem { grid-template-columns: 58px 1fr auto; row-gap: 10px; }
    .citem-sum { grid-column: 2 / -1; text-align: left; min-width: 0; }
    .added-in { gap: 10px; }
    .added-bar .btn { margin-left: 0; flex: 1; }

    .cmp { font-size: 12.5px; }
    .cmp th, .cmp td { padding: 7px 6px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}


/* ── Prikaz proizvoda kao u kategoriji na macunmed.rs ──────────────────
   Dva proizvoda u redu na telefonu, tri od 700px, četiri od 1000px. Tabela svih
   pakovanja u kartici; izabran red je obojen. Dugmad: ikonica korpe + SMS.
   (15.9.2026: krupniji i čitljiviji tekst, natpis kao traka umesto kruga koji
   je sekao duži tekst, ikonica korpe umesto teksta.) */
.oc-grid {
    --oc: #1f6b4a;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
@media (min-width: 700px)  { .oc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }
@media (min-width: 1000px) { .oc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; } }

.oc-item { min-width: 0; }
.oc-thumb {
    position: relative; height: 100%;
    display: flex; flex-direction: column;
    background: #fff; border: 1px solid #e6dfdc; border-radius: 10px; overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .05);
    transition: box-shadow .2s ease, transform .2s ease;
}
.oc-thumb:hover { box-shadow: 0 8px 22px rgba(0, 0, 0, .10); transform: translateY(-2px); }
.oc-image { position: relative; background: #fff; }
.oc-image img { width: 100%; height: auto; display: block; }
.oc-flag {
    position: absolute; top: 8px; left: 8px; z-index: 2;
    max-width: calc(100% - 16px);
    background: var(--oc); color: #fff;
    border-radius: 6px; padding: 3px 8px;
    font-size: 11px; font-weight: 600; line-height: 1.3; letter-spacing: .01em;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .18);
}
.oc-caption { padding: 10px 10px 8px; flex: 1; }
.oc-caption h3 {
    margin: 0 0 8px; font-size: 15px; font-weight: 700; line-height: 1.3;
    text-align: center; color: var(--oc); min-height: 2.6em;
    display: flex; align-items: center; justify-content: center;
}
.oc-prices { width: 100%; border-collapse: collapse; font-size: 13.5px; line-height: 1.35; }
.oc-prices td { border: 0; border-top: 1px solid #f1ecea; padding: 6px 4px; text-align: left; vertical-align: middle; }
.oc-prices tr:first-child td { border-top: 0; }
.oc-prices tr:has(input:checked) td { background: color-mix(in srgb, var(--oc) 9%, #fff); }
.oc-prices td.oc-price {
    text-align: right; color: var(--oc); font-weight: 700;
    white-space: nowrap; font-variant-numeric: tabular-nums; padding-left: 6px;
}
.oc-prices label { display: flex; align-items: center; gap: 6px; cursor: pointer; color: #2c2527; }
.oc-prices input { flex: none; width: 15px; height: 15px; margin: 0; accent-color: var(--oc); }
.oc-buttons { display: flex; margin-top: auto; }
.oc-buttons .oc-add, .oc-buttons .oc-sms {
    display: flex; align-items: center; justify-content: center;
    min-height: 44px; border: 0; cursor: pointer; text-decoration: none; color: #fff;
    transition: filter .15s ease;
}
.oc-buttons .oc-add { flex: 0 0 42%; background: var(--oc); }
/* SMS dugme je uklonjeno 17.9.2026 — kad je korpa jedino dugme, puni ceo red. */
.oc-buttons .oc-add:only-child { flex: 1 1 auto; }
.oc-buttons .oc-add svg { width: 21px; height: 21px; }
.oc-buttons .oc-add.done { background: #17703c; }
.oc-buttons .oc-sms {
    flex: 1 1 auto; background: #353535; padding: 6px 4px;
    font: inherit; font-size: 10.5px; font-weight: 600; line-height: 1.2;
    text-transform: uppercase; letter-spacing: .03em; text-align: center;
}
.oc-buttons .oc-add:hover, .oc-buttons .oc-sms:hover { filter: brightness(1.12); color: #fff; }
.oc-buttons .oc-add:focus-visible, .oc-buttons .oc-sms:focus-visible { outline: 3px solid #f5c542; outline-offset: -3px; }
.oc-grid .sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}


/* Uske kartice na telefonu (dve u redu): naziv pakovanja u najviše dva reda. */
@media (max-width: 699px) {
    .oc-grid { gap: 10px; margin-left: -8px; margin-right: -8px; }
    .oc-caption { padding: 8px 6px 6px; }
    .oc-caption h3 { font-size: 14px; margin-bottom: 6px; }
    .oc-prices { font-size: 12.5px; }
    .oc-prices td { padding: 5px 2px; }
    .oc-prices label { gap: 4px; }
    .oc-prices input { width: 13px; height: 13px; }
    .oc-prices td.oc-price { padding-left: 4px; }
}

/* Akcijska cena: precrtana redovna pored one koja se naplacuje.
   Upisuje se u adminu; kad redovne cene nema, ovog elementa nema ni u HTML-u. */
.oc-old,
#price-list s {
  color: #9a908c;
  font-weight: 400;
  font-size: .88em;
  margin-right: 5px;
}

/* Istaknuto pakovanje u cenovniku — blagi ton, bez dodatne boje. */
#price-list tr.is-best td { background: #fbf7f2; font-weight: 600; }
