/* Frontend Styles for Property Comparables Search */

.pc-search-wrapper {
    max-width: 1200px;
}

/* Search Form */
.pc-search-form {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 40px;
}

.pc-search-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.pc-search-field label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
    color: #333;
}

.pc-search-field select {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #fff;
    transition: all 0.3s ease;
}

.pc-search-field input[type="text"],
.pc-text-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #fff;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.pc-search-field select:focus,
.pc-search-field input[type="text"]:focus,
.pc-text-input:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

.pc-search-submit {
    text-align: center;
}

.pc-search-button {
    background: #0073aa;
    color: #fff;
    border: none;
    padding: 14px 40px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pc-search-button:hover {
    background: #005a87;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 115, 170, 0.3);
}

.pc-search-button .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* Results Section */
.pc-results-wrapper {
    margin-top: 40px;
}

.pc-results-header {
    text-align: center;
    margin-bottom: 40px;
}

.pc-results-header h2 {
    font-size: 32px;
    color: #1d2327;
    margin: 0 0 10px 0;
}

.pc-search-criteria {
    font-size: 16px;
    color: #646970;
    margin: 10px 0;
}

/* Stats Grid */
.pc-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.pc-stat-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pc-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.pc-stat-header {
    background: linear-gradient(135deg, #0073aa 0%, #005a87 100%);
    color: #fff;
    padding: 20px;
    text-align: center;
}

.pc-stat-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
}

.pc-stat-body {
    padding: 25px;
}

.pc-stat-main {
    text-align: center;
    margin-bottom: 20px;
}

.pc-stat-label {
    font-size: 13px;
    color: #646970;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.pc-stat-value {
    font-size: 36px;
    font-weight: 700;
    color: #0073aa;
    line-height: 1;
}

.pc-stat-meta {
    text-align: center;
    margin: 15px 0;
}

.pc-stat-count {
    background: #f0f0f0;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    color: #646970;
    display: inline-block;
}

/* Year-over-Year Comparison */
.pc-stat-comparison {
    margin-top: 20px;
    padding: 20px;
    border-radius: 8px;
    border: 2px solid;
}

.pc-stat-comparison.positive {
    background: #d4edda;
    border-color: #28a745;
}

.pc-stat-comparison.negative {
    background: #f8d7da;
    border-color: #dc3545;
}

.pc-yoy-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    font-weight: 600;
}

.pc-stat-comparison.positive .pc-yoy-label {
    color: #155724;
}

.pc-stat-comparison.negative .pc-yoy-label {
    color: #721c24;
}

.pc-yoy-values {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.pc-yoy-percent {
    font-size: 24px;
    font-weight: 700;
}

.pc-stat-comparison.positive .pc-yoy-percent {
    color: #28a745;
}

.pc-stat-comparison.negative .pc-yoy-percent {
    color: #dc3545;
}

.pc-yoy-amount {
    font-size: 18px;
    font-weight: 600;
}

.pc-stat-comparison.positive .pc-yoy-amount {
    color: #155724;
}

.pc-stat-comparison.negative .pc-yoy-amount {
    color: #721c24;
}

.pc-yoy-details {
    font-size: 13px;
    padding-top: 10px;
    border-top: 1px solid rgba(0,0,0,0.1);
}

.pc-stat-comparison.positive .pc-yoy-details {
    color: #155724;
}

.pc-stat-comparison.negative .pc-yoy-details {
    color: #721c24;
}

.pc-stat-note {
    text-align: center;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
    font-size: 13px;
    color: #646970;
    margin-top: 15px;
}

/* Results Footer */
.pc-results-footer {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #f0f0f0;
}

.pc-disclaimer {
    font-size: 14px;
    color: #646970;
    text-align: center;
    line-height: 1.6;
}

/* No Results */
.pc-no-results {
    background: #fff;
    padding: 60px 40px;
    text-align: center;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
}

.pc-no-results h3 {
    font-size: 24px;
    color: #1d2327;
    margin: 0 0 15px 0;
}

.pc-no-results p {
    font-size: 16px;
    color: #646970;
    margin: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .pc-search-form {
        padding: 20px;
    }
    
    .pc-search-row {
        grid-template-columns: 1fr;
    }
    
    .pc-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .pc-stat-value {
        font-size: 28px;
    }
    
    .pc-yoy-values {
        flex-direction: column;
        gap: 10px;
    }
    
    .pc-results-header h2 {
        font-size: 24px;
    }
}
/* Table Layout Styles */
.pc-results-table-wrapper {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    overflow: hidden;
    margin: 30px 0;
}

.pc-results-table {
    width: 100%;
    border-collapse: collapse;
}

.pc-results-table thead {
    background: linear-gradient(135deg, #0073aa 0%, #005a87 100%);
    color: #fff;
}

.pc-results-table th {
    padding: 18px 15px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pc-results-table tbody tr {
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.3s ease;
}

.pc-results-table tbody tr:hover {
    background: #f8f9fa;
}

.pc-results-table tbody tr:last-child {
    border-bottom: none;
}

.pc-results-table td {
    padding: 15px;
    font-size: 14px;
    color: #333;
}

.pc-table-price {
    font-size: 18px;
    font-weight: 700;
    color: #0073aa;
}

.pc-results-table .pc-positive {
    color: #28a745;
    font-weight: 600;
}

.pc-results-table .pc-negative {
    color: #dc3545;
    font-weight: 600;
}

.pc-results-table small {
    display: block;
    font-size: 11px;
    color: #666;
    margin-top: 3px;
}

/* Type Badge Styles */
.pc-type-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: #fff;
    display: inline-block;
}

.pc-type-badge.pc-rental {
    background: #2271b1;
}

.pc-type-badge.pc-sale {
    background: #00a32a;
}

/* Responsive Table */
@media (max-width: 768px) {
    .pc-results-table-wrapper {
        overflow-x: auto;
    }
    
    .pc-results-table {
        min-width: 600px;
    }
    
    .pc-results-table th,
    .pc-results-table td {
        padding: 10px 8px;
        font-size: 13px;
    }
}