/* Global Styles */
:root {
  --primary: #4361ee;
  --primary-dark: #3a56d4;
  --secondary: #3f37c9;
  --light: #f8f9fa;
  --dark: #212529;
  --gray: #6c757d;
  --light-gray: #e9ecef;
  --white: #ffffff;
  --border-radius: 8px;
  --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--light);
  color: var(--dark);
  line-height: 1.6;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.business-limit-info {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
    text-align: center;
}

/* Card Styles */
.card {
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  padding: 2rem;
  margin: 2rem auto;
  max-width: 600px;
}

.card-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.card-header h2 {
  color: var(--primary);
  font-size: 1.8rem;
}

/* Product Cards */
.product-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 1.5rem;
    transition: all 0.3s ease;
    display: block;
    text-decoration: none;
    color: inherit;
}

.product-image {
    max-width: 100%;
    height: auto;
    max-height: 180px;
    margin-bottom: 1rem;
    border-radius: 4px;
    object-fit: contain;
}

.product-name {
    font-size: 1.2rem;
    margin: 0 0 0.5rem 0;
    color: var(--dark);
}

.product-description {
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.product-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.product-location {
    color: #666;
    font-size: 14px;
    margin-bottom: 8px;
    font-weight: 500;
}

.business-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
}

.business-link:hover .business-name {
    text-decoration: none;
    color: #3a0ca3;
}

/* Buttons */
.btn-delete {
    background: #dc3545;
    color: white;
    border: none;
}

.btn-delete:hover {
    background: #c82333;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.action-buttons .btn {
    flex: 1;
    min-width: 120px;
    text-align: center;
}

/* Form Styles */
.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--dark);
}

.form-control {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid var(--light-gray);
  border-radius: var(--border-radius);
  font-size: 1rem;
  transition: border 0.3s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
}

.btn {
  display: inline-block;
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 0.8rem 1.5rem;
  border-radius: var(--border-radius);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  transition: background 0.3s ease;
  text-decoration: none;
  text-align: center;
}

.btn:hover {
  background: var(--primary-dark);
}

.btn-block {
  display: block;
  width: 100%;
}

.text-center {
  text-align: center;
}

.mt-3 {
  margin-top: 1rem;
}

/* Navigation */
.navbar {
  background: var(--white);
  box-shadow: var(--box-shadow);
  padding: 1rem 2rem;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary);
  text-decoration: none;
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-link {
  color: var(--dark);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: var(--primary);
}

/* Alert Messages */
.alert {
  padding: 0.8rem 1rem;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
}

.alert-danger {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    padding: 0.8rem 1rem;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
}

.alert-success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

/* Grid Layout */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.business-card {
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  padding: 1.5rem;
  transition: transform 0.3s ease;
}

.business-card:hover {
  transform: translateY(-5px);
}

.business-logo {
  max-width: 100%;
  height: auto;
  max-height: 100px;
  margin-bottom: 1rem;
}

.section-title small {
    font-size: 0.8em;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
  .grid {
    grid-template-columns: 1fr;
  }
}