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

:root {
  --bg:         #0f1117;
  --card:       #1e2433;
  --accent:     #68d391;
  --text:       #e2e8f0;
  --text-muted: #718096;
  --border:     #2d3748;
}

body {
  background-color: var(--bg);
  background-image:
    linear-gradient(rgba(15,17,23,.65), rgba(15,17,23,.65)),
    url('../img/istanbul-map.jpg');
  background-size: auto, cover;
  background-position: center, center;
  background-attachment: fixed, fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
  min-height: 100vh;
}

/* ── Hero ── */
.hero {
  position: relative;
  width: 100%;
  height: 60vh;
  min-height: 320px;
  max-height: 500px;
  overflow: hidden;
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(15,17,23,.3) 0%, rgba(15,17,23,.8) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2rem;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  color: #fff;
  letter-spacing: -.02em;
}

.hero-subtitle {
  font-size: 1rem;
  color: rgba(255,255,255,.65);
  margin-top: .25rem;
}

/* ── Feed ── */
.feed {
  max-width: 720px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* ── Card ── */
.card {
  background: var(--card);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.card-photo {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  display: block;
  cursor: pointer;
}

.card-photos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}

.card-photo-thumb {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  cursor: pointer;
  transition: opacity .15s;
}
.card-photo-thumb:hover { opacity: .85; }

/* odd last photo spans both columns */
.card-photos .card-photo-thumb:last-child:nth-child(odd) {
  grid-column: span 2;
  height: 220px;
}

/* ── Lightbox ── */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .92);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.lightbox.open { display: flex; }

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,.15);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
  backdrop-filter: blur(4px);
}
.lightbox-close:hover { background: rgba(255,255,255,.25); }

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 6px;
  cursor: default;
  box-shadow: 0 8px 40px rgba(0,0,0,.6);
}

@media (max-width: 480px) {
  .lightbox img {
    max-width: 100vw;
    max-height: 90vh;
    border-radius: 0;
  }
  .lightbox-close {
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    font-size: 20px;
  }
}

.card-body {
  padding: 1rem 1.25rem;
}

.card-text {
  font-size: 1rem;
  color: var(--text);
  line-height: 1.6;
  white-space: pre-wrap;
}

.card-meta {
  margin-bottom: .6rem;
  display: flex;
  align-items: center;
  gap: .5rem;
}

.card-meta-text {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .3rem;
}

.card-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.card-author { font-size: .85rem; font-weight: 600; }
.card-phrase { font-size: .85rem; color: var(--accent); font-style: italic; }
.card-date   { font-size: .8rem;  color: var(--text-muted); white-space: nowrap; }

/* ── States ── */
.empty {
  text-align: center;
  color: var(--text-muted);
  padding: 3rem 0;
}

.status {
  text-align: center;
  font-size: .75rem;
  color: var(--text-muted);
  padding-bottom: 1.5rem;
}

@media (max-width: 480px) {
  .hero-overlay { padding: 1.25rem; }
  .feed { padding: 1rem .75rem 3rem; }
}
