/* ===== VARIABLES ===== */
:root {
  --dark:        #0f172a;
  --dark-mid:    #1e293b;
  --dark-light:  #334155;
  --accent:      #0ea5e9;
  --accent-dark: #0284c7;
  --accent-glow: rgba(14, 165, 233, 0.15);
  --bg:          #f1f5f9;
  --white:       #ffffff;
  --text:        #1e293b;
  --text-muted:  #64748b;
  --border:      #e2e8f0;
  --radius:      12px;
  --shadow:      0 4px 20px rgba(0,0,0,0.08);
  --shadow-lg:   0 8px 40px rgba(0,0,0,0.14);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
a { text-decoration: none; color: inherit; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 64px;
  background: var(--dark);
  border-bottom: 1px solid var(--dark-light);
  z-index: 200;
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 24px;
}

.nav-logo img {
  height: 36px;
  display: block;
  filter: brightness(0) invert(1);
  opacity: 0.95;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: 32px;
  flex: 1;
}

.nav-link {
  color: #94a3b8;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  background: var(--dark-mid);
  color: #ffffff;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.nav-user {
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 500;
}

.badge-admin {
  background: #f59e0b;
  color: #1a1a1a;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 20px;
  margin-left: 5px;
  vertical-align: middle;
  letter-spacing: 0.5px;
}

.btn-nav {
  background: var(--accent);
  color: white;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 8px;
  transition: background 0.15s, transform 0.1s;
  border: none;
  cursor: pointer;
  white-space: nowrap;
}

.btn-nav:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-ghost {
  color: #94a3b8;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
  background: none;
  border: none;
  cursor: pointer;
}

.btn-ghost:hover { background: var(--dark-mid); color: white; }

.btn-outline {
  color: #94a3b8;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 8px;
  border: 1px solid var(--dark-light);
  background: none;
  transition: border-color 0.15s, color 0.15s;
}

.btn-outline:hover { border-color: var(--accent); color: var(--accent); }

/* ===== MAIN CONTAINER ===== */
.main-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 88px 24px 48px;
}

/* ===== ALERT ===== */
.alert-success {
  background: #dcfce7;
  color: #166534;
  padding: 12px 18px;
  border-radius: var(--radius);
  margin-bottom: 24px;
  font-size: 14px;
  border: 1px solid #bbf7d0;
}

/* ===== FEED HEADER ===== */
.feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.feed-header-left h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.3px;
}

.feed-header-left p {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ===== POSTS GRID ===== */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  list-style: none;
}

/* ===== CARD ===== */
.post-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-image-wrap {
  position: relative;
  overflow: hidden;
  height: 200px;
}

.card-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.post-card:hover .card-image-wrap img { transform: scale(1.04); }

.card-city-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-body {
  padding: 14px 16px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.card-category {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--accent-glow);
  color: var(--accent-dark);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
}

.card-stats {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.card-author {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

.card-author-avatar {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0ea5e9, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; color: white;
  text-transform: uppercase; flex-shrink: 0;
}

.card-date {
  font-size: 11px;
  color: #94a3b8;
}

/* ===== EMPTY STATE ===== */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--text-muted);
}

.empty-state p { font-size: 16px; margin-bottom: 16px; }

/* ===== PAGINATION ===== */
.pagination {
  margin-top: 36px;
  display: flex;
  justify-content: center;
}

.pagination nav {
  position: static; background: none; border: none;
  padding: 0; height: auto;
}

/* ===== POST DETAIL ===== */
.post-detail-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--white);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: box-shadow 0.15s, transform 0.1s;
}

.btn-back:hover { box-shadow: var(--shadow-lg); transform: translateY(-1px); }

.btn-edit {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--accent);
  color: white;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  transition: background 0.15s, transform 0.1s;
}

.btn-edit:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-delete {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fef2f2;
  color: #dc2626;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-delete:hover { background: #fee2e2; }

.post-detail-wrap {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  display: flex;
  min-height: 500px;
}

.post-detail-image {
  flex: 0 0 55%;
  max-width: 55%;
  background: var(--dark);
  display: flex;
  align-items: center;
}

.post-detail-image img {
  width: 100%;
  height: 100%;
  max-height: 620px;
  object-fit: cover;
  display: block;
}

.post-detail-side {
  flex: 1;
  display: flex;
  flex-direction: column;
  border-left: 1px solid var(--border);
  max-height: 620px;
  overflow: hidden;
}

.post-detail-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.post-detail-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0ea5e9, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; color: white;
  text-transform: uppercase; flex-shrink: 0;
}

