/* Trebinje24 — border traffic module */

:root {
    --border-clear: #16835d;
    --border-light: #66a945;
    --border-moderate: #d69b23;
    --border-heavy: #d76a2c;
    --border-very-heavy: #b9383f;
    --border-unknown: #728093;
    --border-ink: #0c1a2c;
    --border-line: rgba(12, 26, 44, .12);
    --border-soft: #f5f7fa;
}

.border-home.shell {
    margin-top: 24px;
    margin-bottom: 42px;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(15, 35, 60, .13);
    border-radius: 28px;
    background:
        radial-gradient(circle at 90% -30%, rgba(42, 101, 163, .2), transparent 40%),
        linear-gradient(135deg, #0a1727 0%, #132d49 100%);
    box-shadow: 0 24px 60px rgba(8, 24, 42, .13);
}

.border-home__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 28px;
    padding: 30px 32px 24px;
    color: #fff;
}

.border-home__head .eyebrow { color: #91b9df; }
.border-home__head h2 { margin: 7px 0 8px; color: #fff; font-size: clamp(1.75rem, 3vw, 2.65rem); letter-spacing: -.035em; }
.border-home__head p { max-width: 760px; margin: 0; color: rgba(255,255,255,.68); line-height: 1.55; }
.border-home__head > a { flex: 0 0 auto; padding-bottom: 6px; color: #fff; font-weight: 800; text-decoration: none; }
.border-home__head > a span { margin-left: 7px; }

.border-home__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: rgba(255,255,255,.13);
    border-top: 1px solid rgba(255,255,255,.13);
}

.border-card {
    position: relative;
    min-height: 218px;
    padding: 26px 28px;
    color: #fff;
    text-decoration: none;
    background: rgba(8, 21, 37, .72);
    transition: transform .2s ease, background .2s ease;
}
.border-card:hover { background: rgba(19, 43, 70, .92); }
.border-card__route { display: block; margin-bottom: 12px; color: rgba(255,255,255,.57); font-size: .78rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.border-card > strong { display: block; font-size: 1.42rem; letter-spacing: -.02em; }
.border-card__status { display: flex; align-items: center; gap: 10px; margin-top: 24px; }
.border-card__status i,
.border-legend__item i,
.border-index-card__signal i,
.border-now-card__status i,
.border-vote-button i,
.border-dot { width: 10px; height: 10px; flex: 0 0 10px; border-radius: 50%; background: var(--border-unknown); box-shadow: 0 0 0 5px rgba(114,128,147,.12); }
.border-card__status b { font-size: 1rem; }
.border-card small { display: block; margin-top: 9px; color: rgba(255,255,255,.53); line-height: 1.35; }
.border-card__more { position: absolute; left: 28px; bottom: 23px; color: rgba(255,255,255,.82); font-size: .83rem; font-weight: 800; }

.border-card--clear .border-card__status i,
.border-index-card--clear .border-index-card__signal i,
.border-detail-hero--clear .border-now-card__status i,
.border-dot--clear,
.border-vote-button--clear i,
.border-legend__item--clear i { background: var(--border-clear); box-shadow: 0 0 0 5px rgba(22,131,93,.16); }
.border-card--light .border-card__status i,
.border-index-card--light .border-index-card__signal i,
.border-detail-hero--light .border-now-card__status i,
.border-dot--light,
.border-vote-button--light i { background: var(--border-light); box-shadow: 0 0 0 5px rgba(102,169,69,.16); }
.border-card--moderate .border-card__status i,
.border-index-card--moderate .border-index-card__signal i,
.border-detail-hero--moderate .border-now-card__status i,
.border-dot--moderate,
.border-vote-button--moderate i,
.border-legend__item--moderate i { background: var(--border-moderate); box-shadow: 0 0 0 5px rgba(214,155,35,.17); }
.border-card--heavy .border-card__status i,
.border-index-card--heavy .border-index-card__signal i,
.border-detail-hero--heavy .border-now-card__status i,
.border-dot--heavy,
.border-vote-button--heavy i { background: var(--border-heavy); box-shadow: 0 0 0 5px rgba(215,106,44,.17); }
.border-card--very_heavy .border-card__status i,
.border-index-card--very_heavy .border-index-card__signal i,
.border-detail-hero--very_heavy .border-now-card__status i,
.border-dot--very_heavy,
.border-vote-button--very_heavy i,
.border-legend__item--very_heavy i { background: var(--border-very-heavy); box-shadow: 0 0 0 5px rgba(185,56,63,.17); }
.border-card--unknown .border-card__status i,
.border-index-card--unknown .border-index-card__signal i,
.border-detail-hero--unknown .border-now-card__status i,
.border-dot--unknown { background: var(--border-unknown); }

/* Index */
.border-page-hero {
    background:
        linear-gradient(120deg, rgba(8,21,38,.96), rgba(16,49,78,.92)),
        radial-gradient(circle at 82% 30%, rgba(68,140,202,.36), transparent 38%);
    color: #fff;
}
.border-page-hero__inner { display: flex; justify-content: space-between; align-items: end; gap: 36px; padding-top: 68px; padding-bottom: 58px; }
.border-page-hero h1 { margin: 8px 0 12px; max-width: 760px; color: #fff; font-size: clamp(2.5rem, 5vw, 5rem); line-height: .98; letter-spacing: -.055em; }
.border-page-hero p { max-width: 770px; margin: 0; color: rgba(255,255,255,.7); font-size: 1.05rem; line-height: 1.65; }
.border-page-hero .eyebrow { color: #9fc6e8; }
.border-legend { display: flex; flex-direction: column; gap: 12px; min-width: 235px; padding: 18px 20px; border: 1px solid rgba(255,255,255,.12); border-radius: 18px; background: rgba(255,255,255,.06); backdrop-filter: blur(12px); }
.border-legend__item { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,.8); font-size: .84rem; font-weight: 700; }

.border-index { padding-top: 42px; padding-bottom: 70px; }
.border-index__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.border-index-card { padding: 26px; border: 1px solid var(--border-line); border-radius: 22px; background: #fff; box-shadow: 0 18px 42px rgba(18,37,58,.07); }
.border-index-card header { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.border-index-card header > span { color: #6b7888; font-size: .75rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.border-index-card__signal { display: flex; align-items: center; gap: 8px; color: var(--border-ink); font-size: .77rem; font-weight: 900; text-align: right; }
.border-index-card h2 { margin: 22px 0 8px; font-size: 1.65rem; letter-spacing: -.035em; }
.border-index-card > p { min-height: 50px; margin: 0; color: #667486; line-height: 1.55; }
.border-index-card__meta { display: flex; flex-wrap: wrap; gap: 7px; margin: 22px 0; }
.border-index-card__meta span { padding: 7px 9px; border-radius: 8px; background: #f2f5f8; color: #5d6b7d; font-size: .72rem; font-weight: 700; }
.border-method-card { margin-top: 22px; padding: 28px 30px; border-radius: 22px; background: #eef4f8; border: 1px solid rgba(24,65,101,.1); }
.border-method-card h2 { margin: 5px 0 8px; font-size: 1.35rem; }
.border-method-card p { max-width: 900px; margin: 0; color: #5f6d7c; line-height: 1.6; }

/* Detail */
.border-detail-hero { color: #fff; background: linear-gradient(130deg, #0b1829, #173a5c); }
.border-detail-hero--clear { background: linear-gradient(130deg, #0a2c2b, #125844 55%, #173e4b); }
.border-detail-hero--light { background: linear-gradient(130deg, #173125, #3c6732 55%, #254c4f); }
.border-detail-hero--moderate { background: linear-gradient(130deg, #342814, #775723 55%, #34424a); }
.border-detail-hero--heavy { background: linear-gradient(130deg, #382318, #874428 55%, #443445); }
.border-detail-hero--very_heavy { background: linear-gradient(130deg, #35191f, #7a2632 55%, #4d2a3d); }
.border-detail-hero__inner { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 44px; align-items: end; padding-top: 52px; padding-bottom: 50px; }
.border-detail-back { display: inline-flex; margin-bottom: 34px; color: rgba(255,255,255,.65); font-weight: 800; text-decoration: none; }
.border-detail-hero .eyebrow { color: rgba(255,255,255,.62); }
.border-detail-hero h1 { margin: 6px 0 8px; color: #fff; font-size: clamp(2.6rem, 5vw, 4.7rem); line-height: 1; letter-spacing: -.055em; }
.border-detail-hero__copy p { max-width: 720px; margin: 0; color: rgba(255,255,255,.68); font-size: 1.02rem; line-height: 1.6; }
.border-now-card { padding: 23px 24px; border: 1px solid rgba(255,255,255,.13); border-radius: 22px; background: rgba(255,255,255,.08); backdrop-filter: blur(16px); }
.border-now-card > span { color: rgba(255,255,255,.55); font-size: .73rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.border-now-card__status { display: flex; align-items: center; gap: 13px; margin: 15px 0 8px; }
.border-now-card__status strong { font-size: 1.35rem; letter-spacing: -.025em; }
.border-now-card p { margin: 0 0 4px; color: rgba(255,255,255,.77); font-weight: 700; }
.border-now-card small { color: rgba(255,255,255,.52); }
.border-now-card > b { display: block; margin-top: 13px; color: rgba(255,255,255,.72); font-size: .75rem; }

.border-detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 24px; align-items: start; padding-top: 32px; padding-bottom: 80px; }
.border-detail-main { display: grid; gap: 22px; }
.border-detail-side { position: sticky; top: 92px; display: grid; gap: 18px; }
.border-panel { padding: 26px; border: 1px solid var(--border-line); border-radius: 22px; background: #fff; box-shadow: 0 12px 34px rgba(18,37,58,.055); }
.border-panel__head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.border-panel__head h2 { margin: 5px 0 5px; font-size: 1.55rem; letter-spacing: -.035em; }
.border-panel__head p { margin: 0; max-width: 760px; color: #667486; line-height: 1.55; }

.border-vote-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.border-vote-button { display: flex; min-height: 82px; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 13px; padding: 14px; border: 1px solid #dce3e9; border-radius: 14px; background: #f9fafb; color: #263446; cursor: pointer; font: inherit; font-size: .78rem; font-weight: 800; text-align: left; transition: border-color .15s ease, background .15s ease, transform .15s ease; }
.border-vote-button:hover { transform: translateY(-2px); border-color: #aebdca; }
.border-vote-button.is-selected { border-color: #0b1728; background: #0b1728; color: #fff; box-shadow: 0 10px 24px rgba(11,23,40,.16); }
.border-vote-button i { width: 9px; height: 9px; flex-basis: 9px; }
.border-vote-breakdown { display: flex; flex-wrap: wrap; gap: 10px 14px; margin-top: 20px; padding-top: 18px; border-top: 1px solid #edf0f3; }
.border-vote-breakdown span { display: inline-flex; align-items: center; gap: 7px; color: #667486; font-size: .74rem; }
.border-vote-breakdown b { color: #172538; }
.border-dot { display: inline-block; width: 8px; height: 8px; flex-basis: 8px; box-shadow: none; }

.border-photo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.border-photo-card { overflow: hidden; margin: 0; border: 1px solid #e0e6eb; border-radius: 16px; background: #f8fafb; }
.border-photo-card > a { display: block; aspect-ratio: 16 / 10; background: #dde3e9; }
.border-photo-card img { width: 100%; height: 100%; display: block; object-fit: cover; }
.border-photo-card figcaption { padding: 13px 14px 14px; }
.border-photo-card p { margin: 0 0 8px; color: #283747; font-size: .86rem; line-height: 1.45; }
.border-photo-card span { color: #7a8796; font-size: .72rem; }
.border-photo-card span b { color: #536172; }

.border-photo-form { margin-top: 18px; padding: 18px; border-radius: 16px; background: #f4f7f9; }
.border-photo-form__fields { display: grid; grid-template-columns: minmax(230px, .75fr) minmax(0, 1.25fr); gap: 12px; margin-bottom: 12px; }
.border-photo-form label { display: grid; gap: 6px; color: #536172; font-size: .74rem; font-weight: 800; }
.border-photo-form input[type="file"],
.border-photo-form input[type="text"],
.border-comment-form textarea { width: 100%; border: 1px solid #d7dfe6; border-radius: 12px; background: #fff; color: #172538; font: inherit; outline: none; }
.border-photo-form input[type="file"] { min-height: 46px; padding: 9px; }
.border-photo-form input[type="text"] { min-height: 46px; padding: 0 13px; }
.border-photo-form input:focus,
.border-comment-form textarea:focus { border-color: #5e809f; box-shadow: 0 0 0 3px rgba(64,108,148,.1); }

.border-comment-form { margin-bottom: 22px; padding: 17px; border-radius: 16px; background: #f4f7f9; }
.border-comment-form textarea { min-height: 105px; resize: vertical; padding: 13px 14px; line-height: 1.5; }
.border-comment-form__actions { display: flex; align-items: center; gap: 13px; margin-top: 11px; }
.border-comment-list { display: grid; gap: 0; }
.border-comment { display: grid; grid-template-columns: 38px minmax(0,1fr); gap: 12px; padding: 18px 0; border-top: 1px solid #edf0f3; }
.border-comment:first-child { border-top: 0; padding-top: 0; }
.border-comment__avatar { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: #e9eef3; color: #34485d; font-size: .72rem; font-weight: 900; }
.border-comment header { display: flex; align-items: center; gap: 9px; }
.border-comment header b { color: #1d2c3d; font-size: .86rem; }
.border-comment header span { color: #8793a0; font-size: .7rem; }
.border-comment p { margin: 6px 0 0; color: #475668; font-size: .9rem; line-height: 1.55; }

.border-fallback-note { margin: 0 0 16px; padding: 10px 12px; border-radius: 10px; background: #fff7df; color: #765b1e; font-size: .75rem; line-height: 1.45; }
.border-empty { padding: 26px; border: 1px dashed #ccd6df; border-radius: 14px; color: #718091; text-align: center; }
.border-form-message { min-height: 20px; margin-top: 10px; color: #556779; font-size: .77rem; font-weight: 700; }
.border-form-message.is-error { color: #a52f39; }
.border-form-message.is-success { color: #147452; }

.border-source-list { display: grid; gap: 1px; overflow: hidden; border: 1px solid #e0e6eb; border-radius: 14px; background: #e0e6eb; }
.border-source-item { padding: 15px; background: #fff; }
.border-source-item > div { display: grid; grid-template-columns: 10px 1fr; gap: 5px 10px; align-items: center; }
.border-source-item > div b { font-size: .82rem; }
.border-source-item > div small { grid-column: 2; color: #7b8794; font-size: .7rem; }
.border-source-item p { margin: 10px 0 7px; color: #536172; font-size: .78rem; }
.border-source-item > a { color: #244c72; font-size: .72rem; font-weight: 800; text-decoration: none; }
.border-source-item > a:hover { text-decoration: underline; }
.border-method-card--side { margin: 0; padding: 21px; }
.border-method-card--side h2 { font-size: 1.15rem; }
.border-method-card--side p { font-size: .82rem; }

@media (max-width: 980px) {
    .border-home__grid,
    .border-index__grid { grid-template-columns: 1fr; }
    .border-card { min-height: 190px; }
    .border-page-hero__inner { align-items: start; flex-direction: column; }
    .border-legend { width: 100%; flex-direction: row; flex-wrap: wrap; }
    .border-detail-hero__inner,
    .border-detail-layout { grid-template-columns: 1fr; }
    .border-detail-side { position: static; grid-row: auto; }
    .border-vote-grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
}

@media (max-width: 680px) {
    .border-home.shell { margin-left: 12px; margin-right: 12px; border-radius: 22px; }
    .border-home__head { align-items: flex-start; flex-direction: column; padding: 25px 22px 20px; }
    .border-card { padding: 22px; min-height: 195px; }
    .border-card__more { left: 22px; }
    .border-page-hero__inner { padding-top: 42px; padding-bottom: 38px; }
    .border-page-hero h1 { font-size: 2.7rem; }
    .border-detail-hero__inner { gap: 28px; padding-top: 34px; padding-bottom: 34px; }
    .border-detail-back { margin-bottom: 22px; }
    .border-detail-hero h1 { font-size: 2.65rem; }
    .border-now-card { padding: 19px; }
    .border-detail-layout { padding-top: 18px; }
    .border-panel { padding: 19px; border-radius: 18px; }
    .border-vote-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .border-vote-button:last-child { grid-column: 1 / -1; }
    .border-photo-grid { grid-template-columns: 1fr; }
    .border-photo-form__fields { grid-template-columns: 1fr; }
    .border-comment-form__actions { align-items: stretch; flex-direction: column; }
}

/* Community-only border status */
.border-community-source {
    padding: 23px;
    background: linear-gradient(150deg,#0e2235,#173c58);
    color: #fff;
}

.border-community-source .eyebrow {
    color: #8fc3df;
}

.border-community-source h2 {
    margin: 5px 0 18px;
    color: #fff;
    font-size: 1.35rem;
    line-height: 1.12;
    letter-spacing: -.035em;
}

.border-community-source__items {
    display: grid;
    gap: 1px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.11);
    border-radius: 14px;
    background: rgba(255,255,255,.11);
}

.border-community-source__items > div {
    display: grid;
    grid-template-columns: 68px minmax(0,1fr);
    gap: 13px;
    align-items: center;
    padding: 15px;
    background: rgba(255,255,255,.055);
}

.border-community-source__items strong {
    color: #fff;
    font-size: 1.12rem;
    letter-spacing: -.03em;
}

.border-community-source__items span {
    color: rgba(255,255,255,.68);
    font-size: .76rem;
    line-height: 1.42;
}
