/* Romaine Healthy — styles */

/* ---- Base / Reset ---- */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Figtree', 'Helvetica Neue', system-ui, sans-serif;
  font-weight: 400;
  background: #f8f9fa;
  color: #212529;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

/* ---- Site Header ---- */
.site-header {
  background: #FFFFFF;
  padding: 16px 0;
  border-bottom: 1px solid #eeeeee;
  margin-bottom: 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-title {
  font-family: 'Figtree', system-ui, sans-serif;
  font-weight: 700;
  font-size: 22px;
  margin: 0;
  color: #222222;
}

.site-subtitle {
  color: #6c757d;
  font-size: 14px;
  margin: 0;
}

/* ---- Search ---- */
.restaurant-search-wrapper {
  background: #FFFFFF;
  padding: 20px 0;
  border-bottom: 1px solid #eeeeee;
}

@media (max-width: 991px) {
  .restaurant-search-wrapper { padding: 15px 0; }
}

.search-wrapper {
  position: relative;
  max-width: 480px;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #6c757d;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.search-input {
  width: 100%;
  height: 44px;
  border-radius: 8px;
  border: 1px solid #cccccc;
  padding: 0 16px 0 40px;
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 15px;
  color: #212529;
  outline: none;
  transition: border-color 150ms ease;
  background: #FFFFFF;
}

.search-input:focus {
  border-color: #222222;
}

.search-input::placeholder {
  color: #999999;
}

/* ---- Filter Bar ---- */
.filter-bar {
  background: #FFFFFF;
  padding: 12px 0;
  border-bottom: 1px solid #eeeeee;
}

.filter-bar__content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.filter-bar__sort {
  margin-right: 4px;
}

/* ---- Price Dropdown ---- */
.price-dropdown {
  position: relative;
  display: inline-block;
}

.price-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.price-dropdown__menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 100;
  min-width: 220px;
  margin-top: 4px;
  background: #FFFFFF;
  border: 1px solid #eeeeee;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  padding: 8px 0;
}

.price-dropdown.open .price-dropdown__menu {
  display: block;
}

.price-dropdown__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.price-option {
  display: block;
  width: 100%;
  padding: 8px 16px;
  border: none;
  background: none;
  text-align: left;
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 14px;
  color: #4d4d4d;
  cursor: pointer;
}

.price-option:hover {
  background: #f6f6f6;
}

.price-option.active {
  font-weight: 600;
  color: #222222;
}

@media (max-width: 991px) {
  .filter-bar { padding: 10px 0; }
}

/* ---- Buttons ---- */
.btn {
  font-family: 'Figtree', 'Helvetica Neue', system-ui, sans-serif;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.btn-sm {
  font-size: 14px;
  padding: 6px 10px;
  line-height: 1.5;
}

.btn-black-border {
  background: #FFFFFF;
  border: solid 1px #cccccc;
  color: #4d4d4d;
  font-family: 'Figtree', 'Helvetica Neue', system-ui, sans-serif;
  transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}

.btn-round {
  border-radius: 8px;
}

.btn-black-border:hover {
  background: #f6f6f6;
  border-color: #999999;
}

.btn-black-border.active {
  background: #222222;
  border-color: #222222;
  color: #FFFFFF;
}

/* ---- Results Section ---- */
.results-section {
  padding: 24px 0;
}

/* ---- Restaurant List ---- */
.restaurant-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 992px) {
  .restaurant-list { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 576px) {
  .restaurant-list { grid-template-columns: 1fr; }
}

/* ---- Restaurant Card ---- */
.restaurant-card {
  background: #FFFFFF;
  border-radius: 8px;
  overflow: hidden;
  transition: transform 150ms ease, box-shadow 150ms ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

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

.card-image {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  position: relative;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-edit-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #4d4d4d;
  opacity: 0;
  transition: opacity 200ms ease;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}

.photo-attribution {
  text-align: right;
  font-size: 10px;
  color: #999999;
  margin-bottom: 4px;
}

.photo-attribution a {
  color: #999999;
  text-decoration: none;
}

.photo-attribution a:hover {
  color: #4d4d4d;
}

.card-image:hover .photo-edit-btn {
  opacity: 1;
}

.photo-edit-btn:hover {
  background: #FFFFFF;
  color: #222222;
}

.card-content {
  padding: 12px 16px 16px;
}

/* ---- Card Content ---- */
.restaurant-name {
  font-family: 'Figtree', system-ui, sans-serif;
  font-weight: 600;
  font-size: 18px;
  color: #222222;
  margin: 0 0 6px;
  line-height: 1.3;
}

.restaurant-badges {
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.restaurant-meta {
  font-size: 14px;
  color: #6c757d;
  margin: 0 0 2px;
}

.restaurant-address {
  font-size: 13px;
  color: #999999;
  margin: 0;
}

/* ---- Badge Icons ---- */
.distinction-icon {
  display: inline-block;
  margin-right: 1px;
  vertical-align: middle;
}

.award-icon {
  display: block;
  height: 18px;
  width: auto;
  max-width: 28px;
  object-fit: contain;
}

.templeton-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 12px;
  vertical-align: middle;
}

.badge-link {
  text-decoration: none;
  display: inline-block;
  vertical-align: middle;
}

/* ---- No Results ---- */
.no-results {
  text-align: center;
  color: #6c757d;
  padding: 40px;
  font-size: 16px;
  display: none;
}

/* ---- Photo Edit Modal ---- */
.photo-modal__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 999;
}

.photo-modal__content {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #FFFFFF;
  border-radius: 12px;
  padding: 24px;
  width: 420px;
  max-width: 90vw;
  z-index: 1000;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}

.photo-modal__title {
  font-family: 'Figtree', system-ui, sans-serif;
  font-weight: 600;
  font-size: 18px;
  margin: 0 0 4px;
}

.photo-modal__subtitle {
  font-size: 14px;
  color: #6c757d;
  margin: 0 0 16px;
}

.photo-modal__input {
  width: 100%;
  height: 40px;
  border-radius: 8px;
  border: 1px solid #cccccc;
  padding: 0 12px;
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 14px;
  outline: none;
}

.photo-modal__input:focus {
  border-color: #222222;
}

.photo-modal__link {
  margin: 8px 0 0;
  font-size: 13px;
}

.photo-modal__link a {
  color: #4d4d4d;
  text-decoration: underline;
}

.photo-modal__link a:hover {
  color: #222222;
}

.photo-modal__label {
  display: block;
  font-size: 13px;
  color: #6c757d;
  margin: 12px 0 4px;
}

.photo-modal__tabs {
  display: flex;
  gap: 0;
  margin-bottom: 12px;
  border-bottom: 1px solid #eeeeee;
}

.photo-tab {
  padding: 8px 16px;
  border: none;
  background: none;
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 14px;
  color: #6c757d;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.photo-tab.active {
  color: #222222;
  border-bottom-color: #222222;
  font-weight: 600;
}

.photo-upload-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  border: 2px dashed #cccccc;
  border-radius: 8px;
  cursor: pointer;
  color: #999999;
  font-size: 14px;
  transition: border-color 150ms ease;
}

.photo-upload-area:hover {
  border-color: #222222;
  color: #222222;
}

.photo-upload-area svg {
  stroke: currentColor;
}

.photo-modal__preview {
  margin-top: 12px;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: #f6f6f6;
}

.photo-modal__preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
}
