/* ==========================================================================
   Trange Frange — zajednički dizajn sistem
   Tokeni su definisani u layouts/master.blade.php (:root --tf-*)
   ========================================================================== */

/* ---------- Osnova stranice ---------- */
.tf-page {
    background: var(--tf-ground);
    color: var(--tf-ink);
    font-family: var(--tf-body);
    font-size: 16px;
    line-height: 1.55;
    padding: 40px 0 80px;
    min-height: 60vh;
}
.tf-page *, .tf-page *::before, .tf-page *::after { box-sizing: border-box; }
.tf-page a { text-decoration: none; }
.tf-page h1, .tf-page h2, .tf-page h3, .tf-page h4 {
    font-family: var(--tf-display);
    color: var(--tf-ink);
    margin: 0;
    letter-spacing: -.015em;
}
.tf-wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.tf-wrap--narrow { max-width: 820px; }
.tf-wrap--text { max-width: 760px; }

.tf-page-head {
    display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap;
    margin-bottom: 28px;
}
.tf-page-head h1 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); font-weight: 800; line-height: 1.05; }
.tf-page-head p { margin: 8px 0 0; color: var(--tf-muted); max-width: 60ch; }
.tf-crumbs { display: flex; gap: 6px; align-items: center; font-size: .88rem; color: var(--tf-muted); margin-bottom: 14px; flex-wrap: wrap; }
.tf-crumbs a { color: var(--tf-forest); }
.tf-crumbs a:hover { text-decoration: underline; }

/* ---------- Kartice ---------- */
.tf-card {
    background: #fff;
    border: 1px solid var(--tf-line);
    border-radius: 18px;
}
.tf-card__body { padding: 24px; }
.tf-card__head {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 18px 24px; border-bottom: 1px solid var(--tf-line);
}
.tf-card__head h2 { font-size: 1.2rem; font-weight: 700; }

