* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  background: #f4f4f4;
  -webkit-tap-highlight-color: transparent;
}

#feed {
  min-height: 100vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-top: 60px; /* space for top bar */
}

.feed-card {
  position: relative;
  width: 92%;
  height: auto;
  margin: 16px auto;
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.feed-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px 18px 80px;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.9) 0%,
    rgba(0,0,0,0.6) 40%,
    rgba(0,0,0,0.2) 70%,
    rgba(0,0,0,0) 100%
  );
  color: #fff;
}

.overlay h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 600;
}

.action-btn:active {
  transform: scale(0.9);
}

.action-btn svg {
  width: 22px;
  height: 22px;
  fill: #fff;
}

.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 14px 18px;
  background: #fff;
  color: #000;
  font-weight: 600;
  font-size: 18px;
  border-bottom: 1px solid #e5e5e5;
  z-index: 10;
}

.feed-card {
  width: 92%;
  margin: 20px auto;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 18px rgba(0,0,0,0.08);
}

/* Header */

.post-header {
  padding: 16px 18px;
}

.post-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #000;
}

/* Image */

.post-image img {
  width: 100%;
  display: block;
}

/* Caption */

.post-body {
  padding: 14px 18px 20px;
}

.post-body p {
  font-size: 14px;
  color: #111;
  line-height: 1.4;
  margin-bottom: 12px;
}

/* Action Row */

.action-row {
  display: flex;
  gap: 18px;
}

.action-btn {
  width: 28px;
  height: 28px;
  cursor: pointer;
}

.action-btn svg {
  width: 100%;
  height: 100%;
  fill: #000;
}

.bottom-nav {
  position: fixed;
  bottom: 18px;               /* lifts it off bottom */
  left: 50%;
  transform: translateX(-50%);
  width: 86%;                  /* not full width */
  height: 60px;
  background: #fff;
  border-radius: 22px;         /* rounded edges */
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 100;
  padding: 0 10px;
}

.nav-item {
  width: 28px;
  height: 28px;
  opacity: 0.6;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-item.active {
  opacity: 1;
}

.nav-item svg {
  width: 100%;
  height: 100%;
  fill: #000;
}

.nav-item:active {
  transform: scale(0.9);
}
