/* 🌐 Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
}

body {
  background-color: #f5f8fa;
  color: #222;
  line-height: 1.6;
  font-size: 15px;
}

a {
  text-decoration: none;
  color: inherit;
}

/* 🧾  */
.top-message {
  text-align: center;
  padding: 8px 12px;
  background-color: #eaf6ff;
  border-bottom: 1px solid #ccc;
}

.top-message .tip {
  font-size: 13px;
  color: #555;
  margin-bottom: 4px;
}

.top-message .made {
  font-size: 12px;
  color: #888;
  font-style: italic;
}

/* 🎯 Header */
header {
  background: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid #ddd;
  position: sticky;
  top: 0;
  z-index: 999;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo {
  height: 40px;
  width: 40px;
  border-radius: 8px;
}

header h1 {
  font-size: 18px;
  font-weight: bold;
}

header p {
  font-size: 12px;
  color: #666;
}

/* 👛  */
.wallet-area {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  flex-wrap: wrap;
}

.wallet-area button {
  padding: 6px 12px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s ease;
}

.wallet-area button:hover {
  background: #0056b3;
}

.wallet-area span {
  font-family: monospace;
}

/* 💰  */
.info-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: center;
  padding: 8px 20px;
  font-size: 14px;
  background: #fffbe6;
  border-bottom: 1px solid #ffe58f;
}

.trade-link,
.guide-link {
  color: #d35400;
  font-weight: bold;
}

.trade-link:hover,
.guide-link:hover {
  text-decoration: underline;
}

/* 📂  */
nav {
  display: flex;
  gap: 10px;
  justify-content: center;
  background: #ffffff;
  padding: 10px;
  border-bottom: 1px solid #eee;
  flex-wrap: wrap;
}

.nav-btn {
  background: transparent;
  border: none;
  padding: 6px 10px;
  font-weight: bold;
  font-size: 15px;
  color: #007bff;
  cursor: pointer;
  transition: color 0.2s ease;
}

.nav-btn:hover {
  color: #0056b3;
  text-decoration: underline;
}



/* 📰  */
main {
  max-width: 720px;
  margin: 20px auto;
  padding: 0 15px;
}

/* 🧾  */
.post {
  background: #fff;
  padding: 15px;
  border-radius: 12px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.post .title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 5px;
}

.post .author {
  font-size: 13px;
  color: #555;
  margin-bottom: 10px;
  word-break: break-word;
}

.post .content {
  margin-bottom: 10px;
}

.post img {
  max-width: 100%;
  border-radius: 8px;
  margin-top: 10px;
}

.post .metrics {
  font-size: 13px;
  color: #777;
  margin-top: 5px;
}

/* 🎯  */
.post .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.post .actions button {
  background: none;
  border: none;
  font-weight: bold;
  font-size: 14px;
  color: #007bff;
  cursor: pointer;
  padding: 4px 8px;
  transition: color 0.2s ease;
}

.post .actions button:hover {
  color: #0056b3;
  text-decoration: underline;
}

/* 📝  */
form {
  background: white;
  padding: 15px;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  margin-bottom: 20px;
}

form input,
form textarea {
  width: 100%;
  margin-top: 6px;
  margin-bottom: 12px;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
}

form textarea {
  resize: vertical;
  min-height: 80px;
}

form label {
  font-weight: bold;
  font-size: 14px;
}

form button {
  padding: 8px 16px;
  background: #28a745;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s ease;
}

form button:hover {
  background: #1e7e34;
}

/* 💬 Bình luận */
.comments {
  background: #f9f9f9;
  padding: 10px;
  border-radius: 8px;
  margin-top: 10px;
}

.comments h4 {
  margin-bottom: 10px;
  font-size: 14px;
}

.comments p {
  margin: 6px 0;
  font-size: 14px;
}

/* 💡  */
.tip {
  text-align: center;
  font-size: 13px;
  color: #777;
  margin: 20px;
}

/* ⬇️  */
main button {
  padding: 8px 16px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s ease;
}

main button:hover {
  background: #0056b3;
}

/* 📍 Footer */
footer {
  text-align: center;
  padding: 20px;
  font-size: 13px;
  color: #888;
}

/* ✅ Responsive  */
@media (max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .wallet-area {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .info-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  nav {
    flex-direction: column;
    align-items: center;
  }

  .nav-btn,
  .wallet-area button,
  form button,
  main button {
    width: 100%;
    text-align: center;
  }

  form input,
  form textarea {
    font-size: 15px;
  }
}

/* 📋  */
.wallet-area button[title="Copy"],
.post .author button {
  padding: 2px 6px;
  background: #ddd;
  color: #333;
  font-size: 12px;
  margin-left: 4px;
  border-radius: 4px;
  cursor: pointer;
  border: none;
  transition: background 0.2s ease;
}

.wallet-area button[title="Copy"]:hover,
.post .author button:hover {
  background: #bbb;
}

/* 🔍  */
#searchInput {
  padding: 6px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 13px;
  min-width: 180px;
}

/* 🔘  */
nav form button {
  padding: 6px 10px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  margin-left: 6px;
}

nav form button:hover {
  background: #0056b3;
}

/* ==== Sticky Bottom Nav (VinSocial) ==== */
:root {
  --bn-bg: #ffffff;         /* */
  --bn-text: #1161ff;       /*  */
  --bn-text-hover: #0a49bf; /*  */
  --bn-shadow: 0 -6px 20px rgba(0,0,0,0.06);
  --bn-border: rgba(0,0,0,0.06);
}

body {
  /* */
  padding-bottom: 76px; /*  */
}

/*  */
.bottom-nav {
  position: sticky;
  position: -webkit-sticky;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--bn-bg);
  border-top: 1px solid var(--bn-border);
  box-shadow: var(--bn-shadow);
  padding: 10px env(safe-area-inset-right) calc(10px + env(safe-area-inset-bottom)) env(safe-area-inset-left);
}

/*  */
.bn-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;              /*  */
  gap: 10px;
  align-items: center;
  justify-content: center;      /*  */
}

/*  */
.bn-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  min-height: 40px;
  border-radius: 10px;
  background: #fff;             /*  */
  color: var(--bn-text);        /* */
  font-weight: 700;
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  border: 1px solid var(--bn-border);
  transition: transform .06s ease, box-shadow .2s ease, color .2s ease;
  box-shadow: 0 1px 0 rgba(0,0,0,0.04);
  white-space: nowrap;          /* */
}

.bn-link:hover,
.bn-link:focus-visible {
  color: var(--bn-text-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(17,97,255,0.12);
  outline: none;
}

/*  */
@media (max-width: 360px) {
  .bn-link {
    padding: 9px 12px;
    font-size: 13px;
  }
}

/* Desktop:  */
@media (min-width: 992px) {
  .bn-container {
    gap: 12px;
  }
  .bn-link {
    padding: 10px 16px;
    font-size: 15px;
  }
}