.post-detail-username {
  font-weight: 700;
  font-size: 14px;
  color: var(--text);
}

.post-detail-meta {
  display: flex;
  gap: 6px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
  flex-shrink: 0;
}

.meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

.post-detail-caption {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.post-detail-caption h1 {
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: -0.2px;
}

.post-detail-caption p {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text);
}

.post-detail-comments {
  flex: 1;
  overflow-y: auto;
  padding: 12px 18px;
}

.comment-item {
  display: flex;
  gap: 9px;
  margin-bottom: 14px;
}

.comment-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0ea5e9, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: white;
  flex-shrink: 0; text-transform: uppercase;
}

.comment-body { flex: 1; }
.comment-username { font-weight: 700; font-size: 13px; color: var(--text); margin-right: 5px; }
.comment-text { font-size: 13px; color: var(--text); }
.comment-time { font-size: 11px; color: var(--text-muted); margin-top: 3px; }

.no-comments {
  text-align: center;
  color: var(--text-muted);
  padding: 30px 0;
  font-size: 14px;
}

.post-detail-actions {
  padding: 12px 18px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.like-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 22px;
  padding: 0;
  line-height: 1;
  transition: transform 0.15s;
}
.like-btn:hover { transform: scale(1.2); }

.post-detail-likes {
  font-weight: 700;
  font-size: 14px;
  color: var(--text);
  margin-top: 6px;
}

.post-detail-date {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-top: 4px;
}

.post-detail-comment-form {
  padding: 10px 18px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.post-detail-comment-form textarea {
  flex: 1;
  border: none;
  outline: none;
  resize: none;
  font-size: 14px;
  font-family: inherit;
  min-height: 20px;
  max-height: 60px;
  padding: 2px 0;
  background: transparent;
  color: var(--text);
}

.post-detail-comment-form textarea::placeholder { color: var(--text-muted); }

.post-detail-comment-form button {
  background: none;
  border: none;
  color: var(--accent);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}

.post-detail-comment-form button:hover { color: var(--accent-dark); }

.login-to-comment {
  padding: 12px 18px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.login-to-comment a { color: var(--accent); font-weight: 600; }

/* ===== FORMS ===== */
.form-page { max-width: 580px; margin: 0 auto; }

.form-page-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 24px;
  letter-spacing: -0.3px;
}

.form-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px;
}

.form-group { margin-bottom: 18px; }

.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.7px;
  margin-bottom: 6px;
}

.form-group input[type="text"],
.form-group input[type="file"],
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form-group input[type="file"] { padding: 9px 12px; cursor: pointer; }

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group textarea { resize: vertical; min-height: 110px; }

.form-group .error {
  color: #dc2626;
  font-size: 12px;
  margin-top: 5px;
  display: block;
}

.form-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 24px;
  letter-spacing: -0.3px;
}

.form-input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
select.form-input { cursor: pointer; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
}

.alert-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 13px;
  margin-bottom: 16px;
}

.btn-primary {
  width: 100%;
  padding: 11px;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); }

.form-back-link {
  text-align: center;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
}

.form-back-link a { color: var(--accent); font-weight: 600; }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 45%, #0284c7 100%);
  border-radius: var(--radius);
  padding: 64px 24px 72px;
  text-align: center;
  margin-bottom: 48px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 60% 50%, rgba(14,165,233,0.25) 0%, transparent 70%);
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 1; }

.hero-title {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -1px;
  margin-bottom: 12px;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: 16px;
  color: #94a3b8;
  margin-bottom: 36px;
}

/* ===== SEARCH ===== */
.search-wrap {
  position: relative;
  max-width: 580px;
  margin: 0 auto;
}

.search-box {
  display: flex;
  align-items: center;
  background: white;
  border-radius: 14px;
  padding: 6px 6px 6px 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  gap: 8px;
}

.search-icon { font-size: 18px; flex-shrink: 0; }

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  background: transparent;
  padding: 8px 0;
}

