/* Escort Informer - Dark Onyx Theme */
:root {
    --onyx-primary: #0a0a0a;
    --onyx-secondary: #1a1a1a;
    --onyx-accent: #2a2a2a;
    --onyx-border: #333333;
    --onyx-text: #e0e0e0;
    --onyx-text-muted: #a0a0a0;
    --accent-pink: #ff69b4;
    --accent-pink-light: #ffb6c1;
    --accent-white: #ffffff;
    --accent-green: #4ade80;
    --accent-red: #f87171;
    --gradient-primary: linear-gradient(135deg, #ff69b4 0%, #ff1493 100%);
    --gradient-secondary: linear-gradient(135deg, #ff69b4 0%, #ffb6c1 100%);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.4);
    --shadow-strong: 0 12px 40px rgba(0, 0, 0, 0.5);
}

* {
    box-sizing: border-box;
}

body {
    background: var(--onyx-primary);
    color: var(--onyx-text);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* Header Section */
.header-section {
    background: var(--gradient-primary);
    padding: 2rem 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-medium);
}

.header-title {
    color: white;
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.header-title i {
    margin-right: 0.5rem;
    color: var(--accent-yellow);
}

/* Main Container */
.main-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem 0;
}

.page-title {
    color: var(--accent-pink);
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, var(--accent-pink) 0%, var(--accent-pink-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Statistics Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stats-card {
    background: var(--onyx-secondary);
    border: 1px solid var(--onyx-border);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-soft);
}

.stats-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-pink);
}

.stats-card h3 {
    color: var(--accent-pink);
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
}

.stats-card p {
    color: var(--onyx-text-muted);
    margin: 0;
    font-size: 0.9rem;
    font-weight: 500;
}

.stats-card i {
    color: var(--accent-pink);
    margin-right: 0.5rem;
}

/* Phone Statistics Section */
.phone-stats-section {
    background: var(--onyx-secondary);
    border: 1px solid var(--onyx-border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-soft);
}

.phone-stats-title {
    color: var(--onyx-text);
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
    display: flex;
    align-items: center;
}

.phone-stats-title i {
    color: var(--accent-pink);
    margin-right: 0.5rem;
}

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

.phone-stat-item {
    background: var(--onyx-accent);
    border: 1px solid var(--onyx-border);
    border-radius: 8px;
    padding: 0.75rem;
    transition: all 0.2s ease;
}

.phone-stat-item:hover {
    background: var(--accent-pink);
    transform: translateY(-1px);
}

/* Top 5 pink colors - outlines only */
.phone-stat-item.top-5:nth-child(1) {
    background: var(--onyx-accent);
    border: 3px solid #e91e63;
    box-shadow: 0 0 10px rgba(233, 30, 99, 0.3);
}

.phone-stat-item.top-5:nth-child(2) {
    background: var(--onyx-accent);
    border: 3px solid #f06292;
    box-shadow: 0 0 10px rgba(240, 98, 146, 0.3);
}

.phone-stat-item.top-5:nth-child(3) {
    background: var(--onyx-accent);
    border: 3px solid #f48fb1;
    box-shadow: 0 0 10px rgba(244, 143, 177, 0.3);
}

.phone-stat-item.top-5:nth-child(4) {
    background: var(--onyx-accent);
    border: 3px solid #f8bbd9;
    box-shadow: 0 0 10px rgba(248, 187, 217, 0.3);
}

.phone-stat-item.top-5:nth-child(5) {
    background: var(--onyx-accent);
    border: 3px solid #fce4ec;
    box-shadow: 0 0 10px rgba(252, 228, 236, 0.3);
}

.phone-stat-item.top-5:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(233, 30, 99, 0.5);
}

.phone-link {
    color: var(--onyx-text);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 500;
}

.phone-link:hover {
    color: white;
    text-decoration: none;
}

