/* Cervicide Content Credits — Admin Styles */

#ccred-types-table input[type="text"],
#ccred-types-table input[type="number"] {
    margin: 0;
}

#ccred-types-table td {
    vertical-align: middle;
    padding: 8px 10px;
}

.ccred-review-panel {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 24px;
}

/* ── User search autocomplete ─────────────────────────────────────────────── */

.ccred-user-search-wrap {
    position: relative;
    display:  inline-block;
    width:    320px;
}

#ccred-user-search {
    width: 100%;
    box-sizing: border-box;
}

#ccred-user-search.ccred-field-error {
    border-color: #dc3232;
    box-shadow: 0 0 0 1px #dc3232;
}

.ccred-user-dropdown {
    display:       none;
    position:      absolute;
    top:           100%;
    left:          0;
    right:         0;
    z-index:       9999;
    background:    #fff;
    border:        1px solid #c3c4c7;
    border-top:    none;
    border-radius: 0 0 4px 4px;
    margin:        0;
    padding:       0;
    list-style:    none;
    box-shadow:    0 4px 10px rgba(0,0,0,.12);
    max-height:    220px;
    overflow-y:    auto;
}

.ccred-user-dropdown.is-open {
    display: block;
}

.ccred-dd-item {
    padding:    9px 12px;
    cursor:     pointer;
    font-size:  13px;
    color:      #1d2327;
    border-bottom: 1px solid #f0f0f1;
    transition: background .1s;
}
.ccred-dd-item:last-child { border-bottom: none; }
.ccred-dd-item:hover      { background: #f0f6fc; color: #2271b1; }

.ccred-dd-empty {
    padding:   9px 12px;
    font-size: 13px;
    color:     #646970;
    font-style: italic;
}

.ccred-user-selected {
    margin-top: 6px;
    font-size:  13px;
    color:      #646970;
    min-height: 18px;
}

.ccred-user-selected.is-set {
    color:       #46b450;
    font-weight: 600;
}

/* ── Rubric sliders ──────────────────────────────────────────────────────────── */

#ccred-rubric-form input[type="range"] {
    vertical-align: middle;
    accent-color:   #2271b1;
}

#ccred-rubric-form .ccred-cat-val {
    display:     inline-block;
    width:       24px;
    font-weight: 600;
    font-size:   13px;
    text-align:  right;
}

#ccred-score-summary {
    font-size: 13px;
}

/* ── Tier badge colors (admin submissions table) ─────────────────────────────── */

.ccred-admin-tier {
    display:        inline-block;
    font-size:      11px;
    font-weight:    700;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding:        2px 7px;
    border-radius:  3px;
    white-space:    nowrap;
}

