body, html {
    color: #1b1b1b !important;
    text-shadow: 0 1px 2px rgba(255,255,255,0.12);
}

body {
  background: url('pietro-de-grandi-Q5dMq3cKqec-unsplash.jpg') no-repeat center center fixed !important;
  background-size: cover !important;
  background-attachment: fixed !important;
  min-height: 100vh;
  min-width: 100vw;
  font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
  color: #222;
  margin: 0;
  padding: 0;
}

main.container, .container, .login-container, .msg-container, .msg-sidebar, .msg-main, .user-greeting, .post-card, .msg-header, .msg-form, .msg-bubble, .msg-contact, .notif-friend-req, #notifMenu, #userSearchDropdown {
    color: #1b1b1b !important;
    background: rgba(255,255,255,0.97) !important;
    box-shadow: 0 2px 16px rgba(44,62,80,0.10);
}

header {
  text-align: center;
  margin-bottom: 2rem;
}

h1, h2, h3, h4, h5, h6, label, .post-title, .user-greeting strong, .msg-header .name, .msg-contact .name, .notif-friend-req span, .post-meta, .post-author, .post-category {
    color: #1b4332 !important;
    text-shadow: 0 1px 2px rgba(255,255,255,0.10);
}

h1 {
  color: #2d6a4f;
  font-size: 2.5rem;
  margin-bottom: 0.2em;
}

h2 {
  color: #40916c;
  margin-top: 1.5em;
  margin-bottom: 0.7em;
}

section {
  margin-bottom: 2rem;
}

/* User greeting and actions */
.user-greeting {
  background: #e9f5ee;
  padding: 1.2rem 1rem;
  border-radius: 8px;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.user-greeting strong {
  color: #1b4332;
}

/* Post form */
form textarea {
  width: 100%;
  border: 1px solid #b7e4c7;
  border-radius: 6px;
  padding: 0.8rem;
  font-size: 1rem;
  resize: vertical;
  background: #f8fafc;
  margin-bottom: 0.5rem;
  color: #000;
}
form button {
  background: #40916c;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 0.6rem 1.5rem;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s;
}
form button:hover {
  background: #26734d;
}

/* Resize topic and post text boxes for better fit and background visibility */
form[action="index.php"] input[name="post_title"] {
    max-width: 600px;
    margin: 0 auto 0.7em auto;
    display: block;
}
form[action="index.php"] textarea[name="post_text"] {
    max-width: 600px;
    margin: 0 auto 0.7em auto;
    display: block;
}
form[action="index.php"] input[name="category"] {
    max-width: 220px;
    margin: 0 auto 0.7em auto;
    display: block;
}
form[action="index.php"] button[type="submit"] {
    max-width: 220px;
    margin: 0 auto;
    display: block;
}
@media (max-width: 700px) {
    form[action="index.php"] input[name="post_title"],
    form[action="index.php"] textarea[name="post_text"] {
        max-width: 98vw;
    }
}

/* Forum posts */
article {
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 1.2rem 1rem;
  margin-bottom: 1.2rem;
  box-shadow: 0 1px 4px rgba(44, 62, 80, 0.04);
}
article header {
  font-weight: bold;
  color: #1b4332;
  margin-bottom: 0.3em;
  font-size: 1.1em;
}
article p {
  margin: 0.5em 0 0 0;
  color: #000;
}

/* Links */
a, a:visited, a:active {
    color: #26734d !important;
    text-shadow: none;
}
a:hover {
  color: #40916c !important;
}

/* Placeholder for no posts */
.no-posts {
  color: #888;
  text-align: center;
  font-style: italic;
  margin: 2em 0;
}

/* --- Responsive & Modern Enhancements for Social Eagle --- */
body {
  font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
  background: #f4f6fb;
  margin: 0;
  padding: 0;
}
.container {
  max-width: 700px;
  margin: 2rem auto;
  background: none !important;
  box-shadow: none !important;
  border: none !important;
  padding: 0 !important;
}
@media (max-width: 600px) {
  .container {
    padding: 1rem 0.5rem;
    max-width: 99vw;
  }
  h1, .landing-title {
    font-size: 1.5rem !important;
  }
  .post-card {
    padding: 1rem 0.5rem !important;
  }
  .post-header {
    flex-direction: column !important;
    align-items: flex-start !important;
  }
  .post-avatar {
    margin-bottom: 0.5em !important;
  }
  .user-greeting {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.7em;
  }
  .landing-container {
    padding: 1.5rem 0.5rem 1.2rem 0.5rem !important;
    max-width: 98vw !important;
  }
  .landing-logo {
    width: 60px !important;
    height: 60px !important;
  }
}
/* Make notification bell and dropdown responsive */
#notif-bell {
  min-width: 44px;
}
#notifMenu {
  min-width: 220px;
  max-width: 98vw;
}
/* Responsive message/chat sidebar */
@media (max-width: 700px) {
  .messages-sidebar {
    min-width: 90px !important;
    max-width: 40vw !important;
    font-size: 0.98em !important;
  }
  .chat-window {
    padding: 0.7em 0.2em !important;
  }
}
/* Responsive message input */
@media (max-width: 600px) {
  .message-input {
    min-height: 44px !important;
    font-size: 1em !important;
  }
}
/* General button and input tweaks for mobile */
input, textarea, button {
  font-size: 1em;
  border-radius: 6px;
}

