/**
 * tasco-modules.css
 * Shared stylesheet for all TASCO Joomla 4 modules.
 * Location: /home4/tasco/public_html/media/tasco/css/tasco-modules.css
 * Web URL:  https://tasco-soccer.com/media/tasco/css/tasco-modules.css
 *
 * Sections:
 *   1. Listing modules  (job boards, open dates, open tournaments, coaching records)
 *   2. Form modules     (add/edit/delete forms)
 *   3. Profile modules  (coaching profile cards)
 *   4. Utilities
 */

/* ─────────────────────────────────────────────────────────────────────────
   1. LISTING MODULES
   ───────────────────────────────────────────────────────────────────────── */

.jb-shell {
    max-width: 960px;
    margin: 0 auto;
    padding: 1.5rem 0;
    font-family: Arial, Helvetica, sans-serif;
    color: #1f2937;
    font-size: 14px;
}
.jb-top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.jb-top-bar h2 {
    font-size: 18px;
    font-weight: 500;
    margin: 0;
}
.jb-section-label {
    font-size: 11px;
    font-weight: 500;
    color: #6b7280;
    letter-spacing: .06em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

/* Card container */
.jb-card {
    background: #fff;
    border: 0.5px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

/* Filter bar */
.jb-filter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    align-items: center;
}
.jb-filter-bar input,
.jb-filter-bar select {
    font-size: 13px;
    padding: 6px 10px;
    border: 0.5px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #1f2937;
    flex: 1;
    min-width: 100px;
}
.jb-filter-bar input[type=text] {
    min-width: 140px;
    flex: 2;
}
.jb-filter-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

/* Tables */
table.jb-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
table.jb-table thead tr {
    border-bottom: 0.5px solid #e5e7eb;
}
table.jb-table th {
    padding: 10px 12px;
    font-size: 11px;
    font-weight: 500;
    color: #6b7280;
    letter-spacing: .04em;
    text-align: left;
    white-space: nowrap;
}
table.jb-table th a {
    color: #6b7280;
    text-decoration: none;
}
table.jb-table th a:hover {
    color: #1f2937;
}
table.jb-table td {
    padding: 10px 12px;
    border-bottom: 0.5px solid #e5e7eb;
    vertical-align: middle;
}
table.jb-table tr:last-child td {
    border-bottom: none;
}

/* Alternating rows — uses nth-child(4n) to skip detail rows */
table.jb-table tbody tr.jb-main-row:nth-child(4n+1) {
    background: #fff;
}
table.jb-table tbody tr.jb-main-row:nth-child(4n+3) {
    background: #f9fafb;
}
table.jb-table tbody tr.jb-main-row {
    cursor: pointer;
    transition: background .12s;
}
table.jb-table tbody tr.jb-main-row:hover {
    background: #eff6ff;
}

/* Accordion detail rows */
.jb-detail-row {
    display: none;
}
.jb-detail-row.open {
    display: table-row;
}
.jb-detail-row td {
    background: #f9fafb;
    border-bottom: 0.5px solid #e5e7eb;
}
.jb-detail-inner {
    padding: 14px 16px 16px 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
@media (max-width: 640px) {
    .jb-detail-inner {
        grid-template-columns: 1fr;
    }
}

/* Arrow toggle */
.jb-arrow {
    display: inline-block;
    font-size: 10px;
    color: #9ca3af;
    width: 16px;
    transition: transform .15s;
    user-select: none;
}
.jb-arrow.open {
    transform: rotate(90deg);
}

/* Definition list inside detail rows */
.jb-dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 12px;
    font-size: 12px;
}
.jb-dl dt {
    color: #6b7280;
    white-space: nowrap;
}
.jb-dl dd {
    color: #1f2937;
}

/* Badges */
.jb-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 500;
    padding: 3px 8px;
    border-radius: 20px;
}
.jb-badge.open {
    background: #dcfce7;
    color: #15803d;
}
.jb-badge.expired {
    background: #fee2e2;
    color: #b91c1c;
}
.jb-badge.days {
    background: #f3f4f6;
    color: #6b7280;
    font-weight: 400;
}
.jb-badge.active {
    background: #dcfce7;
    color: #15803d;
}
.jb-badge.inactive {
    background: #fee2e2;
    color: #b91c1c;
}

/* Action groups */
.jb-action-group {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}


/* ─────────────────────────────────────────────────────────────────────────
   2. BUTTONS (shared across listing + form modules)
   ───────────────────────────────────────────────────────────────────────── */

