/* Japanese-inspired Design System */
:root {
  --aka-red: #DC143C;
  --sumi-black: #1B1B1B;
  --rice-paper: #F7E7CE;
  --wasabi-green: #228B22;
  --bg-white: #FAFAFA;
  --shadow-light: 0 2px 4px rgba(0,0,0,0.1);
  --shadow-medium: 0 4px 8px rgba(0,0,0,0.15);
  --border-radius: 4px;
  --transition: all 0.3s ease;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg-white);
  color: var(--sumi-black);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
}

a {
  color: var(--aka-red);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  opacity: 0.8;
}

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

/* Header */
header {
  background: white;
  box-shadow: var(--shadow-light);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--sumi-black);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--aka-red);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
}

nav a {
  color: var(--sumi-black);
  font-weight: 500;
  padding: 0.5rem 0;
  border-bottom: 2px solid transparent;
}

nav a:hover, nav a.active {
  border-bottom-color: var(--aka-red);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--rice-paper) 0%, white 100%);
  padding: 2rem 0;
  text-align: center;
  border-bottom: 1px solid rgba(220, 20, 60, 0.1);
}

.hero h1 {
  color: var(--sumi-black);
  margin-bottom: 0.75rem;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 1rem;
}

/* Search Bar */
.search-container {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
}

.search-bar {
  width: 100%;
  padding: 1rem 3rem 1rem 1rem;
  border: 2px solid var(--aka-red);
  border-radius: 50px;
  font-size: 1rem;
  outline: none;
  transition: var(--transition);
}

.search-bar:focus {
  box-shadow: 0 0 0 3px rgba(220, 20, 60, 0.1);
}

.search-btn {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--aka-red);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  cursor: pointer;
  transition: var(--transition);
}

.search-btn:hover {
  background: #B91C3C;
}

/* Map Container */
#map {
  height: 500px;
  width: 100%;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-medium);
  margin: 2rem 0;
}

@media (max-width: 768px) {
  #map {
    height: 400px;
  }
}

/* Restaurant Cards */
.restaurant-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.restaurant-card {
  background: white;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  padding: 1.5rem;
  transition: var(--transition);
  border: 1px solid #eee;
}

.restaurant-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.restaurant-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 1rem;
}

.restaurant-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--sumi-black);
  margin: 0;
}

.restaurant-rating {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: #FFB400;
}

.price-badge {
  color: var(--wasabi-green);
  font-weight: 600;
}

.restaurant-info {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.6;
}

.restaurant-address {
  display: flex;
  align-items: start;
  gap: 0.5rem;
  margin: 0.5rem 0;
}

.restaurant-hours {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.5rem 0;
}

.open-badge {
  background: var(--wasabi-green);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
}

.closed-badge {
  background: #dc3545;
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
}

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

.city-card {
  background: white;
  border: 2px solid var(--aka-red);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  text-align: center;
  transition: var(--transition);
  cursor: pointer;
}

.city-card:hover {
  background: var(--aka-red);
  color: white;
}

.city-card:hover a {
  color: white;
}

.city-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.city-count {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Filters */
.filters {
  background: white;
  border-radius: var(--border-radius);
  padding: 0.75rem 1rem;
  box-shadow: var(--shadow-light);
  margin-bottom: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
}

.filter-label {
  font-weight: 600;
  font-size: 0.9rem;
  margin: 0;
  white-space: nowrap;
}

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

.filter-btn {
  padding: 0.4rem 0.8rem;
  border: 1px solid #ddd;
  background: white;
  border-radius: 20px;
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.85rem;
}

.filter-btn:hover {
  border-color: var(--aka-red);
}

.filter-btn.active {
  background: var(--aka-red);
  color: white;
  border-color: var(--aka-red);
}

/* Footer */
footer {
  background: var(--sumi-black);
  color: white;
  padding: 3rem 0 1rem;
  margin-top: 4rem;
}

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

.footer-section h4 {
  margin-bottom: 1rem;
}

.footer-section ul {
  list-style: none;
}

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

.footer-section a {
  color: #ccc;
}

.footer-section a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid #333;
  color: #999;
  font-size: 0.9rem;
}

/* Blog Styles */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.blog-card {
  background: white;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-light);
  transition: var(--transition);
}

.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.blog-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: var(--rice-paper);
}

.blog-content {
  padding: 1.5rem;
}

.blog-meta {
  color: #666;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.blog-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--sumi-black);
}

.blog-excerpt {
  color: #666;
  line-height: 1.6;
}

/* Loading Spinner */
.spinner {
  border: 3px solid #f3f3f3;
  border-top: 3px solid var(--aka-red);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 2rem auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-muted { color: #666; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.pt-4 { padding-top: 2rem; }
.pb-4 { padding-bottom: 2rem; }

/* Mobile Responsive */
@media (max-width: 768px) {
  .header-inner {
    flex-direction: column;
    gap: 1rem;
  }

  nav ul {
    gap: 1rem;
    font-size: 0.9rem;
  }

  .hero {
    padding: 1.5rem 0;
  }

  .hero h1 {
    font-size: 1.75rem;
  }

  .filters {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .filter-group {
    flex-wrap: wrap;
  }

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

  .city-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}