/* --- LANDING PAGE --- */
.landing-container {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 2px 24px rgba(44,62,80,0.13);
  max-width: 420px;
  width: 100%;
  padding: 2.5rem 2rem 2.2rem 2rem;
  text-align: center;
}
.landing-logo {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 1.2rem;
  box-shadow: 0 2px 8px rgba(44,62,80,0.10);
  background: #fff;
}
.landing-title {
  color: #2d6a4f;
  font-size: 2.2rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  letter-spacing: 1px;
}
.landing-desc {
  color: #555;
  font-size: 1.13em;
  margin-bottom: 2.2rem;
}
.landing-btns {
  display: flex;
  flex-direction: column;
  gap: 1.1em;
  margin-bottom: 1.2em;
}
.landing-btns a {
  background: #40916c;
  color: #fff;
  border-radius: 7px;
  padding: 0.9em 0;
  font-size: 1.1em;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.18s;
}
.landing-btns a:hover {
  background: #26734d;
}
.landing-btns a:last-child {
  background: #fff;
  color: #40916c;
  border: 1.5px solid #40916c;
}
.landing-footer {
  color: #888;
  font-size: 0.98em;
  margin-top: 1.5em;
}

/* --- SHARED MOBILE STYLES --- */
@media (max-width: 600px) {
  .container {
    padding: 1rem 0.5rem !important;
    max-width: 99vw !important;
  }
  h1, .landing-title {
    font-size: 1.5rem !important;
  }
  .post-card, .user-greeting, .landing-container {
    padding: 1rem 0.5rem !important;
  }
  .post-header {
    flex-direction: column !important;
    align-items: flex-start !important;
  }
  .post-avatar, .landing-logo {
    width: 44px !important;
    height: 44px !important;
    margin-bottom: 0.5em !important;
  }
  .landing-logo {
    width: 60px !important;
    height: 60px !important;
  }
  .landing-btns a {
    font-size: 1em !important;
    padding: 0.7em 0 !important;
  }
  .landing-desc {
    font-size: 1em !important;
  }
}

/* --- BUTTONS & FORMS --- */
button, .contrast, .landing-btns a {
  border-radius: 6px;
  font-weight: 500;
  transition: background 0.18s, color 0.18s;
}
button:hover, .contrast:hover, .landing-btns a:hover {
  filter: brightness(0.95);
}

/* --- NOTIFICATION BADGE --- */
#notifBadge {
  min-width: 22px;
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95em;
  font-weight: bold;
  background: #dc3545;
  color: #fff;
  border-radius: 50%;
  padding: 2px 7px;
  position: absolute;
  top: -8px;
  right: -8px;
  z-index: 20;
}

/* --- POST FORM & CARDS --- */
.post-card {
  margin-bottom: 1.5rem;
  border-radius: 14px;
  box-shadow: 0 2px 8px rgba(44,62,80,0.06);
  padding: 1.2rem 1.2rem 1rem 1.2rem;
  background: #fff;
}
@media (max-width: 600px) {
  .post-card {
    padding: 1rem 0.5rem !important;
  }
}

/* --- USER GREETING --- */
.user-greeting {
  background: #e9f5ee;
  padding: 1.2rem 1rem;
  border-radius: 8px;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
@media (max-width: 600px) {
  .user-greeting {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.7em;
  }
}

/* --- MESSAGES PAGE --- */
.messages-sidebar, .messages-chat {
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(44,62,80,0.07);
  background: #fff;
}
@media (max-width: 600px) {
  .messages-sidebar, .messages-chat {
    border-radius: 8px !important;
    box-shadow: none !important;
    padding: 0.5em !important;
  }
}

/* For notification dropdown and search dropdown */
#notifMenu, #userSearchDropdown {
    background: rgba(255,255,255,0.99) !important;
    color: #1b1b1b !important;
    border: 1px solid #e0e0e0 !important;
}

/* For error/info messages */
.no-posts, #noPendingMsg, .login-container em {
    color: #dc3545 !important;
    background: rgba(255,255,255,0.92) !important;
    font-weight: 500;
    border-radius: 6px;
    padding: 0.5em 1em;
}

/* --- Message Box Enhancements --- */
.msg-form textarea {
            width: 100%;
            min-height: 180px;
            max-width: 600px;
            margin: 0 auto 0.7em auto;
            display: block;
            border-radius: 8px;
            border: 1.5px solid #b7e4c7;
            padding: 1.1em 3.5em 1.1em 1.1em;
            font-size: 1.15em;
            resize: vertical;
        }
        .msg-form {
            max-width: 600px;
            margin: 0 auto;
            position: relative;
        }
        .msg-form .msg-upload-icons {
            position: absolute;
            bottom: 28px;
            right: 18px;
            z-index: 2;
            gap: 0.2em;
            display: flex;
        }
        .msg-form button[type="submit"] {
    max-width: 220px;
    margin: 0.7em auto 0 auto;
    display: block;
}

/* User search dropdown styles */
.user-search-dropdown {
    position: absolute;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(44,62,80,0.13);
    min-width: 260px;
    max-width: 90vw;
    z-index: 100;
    display: none;
}
.user-search-item {
    display: flex;
    align-items: center;
    padding: 0.5em 0.7em;
    cursor: pointer;
}
.user-search-item:hover {
  background: #e9f5ee;
}
.user-search-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #e9f5ee;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1em;
    color: #40916c;
    font-weight: bold;
    margin-right: 0.7em;
    overflow: hidden;
}
.user-search-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}