/* Primary — post/save (green) */
.jb-post-btn {
    display: inline-block;
    border: none;
    border-radius: 8px;
    background: #1a2e4a;
    color: #fff;
    font-weight: 500;
    font-size: 13px;
    padding: 8px 16px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: background .12s;
}
.jb-post-btn:hover { background: #243d60; color: #fff; }

/* Save (green) */
.jb-btn-save {
    display: block;
    width: 100%;
    border: none;
    border-radius: 8px;
    background: #15803d;
    color: #fff;
    font-weight: 500;
    font-size: 14px;
    padding: 11px 20px;
    cursor: pointer;
    text-align: center;
    transition: background .12s;
    margin-bottom: 10px;
}
.jb-btn-save:hover { background: #166534; }

/* Neutral (edit/back) */
.jb-btn-edit {
    background: none;
    border: 0.5px solid #d1d5db;
    border-radius: 6px;
    padding: 8px 10px;
    font-size: 12px;
    color: #374151;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: background .12s;
}
.jb-btn-edit:hover { background: #f3f4f6; color: #374151; }

/* Back button (full width) */
.jb-btn-back {
    display: block;
    width: 100%;
    border: 0.5px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #374151;
    font-weight: 500;
    font-size: 14px;
    padding: 11px 20px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background .12s;
    margin-bottom: 10px;
    box-sizing: border-box;
}
.jb-btn-back:hover { background: #f3f4f6; color: #374151; }

/* Danger (remove) */
.jb-btn-remove {
    background: none;
    border: 0.5px solid #f87171;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    color: #b91c1c;
    cursor: pointer;
    transition: background .12s;
}
.jb-btn-remove:hover { background: #fef2f2; }

/* Renew (blue) */
.jb-btn-renew {
    background: none;
    border: 0.5px solid #93c5fd;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    color: #1d4ed8;
    cursor: pointer;
    text-decoration: none;
    transition: background .12s;
}
.jb-btn-renew:hover { background: #eff6ff; }

/* Apply/search */
.jb-btn-apply {
    background: #c4151d;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 13px;
    cursor: pointer;
    transition: background .12s;
}
.jb-btn-apply:hover { background: #a31219; }

/* Reset */
.jb-btn-reset {
    background: none;
    border: 0.5px solid #d1d5db;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 13px;
    color: #6b7280;
    cursor: pointer;
    text-decoration: none;
    transition: background .12s;
}
.jb-btn-reset:hover { background: #f3f4f6; }


/* ─────────────────────────────────────────────────────────────────────────
   3. FORM MODULES
   ───────────────────────────────────────────────────────────────────────── */

.jb-form-shell {
    max-width: 640px;
    margin: 0 auto;
    padding: 1.5rem 0;
    font-family: Arial, Helvetica, sans-serif;
    color: #1f2937;
    font-size: 14px;
}
.jb-form-card {
    background: #f9fafb;
    border: 0.5px solid #e5e7eb;
    border-radius: 12px;
    padding: 24px 26px;
    margin-bottom: 1.25rem;
}
.jb-form-card h3 {
    margin: 0 0 16px;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: .05em;
    border-bottom: 0.5px solid #e5e7eb;
    padding-bottom: 10px;
}
.jb-field {
    margin-bottom: 14px;
}
.jb-field label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.jb-field input[type=text],
.jb-field input[type=date],
.jb-field input[type=email],
.jb-field input[type=url],
.jb-field input[type=number],
.jb-field select,
.jb-field textarea {
    width: 100%;
    box-sizing: border-box;
    border: 0.5px solid #d1d5db;
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 13px;
    background: #fff;
    color: #1f2937;
    transition: border-color .12s;
}
.jb-field input:focus,
.jb-field select:focus,
.jb-field textarea:focus {
    outline: none;
    border-color: #1d4ed8;
    box-shadow: 0 0 0 3px rgba(29,78,216,.08);
}
.jb-field textarea {
    min-height: 80px;
    resize: vertical;
}
.jb-field.checkbox-field {
    display: flex;
    align-items: center;
    gap: 10px;
}
.jb-field.checkbox-field input {
    width: auto;
}
.jb-field.checkbox-field label {
    margin: 0;
    text-transform: none;
    letter-spacing: 0;
    font-size: 13px;
}
.jb-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 10px;
}
@media (max-width: 560px) {
    .jb-grid-2 { grid-template-columns: 1fr; }
}

/* Notices */
.jb-notice {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 13px;
    line-height: 1.5;
}
.jb-notice.success {
    background: #f0fdf4;
    color: #15803d;
    border: 0.5px solid #bbf7d0;
}
.jb-notice.danger {
    background: #fef2f2;
    color: #b91c1c;
    border: 0.5px solid #fecaca;
}
.jb-notice.warning {
    background: #fffbeb;
    color: #92400e;
    border: 0.5px solid #fcd34d;
}


/* ─────────────────────────────────────────────────────────────────────────
   4. PROFILE MODULES  (coaching profile cards — cp-shell scoped)
   ───────────────────────────────────────────────────────────────────────── */

#cp-shell, #cps-shell, #cpa-shell {
    max-width: 600px;
    margin: 0 auto;
    padding: 18px 12px 32px;
    font-family: Arial, Helvetica, sans-serif;
    color: #1f2937;
}
#cp-shell .cp-header,
#cps-shell .cp-header,
#cpa-shell .cp-header {
    background: #fff;
    border: 0.5px solid #e5e7eb;
    border-radius: 12px;
    padding: 22px 24px;
    margin-bottom: 22px;
}
#cp-shell .cp-header h1,
#cps-shell .cp-header h1,
#cpa-shell .cp-header h1 {
    margin: 0;
    font-size: 22px;
    font-weight: 500;
    color: #1f2937;
}
#cp-shell .cp-card,
#cps-shell .cp-card,
#cpa-shell .cp-card {
    background: #f9fafb;
    border: 0.5px solid #e5e7eb;
    border-radius: 12px;
    padding: 24px 26px;
    margin-bottom: 20px;
}
#cp-shell .cp-card h3,
#cps-shell .cp-card h3,
#cpa-shell .cp-card h3 {
    margin: 0 0 16px;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: .05em;
    border-bottom: 0.5px solid #e5e7eb;
    padding-bottom: 10px;
}
#cp-shell .cp-field,
#cps-shell .cp-field,
#cpa-shell .cp-field { margin-bottom: 14px; }

#cp-shell .cp-field label,
#cps-shell .cp-field label,
#cpa-shell .cp-field label {
    display: block;
    font-weight: 500;
    font-size: 12px;
    color: #374151;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: .04em;
}
#cp-shell .cp-field input,
#cps-shell .cp-field input,
#cpa-shell .cp-field input,
#cp-shell .cp-field select,
#cps-shell .cp-field select,
#cpa-shell .cp-field select {
    width: 100%;
    box-sizing: border-box;
    border: 0.5px solid #d1d5db;
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 13px;
    background: #fff;
    color: #1f2937;
}
#cp-shell .cp-field input:focus,
#cps-shell .cp-field input:focus,
#cpa-shell .cp-field input:focus {
    outline: none;
    border-color: #1d4ed8;
    box-shadow: 0 0 0 3px rgba(29,78,216,.08);
}
#cp-shell .cp-field input:disabled,
#cps-shell .cp-field input:disabled,
#cpa-shell .cp-field input:disabled {
    background: #f3f4f6;
    color: #9ca3af;
}
#cp-shell .cp-info-row,
#cps-shell .cp-info-row,
#cpa-shell .cp-info-row {
    display: flex;
    padding: 9px 0;
    border-bottom: 0.5px solid #f0f0f0;
    font-size: 14px;
}
#cp-shell .cp-info-row:last-child,
#cps-shell .cp-info-row:last-child,
#cpa-shell .cp-info-row:last-child { border-bottom: none; }