.phone-number {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.phone-rank {
    font-weight: 700;
    font-size: 1.1em;
}

/* Top 5 text colors */
.phone-stat-item.top-5 .phone-link {
    color: var(--onyx-text);
    font-weight: 600;
}

.phone-stat-item.top-5 .phone-rank {
    color: var(--accent-pink);
    font-weight: 800;
    font-size: 1.2em;
}

.phone-stat-item.top-5 .phone-badge {
    background: var(--accent-pink);
    color: white;
    font-weight: 700;
}

.phone-badge {
    background: var(--accent-pink);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Search and Filters Section */
.search-section {
    background: var(--onyx-secondary);
    border: 1px solid var(--onyx-border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-soft);
}

.search-form {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto auto;
    gap: 1rem;
    align-items: end;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-label {
    color: var(--onyx-text);
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-control, .form-select {
    background: var(--onyx-accent);
    border: 1px solid var(--onyx-border);
    color: var(--onyx-text);
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.form-control:focus, .form-select:focus {
    outline: none;
    border-color: var(--accent-pink);
    box-shadow: 0 0 0 3px rgba(255, 105, 180, 0.1);
}

.form-control::placeholder {
    color: var(--onyx-text-muted);
}

.btn {
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--gradient-secondary);
    color: white;
    box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-medium);
}

.btn-outline-secondary {
    background: transparent;
    color: var(--onyx-text-muted);
    border: 1px solid var(--onyx-border);
}

.btn-outline-secondary:hover {
    background: var(--onyx-accent);
    color: var(--onyx-text);
    border-color: var(--accent-pink);
}

/* Table Section */
.table-section {
    background: var(--onyx-secondary);
    border: 1px solid var(--onyx-border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    margin-bottom: 2rem;
}

.table-container {
    overflow-x: auto;
}

.table {
    width: 100%;
    margin: 0;
    background: var(--onyx-secondary) !important;
    color: var(--onyx-text) !important;
}

.table thead th {
    background: var(--onyx-accent);
    color: var(--onyx-text);
    border: none;
    padding: 1rem;
    font-weight: 600;
    font-size: 0.9rem;
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 2px solid var(--onyx-border);
}

.table tbody td {
    padding: 1rem;
    border-bottom: 1px solid var(--onyx-border);
    vertical-align: middle;
    color: var(--onyx-text);
    background: var(--onyx-secondary) !important;
}

.table tbody tr {
    transition: all 0.2s ease;
    background: var(--onyx-secondary) !important;
}

.table tbody tr:hover {
    background: var(--onyx-accent) !important;
}

.sort-link {
    color: var(--onyx-text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.sort-link:hover {
    color: var(--accent-pink);
    text-decoration: none;
}

.title-cell {
    max-width: 300px;
    word-wrap: break-word;
    line-height: 1.4;
}

.link-cell {
    max-width: 200px;
    word-wrap: break-word;
}

.phone-link {
    color: var(--accent-pink);
    text-decoration: none;
    font-weight: 500;
}

.phone-link:hover {
    color: var(--accent-white);
    text-decoration: underline;
}

.badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.badge-success {
    background: var(--accent-green);
    color: var(--onyx-primary);
}

.badge-secondary {
    background: var(--onyx-text-muted);
    color: var(--onyx-primary);
}

.photo-thumbnail {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s ease;
    border: 2px solid var(--onyx-border);
}

.photo-thumbnail:hover {
    transform: scale(1.1);
    border-color: var(--accent-pink);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

.btn-outline-primary {
    background: transparent;
    color: var(--accent-pink);
    border: 1px solid var(--accent-pink);
}

.btn-outline-primary:hover {
    background: var(--accent-pink);
    color: white;
}

/* Pagination Section */
.pagination-section {
    background: var(--onyx-secondary);
    border: 1px solid var(--onyx-border);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-soft);
}

.pagination-info {
    color: var(--onyx-text-muted);
    font-size: 0.9rem;
    margin: 0;
}

.pagination {
    margin: 0;
    gap: 0.25rem;
}

.page-link {
    background: var(--onyx-accent);
    border: 1px solid var(--onyx-border);
    color: var(--onyx-text);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.page-link:hover {
    background: var(--accent-pink);
    color: white;
    border-color: var(--accent-pink);
}

.page-item.active .page-link {
    background: var(--accent-pink);
    color: white;
    border-color: var(--accent-pink);
}

.page-item.disabled .page-link {
    background: var(--onyx-accent);
    color: var(--onyx-text-muted);
    border-color: var(--onyx-border);
}

/* Modal Styles */
.modal-content {
    background: var(--onyx-secondary) !important;
    border: 1px solid var(--onyx-border) !important;
    border-radius: 12px !important;
    color: var(--onyx-text) !important;
}

.modal-header {
    border-bottom: 1px solid var(--onyx-border) !important;
    background: var(--onyx-accent) !important;
}

.modal-title {
    color: var(--onyx-text) !important;
    font-weight: 600;
}

.modal-body {
    background: var(--onyx-secondary) !important;
    color: var(--onyx-text) !important;
}

.modal-footer {
    border-top: 1px solid var(--onyx-border) !important;
    background: var(--onyx-accent) !important;
}

.btn-close {
    filter: invert(1) !important;
}

/* Override Bootstrap modal backdrop */
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.8) !important;
}

/* Ensure modal is hidden by default */
.modal {
    display: none !important;
}

.modal.show {
    display: block !important;
}

/* Fix modal positioning */
.modal-dialog {
    margin: 1.75rem auto;
}

/* Ensure modal content is properly styled */
.modal-content img {
    max-width: 100%;
    max-height: 70vh;
    width: auto;
    height: auto;
    border-radius: 8px;
    object-fit: contain;
}

/* Modal responsive scaling */
.modal-dialog {
    max-width: 90vw;
    max-height: 90vh;
    margin: 1.75rem auto;
}

.modal-body {
    max-height: 70vh;
    overflow-y: auto;
}

@media (max-width: 768px) {
    .modal-dialog {
        max-width: 95vw;
        margin: 0.5rem auto;
    }
    
    .modal-content img {
        max-height: 60vh;
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--onyx-text-muted);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--onyx-text-muted);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .search-form {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
    
    .search-form .btn {
        grid-column: 1 / -1;
        justify-self: start;
    }
}

@media (max-width: 768px) {
    .main-container {
        padding: 0 0.5rem;
    }
    
    .header-title {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 1rem;
    }
    
    .stats-card {
        padding: 1rem;
    }
    
    .stats-card h3 {
        font-size: 1.5rem;
    }
    
    .phone-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .search-form {
        grid-template-columns: 1fr;
    }
    
    .table-container {
        font-size: 0.8rem;
    }
    
    .table thead th,
    .table tbody td {
        padding: 0.75rem 0.5rem;
    }
}

@media (max-width: 480px) {
    .header-title {
        font-size: 1.5rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .title-cell {
        max-width: 150px;
    }
    
    .link-cell {
        max-width: 100px;
    }
}

/* Loading and Animation States */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--onyx-accent);
}

::-webkit-scrollbar-thumb {
    background: var(--onyx-border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-pink);
}
