/* Coach Directory Public Styles */
.ads-directory-container {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #1e293b;
    max-width: 1200px;
    margin: 2rem auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

/* Filters Section */
.ads-filters-section {
    padding: 1.5rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.ads-filters-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .ads-filters-grid {
        grid-template-columns: 2fr 1fr;
    }
}

.ads-search-box input {
    width: 100%;
    padding: 0.75rem 0rem 0.75rem 0.5rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.ads-search-box input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.ads-filter-group-label {
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
    color: #475569;
    display: block;
}

.ads-checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.5rem;
}

.ads-checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
}

.ads-checkbox-item input {
    cursor: pointer;
}

/* Table Section */
.ads-table-wrapper {
    overflow-x: auto;
}

.ads-directory-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.ads-directory-table th {
    background: #fff;
    text-align: left;
    padding: 1rem;
    font-weight: 600;
    color: #64748b;
    border-bottom: 2px solid #f1f5f9;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}

.ads-directory-table td {
    padding: 1rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.ads-row-main {
    transition: background-color 0.2s;
}

.ads-row-main:hover {
    background-color: #f8fafc;
}

.ads-roles-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.ads-role-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.2;
}

.ads-role-default {
    background: #f1f5f9;
    color: #475569;
}

.ads-role-green {
    background: #dcfce7;
    color: #166534;
}

.ads-role-orange {
    background: #ffedd5;
    color: #9a3412;
}

.ads-role-red {
    background: #fee2e2;
    color: #991b1b;
}

.ads-toggle-link {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    margin-right: 0.5rem;
}

.ads-toggle-link:hover {
    text-decoration: underline;
}

/* Expanded Row */
.ads-row-details {
    background: #f1f5f9;
    display: none;
}

.ads-details-content {
    padding: 1.5rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .ads-details-content {
        grid-template-columns: 1fr 1fr;
    }
}

.ads-details-column h4 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1rem;
    color: #334155;
    border-bottom: 1px solid #cbd5e1;
    padding-bottom: 0.5rem;
}

.ads-detail-item {
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

.ads-detail-label {
    font-weight: 600;
    color: #64748b;
    width: 140px;
    display: inline-block;
}

.ads-detail-value {
    color: #1e293b;
}

.ads-expiry-valid {
    color: #166534;
    font-weight: 500;
}

.ads-expiry-expired {
    color: #dc2626;
    font-weight: 500;
}

/* Pagination */
.ads-pagination {
    padding: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    border-top: 1px solid #e2e8f0;
}

.ads-page-link {
    padding: 0.5rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    text-decoration: none;
    color: #475569;
    font-size: 0.875rem;
    transition: all 0.2s;
    cursor: pointer;
}

.ads-page-link.active {
    background: #3b82f6;
    color: #fff;
    border-color: #3b82f6;
}

.ads-page-link:hover:not(.active) {
    background: #f1f5f9;
}

.ads-pagination-info {
    margin-right: auto;
    font-size: 0.875rem;
    color: #64748b;
}

/* Loading State */
.ads-loading {
    opacity: 0.5;
    pointer-events: none;
}

/* Hide empty paragraphs injected by WordPress wpautop */
.ads-directory-container p:empty,
.ads-directory-container p:blank {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
}