#cp-shell .cp-info-row strong,
#cps-shell .cp-info-row strong,
#cpa-shell .cp-info-row strong { min-width: 140px; color: #374151; }

#cp-shell .cp-btn,
#cps-shell .cp-btn,
#cpa-shell .cp-btn {
    display: block;
    width: 100%;
    border: none;
    border-radius: 8px;
    background: #0b122b;
    color: #fff;
    font-weight: 500;
    font-size: 14px;
    padding: 12px 20px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    margin-bottom: 10px;
    transition: background .12s;
    box-sizing: border-box;
}
#cp-shell .cp-btn:hover,
#cps-shell .cp-btn:hover,
#cpa-shell .cp-btn:hover { background: #162044; color: #fff; }

#cp-shell .cp-btn.green,
#cps-shell .cp-btn.green,
#cpa-shell .cp-btn.green { background: #15803d; }
#cp-shell .cp-btn.green:hover,
#cps-shell .cp-btn.green:hover,
#cpa-shell .cp-btn.green:hover { background: #166534; }

#cp-shell .cp-btn.grey,
#cps-shell .cp-btn.grey,
#cpa-shell .cp-btn.grey { background: #6b7280; }
#cp-shell .cp-btn.grey:hover,
#cps-shell .cp-btn.grey:hover,
#cpa-shell .cp-btn.grey:hover { background: #4b5563; }