.search-input::placeholder { color: #94a3b8; }

.search-btn {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s;
}

.search-btn:hover { background: var(--accent-dark); }

.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0; right: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  overflow: hidden;
  z-index: 50;
}

.search-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 12px 18px;
  border: none;
  background: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.1s;
  gap: 12px;
}

.search-item:hover { background: var(--bg); }

.search-item-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.search-item-count {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.search-empty {
  padding: 16px 18px;
  font-size: 14px;
  color: var(--text-muted);
  text-align: center;
}

/* ===== SECTIONS ===== */
.section { margin-bottom: 48px; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.section-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.3px;
}

/* ===== CITIES GRID ===== */
.cities-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.city-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  display: block;
  background: var(--dark-mid);
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}

.city-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.city-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}

.city-card:hover img { transform: scale(1.05); }

.city-card-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--dark-mid), var(--accent-dark));
}

.city-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
}

.city-card-name {
  color: white;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.2px;
}

.city-card-count {
  color: rgba(255,255,255,0.75);
  font-size: 12px;
  margin-top: 2px;
}

/* ===== CITY PAGE HERO ===== */
.city-hero {
  position: relative;
  height: 240px;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 0;
  background: var(--dark);
}

.city-hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.3s;
}

.city-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.3) 100%);
}

.city-hero-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
}

.city-hero-back {
  position: absolute;
  top: 20px;
  left: 20px;
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  font-weight: 600;
  background: rgba(0,0,0,0.3);
  padding: 6px 14px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  transition: background 0.15s;
}

.city-hero-back:hover { background: rgba(0,0,0,0.55); color: white; }

.city-hero-title {
  font-size: 32px;
  font-weight: 900;
  color: white;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.city-hero-meta {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  margin-top: 4px;
}

/* ===== CATEGORY FILTER ===== */
.cat-filter-wrap {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  background: var(--white);
  color: var(--text-muted);
  border: 1.5px solid var(--border);
  transition: all 0.15s;
  white-space: nowrap;
}

.cat-pill:hover { border-color: var(--accent); color: var(--accent); }
.cat-pill.active { background: var(--accent); color: white; border-color: var(--accent); }

/* ===== PERFILES ===== */

.profile-page { max-width: 1000px; margin: 0 auto; padding: 40px 24px 60px; }

.profile-header {
  display: flex;
  gap: 32px;
  align-items: center;
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.profile-avatar-wrap { flex-shrink: 0; }

.profile-avatar {
  width: 96px; height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--border);
}

.profile-avatar-placeholder {
  width: 96px; height: 96px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  font-size: 2.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-info { flex: 1; }

.profile-name-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.profile-name  { font-size: 1.5rem; font-weight: 700; }
.profile-bio   { color: var(--text-muted); font-size: 14px; margin-bottom: 8px; line-height: 1.5; }
.profile-stats { font-size: 13px; color: var(--text-muted); }

.profile-grid { padding: 0; }

/* Avatar en navbar */
.nav-user { display: flex; align-items: center; gap: 7px; color: var(--white); font-size: 13px; font-weight: 500; }
.nav-user:hover { color: var(--accent); }

.nav-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,.3);
}

.nav-avatar-initial {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Avatar edit form */
.profile-avatar-edit {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}
.profile-avatar-edit .profile-avatar,
.profile-avatar-edit .profile-avatar-placeholder {
  width: 64px; height: 64px;
  font-size: 1.4rem;
  flex-shrink: 0;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
  .cities-grid { grid-template-columns: repeat(2, 1fr); }
  .post-detail-wrap { flex-direction: column; }
  .post-detail-image { flex: none; max-width: 100%; }
  .post-detail-image img { height: 300px; max-height: 300px; }
  .post-detail-side { border-left: none; border-top: 1px solid var(--border); max-height: none; }
  .post-detail-wrap { min-height: 0; }
}

@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .posts-grid { grid-template-columns: 1fr; gap: 16px; }
  .cities-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .profile-header { flex-direction: column; text-align: center; }
  .profile-name-row { justify-content: center; }
  .main-container { padding: 76px 16px 40px; }
  .nav-menu { display: none; }
  .form-card { padding: 20px; }
  .hero { padding: 48px 16px 56px; }
  .hero-subtitle { font-size: 14px; }
}
