/* Directory page specific styles */

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.subtitle {
    color: #94a3b8;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.back-btn {
    background: rgba(30, 41, 59, 0.8);
    border: 2px solid #334155;
    padding: 0.5rem 1rem;
    text-decoration: none;
    color: #fff;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: #3b82f6;
}

.main-content {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.search-section {
    background: rgba(10, 14, 39, 0.95);
    border: 2px solid #1e3a8a;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.search-section h2 {
    color: #60a5fa;
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.search-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #1e3a8a;
}

.tab-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    padding: 0.75rem 1rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.tab-btn:hover {
    color: #60a5fa;
}

.tab-btn.active {
    color: #60a5fa;
    border-bottom-color: #60a5fa;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.search-box {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    color: #cbd5e1;
    font-size: 0.875rem;
    font-weight: 500;
}

.input-group input,
.input-group select {
    background: rgba(30, 41, 59, 0.8);
    border: 2px solid #334155;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    transition: border-color 0.2s;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: #60a5fa;
}

.input-group input[type="number"] {
    max-width: 200px;
}

.input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.search-options {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #1e3a8a;
}

.search-options label {
    color: #94a3b8;
    font-size: 0.875rem;
}

.search-options select {
    background: rgba(30, 41, 59, 0.8);
    border: 2px solid #334155;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

.results-section {
    background: rgba(10, 14, 39, 0.95);
    border: 2px solid #1e3a8a;
    border-radius: 0.5rem;
    padding: 1.5rem;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.results-header h2 {
    color: #60a5fa;
    font-size: 1.25rem;
}

.results-count {
    color: #94a3b8;
    font-size: 0.875rem;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1rem;
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #94a3b8;
}

.pds-card {
    background: rgba(30, 41, 59, 0.4);
    border: 2px solid #334155;
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.3s ease;
    position: relative;
}

.pds-card:hover {
    border-color: #60a5fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.pds-card.highlight {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.highlight-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: #10b981;
    color: #fff;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: bold;
}

.pds-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
    gap: 0.5rem;
}

.pds-card-header h3 {
    color: #60a5fa;
    font-size: 0.95rem;
    word-break: break-all;
    line-height: 1.3;
    margin: 0;
}

.pds-card-body {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pds-card-body p {
    margin: 0;
    font-size: 0.85rem;
    color: #cbd5e1;
}

.invite-required {
    color: #fbbf24 !important;
}

.ping-info {
    padding-top: 0.5rem;
    border-top: 1px solid #334155;
    margin-top: 0.25rem !important;
}

.ping-value {
    font-weight: bold;
}

.ping-value.excellent {
    color: #10b981;
}

.ping-value.good {
    color: #34d399;
}

.ping-value.fair {
    color: #fbbf24;
}

.ping-value.poor {
    color: #f87171;
}

.ping-value.timeout,
.ping-value.offline {
    color: #94a3b8;
}

/* Responsive design */
@media (max-width: 768px) {
    .main-content {
        padding: 1rem;
    }
    
    .input-row {
        grid-template-columns: 1fr;
    }
    
    .results-grid {
        grid-template-columns: 1fr;
    }
    
    .search-options {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
}