.ccred-admin-tier-elite      { background: #fff3cd; color: #7a5c00; border: 1px solid #e0c050; }
.ccred-admin-tier-strong     { background: #d4edda; color: #1a6b31; border: 1px solid #5daa73; }
.ccred-admin-tier-solid      { background: #fff0e6; color: #8a3800; border: 1px solid #f0884a; }
.ccred-admin-tier-acceptable { background: #f0f0f1; color: #50575e; border: 1px solid #c3c4c7; }
.ccred-admin-tier-raw        { background: #e6f0fb; color: #1a4d8a; border: 1px solid #72a8e5; }

.ccred-admin-track {
    display:        inline-block;
    font-size:      10px;
    font-weight:    600;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding:        2px 6px;
    border-radius:  3px;
    background:     #f0f0f1;
    color:          #50575e;
    border:         1px solid #c3c4c7;
    margin-left:    4px;
}

/* ── Participants table: notes inline edit ───────────────────────────────────── */

.ccred-notes-wrap {
    display:        flex;
    flex-direction: column;
    gap:            4px;
    min-width:      150px;
}

.ccred-notes-input {
    flex:          1;
    min-width:     80px;
    font-size:     12px;
    padding:       4px 6px;
    border:        1px solid #c3c4c7;
    border-radius: 3px;
    background:    #fafafa;
    color:         #1d2327;
    transition:    border-color .15s;
}
.ccred-notes-input:focus { border-color: #2271b1; outline: none; background: #fff; }

/* Applications note field: single-line, truncates instead of widening the column. */
.ccred-app-note-input {
    flex:          1;
    min-width:     80px;
    max-width:     220px;
    font-size:     12px;
    padding:       4px 6px;
    border:        1px solid #c3c4c7;
    border-radius: 3px;
    background:    #fafafa;
    color:         #1d2327;
    text-overflow: ellipsis;
    transition:    border-color .15s;
}
.ccred-app-note-input:focus { border-color: #2271b1; outline: none; background: #fff; }

.ccred-notes-save-btn.button.button-small {
    flex-shrink: 0;
    padding:     2px 8px;
    min-height:  0;
    font-size:   11px;
    line-height: 1.6;
}

.ccred-notes-flash {
    font-size:   11px;
    opacity:     0;
    transition:  opacity .4s;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ── Compact rubric form ─────────────────────────────────────────────────────── */

.ccred-rubric-cats {
    display:        flex;
    flex-direction: column;
    margin-bottom:  10px;
    border:         1px solid #e0e0e0;
    border-radius:  3px;
    overflow:       hidden;
}

.ccred-rubric-cat-row {
    display:     grid;
    grid-template-columns: 1fr 150px 28px 28px;
    align-items: center;
    gap:         6px;
    padding:     5px 10px;
    border-bottom: 1px solid #f0f0f0;
    background:  #fff;
}
.ccred-rubric-cat-row:last-child { border-bottom: none; }
.ccred-rubric-cat-row:nth-child(odd) { background: #fafafa; }

.ccred-rubric-cat-label {
    font-size: 12px;
    color:     #1d2327;
    line-height: 1.3;
}

.ccred-rubric-cat-row input[type="range"] {
    width:       100%;
    accent-color:#2271b1;
    margin:      0;
}

.ccred-rubric-cat-row .ccred-cat-val {
    font-size:   12px;
    font-weight: 700;
    text-align:  center;
    color:       #2271b1;
    width:       auto;
}

.ccred-rubric-cat-max {
    font-size:  11px;
    color:      #999;
    text-align: right;
}

.ccred-rubric-bonuses {
    background:    #f8f8f8;
    border:        1px solid #e0e0e0;
    border-radius: 3px;
    padding:       8px 10px;
    margin:        8px 0;
}

.ccred-rubric-bonus-header {
    font-size:      10px;
    font-weight:    700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color:          #646970;
    margin-bottom:  6px;
}

.ccred-rubric-bonus-row {
    display:         flex;
    align-items:     center;
    justify-content: space-between;
    gap:             8px;
    padding:         3px 0;
    font-size:       12px;
    color:           #1d2327;
    border-bottom:   1px solid #eee;
}
.ccred-rubric-bonus-row:last-child { border-bottom: none; }

.ccred-rubric-bonus-row select {
    font-size: 12px;
    padding:   2px 4px;
    width:     80px;
}

.ccred-rubric-notes-row {
    display:               grid;
    grid-template-columns: 1fr 1fr;
    gap:                   8px;
    margin-top:            8px;
}
.ccred-rubric-notes-row label        { margin: 0; }
.ccred-rubric-notes-row .large-text  { width: 100%; box-sizing: border-box; font-size: 12px; }

.ccred-rubric-notes-label {
    display:        block;
    font-size:      10px;
    font-weight:    700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color:          #646970;
    margin-bottom:  3px;
}

@media (max-width: 782px) {
    .ccred-rubric-notes-row        { grid-template-columns: 1fr; }
    .ccred-rubric-cat-row          { grid-template-columns: 1fr 110px 24px 24px; }
}

/* ── Contributor Hunts table pills ─────────────────────────────────────────── */
.ccred-admin-hunt-pill {
    display:        inline-block;
    font-size:      10px;
    font-weight:    700;
    letter-spacing: .04em;
    text-transform: uppercase;
    padding:        2px 7px;
    border-radius:  3px;
    margin-left:    4px;
    vertical-align: middle;
}
.ccred-admin-hunt-pill-whitetail { background:rgba(80,190,180,.16);  color:#2a8e7e; border:1px solid rgba(80,190,180,.4); }
.ccred-admin-hunt-pill-elk       { background:rgba(220,170,60,.16);  color:#8a6a1a; border:1px solid rgba(220,170,60,.4); }
.ccred-admin-hunt-pill-mule_deer { background:rgba(170,120,200,.16); color:#6a4a8a; border:1px solid rgba(170,120,200,.4); }
.ccred-admin-hunt-pill-ducks     { background:rgba(80,140,210,.16);  color:#2a5a8a; border:1px solid rgba(80,140,210,.4); }
.ccred-admin-hunt-pill-other     { background:#f0f0f0;               color:#666;    border:1px solid #ccc; }

.ccred-admin-clearance-pill {
    display:        inline-block;
    font-size:      10px;
    font-weight:    700;
    letter-spacing: .04em;
    text-transform: uppercase;
    padding:        2px 6px;
    border-radius:  2px;
    margin-right:   2px;
    background:     #f0f6fc;
    border:         1px solid #c8d8ea;
    color:          #2271b1;
}

/* ── Media "medal" file buttons (shared: admin panel + front-end reviewer) ───── */
.ccred-file-btn {
    display:         inline-flex;
    align-items:     center;
    gap:             7px;
    text-decoration: none;
    font-size:       13px;
    font-weight:     600;
    line-height:     1;
    padding:         9px 14px 9px 10px;
    border-radius:   999px;
    color:           #1d2327;
    background:      linear-gradient(180deg,#ffffff 0%,#f2f4f7 100%);
    border:          1px solid #c3c4c7;
    box-shadow:      0 1px 2px rgba(0,0,0,.08);
    transition:      transform .08s ease, box-shadow .12s ease, border-color .12s ease;
}
.ccred-file-btn:hover,
.ccred-file-btn:focus {
    border-color: #2271b1;
    box-shadow:   0 3px 8px rgba(34,113,177,.22);
    transform:    translateY(-1px);
    color:        #135e96;
}
.ccred-file-btn .ccred-file-ic {
    display:         inline-flex;
    align-items:     center;
    justify-content: center;
    width:           22px;
    height:          22px;
    border-radius:   50%;
    background:      #2271b1;
    color:           #fff;
    font-size:       12px;
    flex-shrink:     0;
}

/* ── Front-end reviewer page ([ccred_reviewer]) ──────────────────────────────── */
.ccred-reviewer {
    max-width:   1040px;
    margin:      0 auto;
    color:       #1d2327;
}
.ccred-rv-head {
    display:       flex;
    align-items:   baseline;
    gap:           12px;
    flex-wrap:     wrap;
    border-bottom: 2px solid #ececef;
    padding-bottom: 10px;
    margin-bottom: 18px;
}
.ccred-rv-head h1 { margin: 0; font-size: 30px; line-height: 1.1; }
.ccred-rv-sub { color: #646970; font-size: 13px; }

.ccred-rv-notice {
    margin:        0 0 18px;
    padding:       11px 16px;
    border-radius: 5px;
    font-size:     14px;
}
.ccred-rv-notice.is-success { background:#e7f6ec; border-left:4px solid #1a7f4b; color:#0f5c34; }
.ccred-rv-notice.is-error   { background:#fbeaea; border-left:4px solid #b32d2e; color:#8a2322; }

.ccred-rv-toolbar {
    display:       flex;
    align-items:   center;
    gap:           10px;
    margin:        0 0 20px;
    padding:       10px 14px;
    background:    #f6f7f8;
    border:        1px solid #e6e7ea;
    border-radius: 6px;
}
.ccred-rv-toolbar label { font-size:12px; font-weight:700; text-transform:uppercase; letter-spacing:.05em; color:#646970; margin:0; }
.ccred-rv-toolbar select { font-size:14px; padding:6px 10px; border-radius:5px; border:1px solid #c3c4c7; background:#fff; }

.ccred-rv-section { margin-bottom: 30px; }
.ccred-rv-section-head {
    display:       flex;
    align-items:   center;
    gap:           10px;
    margin:        0 0 10px;
}
.ccred-rv-section-head h2 { margin:0; font-size:17px; }
.ccred-rv-count {
    font-size:     12px;
    font-weight:   700;
    color:         #50575e;
    background:    #eef0f2;
    border-radius: 999px;
    padding:       2px 10px;
}
.ccred-rv-section.is-contrib .ccred-rv-count { background:#fff0e6; color:#8a3800; }
.ccred-rv-section.is-social .ccred-rv-count { background:#efe8fb; color:#5a3aa0; }

.ccred-rv-card {
    border:        1px solid #e6e7ea;
    border-radius: 8px;
    overflow:      hidden;
    background:    #fff;
    box-shadow:    0 1px 3px rgba(0,0,0,.05);
}
.ccred-rv-table { width:100%; border-collapse:collapse; font-size:14px; }
.ccred-rv-table thead th {
    text-align:    left;
    font-size:     11px;
    font-weight:   700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color:         #646970;
    background:    #fafbfc;
    padding:       10px 14px;
    border-bottom: 1px solid #e6e7ea;
}
.ccred-rv-table tbody td { padding: 11px 14px; border-bottom: 1px solid #f0f1f3; vertical-align: middle; }
.ccred-rv-table tbody tr:last-child td { border-bottom: none; }
.ccred-rv-table tbody tr:hover { background: #f7fafd; }
.ccred-rv-title { font-weight: 600; color: #1d2327; }
.ccred-rv-user  { color: #50575e; }
.ccred-rv-date  { color: #787c82; white-space: nowrap; }
.ccred-rv-action {
    display:         inline-flex;
    align-items:     center;
    gap:             5px;
    text-decoration: none;
    font-size:       13px;
    font-weight:     600;
    color:           #2271b1;
    padding:         6px 12px;
    border:          1px solid #2271b1;
    border-radius:   5px;
    transition:      background .12s, color .12s;
    white-space:     nowrap;
}
.ccred-rv-action:hover { background:#2271b1; color:#fff; }
.ccred-rv-action.is-view { color:#646970; border-color:#c3c4c7; }
.ccred-rv-action.is-view:hover { background:#646970; color:#fff; }

.ccred-rv-empty {
    padding:       30px 16px;
    text-align:    center;
    color:         #787c82;
    font-size:     14px;
}

.ccred-rv-pager {
    display:       flex;
    align-items:   center;
    justify-content: flex-end;
    gap:           12px;
    padding:       10px 14px;
    background:    #fafbfc;
    border-top:    1px solid #e6e7ea;
    font-size:     13px;
    color:         #646970;
}
.ccred-rv-pager a {
    text-decoration: none;
    color:           #2271b1;
    font-weight:     600;
    padding:         4px 10px;
    border:          1px solid #c3c4c7;
    border-radius:   5px;
}
.ccred-rv-pager a:hover { border-color:#2271b1; background:#f0f6fc; }
.ccred-rv-pager .is-disabled { color:#c3c4c7; border-color:#e6e7ea; pointer-events:none; }

/* Front-end fallback so the shared review-panel buttons look right off wp-admin */
.ccred-reviewer .button {
    display:         inline-block;
    font-size:       14px;
    line-height:     1.4;
    padding:         8px 16px;
    border-radius:   5px;
    border:          1px solid #c3c4c7;
    background:      #f6f7f7;
    color:           #1d2327;
    cursor:          pointer;
    text-decoration: none;
}
.ccred-reviewer .button:hover { background:#f0f0f1; border-color:#2271b1; }
.ccred-reviewer .button-primary { background:#2271b1; border-color:#2271b1; color:#fff; }
.ccred-reviewer .button-primary:hover { background:#135e96; }
.ccred-reviewer .button-primary:disabled { background:#a7c7e0; border-color:#a7c7e0; cursor:not-allowed; }

.ccred-rv-legacy summary {
    cursor:      pointer;
    font-weight: 600;
    font-size:   15px;
    padding:     10px 0;
    color:       #50575e;
}
