:root {
    --primary-color: #0d6efd;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --success-color: #198754;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f8f9fa;
}

.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

.search-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 3rem 0;
    margin-bottom: 2rem;
}

.search-box {
    max-width: 600px;
    margin: 0 auto;
}

.search-box input {
    height: 55px;
    font-size: 1.1rem;
    border-radius: 10px 0 0 10px;
}

.search-box button {
    height: 55px;
    padding: 0 2rem;
    border-radius: 0 10px 10px 0;
}

.phone-card {
    background: white;
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,.1);
}

.phone-number-display {
    font-size: 2.5rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 1rem;
}

.rating-stars {
    font-size: 1.5rem;
    color: #ffc107;
}

.comment-card {
    background: white;
    border-left: 4px solid #dee2e6;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-radius: 5px;
}

.comment-card.rating-1,
.comment-card.rating-2 {
    border-left-color: #dc3545;
}

.comment-card.rating-3 {
    border-left-color: #ffc107;
}

.comment-card.rating-4,
.comment-card.rating-5 {
    border-left-color: #198754;
}

.stats-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,.1);
}

.stats-card h3 {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.stats-card p {
    margin-bottom: 0;
    color: #6c757d;
}

.blog-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.1);
    transition: transform 0.2s;
    margin-bottom: 2rem;
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-card-body {
    padding: 1.5rem;
}

footer {
    background: #212529;
    color: white;
    padding: 2rem 0;
    margin-top: 3rem;
}

.chart-container {
    background: white;
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,.1);
}

.hover-shadow {
    transition: all 0.3s ease;
    border: 1px solid #dee2e6;
}

.hover-shadow:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
    border-color: #667eea;
}

/* ========================================
   MOBILE OPTIMIZATIONS
   ======================================== */

/* Mobile: Tablets and smaller */
@media (max-width: 768px) {
    .search-hero {
        padding: 2rem 0;
    }

    .phone-card {
        padding: 1.5rem;
    }

    .search-box input {
        height: 50px;
        font-size: 1rem;
    }

    .search-box button {
        height: 50px;
        padding: 0 1.5rem;
        font-size: 0.9rem;
    }

    .phone-number-display {
        font-size: 1.8rem;
    }

    .stats-card h3 {
        font-size: 1.5rem;
    }

    .comment-card {
        padding: 1rem;
    }

    .rating-stars {
        font-size: 1.2rem;
    }

    .chart-container {
        padding: 1rem;
    }

    footer {
        padding: 1.5rem 0;
    }

    footer .col-md-4 {
        margin-bottom: 1.5rem;
    }
}

/* Mobile: Phones */
@media (max-width: 576px) {
    .phone-number-display {
        font-size: 1.5rem;
        word-break: break-all;
    }

    .stats-card {
        padding: 1rem;
    }

    .stats-card h3 {
        font-size: 1.3rem;
    }

    .search-box input {
        border-radius: 10px 10px 0 0;
    }

    .search-box button {
        border-radius: 0 0 10px 10px;
        width: 100%;
    }

    .search-box .d-flex {
        flex-direction: column !important;
    }

    .btn {
        padding: 0.5rem 1rem;
    }

    h1.display-4 {
        font-size: 2rem;
    }

    h1.display-5 {
        font-size: 1.8rem;
    }

    .lead {
        font-size: 1rem;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .btn {
        min-height: 44px;
        padding: 0.6rem 1.2rem;
    }

    .form-control, .form-select {
        min-height: 44px;
    }

    .list-group-item-action {
        padding: 1rem;
    }

    .blog-card:hover {
        transform: none;
    }
}

/* Landscape orientation on phones */
@media (max-width: 896px) and (orientation: landscape) {
    .search-hero {
        padding: 1.5rem 0;
    }

    .phone-number-display {
        font-size: 1.5rem;
    }
}

img {
    max-width: 100%;
    height: auto;
}

.text-break {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

table {
    width: 100%;
}

@media (max-width: 768px) {
    table {
        font-size: 0.9rem;
    }
}

html {
    scroll-behavior: smooth;
}

/* Fix for iOS input zoom */
@media screen and (max-width: 768px) {
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    textarea,
    select {
        font-size: 16px !important;
    }
}
