/* Listy.sbs - Main Stylesheet */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --dark-color: #1f2937;
    --light-color: #f3f4f6;
    --border-color: #e5e7eb;
    --text-color: #374151;
    --heading-color: #111827;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: #fff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

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

.logo a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 700;
}

.nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav a:hover, .nav a.active {
    color: var(--primary-color);
}

/* Buttons */
.btn-primary {
    background: var(--primary-color);
    color: #fff;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    text-decoration: none;
    display: inline-block;
    border: none;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: var(--secondary-color);
}

.btn-secondary {
    background: var(--light-color);
    color: var(--text-color);
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    text-decoration: none;
    display: inline-block;
    border: 1px solid var(--border-color);
}

.btn-large {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
}

.btn-block {
    width: 100%;
    display: block;
    text-align: center;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
    padding: 4rem 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

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

.search-box form {
    display: flex;
    gap: 0.5rem;
}

.search-box input {
    flex: 1;
    padding: 1rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
}

.search-box button {
    padding: 1rem 2rem;
    background: var(--dark-color);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
}

.search-box button:hover {
    background: #000;
}

/* Main Content Layout */
.main-content {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
    margin: 2rem auto;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 100px;
    align-self: start;
}

.widget {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.widget h3 {
    color: var(--heading-color);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.filter-form {
    display: flex;
    gap: 0.5rem;
}

.filter-form input {
    flex: 1;
    padding: 0.6rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
}

.filter-form button {
    padding: 0.6rem 1rem;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.category-list, .city-list {
    list-style: none;
}

.category-list li, .city-list li {
    margin-bottom: 0.5rem;
}

.category-list a, .city-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem;
    color: var(--text-color);
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s;
}

.category-list a:hover, .city-list a:hover, .category-list a.active, .city-list a.active {
    background: var(--light-color);
    color: var(--primary-color);
}

.count {
    background: var(--light-color);
    color: var(--text-color);
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.85rem;
}

.recent-list, .popular-list {
    list-style: none;
}

.recent-list li {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.recent-list li:last-child {
    border-bottom: none;
}

.recent-list a {
    display: flex;
    gap: 0.8rem;
    color: var(--text-color);
    text-decoration: none;
}

.recent-list img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
}

.recent-list h4 {
    font-size: 0.95rem;
    color: var(--heading-color);
    margin-bottom: 0.3rem;
}

.recent-list p {
    font-size: 0.85rem;
    color: #6b7280;
}

.popular-list li {
    margin-bottom: 0.8rem;
}

.popular-list a {
    color: var(--text-color);
    text-decoration: none;
}

.popular-list h4 {
    font-size: 0.95rem;
    color: var(--heading-color);
    margin-bottom: 0.2rem;
}

.cta-widget {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
}

.cta-widget h3 {
    color: #fff;
}

.cta-widget .btn-primary {
    background: #fff;
    color: var(--primary-color);
    width: 100%;
    margin-top: 1rem;
}

/* Content Area */
.content {
    min-height: 600px;
}

.content h2 {
    color: var(--heading-color);
    margin-bottom: 1.5rem;
}

.filter-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: var(--light-color);
    border-radius: 6px;
    margin-bottom: 1.5rem;
}

.clear-filters {
    color: var(--primary-color);
    text-decoration: none;
}

.no-results {
    text-align: center;
    padding: 4rem 2rem;
    color: #6b7280;
}

.no-results i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

/* Business Grid */
.business-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.business-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s;
}

.business-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.business-card a {
    color: var(--text-color);
    text-decoration: none;
}

.business-image {
    height: 200px;
    overflow: hidden;
}

.business-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.business-info {
    padding: 1.2rem;
}

.category {
    display: inline-block;
    background: var(--light-color);
    color: var(--primary-color);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.business-info h3 {
    color: var(--heading-color);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.description {
    color: #6b7280;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.8rem;
}

.location {
    color: #6b7280;
    font-size: 0.9rem;
}

.location i {
    color: var(--primary-color);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.pagination a, .pagination span {
    padding: 0.6rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s;
}

.pagination a:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.pagination .current {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

/* Business Detail Page */
.breadcrumb {
    padding: 1rem 0;
    color: #6b7280;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb i {
    margin: 0 0.5rem;
}

.business-detail {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 2rem;
}

.business-header-image {
    height: 400px;
    overflow: hidden;
}

.business-header-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.business-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.business-title-section h1 {
    color: var(--heading-color);
    font-size: 2rem;
    margin: 0.5rem 0 1rem;
}

.category-badge {
    background: var(--primary-color);
    color: #fff;
    padding: 0.4rem 1rem;
    border-radius: 4px;
    font-size: 0.9rem;
    display: inline-block;
}

.business-meta {
    display: flex;
    gap: 1.5rem;
    color: #6b7280;
    font-size: 0.95rem;
}

.business-meta i {
    color: var(--primary-color);
    margin-right: 0.3rem;
}

.business-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    padding: 2rem;
}

.business-main .section {
    margin-bottom: 2rem;
}

.business-main h2 {
    color: var(--heading-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.contact-info {
    display: grid;
    gap: 1rem;
}

.info-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: var(--light-color);
    border-radius: 6px;
}

.info-item i {
    color: var(--primary-color);
    font-size: 1.3rem;
    min-width: 30px;
}

.info-item strong {
    display: block;
    color: var(--heading-color);
    margin-bottom: 0.3rem;
}

.info-item a {
    color: var(--primary-color);
    text-decoration: none;
}

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

.related-card {
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    transition: all 0.3s;
}

.related-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.related-card a {
    text-decoration: none;
    color: var(--text-color);
}

.related-card img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.related-card h3 {
    padding: 0.8rem;
    font-size: 0.95rem;
    color: var(--heading-color);
}

.related-card p {
    padding: 0 0.8rem 0.8rem;
    font-size: 0.85rem;
    color: #6b7280;
}

.business-sidebar .widget {
    position: sticky;
    top: 100px;
}

.quick-actions {
    display: grid;
    gap: 0.8rem;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem;
    background: var(--light-color);
    color: var(--text-color);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s;
}

.action-btn:hover {
    background: var(--primary-color);
    color: #fff;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--heading-color);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
}

.form-group textarea {
    resize: vertical;
}

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

.required {
    color: var(--danger-color);
}

.optional {
    color: #6b7280;
    font-weight: 400;
    font-size: 0.85rem;
}

.help-text {
    font-size: 0.85rem;
    color: #6b7280;
    margin-top: 0.5rem;
}

.form-section {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.form-section h2 {
    color: var(--heading-color);
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.form-note {
    background: var(--light-color);
    padding: 1rem;
    border-radius: 6px;
    margin-top: 1rem;
    font-size: 0.9rem;
}

/* Alerts */
.alert {
    padding: 1rem 1.5rem;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.alert i {
    font-size: 1.3rem;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

/* Page Content */
.page-content {
    margin: 2rem auto;
}

.page-header {
    text-align: center;
    margin-bottom: 3rem;
}

.page-header h1 {
    color: var(--heading-color);
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    color: #6b7280;
    font-size: 1.1rem;
}

.content-section {
    max-width: 800px;
    margin: 0 auto;
}

.content-section h2 {
    color: var(--heading-color);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.content-section h3 {
    color: var(--heading-color);
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
}

.content-section ul {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.content-section li {
    margin-bottom: 0.5rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.feature-card i {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.feature-card h3 {
    color: var(--heading-color);
    margin-bottom: 0.8rem;
}

/* Contact Page */
.contact-page {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-details {
    margin-top: 2rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-item i {
    color: var(--primary-color);
    font-size: 1.5rem;
    min-width: 30px;
}

.contact-item strong {
    display: block;
    color: var(--heading-color);
    margin-bottom: 0.3rem;
}

.contact-form-section {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 2rem;
}

/* Footer */
.footer {
    background: var(--dark-color);
    color: #fff;
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer nav {
    display: flex;
    gap: 1.5rem;
}

.footer a {
    color: #fff;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.footer a:hover {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
    }

    .business-content {
        grid-template-columns: 1fr;
    }

    .business-sidebar {
        order: -1;
    }

    .hero h2 {
        font-size: 1.8rem;
    }

    .search-box form {
        flex-direction: column;
    }

    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .nav {
        flex-wrap: wrap;
        justify-content: center;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .contact-page {
        grid-template-columns: 1fr;
    }

    .footer .container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer nav {
        flex-direction: column;
        gap: 0.5rem;
    }

    .business-hours-table table {
        font-size: 0.9rem;
    }

    .categories-grid {
        grid-template-columns: 1fr;
    }
}

/* Business Hours Table */
.business-hours-table {
    overflow-x: auto;
    margin-top: 1rem;
}

.business-hours-table table {
    width: 100%;
    border-collapse: collapse;
}

.business-hours-table thead {
    background: var(--light-color);
}

.business-hours-table th {
    padding: 0.8rem;
    text-align: left;
    font-weight: 600;
    color: var(--heading-color);
    border: 1px solid var(--border-color);
}

.business-hours-table td {
    padding: 0.8rem;
    border: 1px solid var(--border-color);
}

.business-hours-table .day-cell {
    font-weight: 500;
    color: var(--heading-color);
}

.business-hours-table select,
.business-hours-table input[type="time"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95rem;
}

.business-hours-table input[type="time"]:disabled {
    background: var(--light-color);
    color: #9ca3af;
}

/* Categories Page */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.category-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s;
}

.category-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
    border-color: var(--primary-color);
}

.category-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-color);
    border-radius: 8px;
    color: var(--primary-color);
    font-size: 1.8rem;
    flex-shrink: 0;
}

.category-info h3 {
    color: var(--heading-color);
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}

.category-info p {
    color: #6b7280;
    font-size: 0.9rem;
}

/* Cities Page */
.cities-container {
    margin-top: 2rem;
}

.state-section {
    margin-bottom: 3rem;
}

.state-name {
    color: var(--heading-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.state-name i {
    color: var(--primary-color);
}

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

.city-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s;
}

.city-link:hover {
    background: var(--light-color);
    border-color: var(--primary-color);
}

.city-name {
    color: var(--heading-color);
    font-weight: 500;
}

.city-count {
    color: #6b7280;
    font-size: 0.85rem;
    background: var(--light-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
}

/* Business Hours Display */
.business-hours-display {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
}

.business-hours-display .hours-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.business-hours-display .hours-row:last-child {
    border-bottom: none;
}

.business-hours-display .day {
    font-weight: 500;
    color: var(--heading-color);
}

.business-hours-display .hours {
    color: #6b7280;
}

.business-hours-display .closed {
    color: var(--danger-color);
}

.business-hours-display .open-24 {
    color: #059669;
    font-weight: 500;
}