/* ---------- Dugmad ---------- */
.tf-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
    min-height: 46px; padding: .65rem 1.3rem;
    border-radius: 999px; border: 2px solid transparent;
    font-family: var(--tf-body); font-weight: 600; font-size: .98rem; line-height: 1;
    cursor: pointer; text-decoration: none; white-space: nowrap;
    transition: background-color .15s, color .15s, border-color .15s;
}
.tf-btn i { font-size: 1.2em; }
.tf-btn:active { transform: translateY(1px); }
.tf-btn:disabled, .tf-btn.is-disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }
.tf-btn--sun { background: var(--tf-sun); color: var(--tf-ink); }
.tf-btn--sun:hover { background: var(--tf-sun-deep); color: var(--tf-ink); }
.tf-btn--forest { background: var(--tf-forest); color: #fff; }
.tf-btn--forest:hover { background: var(--tf-forest-deep); color: #fff; }
.tf-btn--line { background: #fff; border-color: var(--tf-line); color: var(--tf-ink); }
.tf-btn--line:hover { border-color: var(--tf-forest); color: var(--tf-forest); }
.tf-btn--ghost { background: transparent; color: var(--tf-forest); }
.tf-btn--ghost:hover { background: var(--tf-sage); color: var(--tf-forest); }
.tf-btn--danger { background: #fff; border-color: #F1C2BC; color: #B3261E; }
.tf-btn--danger:hover { background: #FBECEA; border-color: #B3261E; color: #B3261E; }
.tf-btn--success { background: #1F8A4C; color: #fff; }
.tf-btn--success:hover { background: #17703D; color: #fff; }
.tf-btn--sm { min-height: 38px; padding: .45rem .95rem; font-size: .88rem; }
.tf-btn--block { width: 100%; }
.tf-icon-btn {
    width: 40px; height: 40px; border-radius: 50%;
    display: inline-grid; place-items: center;
    background: transparent; border: 1px solid transparent; color: var(--tf-ink);
    font-size: 1.25rem; cursor: pointer; text-decoration: none;
}
.tf-icon-btn:hover { background: var(--tf-ground); color: var(--tf-forest); }
.tf-icon-btn--danger:hover { background: #FBECEA; color: #B3261E; }
.tf-link { color: var(--tf-forest); font-weight: 600; text-decoration: none; }
.tf-link:hover { color: var(--tf-forest-deep); text-decoration: underline; }

.tf-page :focus-visible, .tf-auth :focus-visible, .tf-modal :focus-visible {
    outline: 3px solid var(--tf-sun); outline-offset: 2px;
}

/* ---------- Forme ---------- */
.tf-form { display: grid; gap: 18px; }
.tf-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.tf-form__row--3 { grid-template-columns: repeat(3, 1fr); }
.tf-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tf-label { font-weight: 600; font-size: .92rem; color: var(--tf-ink); }
.tf-label small { font-weight: 400; color: var(--tf-muted); }
.tf-input, .tf-select, .tf-textarea {
    width: 100%;
    min-height: 48px; padding: .7rem 1rem;
    border: 1px solid #CFD8C9; border-radius: 12px;
    background: #fff; color: var(--tf-ink);
    font-family: var(--tf-body); font-size: 1rem; line-height: 1.4;
    transition: border-color .15s, box-shadow .15s;
    appearance: none; -webkit-appearance: none;
}
.tf-textarea { min-height: 140px; resize: vertical; }
.tf-select {
    padding-right: 2.6rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%231E4A2C' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 1rem center;
}
.tf-input::placeholder, .tf-textarea::placeholder { color: #8A968D; }
.tf-input:focus, .tf-select:focus, .tf-textarea:focus {
    outline: none; border-color: var(--tf-forest); box-shadow: 0 0 0 3px rgba(30,74,44,.14);
}
.tf-input:disabled, .tf-input[readonly] { background: var(--tf-ground); color: var(--tf-muted); }
.tf-input.is-invalid, .tf-select.is-invalid, .tf-textarea.is-invalid { border-color: #B3261E; }
.tf-hint { font-size: .84rem; color: var(--tf-muted); }
.tf-error { font-size: .86rem; color: #B3261E; display: flex; gap: 4px; align-items: flex-start; }
.tf-error i { margin-top: 2px; }

.tf-pass { position: relative; }
.tf-pass .tf-input { padding-right: 3rem; }
.tf-pass__toggle {
    position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
    width: 38px; height: 38px; border-radius: 50%; border: 0; background: transparent;
    display: grid; place-items: center; color: var(--tf-muted); font-size: 1.25rem; cursor: pointer;
}
.tf-pass__toggle:hover { color: var(--tf-forest); background: var(--tf-ground); }

.tf-check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: .95rem; }
.tf-check input {
    flex: none; width: 22px; height: 22px; margin: 1px 0 0;
    accent-color: var(--tf-forest); cursor: pointer;
}
.tf-check a { color: var(--tf-forest); font-weight: 600; text-decoration: underline; }

/* ---------- Obaveštenja ---------- */
.tf-alert {
    display: flex; gap: 10px; align-items: flex-start;
    padding: 12px 14px; border-radius: 12px; font-size: .94rem; line-height: 1.45;
    border: 1px solid transparent;
}
.tf-alert i { font-size: 1.25rem; flex: none; margin-top: -1px; }
.tf-alert a { color: inherit; font-weight: 600; text-decoration: underline; }
.tf-alert--info { background: #EEF4EA; border-color: #D3E2C9; color: #23452E; }
.tf-alert--success { background: #E6F4EA; border-color: #BFE0C9; color: #145A32; }
.tf-alert--warning { background: #FFF7D6; border-color: #F5E2A0; color: #6B5000; }
.tf-alert--danger { background: #FBECEA; border-color: #F1C2BC; color: #8E2A20; }

/* ---------- Oznake statusa ---------- */
.tf-status {
    display: inline-flex; align-items: center; gap: 6px;
    padding: .3rem .7rem; border-radius: 999px;
    font-size: .8rem; font-weight: 600; white-space: nowrap;
}
.tf-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.tf-status--pending { background: #FFF4CC; color: #7A5B00; }
.tf-status--accepted { background: #E2EEF9; color: #1F4E79; }
.tf-status--done { background: #E6F4EA; color: #17703D; }
.tf-status--rejected, .tf-status--canceled { background: #FBECEA; color: #A0281D; }
.tf-status--muted { background: var(--tf-ground); color: var(--tf-muted); }

/* ---------- Prazno stanje ---------- */
.tf-empty {
    text-align: center; padding: 56px 24px;
    border: 2px dashed var(--tf-line); border-radius: 18px; background: #fff;
}
.tf-empty > i { font-size: 2.8rem; color: var(--tf-forest); }
.tf-empty h3 { font-size: 1.35rem; margin: 10px 0 6px; }
.tf-empty p { color: var(--tf-muted); margin: 0 auto 20px; max-width: 46ch; }

/* ---------- Nalog: meni + sadržaj ---------- */
.tf-account { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 28px; align-items: start; }
.tf-account > * { min-width: 0; }
.tf-account-nav { position: sticky; top: 20px; }
.tf-account-nav__user {
    display: flex; align-items: center; gap: 12px; padding: 16px; margin-bottom: 10px;
}
.tf-account-nav__avatar {
    width: 48px; height: 48px; border-radius: 50%; flex: none;
    display: grid; place-items: center;
    background: var(--tf-forest); color: #fff;
    font-family: var(--tf-display); font-weight: 700; font-size: 1.2rem;
}
.tf-account-nav__user strong { display: block; line-height: 1.2; }
.tf-account-nav__user div span { font-size: .85rem; color: var(--tf-muted); }
.tf-account-nav nav { display: flex; flex-direction: column; gap: 2px; padding: 0 8px 8px; }
.tf-account-nav nav a, .tf-account-nav nav button {
    display: flex; align-items: center; gap: 12px;
    padding: .7rem .85rem; border-radius: 12px; border: 0; background: transparent;
    color: var(--tf-ink); font-weight: 500; font-size: .97rem; text-align: left; cursor: pointer; width: 100%;
}
.tf-account-nav nav i { font-size: 1.3rem; color: var(--tf-forest); }
.tf-account-nav nav a:hover, .tf-account-nav nav button:hover { background: var(--tf-ground); color: var(--tf-forest); }
.tf-account-nav nav a.is-active { background: var(--tf-sage); color: var(--tf-forest); font-weight: 600; }
.tf-account-nav nav .tf-account-nav__count {
    margin-left: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
    display: grid; place-items: center; background: var(--tf-forest); color: #fff; font-size: .75rem; font-weight: 700;
}
.tf-account-nav hr { margin: 6px 8px; border-color: var(--tf-line); opacity: 1; }
.tf-account-impact { margin: 0 16px 16px; padding: 14px; border-radius: 14px; background: var(--tf-sun); }
.tf-account-impact strong { display: block; font-family: var(--tf-display); font-size: .95rem; margin-bottom: 6px; }
.tf-account-impact ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; font-size: .88rem; }
.tf-account-impact li { display: flex; justify-content: space-between; gap: 8px; }
.tf-account-impact li b { font-weight: 700; }

/* ---------- Segmentirani tabovi ---------- */
.tf-tabs { display: inline-flex; gap: 4px; padding: 4px; background: #fff; border: 1px solid var(--tf-line); border-radius: 999px; flex-wrap: wrap; }
.tf-tabs button, .tf-tabs a {
    border: 0; background: transparent; padding: .5rem 1rem; border-radius: 999px;
    font-weight: 600; font-size: .9rem; color: var(--tf-muted); cursor: pointer; text-decoration: none;
    display: inline-flex; gap: 6px; align-items: center;
}
.tf-tabs button:hover, .tf-tabs a:hover { color: var(--tf-forest); }
.tf-tabs .is-active { background: var(--tf-forest); color: #fff !important; }
.tf-tabs .tf-tabs__n { font-size: .75rem; opacity: .8; }

/* ---------- Lista stavki (moji oglasi, praćeni) ---------- */
.tf-rows { display: flex; flex-direction: column; }
.tf-row {
    display: grid; grid-template-columns: 72px 1fr auto; gap: 16px; align-items: center;
    padding: 14px 20px; border-top: 1px solid var(--tf-line);
}
.tf-row:first-child { border-top: 0; }
.tf-row__img {
    width: 72px; height: 72px; border-radius: 12px; object-fit: cover; background: var(--tf-sage);
    display: grid; place-items: center; color: var(--tf-forest); font-size: 1.6rem;
}
.tf-row__main { min-width: 0; }
.tf-row__title { font-weight: 600; font-size: 1.02rem; color: var(--tf-ink); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tf-row__title:hover { color: var(--tf-forest); }
.tf-row__meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 4px; color: var(--tf-muted); font-size: .85rem; }
.tf-row__meta span { display: inline-flex; align-items: center; gap: 4px; }
.tf-row__actions { display: flex; align-items: center; gap: 4px; }
.tf-row__actions form { margin: 0; }

/* ---------- Kartica razmene (ponude/zahtevi) ---------- */
.tf-deal { padding: 0; overflow: hidden; }
.tf-deal + .tf-deal { margin-top: 16px; }
.tf-deal__head {
    display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
    padding: 14px 20px; border-bottom: 1px solid var(--tf-line);
}
.tf-deal__who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tf-deal__who .tf-account-nav__avatar { width: 36px; height: 36px; font-size: .95rem; background: var(--tf-sage); color: var(--tf-forest); }
.tf-deal__who strong { display: block; line-height: 1.2; }
.tf-deal__who span { font-size: .82rem; color: var(--tf-muted); }
.tf-deal__swap {
    display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: center;
    padding: 20px;
}
.tf-deal__item { display: flex; gap: 14px; align-items: center; min-width: 0; color: var(--tf-ink); }
.tf-deal__item:hover .tf-deal__name { color: var(--tf-forest); }
.tf-deal__item img, .tf-deal__noimg {
    width: 92px; height: 92px; border-radius: 14px; object-fit: cover; flex: none;
    background: var(--tf-sage); display: grid; place-items: center; color: var(--tf-forest); font-size: 1.8rem;
}
.tf-deal__label { display: block; font-size: .78rem; color: var(--tf-muted); margin-bottom: 2px; }
.tf-deal__name { display: block; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.tf-deal__arrow {
    width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
    background: var(--tf-sun); color: var(--tf-ink); font-size: 1.4rem;
}
.tf-deal__contact {
    display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center;
    margin: 0 20px; padding: 12px 16px; border-radius: 12px; background: var(--tf-ground); font-size: .92rem;
}
.tf-deal__contact span { display: inline-flex; align-items: center; gap: 6px; }
.tf-deal__contact i { color: var(--tf-forest); font-size: 1.1rem; }
.tf-deal__contact a:not(.tf-btn) { color: var(--tf-forest); font-weight: 600; }
.tf-deal__foot {
    display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
    padding: 16px 20px; margin-top: 16px; border-top: 1px solid var(--tf-line); background: #FBFCF9;
}
.tf-deal__question { font-weight: 600; }
.tf-deal__actions { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.tf-deal__actions form { margin: 0; }
.tf-deal.is-blocked .tf-deal__swap { opacity: .55; }
.tf-deal .tf-alert { margin: 16px 20px 0; }

/* ---------- Modal ---------- */
.tf-modal .modal-content { border: 0; border-radius: 20px; overflow: hidden; font-family: var(--tf-body); }
.tf-modal .modal-header { border-bottom: 1px solid var(--tf-line); padding: 18px 22px; }
.tf-modal .modal-title { font-family: var(--tf-display); font-weight: 700; font-size: 1.2rem; }
.tf-modal .modal-body { padding: 22px; }
.tf-modal .modal-footer { border-top: 1px solid var(--tf-line); padding: 14px 22px; gap: 8px; }

/* ---------- Ocene ---------- */
.tf-rate { display: flex; gap: 8px; }
.tf-rate button {
    display: inline-flex; align-items: center; gap: 6px;
    padding: .45rem .9rem; border-radius: 999px; border: 1px solid var(--tf-line); background: #fff;
    font-weight: 600; font-size: .9rem; color: var(--tf-ink); cursor: pointer;
}
.tf-rate button i { font-size: 1.15rem; }
.tf-rate .like-button i { color: #1F8A4C; }
.tf-rate .dislike-button i { color: #B3261E; }
.tf-rate button:hover:not(:disabled) { border-color: var(--tf-forest); }
.tf-rate button:disabled { cursor: default; opacity: .8; }

/* ---------- Tekstualne stranice ---------- */
.tf-prose { font-size: 1.05rem; line-height: 1.75; color: #2B3A2F; }
.tf-prose > * + * { margin-top: 1em; }
.tf-prose h2 { font-size: 1.6rem; font-weight: 800; margin-top: 1.8em; line-height: 1.2; }
.tf-prose h3 { font-size: 1.25rem; font-weight: 700; margin-top: 1.5em; line-height: 1.3; }
.tf-prose h4 { font-size: 1.05rem; font-weight: 700; margin-top: 1.2em; }
.tf-prose p { margin: 0; }
.tf-prose ul, .tf-prose ol { padding-left: 1.3em; margin-bottom: 0; }
.tf-prose li + li { margin-top: .35em; }
.tf-prose a:not(.tf-btn) { color: var(--tf-forest); font-weight: 600; text-decoration: underline; }
.tf-prose img { max-width: 100%; height: auto; border-radius: 14px; }
.tf-prose blockquote { margin: 0; padding: 12px 18px; border-left: 4px solid var(--tf-sun); background: #fff; border-radius: 0 12px 12px 0; }
.tf-prose strong { color: var(--tf-ink); }

.tf-steps-list { list-style: none; padding: 0; margin: 0; counter-reset: tfstep; display: grid; gap: 14px; }
.tf-steps-list > li {
    counter-increment: tfstep;
    display: grid; grid-template-columns: 48px 1fr; gap: 16px; align-items: start;
    padding: 20px; background: #fff; border: 1px solid var(--tf-line); border-radius: 16px;
}
.tf-steps-list > li::before {
    content: counter(tfstep);
    width: 48px; height: 48px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--tf-sun); color: var(--tf-ink);
    font-family: var(--tf-display); font-weight: 800; font-size: 1.25rem;
}
.tf-steps-list h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 4px; }
.tf-steps-list p { margin: 0; color: #3D4A40; }

/* ---------- Hero traka za podstranice ---------- */
.tf-band {
    background: var(--tf-forest); color: #fff; padding: 56px 0 52px; position: relative; overflow: hidden;
}
.tf-band::after {
    content: ""; position: absolute; right: -140px; top: -180px; width: 460px; height: 460px; border-radius: 50%;
    background: var(--tf-forest-deep);
}
.tf-band > * { position: relative; z-index: 1; }
.tf-band h1 {
    font-family: var(--tf-display); font-weight: 800; color: #fff;
    font-size: clamp(2.2rem, 5vw, 3.6rem); line-height: 1; letter-spacing: -.03em; max-width: 16ch; margin: 0;
}
.tf-band p { margin: 16px 0 0; max-width: 56ch; color: rgba(255,255,255,.82); font-size: 1.1rem; }
.tf-band .tf-crumbs, .tf-band .tf-crumbs a { color: var(--tf-sage); }
.tf-band + .tf-page { padding-top: 48px; }

/* ---------- Galerija i detalji oglasa ---------- */
.tf-product { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 32px; align-items: start; }
.tf-product > * { min-width: 0; }
.tf-gallery__main {
    position: relative; aspect-ratio: 4 / 3; border-radius: 20px; overflow: hidden;
    background: #fff; border: 1px solid var(--tf-line);
}
.tf-gallery__main img { width: 100%; height: 100%; object-fit: contain; display: block; cursor: zoom-in; background: #fff; }
.tf-gallery__nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 44px; height: 44px; border-radius: 50%; border: 0;
    display: grid; place-items: center; background: rgba(255,255,255,.92); color: var(--tf-ink);
    font-size: 1.6rem; cursor: pointer; box-shadow: 0 4px 14px rgba(23,38,27,.18);
}
.tf-gallery__nav--prev { left: 12px; }
.tf-gallery__nav--next { right: 12px; }
.tf-gallery__count {
    position: absolute; right: 12px; bottom: 12px; padding: .25rem .65rem; border-radius: 999px;
    background: rgba(23,38,27,.7); color: #fff; font-size: .8rem; font-weight: 600;
}
.tf-gallery__thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; }
.tf-gallery__thumbs button {
    flex: none; width: 76px; height: 76px; padding: 0; border-radius: 12px; overflow: hidden;
    border: 2px solid transparent; background: var(--tf-sage); cursor: pointer;
}
.tf-gallery__thumbs button.is-active { border-color: var(--tf-forest); }
.tf-gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }

.tf-lightbox {
    position: fixed; inset: 0; z-index: 2000; background: rgba(10,20,13,.94);
    display: flex; align-items: center; justify-content: center; padding: 56px 16px;
}
.tf-lightbox[hidden] { display: none; }
.tf-lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 8px; user-select: none; }
.tf-lightbox__close, .tf-lightbox__nav {
    position: absolute; width: 48px; height: 48px; border-radius: 50%; border: 0;
    display: grid; place-items: center; background: rgba(255,255,255,.14); color: #fff; font-size: 1.7rem; cursor: pointer;
}
.tf-lightbox__close { top: 14px; right: 14px; }
.tf-lightbox__nav--prev { left: 14px; top: 50%; transform: translateY(-50%); }
.tf-lightbox__nav--next { right: 14px; top: 50%; transform: translateY(-50%); }
.tf-lightbox__count { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,.8); font-size: .9rem; }

.tf-pinfo { display: flex; flex-direction: column; gap: 18px; }
.tf-pinfo__tags { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.tf-tag {
    display: inline-flex; align-items: center; gap: 5px;
    padding: .3rem .75rem; border-radius: 999px; background: #fff; border: 1px solid var(--tf-line);
    font-size: .82rem; font-weight: 500; color: var(--tf-muted);
}
.tf-tag--sun { background: var(--tf-sun); border-color: var(--tf-sun); color: var(--tf-ink); font-weight: 600; }
.tf-pinfo h1 { font-size: clamp(1.8rem, 3vw, 2.4rem); font-weight: 800; line-height: 1.1; overflow-wrap: anywhere; }
.tf-owner { display: flex; align-items: center; gap: 12px; padding: 16px; }
.tf-owner .tf-account-nav__avatar { width: 48px; height: 48px; }
.tf-owner__name { font-weight: 700; display: block; }
.tf-owner__meta { font-size: .88rem; color: var(--tf-muted); display: flex; gap: 12px; flex-wrap: wrap; }
.tf-owner .tf-rate { margin-left: auto; }
.tf-impact {
    padding: 18px; border-radius: 16px; background: var(--tf-sun);
}
.tf-impact h2 { font-size: 1rem; font-weight: 700; margin-bottom: 10px; }
.tf-impact__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tf-impact__grid div { background: rgba(255,255,255,.55); border-radius: 12px; padding: 10px 12px; }
.tf-impact__grid b { display: block; font-family: var(--tf-display); font-size: 1.2rem; }
.tf-impact__grid span { font-size: .8rem; color: #4B4A2E; }

/* Panel za izbor stvari za razmenu */
.tf-picker { display: grid; gap: 8px; max-height: 320px; overflow-y: auto; }
.tf-pick {
    position: relative; display: flex; align-items: center; gap: 10px;
    padding: 8px 10px; border: 2px solid var(--tf-line); border-radius: 12px; cursor: pointer; background: #fff; margin: 0;
}
.tf-pick input { position: absolute; opacity: 0; pointer-events: none; }
.tf-pick img, .tf-pick .tf-pick__noimg { width: 48px; height: 48px; border-radius: 10px; object-fit: cover; flex: none; background: var(--tf-sage); display: grid; place-items: center; color: var(--tf-forest); }
.tf-pick__name { flex: 1; font-size: .94rem; font-weight: 500; line-height: 1.3; }
.tf-pick__name small { display: block; color: var(--tf-muted); font-weight: 400; }
.tf-pick__check { font-size: 1.4rem; color: var(--tf-forest); opacity: 0; }
.tf-pick:hover { border-color: #BFCDB4; }
.tf-pick:has(input:checked) { border-color: var(--tf-forest); background: #F1F6EC; }
.tf-pick:has(input:checked) .tf-pick__check { opacity: 1; }
.tf-pick:has(input:focus-visible) { outline: 3px solid var(--tf-sun); outline-offset: 2px; }
.tf-pick.is-disabled { opacity: .5; cursor: not-allowed; }

/* Komentari */
.tf-review { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 16px 0; border-top: 1px solid var(--tf-line); }
.tf-review:first-child { border-top: 0; padding-top: 0; }
.tf-review .tf-account-nav__avatar { width: 40px; height: 40px; font-size: .95rem; background: var(--tf-sage); color: var(--tf-forest); }
.tf-review__head { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.tf-review__head strong { font-weight: 600; }
.tf-review__head time { font-size: .82rem; color: var(--tf-muted); }
.tf-review p { margin: 4px 0 0; white-space: pre-line; overflow-wrap: anywhere; }

/* Dropzona za slike */
.tf-drop {
    position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
    padding: 28px 16px; border: 2px dashed #BFCDB4; border-radius: 16px; background: #FBFCF9;
    text-align: center; cursor: pointer; transition: border-color .15s, background-color .15s;
}
.tf-drop:hover, .tf-drop.is-over { border-color: var(--tf-forest); background: #F1F6EC; }
.tf-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.tf-drop > i { font-size: 2.2rem; color: var(--tf-forest); }
.tf-drop strong { font-size: 1rem; }
.tf-drop span { font-size: .86rem; color: var(--tf-muted); }
.tf-previews { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.tf-previews:empty { display: none; }
.tf-previews figure { position: relative; margin: 0; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--tf-sage); }
.tf-previews img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tf-previews figcaption {
    position: absolute; left: 6px; top: 6px; padding: .1rem .5rem; border-radius: 999px;
    background: var(--tf-sun); font-size: .7rem; font-weight: 700;
}

/* CKEditor uklapanje */
.tf-page .ck.ck-editor__main > .ck-editor__editable { min-height: 220px; border-radius: 0 0 12px 12px !important; font-size: 1rem; }
.tf-page .ck.ck-editor__top .ck-toolbar { border-radius: 12px 12px 0 0 !important; background: #FBFCF9; }
.tf-page .ck.ck-editor__main > .ck-editor__editable.ck-focused { border-color: var(--tf-forest) !important; box-shadow: 0 0 0 3px rgba(30,74,44,.14) !important; }

/* ---------- Prijava / registracija ---------- */
.tf-auth {
    display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    min-height: calc(100vh - 77px);
    background: var(--tf-ground); font-family: var(--tf-body); color: var(--tf-ink);
}
.tf-auth *, .tf-auth *::before, .tf-auth *::after { box-sizing: border-box; }
.tf-auth a { text-decoration: none; }
.tf-auth__aside {
    position: relative; overflow: hidden;
    background: var(--tf-forest); color: #fff;
    padding: 64px 56px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px;
}
.tf-auth__aside::after {
    content: ""; position: absolute; right: -180px; bottom: -200px; width: 520px; height: 520px; border-radius: 50%;
    background: var(--tf-forest-deep);
}
.tf-auth__aside > * { position: relative; z-index: 1; }
.tf-auth__aside h2 {
    font-family: var(--tf-display); font-weight: 800; color: #fff; margin: 0;
    font-size: clamp(2.2rem, 3.6vw, 3.3rem); line-height: 1; letter-spacing: -.03em; max-width: 12ch;
}
.tf-auth__aside p { color: rgba(255,255,255,.8); max-width: 40ch; margin: 18px 0 0; font-size: 1.05rem; }
.tf-auth__points { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.tf-auth__points li { display: flex; gap: 12px; align-items: flex-start; color: rgba(255,255,255,.88); }
.tf-auth__points i {
    flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
    background: var(--tf-sun); color: var(--tf-ink); font-size: 1.1rem;
}
.tf-auth__main { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.tf-auth__box { width: 100%; max-width: 480px; }
.tf-auth__box--wide { max-width: 620px; }
.tf-auth__box h1 { font-family: var(--tf-display); font-weight: 800; font-size: 2.1rem; letter-spacing: -.02em; margin: 0; }
.tf-auth__lead { margin: 8px 0 28px; color: var(--tf-muted); }
.tf-auth__lead a, .tf-auth__switch a, .tf-auth__forgot { color: var(--tf-forest); font-weight: 600; }
.tf-auth__lead a:hover, .tf-auth__switch a:hover, .tf-auth__forgot:hover { text-decoration: underline; }
.tf-auth__switch { text-align: center; margin-top: 22px; color: var(--tf-muted); }
.tf-auth__between { display: flex; justify-content: flex-end; margin-top: -8px; }
.tf-auth__section { font-family: var(--tf-display); font-weight: 700; font-size: 1.05rem; margin: 8px 0 -4px; }

/* ---------- Pretraga ---------- */
.tf-searchbar { display: flex; gap: 10px; max-width: 640px; }
.tf-searchbar .tf-input { border-radius: 999px; padding-left: 1.2rem; }

/* ---------- Mreža oglasa (pretraga, praćeni) ---------- */
.tf-pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.tf-pcard { position: relative; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--tf-line); border-radius: 18px; overflow: visible; }
.tf-pcard:hover { border-color: #C4D2BA; }
.tf-pcard__media { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 17px 17px 0 0; background: var(--tf-sage); }
.tf-pcard__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tf-pcard__noimg { display: grid; place-items: center; height: 100%; color: var(--tf-forest); font-size: 2.6rem; opacity: .5; }
.tf-pcard__cond { position: absolute; left: 12px; bottom: 12px; background: var(--tf-sun); color: var(--tf-ink); padding: .2rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 600; }
.tf-pcard__body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; gap: 6px; }
.tf-pcard__title { font-family: var(--tf-display); font-weight: 700; font-size: 1.1rem; line-height: 1.25; color: var(--tf-ink); overflow-wrap: anywhere; }
.tf-pcard__title:hover { color: var(--tf-forest); }
.tf-pcard__meta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: var(--tf-muted); font-size: .84rem; }
.tf-pcard__meta span { display: inline-flex; gap: 4px; align-items: center; }
.tf-pcard__meta i { color: var(--tf-forest); }
.tf-heart {
    position: absolute; top: 12px; right: 12px; z-index: 2;
    width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center;
    background: #fff; border: 0; color: var(--tf-forest); font-size: 1.35rem; cursor: pointer;
    box-shadow: 0 4px 14px rgba(23,38,27,.18);
}
.tf-heart .bxs-heart { color: #D6336C; }

/* ---------- Paginacija ---------- */
.tf-pagination { margin-top: 40px; display: flex; justify-content: center; }
.tf-pagination .pagination { gap: 6px; flex-wrap: wrap; justify-content: center; margin: 0; }
.tf-pagination .page-link {
    min-width: 44px; height: 44px; display: grid; place-items: center;
    border-radius: 999px !important; border: 1px solid var(--tf-line);
    color: var(--tf-ink); background: #fff; font-weight: 500;
}
.tf-pagination .page-link:hover { border-color: var(--tf-forest); color: var(--tf-forest); background: #fff; }
.tf-pagination .page-item.active .page-link { background: var(--tf-forest); border-color: var(--tf-forest); color: #fff; }
.tf-pagination .page-item.disabled .page-link { color: #A9B3AA; background: transparent; }

/* ---------- Blog ---------- */
.tf-posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.tf-post { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--tf-line); border-radius: 18px; overflow: hidden; color: var(--tf-ink); }
.tf-post:hover { border-color: #C4D2BA; color: var(--tf-ink); }
.tf-post__img { aspect-ratio: 16 / 9; background: var(--tf-sage); overflow: hidden; }
.tf-post__img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.tf-post:hover .tf-post__img img { transform: scale(1.03); }
.tf-post__noimg { height: 100%; display: grid; place-items: center; color: var(--tf-forest); font-size: 2.6rem; opacity: .5; }
.tf-post__body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.tf-post__body time { font-size: .84rem; color: var(--tf-muted); }
.tf-post__body h2 { font-size: 1.3rem; font-weight: 700; line-height: 1.25; }
.tf-post__body p { margin: 0; color: var(--tf-muted); font-size: .95rem; }
.tf-post__more { margin-top: auto; padding-top: 6px; color: var(--tf-forest); font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }
.tf-article__cover { border-radius: 20px; overflow: hidden; margin-bottom: 32px; aspect-ratio: 16 / 8; background: var(--tf-sage); }
.tf-article__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Kontakt / info kartice ---------- */
.tf-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.tf-info { padding: 22px; }
.tf-info > i {
    width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
    background: var(--tf-sun); color: var(--tf-ink); font-size: 1.5rem; margin-bottom: 14px;
}
.tf-info h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 4px; }
.tf-info p { margin: 0; color: var(--tf-muted); }
.tf-info a { color: var(--tf-forest); font-weight: 600; }

/* ---------- Responzivno ---------- */
@media (max-width: 991.98px) {
    .tf-account { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .tf-account-nav { position: static; }
    .tf-account-nav__user, .tf-account-impact { display: none; }
    .tf-account-nav nav { flex-direction: row; overflow-x: auto; padding: 6px; gap: 4px; scrollbar-width: none; }
    .tf-account-nav nav::-webkit-scrollbar { display: none; }
    .tf-account-nav nav a, .tf-account-nav nav button { flex: none; width: auto; white-space: nowrap; padding: .55rem .85rem; }
    .tf-account-nav hr { display: none; }
    .tf-product { grid-template-columns: minmax(0, 1fr); gap: 24px; }
    .tf-auth { grid-template-columns: 1fr; min-height: 0; }
    .tf-auth__aside { padding: 36px 24px; gap: 20px; }
    .tf-auth__aside h2 { font-size: 2rem; }
    .tf-auth__points { display: none; }
}
@media (max-width: 767.98px) {
    .tf-page { padding: 24px 0 56px; }
    .tf-wrap { padding: 0 16px; }
    .tf-card__body { padding: 18px; }
    .tf-form__row, .tf-form__row--3 { grid-template-columns: 1fr; }
    .tf-row { grid-template-columns: 56px 1fr; padding: 12px 14px; gap: 12px; }
    .tf-row__img { width: 56px; height: 56px; }
    .tf-row__actions { grid-column: 1 / -1; justify-content: flex-end; margin-top: -4px; }
    .tf-deal__swap { grid-template-columns: 1fr; gap: 10px; padding: 16px; }
    .tf-deal__arrow { transform: rotate(90deg); margin: 0 auto; width: 36px; height: 36px; font-size: 1.15rem; }
    .tf-deal__item img, .tf-deal__noimg { width: 72px; height: 72px; }
    .tf-deal__contact { margin: 0 16px; }
    .tf-deal__foot { padding: 14px 16px; }
    .tf-deal__actions { width: 100%; }
    .tf-deal__actions > * { flex: 1; }
    .tf-deal__actions .tf-btn { width: 100%; }
    .tf-pgrid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .tf-tabs { flex-wrap: nowrap; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
    .tf-tabs::-webkit-scrollbar { display: none; }
    .tf-tabs button, .tf-tabs a { flex: none; }
    .tf-page-head > .tf-tabs { width: 100%; }
    .tf-pcard__title { font-size: 1rem; }
    .tf-impact__grid { grid-template-columns: 1fr 1fr 1fr; }
    .tf-band { padding: 40px 0 36px; }
    .tf-auth__main { padding: 32px 16px 48px; }
    .tf-auth__box h1 { font-size: 1.8rem; }
    .tf-owner { flex-wrap: wrap; }
    .tf-owner .tf-rate { margin-left: 0; }
}
@media (max-width: 380px) {
    .tf-pgrid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .tf-page *, .tf-auth * { transition: none !important; animation: none !important; }
}

/* ---------- Obaveštenja ---------- */
.tfn-item {
    position: relative; display: grid; grid-template-columns: 40px 1fr auto; gap: 12px; align-items: start;
    padding: 12px 14px; border-radius: 14px; color: var(--tf-ink); text-decoration: none;
}
.tfn-item:hover { background: var(--tf-ground); color: var(--tf-ink); }
.tfn-item:focus-visible { outline: 3px solid var(--tf-sun); outline-offset: -3px; }
.tfn-item__icon {
    width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-size: 1.25rem;
}
.tfn-tone--sun { background: #FFF1B8; color: #7A5B00; }
.tfn-tone--green { background: #E2F2E7; color: #17703D; }
.tfn-tone--red { background: #FBECEA; color: #A0281D; }
.tfn-tone--forest { background: var(--tf-sage); color: var(--tf-forest); }
.tfn-tone--muted { background: var(--tf-ground); color: var(--tf-muted); }
.tfn-item__body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tfn-item__title { font-weight: 500; font-size: .94rem; line-height: 1.3; }
.tfn-item.is-unread .tfn-item__title { font-weight: 700; }
.tfn-item__msg {
    font-size: .88rem; color: var(--tf-muted); line-height: 1.4;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere;
}
.tfn-item__time { font-size: .78rem; color: var(--tf-muted); margin-top: 2px; }
.tfn-item.is-unread .tfn-item__time { color: var(--tf-forest); font-weight: 600; }
.tfn-item__dot { width: 10px; height: 10px; border-radius: 50%; background: #D6336C; margin-top: 6px; }

/* Meni u headeru */
.tfn-menu {
    width: 400px; max-width: calc(100vw - 24px); padding: 0 !important; overflow: hidden;
    border: 1px solid var(--tf-line) !important; border-radius: 18px !important;
    box-shadow: 0 24px 60px -16px rgba(23,38,27,.35) !important; margin-top: 10px !important;
    font-family: var(--tf-body);
}
.tfn-menu__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 18px 10px; }
.tfn-menu__head strong { font-family: var(--tf-display); font-size: 1.15rem; }
.tfn-menu__head button {
    border: 0; background: transparent; color: var(--tf-forest); font-weight: 600; font-size: .85rem; padding: .3rem .5rem; border-radius: 8px; cursor: pointer;
}
.tfn-menu__head button:hover { background: var(--tf-ground); }
.tfn-menu__head button[hidden] { display: none; }
.tfn-menu__list { max-height: min(440px, 60vh); overflow-y: auto; padding: 0 6px 6px; }
.tfn-menu__empty { text-align: center; padding: 28px 20px 32px; color: var(--tf-muted); }
.tfn-menu__empty i { font-size: 2.2rem; color: var(--tf-forest); display: block; margin-bottom: 6px; }
.tfn-menu__foot {
    display: block; text-align: center; padding: 12px; border-top: 1px solid var(--tf-line);
    color: var(--tf-forest); font-weight: 600; font-size: .92rem; text-decoration: none;
}
.tfn-menu__foot:hover { background: var(--tf-ground); color: var(--tf-forest-deep); }

/* Stranica obaveštenja */
.tfn-page { padding: 8px 10px 10px; }
.tfn-page__group { font-family: var(--tf-body) !important; font-size: .8rem !important; font-weight: 600 !important; color: var(--tf-muted) !important; letter-spacing: 0 !important; margin: 14px 12px 4px !important; }
.tfn-page__row { display: flex; align-items: flex-start; gap: 4px; }
.tfn-page__row .tfn-item { flex: 1; min-width: 0; }
.tfn-page__actions { display: flex; gap: 2px; padding-top: 12px; opacity: .6; }
.tfn-page__row:hover .tfn-page__actions, .tfn-page__actions:focus-within { opacity: 1; }
.tfn-page__actions form { margin: 0; }

@media (max-width: 575.98px) {
    .tfn-menu.show { position: fixed !important; inset: 64px 12px auto 12px !important; transform: none !important; width: auto !important; max-width: none; }
    .tfn-page__actions { opacity: 1; flex-direction: column; padding-top: 8px; }
}
