/*
 * Joy News Suite — Short URL Share Bar
 */

/* ── Sticky Share Bar (bottom of page, above footer) ──────────────────── */
.jns-share-bar {
    background: var(--jns-bg-card, #fff);
    border-top: 2px solid var(--jns-accent, #FD0000);
    box-shadow: 0 -4px 20px rgba(0,0,0,.10);
    padding: 12px 0;
    margin-top: 40px;
    position: relative;
    z-index: 10;
    clear: both;
}

.jns-share-inner {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.jns-share-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--jns-text, #1a1a2e);
    white-space: nowrap;
    margin-right: 2px;
}

/* Share icon buttons */
.jns-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    text-decoration: none;
    transition: transform .18s, opacity .18s;
    flex-shrink: 0;
}
.jns-share-btn:hover { transform: scale(1.12); opacity: .88; }
.jns-share-btn svg { width: 18px; height: 18px; }

.jns-share-fb { background: #1877F2; color: #fff; }
.jns-share-wa { background: #25D366; color: #fff; }
.jns-share-tg { background: #229ED9; color: #fff; }
.jns-share-tw { background: #000;    color: #fff; }
.jns-share-li { background: #0A66C2; color: #fff; }

/* Copy URL row */
.jns-share-copy-wrap {
    display: flex;
    align-items: center;
    gap: 0;
    margin-left: auto;
    border: 1.5px solid #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
}

.jns-share-url-input {
    border: none !important;
    outline: none !important;
    padding: 7px 12px;
    font-size: 12px;
    font-family: 'Courier New', monospace;
    color: #2563eb;
    font-weight: 600;
    background: #f8faff;
    width: 200px;
    cursor: text;
}

.jns-share-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 14px;
    background: var(--jns-accent, #FD0000);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    transition: background .15s;
    white-space: nowrap;
}
.jns-share-copy-btn:hover { background: #c00; }
.jns-share-copy-btn svg  { width: 14px; height: 14px; }

/* Mobile responsive */
@media (max-width: 600px) {
    .jns-share-inner     { gap: 8px; justify-content: center; }
    .jns-share-label     { width: 100%; text-align: center; }
    .jns-share-copy-wrap { width: 100%; }
    .jns-share-url-input { flex: 1; width: auto; }
    .jns-share-btn       { width: 40px; height: 40px; }
}

/* ── Admin: Short URL stats table ─────────────────────────────────────── */
.jns-shorturl-stats { width: 100%; border-collapse: collapse; margin-top: 10px; }
.jns-shorturl-stats th {
    background: #f5f5f5;
    padding: 8px 12px;
    text-align: left;
    font-size: 12px;
    font-weight: 700;
    border-bottom: 2px solid #e0e0e0;
}
.jns-shorturl-stats td {
    padding: 8px 12px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 12px;
    vertical-align: middle;
}
.jns-shorturl-stats tr:hover td { background: #fafafa; }
.jns-su-code-pill {
    background: #f0f4ff;
    color: #2563eb;
    font-family: monospace;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    user-select: all;
    display: inline-block;
}
.jns-su-code-pill:hover { background: #dbeafe; }
.jns-su-hits-bar {
    display: inline-block;
    height: 6px;
    background: var(--jns-accent, #FD0000);
    border-radius: 3px;
    vertical-align: middle;
    margin-left: 6px;
    opacity: .7;
    min-width: 2px;
}

/* ── Settings tab: Short URL settings row ─────────────────────────────── */
.jns-short-url-setting {
    background: #f8faff;
    border: 1px solid #dbeafe;
    border-radius: 7px;
    padding: 16px 18px;
    margin-bottom: 16px;
}
.jns-short-url-setting label { font-weight: 600; font-size: 13px; color: #1a1a2e; }
.jns-short-url-setting p.desc { font-size: 12px; color: #888; margin: 4px 0 0; }