#cp-shell .cp-notice,
#cps-shell .cp-notice,
#cpa-shell .cp-notice {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 13px;
    line-height: 1.5;
}
#cp-shell .cp-notice.success,
#cps-shell .cp-notice.success,
#cpa-shell .cp-notice.success { background: #f0fdf4; color: #15803d; border: 0.5px solid #bbf7d0; }
#cp-shell .cp-notice.danger,
#cps-shell .cp-notice.danger,
#cpa-shell .cp-notice.danger { background: #fef2f2; color: #b91c1c; border: 0.5px solid #fecaca; }


/* ─────────────────────────────────────────────────────────────────────────
   5. UTILITIES
   ───────────────────────────────────────────────────────────────────────── */

.jb-muted { color: #9ca3af; font-size: 12px; }
.jb-help  { font-size: 12px; color: #6b7280; margin-top: 4px; }
.tasco-page-wrapper .row { align-items: flex-start !important; }


/* ─────────────────────────────────────────────────────────────────────────
   6. PAGE HEADER
   ───────────────────────────────────────────────────────────────────────── */

.tasco-page-header {
    padding: 28px 0 20px;
    border-bottom: 0.5px solid #e5e7eb;
    margin-bottom: 28px;
}
.tasco-page-header .ph-breadcrumb {
    font-size: 12px;
    color: #9ca3af;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.tasco-page-header .ph-breadcrumb a {
    color: #6b7280;
    text-decoration: none;
}
.tasco-page-header .ph-breadcrumb a:hover { color: #0b122b; }
.tasco-page-header .ph-breadcrumb span { color: #d1d5db; }
.tasco-page-header .ph-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: nowrap;
}
.tasco-page-header .ph-eyebrow {
    font-size: 11px;
    font-weight: 500;
    color: #c4151d;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.tasco-page-header .ph-eyebrow::before {
    content: '';
    display: inline-block;
    width: 16px;
    height: 2px;
    background: #c4151d;
    flex-shrink: 0;
}
.tasco-page-header h1 {
    font-size: 26px;
    font-weight: 700;
    color: #0b122b;
    line-height: 1.2;
    margin: 0;
}
.tasco-page-header .ph-subtitle {
    font-size: 13px;
    color: #6b7280;
    margin-top: 6px;
}
.tasco-page-header .ph-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;
    padding-bottom: 4px;
}
@media (max-width: 600px) {
    .tasco-page-header .ph-inner { flex-wrap: wrap; }
    .tasco-page-header .ph-actions { width: 100%; }
}


/* ─────────────────────────────────────────────────────────────────────────
   7. TWO-COLUMN FORM LAYOUT (open dates, open tournaments)
   ───────────────────────────────────────────────────────────────────────── */

.tasco-form-wide { max-width: 860px; margin: 0 auto; padding: 1.5rem 0; font-family: Arial, Helvetica, sans-serif; }
.tasco-form-wide .jb-form-card { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
.tasco-form-wide .jb-field { margin-bottom: 14px; }
.tasco-form-wide .jb-field.full { grid-column: 1 / -1; }
.tasco-form-wide .submit-row { grid-column: 1 / -1; margin-top: 6px; }
.tasco-form-wide .jb-field label { display: block; font-size: 11px; font-weight: 500; color: #6b7280; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 5px; }
.tasco-form-wide .jb-field input,
.tasco-form-wide .jb-field select,
.tasco-form-wide .jb-field textarea { width: 100%; box-sizing: border-box; border: 0.5px solid #d1d5db; border-radius: 8px; padding: 9px 12px; font-size: 13px; background: #fff; color: #1f2937; }
.tasco-form-wide .jb-field textarea { min-height: 80px; resize: vertical; }
.tasco-form-wide .jb-field input:focus,
.tasco-form-wide .jb-field select:focus,
.tasco-form-wide .jb-field textarea:focus { outline: none; border-color: #1d4ed8; box-shadow: 0 0 0 3px rgba(29,78,216,.08); }
@media (max-width: 600px) {
    .tasco-form-wide .jb-form-card { grid-template-columns: 1fr; }
    .tasco-form-wide .jb-field.full,
    .tasco-form-wide .submit-row { grid-column: 1; }
}