/* ==========================================================================
   PÁGINA DE CATEGORÍAS - DISEÑO SIMPLE
   ========================================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Roboto', 'Segoe UI', Arial, sans-serif;
  background: #f5f5f5;
  color: #333;
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ==================== TOP BAR ==================== */
.top-bar {
  background: white;
  border-bottom: 1px solid #e0e0e0;
  padding: 12px 0;
}

.top-bar-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.breadcrumb {
  font-size: 14px;
  color: #666;
}

.breadcrumb a {
  color: #1565c0;
  transition: color 0.2s;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.top-bar-logo img {
  height: 30px;
  width: auto;
}

/* ==================== MAIN LAYOUT ==================== */
.main-layout {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 30px;
  min-height: calc(100vh - 100px);
}

/* ==================== SIDEBAR ==================== */
.sidebar-filter {
  background: #003d5c;
  border-radius: 8px;
  padding: 0;
  height: fit-content;
  position: sticky;
  top: 20px;
}

.sidebar-inner {
  padding: 25px;
}

.sidebar-title {
  color: white;
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 20px;
}

.filter-group {
  margin-bottom: 20px;
}

.filter-label {
  display: block;
  color: white;
  font-size: 14px;
  margin-bottom: 8px;
  font-weight: 500;
}

.search-box {
  position: relative;
}

.search-box i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #999;
}

.search-box input {
  width: 100%;
  padding: 12px 15px 12px 40px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  outline: none;
}

.filter-select {
  width: 100%;
  padding: 12px 15px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  background: white;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 16px;
  padding-right: 35px;
}

/* ==================== CONTENT AREA ==================== */
.content-area {
  background: transparent;
}

.category-header {
  background: white;
  padding: 25px;
  border-radius: 8px;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.category-header-left {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.category-icon {
  width: 60px;
  height: 60px;
  background: #f5f5f5;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.category-icon i {
  font-size: 28px;
  color: #1565c0;
}

.category-info h1 {
  font-size: 24px;
  font-weight: 500;
  color: #333;
  margin-bottom: 4px;
}

.category-location {
  font-size: 14px;
  color: #666;
  margin-bottom: 4px;
}

.category-results {
  font-size: 14px;
  color: #999;
}

.category-header-right {
  display: flex;
  align-items: center;
  gap: 15px;
}

.sort-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sort-group label {
  font-size: 14px;
  color: #666;
  font-weight: 500;
}

.sort-select {
  padding: 8px 30px 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  background: white;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 14px;
}

.map-view-btn {
  padding: 10px 20px;
  background: #1976d2;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s;
}

.map-view-btn:hover {
  background: #1565c0;
}

/* ==================== BUSINESS CARDS ==================== */
.businesses-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.business-card {
  background: white;
  border-radius: 8px;
  padding: 25px;
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 25px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

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

.business-logo {
  width: 100px;
  height: 100px;
  background: #f5f5f5;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

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

.business-info {
  flex: 1;
  min-width: 0;
}

.business-name {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 8px;
  display: inline-block;
}

.business-name a {
  color: #333;
  transition: color 0.2s;
}

.business-name a:hover {
  color: #1565c0;
}

.business-status {
  display: inline-block;
  font-size: 13px;
  margin-left: 12px;
  color: #4caf50;
  font-weight: 500;
}

.business-status.closed {
  color: #f44336;
}

.business-category {
  font-size: 13px;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
  font-weight: 500;
}

.business-description {
  font-size: 14px;
  color: #666;
  line-height: 1.6;
  margin: 0;
}

.business-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 150px;
}

.action-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
  width: 100%;
}

.btn-phone {
  background: #7cb342;
  color: white;
}

.btn-phone:hover {
  background: #689f38;
}

.btn-location {
  background: #1976d2;
  color: white;
}

.btn-location:hover {
  background: #1565c0;
}

/* ==================== PAGINATION ==================== */
.pagination {
  background: white;
  padding: 20px;
  border-radius: 8px;
  margin-top: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
}

.pagination-btn {
  padding: 10px 20px;
  background: #1565c0;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s;
}

.pagination-btn:hover:not(:disabled) {
  background: #0d47a1;
}

.pagination-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}

.pagination-info {
  font-size: 14px;
  color: #666;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1024px) {
  .main-layout {
    grid-template-columns: 1fr;
  }
  
  .sidebar-filter {
    position: static;
  }
  
  .category-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .category-header-right {
    width: 100%;
    flex-wrap: wrap;
  }
}

@media (max-width: 768px) {
  .main-layout {
    padding: 15px;
    gap: 20px;
  }
  
  .business-card {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .business-logo {
    width: 100%;
    height: 200px;
  }
  
  .business-actions {
    flex-direction: row;
  }
  
  .category-header-left {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .top-bar-content {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
}
