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

:root {
  --bg-primary: #000000;
  --bg-secondary: #16181c;
  --bg-hover: #1e1f23;
  --border-color: #2f3336;
  --border-color-soft: rgba(47, 51, 54, 0.5);
  --text-primary: #ffffff;
  --text-secondary: #71767a;
  --accent-color: #1d9bf0;
  --accent-hover: #1a8cd8;
  --like-color: #f4212e;
  --retweet-color: #00ba7c;
  --reply-color: #1d9bf0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
}

/* Override body background for auth pages */
body:has(.auth-page-container) {
  background-color: #ffffff;
}

/* App Container - Three Column Layout */
.app-container {
  display: flex;
  max-width: 1265px;
  margin: 0 auto;
  min-height: 100vh;
}

/* Left Sidebar */
.left-sidebar {
  width: 275px;
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  padding: 0 12px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border-color);
}

.sidebar-content {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 8px 0;
}

.logo-container {
  padding: 12px;
  margin-bottom: 4px;
}

.logo-link {
  display: inline-block;
  padding: 12px;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.logo-link:hover {
  background-color: var(--bg-hover);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 12px;
  border-radius: 9999px;
  text-decoration: none;
  color: var(--text-primary);
  font-size: 20px;
  font-weight: 400;
  transition: background-color 0.2s;
  position: relative;
}

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

.nav-item.active {
  font-weight: 700;
  color: var(--text-primary);
}

.nav-item.active .nav-icon {
  color: var(--text-primary);
}

.nav-icon {
  width: 26.25px;
  height: 26.25px;
  color: var(--text-primary);
}

.nav-item span {
  font-size: 20px;
}

.notification-badge {
  background-color: var(--accent-color);
  color: white;
  border-radius: 10px;
  padding: 0 6px;
  font-size: 11px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.post-button-container {
  margin-top: 16px;
  margin-bottom: 16px;
}

.post-button {
  display: block;
  width: 100%;
  background-color: var(--accent-color);
  color: white;
  text-align: center;
  padding: 16px 32px;
  border-radius: 9999px;
  text-decoration: none;
  font-weight: 700;
  font-size: 17px;
  transition: background-color 0.2s;
}

.post-button:hover {
  background-color: var(--accent-hover);
}

.user-profile-card {
  margin-top: auto;
  padding: 12px;
  border-radius: 9999px;
  transition: background-color 0.2s;
  cursor: pointer;
}

.user-profile-card:hover {
  background-color: var(--bg-hover);
}

.profile-dropdown {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.profile-info-small {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.profile-avatar-small,
.profile-avatar-small-placeholder {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

.profile-avatar-small-placeholder {
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
}

.profile-details {
  flex: 1;
  min-width: 0;
}

.profile-name {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-username {
  font-size: 15px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.logout-button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s;
}

.logout-button:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.logout-icon {
  width: 20px;
  height: 20px;
  color: var(--text-primary);
}

/* Main Content */
.main-content {
  flex: 1;
  min-height: 100vh;
  max-width: 600px;
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  background-color: var(--bg-primary);
  font-size: 17px;
}

/* Main content will have margins set inline when sidebars are present */

/* Right Sidebar */
.right-sidebar {
  width: 350px;
  position: fixed;
  right: 0;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  padding: 0 16px;
}

.right-sidebar .sidebar-content {
  padding: 12px 0;
}

/* Search Box */
.search-container {
  position: sticky;
  top: 0;
  background-color: var(--bg-primary);
  z-index: 10;
  padding: 12px 0;
}

.search-box {
  position: relative;
  background-color: var(--bg-secondary);
  border-radius: 9999px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid transparent;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent-color);
  background-color: var(--bg-primary);
}

.search-icon {
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.search-form-inline {
  flex: 1;
}

.search-input {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 15px;
  outline: none;
}

.search-input::placeholder {
  color: var(--text-secondary);
}

/* Trending Section */
.trending-section,
.who-to-follow-section,
.pinned-posts-section {
  background-color: var(--bg-secondary);
  border-radius: 16px;
  margin-top: 16px;
  overflow: hidden;
}

.trending-header,
.section-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
}

.trending-header h3,
.section-header h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.trending-list {
  padding: 0;
}

.trending-item {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
  transition: background-color 0.2s;
}

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

.trending-item:last-child {
  border-bottom: none;
}

.trending-category {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 2px;
}

.trending-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.trending-count {
  font-size: 13px;
  color: var(--text-secondary);
}

.show-more-link {
  padding: 16px;
}

.show-more-link a {
  color: var(--accent-color);
  text-decoration: none;
  font-size: 15px;
}

.show-more-link a:hover {
  text-decoration: underline;
}

/* Who to Follow */
.who-to-follow-list {
  padding: 0;
}

.who-to-follow-item {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border-color);
}

.who-to-follow-item:last-child {
  border-bottom: none;
}

.follow-avatar,
.follow-avatar-placeholder {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.follow-avatar-placeholder {
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
}

.follow-info {
  flex: 1;
  min-width: 0;
}

.follow-name {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.follow-username {
  font-size: 15px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.follow-form {
  margin-left: auto;
}

.follow-button-follow,
.follow-button-following {
  padding: 8px 16px;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  border: 1px solid var(--border-color);
  transition: background-color 0.2s;
}

.follow-button-follow {
  background-color: var(--text-primary);
  color: var(--bg-primary);
  border: none;
}

.follow-button-follow:hover {
  background-color: #e7e9ea;
}

.follow-button-following {
  background-color: transparent;
  color: var(--text-primary);
}

.follow-button-following:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: var(--like-color);
  border-color: var(--like-color);
}

/* Posts Container */
.posts-container {
  background-color: #ffffff;
  color: #000000;
  max-width: 600px;
  width: 100%;
}

.posts-container h1 {
  padding: 12px 16px;
  font-size: 20px;
  font-weight: 700;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.home-main-heading {
  font-size: 64px;
  font-weight: 700;
  color: #000000;
  margin-bottom: 0;
  line-height: 1.2;
  letter-spacing: -0.02em;
  padding: 0;
  border-bottom: none;
  position: static;
  background-color: transparent;
  backdrop-filter: none;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.timeline-filters {
  display: flex;
  border-bottom: 1px solid var(--border-color);
}

.filter-link {
  flex: 1;
  padding: 20px 16px;
  text-align: center;
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 15px;
  position: relative;
  transition: background-color 0.2s;
}

.filter-link:hover {
  background-color: var(--bg-hover);
  color: var(--text-primary);
}

.filter-link.active {
  color: var(--text-primary);
  font-weight: 700;
}

.filter-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 56px;
  height: 3px;
  background-color: var(--accent-color);
  border-radius: 9999px;
}

/* Post Form */
.post-form-container {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  background-color: var(--bg-primary);
}

.post-input-wrapper {
  position: relative;
  display: flex;
  align-items: flex-start;
  background-color: var(--bg-secondary);
  border: 1px solid transparent;
  border-radius: 16px;
  padding: 12px 16px 12px 48px;
  min-height: 60px;
  transition: all 0.2s;
}

.post-input-wrapper:focus-within {
  background-color: var(--bg-primary);
  border-color: var(--accent-color);
}

.post-input-icon {
  position: absolute;
  left: 16px;
  top: 16px;
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  pointer-events: none;
  flex-shrink: 0;
}

.post-clear-btn {
  position: absolute;
  right: 12px;
  top: 12px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s;
  z-index: 5;
}

.post-clear-btn:hover {
  background-color: var(--bg-hover);
}

.post-clear-btn .clear-icon {
  width: 18px;
  height: 18px;
  color: var(--text-secondary);
}

.post-clear-btn:hover .clear-icon {
  color: var(--text-primary);
}

.post-form {
  display: flex;
  gap: 12px;
}

.post-form-avatar {
  flex-shrink: 0;
}

.post-form-content {
  flex: 1;
}

.post-form textarea {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 20px;
  resize: none;
  min-height: 70px;
  line-height: 1.5;
  padding: 4px 0;
  outline: none;
  font-family: inherit;
}

.post-form textarea::placeholder {
  color: var(--text-secondary);
}

.post-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-color);
}

.post-form-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
}

.post-form-file-input {
  display: none;
}

.post-form-file-label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34.75px;
  height: 34.75px;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.2s;
  color: var(--accent-color);
}

.post-form-file-label:hover {
  background-color: rgba(29, 155, 240, 0.1);
}

.post-form-textarea {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 20px;
  resize: none;
  min-height: 70px;
  line-height: 1.5;
  padding: 4px 0;
  outline: none;
  font-family: inherit;
}

.post-form-textarea::placeholder {
  color: var(--text-secondary);
}

.post-form-submit {
  background-color: var(--accent-color);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  box-shadow: 0 0 0 0 rgba(29, 155, 240, 0);
  transition: all 0.2s;
}

.post-form-submit:hover:not(:disabled) {
  background-color: var(--accent-hover);
  transform: scale(1.02);
  box-shadow: 0 2px 8px rgba(29, 155, 240, 0.3);
}

.post-form-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.char-count {
  color: var(--text-secondary);
  font-size: 13px;
}

/* Contenteditable post form */
.post-form-contenteditable {
  flex: 1;
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 16px;
  resize: none;
  min-height: 24px;
  max-height: 400px;
  overflow-y: auto;
  line-height: 1.5;
  padding: 0;
  margin: 0;
  outline: none;
  font-family: inherit;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.post-form-contenteditable.empty::before {
  content: attr(data-placeholder);
  color: var(--text-secondary);
  pointer-events: none;
}

.post-form-contenteditable:focus {
  outline: none;
}

/* Highlighted elements in editor */
.post-form-contenteditable .mention-link-editor {
  color: var(--accent-color);
  font-weight: 600;
  pointer-events: none;
  text-decoration: none;
}

.post-form-contenteditable .hashtag-link-editor {
  color: var(--accent-color);
  font-weight: 700;
  pointer-events: none;
  text-decoration: none;
}

.post-form-contenteditable .url-link-editor {
  color: #1d9bf0;
  pointer-events: none;
  text-decoration: none;
  word-break: break-all;
}

/* Post Card */
.post-card {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  gap: 12px;
  transition: background-color 0.15s ease, transform 0.05s ease;
  min-height: auto;
  height: auto;
}

.post-card:hover {
  background-color: var(--bg-hover);
  transform: translateY(-1px);
}

.post-avatar {
  flex-shrink: 0;
}

.post-avatar img,
.post-avatar-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.post-avatar-placeholder {
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
}

.post-content-wrapper {
  flex: 1;
  min-width: 0;
}

.post-header {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 4px;
}

.user-link {
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 15px;
}

.user-link:hover {
  text-decoration: underline;
}

.username {
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 400;
  margin-left: 4px;
}

.username-link {
  text-decoration: none;
  color: var(--text-secondary);
}

.username-link:hover {
  text-decoration: underline;
}

.post-time {
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 400;
  margin-left: 4px;
}

.post-time::before {
  content: '·';
  margin-right: 4px;
}

.post-content {
  margin: 6px 0 12px 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--text-primary);
  text-align: left;
  word-wrap: break-word;
  white-space: normal;
}

.post-content p {
  margin: 0;
}

.post-media {
  margin-top: 12px;
  border-radius: 16px;
  overflow: hidden;
}

.post-image {
  width: 100%;
  max-height: 510px;
  object-fit: cover;
}

.post-video {
  width: 100%;
  max-height: 510px;
}

.post-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 480px;
  margin-top: 4px;
  padding-top: 4px;
}

.action-link,
.action-button {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: inherit;
  min-width: fit-content;
}

.action-icon {
  width: 18.75px;
  height: 18.75px;
  color: currentColor;
}

.action-link:hover,
.action-button:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--reply-color);
}

.action-link.liked,
.action-button.liked {
  color: var(--like-color);
}

.action-link.liked:hover,
.action-button.liked:hover {
  background-color: rgba(244, 33, 46, 0.1);
}

.action-button.retweet-button:hover {
  background-color: rgba(0, 186, 124, 0.1);
  color: var(--retweet-color);
}

.action-button.retweeted {
  color: var(--retweet-color);
}

.action-button.retweeted:hover {
  background-color: rgba(0, 186, 124, 0.1);
  color: var(--retweet-color);
}

.action-button.pinned {
  color: var(--accent-color);
}

.action-button.pinned:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--accent-color);
}

/* Pinned Posts Section */
.pinned-posts-list {
  padding: 0;
}

.pinned-post-item {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.2s;
}

.pinned-post-item:hover {
  background-color: var(--bg-hover);
}

.pinned-post-item:last-child {
  border-bottom: none;
}

.pinned-post-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.pinned-avatar,
.pinned-avatar-placeholder {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.pinned-avatar-placeholder {
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
}

.pinned-post-info {
  flex: 1;
  min-width: 0;
}

.pinned-post-name {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
}

.pinned-post-username {
  font-size: 13px;
  color: var(--text-secondary);
}

.pinned-post-content {
  font-size: 17px;
  color: var(--text-primary);
  margin-bottom: 8px;
  line-height: 1.4;
}

.pinned-post-link {
  color: var(--accent-color);
  text-decoration: none;
  font-size: 13px;
}

.pinned-post-link:hover {
  text-decoration: underline;
}

.action-link.retweeted,
.action-button.retweeted {
  color: var(--retweet-color);
}

.action-link.retweeted:hover,
.action-button.retweeted:hover {
  background-color: rgba(0, 186, 124, 0.1);
}

.action-link.delete-link:hover,
.action-button.delete-link:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: var(--like-color);
}

.inline-form {
  display: inline;
}

.reply-indicator {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 13px;
}

.reply-indicator a {
  color: var(--accent-color);
  text-decoration: none;
}

.reply-indicator a:hover {
  text-decoration: underline;
}

.reply-toggle-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  border-radius: 9999px;
  transition: all 0.2s;
  font-family: inherit;
}

.reply-toggle-btn:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--reply-color);
}

.reply-form-wrapper {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-color);
}

.reply-form-inline {
  display: flex;
  gap: 0;
  padding: 8px 0;
}

.reply-form-avatar {
  flex-shrink: 0;
}

.reply-form-content {
  flex: 1;
  min-width: 0;
}

.reply-form {
  width: 100%;
}

.reply-textarea {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 15px;
  resize: none;
  min-height: 40px;
  outline: none;
  font-family: inherit;
  margin-bottom: 8px;
}

.reply-textarea::placeholder {
  color: var(--text-secondary);
}

.reply-form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 8px;
}

.reply-char-count {
  color: var(--text-secondary);
  font-size: 13px;
}

.reply-submit-btn {
  background-color: var(--accent-color);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.reply-submit-btn:hover:not(:disabled) {
  background-color: var(--accent-hover);
}

.reply-submit-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.replies-list {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-color-soft);
}

.replies-list .post-card {
  padding: 12px 16px 12px 56px;
  border-bottom: 1px solid var(--border-color);
  position: relative;
  margin-bottom: 0;
  border-radius: 0;
  background-color: rgba(255, 255, 255, 0.01);
  transition: background-color 0.15s ease, transform 0.05s ease;
  min-height: auto;
  height: auto;
  width: auto;
}

.replies-list .post-card::before {
  content: '';
  position: absolute;
  left: 30px;
  top: 0;
  bottom: 0;
  width: 2px;
  background-color: var(--border-color);
  opacity: 0.6;
}

.replies-list .post-card:last-child {
  border-bottom: none;
}

.replies-list .post-card:hover {
  background-color: var(--bg-hover);
  transform: translateY(-1px);
}

.replies-list .post-avatar {
  width: 36px;
  height: 36px;
}

.replies-list .post-avatar-placeholder {
  width: 36px;
  height: 36px;
  font-size: 14px;
}

.replies-list .post-header {
  margin-bottom: 2px;
}

.replies-list .post-content {
  margin: 2px 0 4px 0;
  font-size: 17px;
}

.replies-list .post-actions {
  margin-top: 0;
}

.empty-state {
  text-align: center;
  color: var(--text-secondary);
  padding: 60px 20px;
  font-size: 20px;
  font-weight: 500;
}

.empty-state::before {
  content: '';
  display: block;
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  background-color: var(--bg-secondary);
  border-radius: 50%;
  opacity: 0.5;
}

/* Post Detail Page */
.post-detail-container {
  background-color: var(--bg-primary);
}

.post-detail-header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.post-detail-header .back-icon {
  width: 70px;
  height: 70px;
  padding: 25px;
}

.back-button {
  display: flex;
  align-items: center;
  gap: 24px;
  text-decoration: none;
  color: var(--text-primary);
  font-size: 20px;
  font-weight: 700;
}

.back-icon {
  width: 20px;
  height: 20px;
  padding: 8px;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.back-button:hover .back-icon {
  background-color: var(--bg-hover);
}

:root.light-mode .post-detail-header {
  background-color: #ffffff;
  backdrop-filter: none;
}

:root.light-mode .back-button {
  color: #000000;
}

:root.light-mode .back-link,
:root.light-mode .back-icon,
:root.light-mode .back-button {
  color: #000000 !important;
  fill: currentColor;
}

.post-detail-main {
  padding: 0;
}

.post-detail-card {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
}

.post-detail-author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.post-detail-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

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

.post-detail-author-info {
  display: flex;
  flex-direction: column;
}

.post-detail-name {
  font-weight: 700;
  font-size: 17px;
  color: var(--text-primary);
  text-decoration: none;
}

.post-detail-name:hover {
  text-decoration: underline;
}

.post-detail-username {
  font-size: 17px;
  color: var(--text-secondary);
  text-decoration: none;
}

.post-detail-content {
  font-size: 26px;
  line-height: 1.4;
  color: var(--text-primary);
  margin-bottom: 16px;
  word-wrap: break-word;
}

.post-detail-content p {
  margin: 0;
}

.post-detail-media {
  margin-bottom: 16px;
  border-radius: 16px;
  overflow: hidden;
}

.post-detail-image {
  width: 100%;
  max-height: 600px;
  object-fit: cover;
}

.post-detail-video {
  width: 100%;
  max-height: 600px;
}

.post-detail-timestamp {
  font-size: 15px;
  color: var(--text-secondary);
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.post-detail-stats {
  display: flex;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-color);
}

.stat-item {
  display: flex;
  gap: 4px;
  font-size: 15px;
}

.stat-number {
  font-weight: 700;
  color: var(--text-primary);
}

.stat-label {
  color: var(--text-secondary);
}

.post-detail-actions {
  display: flex;
  justify-content: space-around;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-color);
}

.detail-action-button {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 12px;
  border-radius: 50%;
  transition: all 0.2s;
}

.detail-action-button:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--accent-color);
}

.detail-action-button.retweeted {
  color: var(--retweet-color);
}

.detail-action-button.retweeted:hover {
  background-color: rgba(0, 186, 124, 0.1);
}

.detail-action-button.liked {
  color: var(--like-color);
}

.detail-action-button.liked:hover {
  background-color: rgba(244, 33, 46, 0.1);
}

.detail-action-button.pinned {
  color: var(--accent-color);
}

.detail-action-button.delete-link:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: var(--like-color);
}

.detail-action-icon {
  width: 22px;
  height: 22px;
}

.post-detail-reply-form {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
}

.reply-form-avatar {
  flex-shrink: 0;
}

.reply-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

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

.reply-form-inline {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.reply-textarea-detail {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 20px;
  resize: none;
  outline: none;
  font-family: inherit;
  min-height: 52px;
  padding: 8px 0;
}

.reply-textarea-detail::placeholder {
  color: var(--text-secondary);
}

.reply-form-actions-detail {
  display: flex;
  justify-content: flex-end;
  padding-top: 8px;
}

.post-detail-replies {
  background-color: var(--bg-primary);
}

.reply-item {
  position: relative;
}

.reply-connector {
  display: none;
}

/* Flash Messages */
.flash {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  padding: 16px 24px;
  border-radius: 16px;
  max-width: 600px;
  font-size: 15px;
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  animation: slideDown 0.3s ease-out;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.flash-notice {
  background-color: #00ba7c;
  color: white;
}

.flash-alert {
  background-color: #f4212e;
  color: white;
}

.flash-close {
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 20px;
  opacity: 0.8;
  padding: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.flash-close:hover {
  opacity: 1;
}

/* Auth Pages - Centered Design */
.auth-page-container {
  display: flex;
  min-height: 100vh;
  background-color: #ffffff;
  justify-content: center;
  align-items: center;
}

.auth-logo-section {
  display: none;
}

.auth-content-section {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #ffffff;
  padding: 40px;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

.auth-content-wrapper {
  width: 100%;
  max-width: 400px;
}

.auth-main-heading {
  font-size: 64px;
  font-weight: 700;
  color: #000000;
  margin-bottom: 48px;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.auth-sub-heading {
  font-size: 31px;
  font-weight: 700;
  color: #000000;
  margin-bottom: 32px;
  line-height: 1.2;
}

.auth-form-container {
  width: 100%;
}

.auth-form {
  width: 100%;
}

.auth-form .form-group {
  margin-bottom: 12px;
}

.auth-form textarea.auth-input,
.auth-form textarea.form-control.auth-input {
  border-radius: 9999px !important;
  resize: vertical;
  min-height: 52px;
  padding: 16px 20px !important;
  background-color: #000000 !important;
  color: #ffffff !important;
  border: 1px solid #2f3336 !important;
  height: auto;
  line-height: 1.5;
}

.auth-form textarea.auth-input:focus,
.auth-form textarea.form-control.auth-input:focus {
  border-color: #1d9bf0 !important;
  box-shadow: 0 0 0 2px rgba(29, 155, 240, 0.1);
  background-color: #000000 !important;
}

.auth-form textarea.auth-input::placeholder,
.auth-form textarea.form-control.auth-input::placeholder {
  color: #71767a !important;
}

.auth-input,
.auth-form .form-control.auth-input {
  width: 100%;
  padding: 16px 20px;
  background-color: #000000 !important;
  border: 1px solid #2f3336 !important;
  border-radius: 9999px !important;
  color: #ffffff !important;
  font-size: 17px;
  margin-bottom: 12px;
  transition: all 0.2s;
  outline: none;
  min-height: 52px;
  height: auto;
  box-sizing: border-box;
}

.auth-input:focus,
.auth-form .form-control.auth-input:focus {
  border-color: #1d9bf0 !important;
  box-shadow: 0 0 0 2px rgba(29, 155, 240, 0.1);
  background-color: #000000 !important;
}

.auth-input::placeholder,
.auth-form .form-control.auth-input::placeholder {
  color: #71767a !important;
}

.auth-submit {
  width: 100%;
  padding: 14px 24px;
  background-color: #000000;
  color: #ffffff;
  border: none;
  border-radius: 9999px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 12px;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-submit:hover {
  background-color: #272c30;
}

.auth-submit:active {
  transform: scale(0.98);
}

.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 24px 0;
  color: #536471;
  font-size: 15px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid #cfd9de;
}

.auth-divider span {
  padding: 0 16px;
}

.auth-link-text {
  text-align: center;
  color: #536471;
  font-size: 15px;
  margin-top: 24px;
}

.auth-link {
  color: #1d9bf0;
  text-decoration: none;
}

.auth-link:hover {
  text-decoration: underline;
}

.auth-legal-text {
  font-size: 13px;
  color: #536471;
  line-height: 1.4;
  margin-top: 24px;
}

.auth-legal-text .auth-link {
  color: #1d9bf0;
  text-decoration: none;
}

.auth-legal-text .auth-link:hover {
  text-decoration: underline;
}

/* Legacy auth-container for backwards compatibility */
.auth-container {
  max-width: 600px;
  margin: 80px auto;
  padding: 40px;
  background-color: var(--bg-primary);
}

.auth-container h1 {
  font-size: 31px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.auth-subtitle {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 32px;
}

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
}

.form-control {
  width: 100%;
  padding: 12px;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 17px;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-color);
}

/* Override form-control styles for auth inputs */
.auth-form .form-control.auth-input {
  border-radius: 9999px !important;
  background-color: #000000 !important;
  border: 1px solid #2f3336 !important;
  color: #ffffff !important;
  padding: 16px 20px !important;
  min-height: 52px;
}

.form-group small {
  display: block;
  margin-top: 4px;
  color: var(--text-secondary);
  font-size: 13px;
}

.form-actions {
  margin-top: 24px;
}

.auth-form-container .form-actions {
  margin-top: 20px;
  margin-bottom: 0;
}

.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 9999px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background-color 0.2s;
}

.btn-primary {
  background-color: var(--text-primary);
  color: var(--bg-primary);
}

.auth-form .btn-primary {
  width: 100%;
}

.btn-primary:hover {
  background-color: #e7e9ea;
}

/* Files form specific button styling */
.files-form .btn-primary {
  background-color: var(--accent-color);
  color: white;
  width: auto;
  padding: 10px 20px;
}

.files-form .btn-primary:hover {
  background-color: var(--accent-hover);
}

.btn-secondary {
  background-color: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: var(--bg-hover);
}


/* User Profile */
.user-profile {
  background-color: var(--bg-primary);
  max-width: 600px;
  width: 100%;
}

.profile-banner {
  width: 100%;
  height: 200px;
  background-color: var(--bg-secondary);
}

.profile-info-section {
  padding: 12px 16px;
  position: relative;
  border-bottom: 1px solid var(--border-color);
}

.profile-avatar-container {
  position: relative;
}

.profile-avatar-large {
  width: 133px;
  height: 133px;
  border-radius: 50%;
  border: 4px solid var(--bg-primary);
  margin-top: -67px;
  object-fit: cover;
  position: relative;
  z-index: 1;
}

.profile-avatar-large-placeholder {
  width: 133px;
  height: 133px;
  border-radius: 50%;
  border: 4px solid var(--bg-primary);
  margin-top: -67px;
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  font-weight: 700;
  position: relative;
  z-index: 1;
}

.profile-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
  margin-bottom: 16px;
}

.profile-edit-btn,
.profile-follow-btn,
.profile-block-btn {
  padding: 8px 16px;
  border-radius: 9999px;
  font-size: 15px;
  font-weight: 700;
  border: 1px solid var(--border-color);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s;
  text-decoration: none;
  display: inline-block;
  min-width: 80px;
  box-sizing: border-box;
}

.profile-edit-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.profile-follow-btn {
  background-color: var(--text-primary);
  color: var(--bg-primary);
  border: none;
}

.profile-follow-btn:hover {
  background-color: rgba(255, 255, 255, 0.9);
}

.profile-follow-btn.following {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.profile-follow-btn.following:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: #f4212e;
  border-color: #f4212e;
}

.profile-block-btn {
  border: none;
  background-color: #f4212e;
  color: #fff;
  cursor: pointer;
}

.profile-block-btn:hover {
  background-color: #d91e2a;
}

.profile-block-btn.blocked {
  background-color: var(--bg-primary);
  color: #f4212e;
  border: 1px solid #f4212e;
}

.profile-block-btn.blocked:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: #f4212e;
  border-color: #f4212e;
}

.profile-action-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
}

.profile-action-buttons input[type="submit"],
.profile-action-buttons button[type="submit"] {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  margin: 0;
  font-family: inherit;
  line-height: 1.5;
}

.profile-info {
  margin-bottom: 16px;
}

.profile-info h1 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
  line-height: 1.3;
}

.profile-info .username {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.profile-bio {
  font-size: 17px;
  color: var(--text-primary);
  margin-bottom: 16px;
  line-height: 1.6;
  white-space: pre-wrap;
}

.profile-bio p {
  margin: 0;
}

.profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 16px;
  margin-bottom: 16px;
}

.profile-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.profile-meta-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.8;
}

.profile-link {
  color: var(--accent-color);
  text-decoration: none;
}

.profile-link:hover {
  text-decoration: underline;
}

.profile-social-links {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
  transition: all 0.2s;
}

.social-link:hover {
  background-color: var(--accent-color);
  color: white;
}

.social-icon {
  width: 18px;
  height: 18px;
}

.profile-stats {
  display: flex;
  gap: 20px;
  font-size: 15px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-color);
}

.stat-link {
  text-decoration: none;
  color: var(--accent-color);
}

.stat-link:hover {
  text-decoration: underline;
}

.stat-link strong {
  color: var(--accent-color);
  font-weight: 700;
}

.user-posts {
  border-top: 1px solid var(--border-color);
}

.user-posts h2 {
  padding: 12px 16px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}

/* Edit Profile */
.edit-profile-page {
  background-color: var(--bg-primary);
  min-height: 100vh;
}

.edit-profile-header {
  padding: 24px 80px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
  max-width: 1000px;
  margin: 0 auto;
}

.edit-profile-header h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  text-align: center;
}

.edit-profile-form {
  padding: 60px 80px;
  max-width: 1000px;
  margin: 0 auto;
}

.edit-profile-form .form-group {
  margin-bottom: 40px;
}

.edit-profile-form label {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.edit-profile-form .form-control {
  width: 100%;
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-size: 15px;
  transition: all 0.2s ease;
}

.edit-profile-form .form-control:hover {
  border-color: var(--bg-hover);
}

.edit-profile-form .form-control:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 2px rgba(29, 155, 240, 0.1);
}

.edit-profile-form .form-control::placeholder {
  color: var(--text-secondary);
}

.edit-profile-form .bio-textarea {
  resize: vertical;
  min-height: 110px;
  font-family: inherit;
  line-height: 1.5;
}

.current-avatar {
  margin-bottom: 12px;
}

/* Avatar Upload Container */
.avatar-upload-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.avatar-preview-wrapper {
  position: relative;
  width: 120px;
  height: 120px;
  cursor: pointer;
  border-radius: 50%;
  overflow: hidden;
  background-color: var(--bg-secondary);
  border: 2px solid var(--border-color);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.avatar-preview-wrapper:hover {
  border-color: var(--accent-color);
}

.avatar-preview-wrapper .avatar-preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar-preview-placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--accent-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  font-weight: 700;
}

.avatar-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.65);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
  border-radius: 50%;
}

.avatar-preview-wrapper:hover .avatar-overlay {
  opacity: 1;
}

.avatar-overlay-text {
  font-size: 13px;
  font-weight: 600;
  color: white;
  text-align: center;
}

.avatar-file-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 10;
}

.avatar-help-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.avatar-help-text p {
  margin: 0 0 8px 0;
}

.remove-avatar-btn {
  background: none;
  border: none;
  color: #f4212e;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
  text-decoration: underline;
  transition: opacity 0.2s;
}

.remove-avatar-btn:hover {
  opacity: 0.8;
}

.char-count {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 6px;
}

.form-section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 60px;
  margin-bottom: 32px;
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.field-with-toggle {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
}

.toggle-text {
  font-size: 15px;
  color: var(--text-primary);
  font-weight: 500;
  transition: color 0.2s ease;
}

.field-with-toggle:hover .toggle-text {
  color: var(--accent-color);
}

/* Switch Wrapper */
.switch-wrapper,
.profile-fields-table .switch-wrapper {
  position: relative !important;
  display: inline-block !important;
  width: 52px !important;
  height: 30px !important;
  cursor: pointer !important;
  flex-shrink: 0 !important;
  vertical-align: middle !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
}

/* Ensure label wrapper doesn't interfere */
label.switch-wrapper {
  display: inline-block !important;
  width: 52px !important;
  height: 30px !important;
}

/* Completely hide the actual checkbox - no visual trace */
.switch-wrapper .toggle-switch,
.switch-wrapper input[type="checkbox"].toggle-switch,
.switch-wrapper input.toggle-switch {
  position: absolute !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  clip: rect(0, 0, 0, 0) !important;
  overflow: hidden !important;
  pointer-events: none !important;
  z-index: -1 !important;
  visibility: hidden !important;
  display: none !important;
}

/* Hide any Rails-generated hidden inputs */
.switch-wrapper input[type="hidden"] {
  display: none !important;
}

/* Switch Track (the background) - Techy look matching posts button */
.switch-slider,
.profile-fields-table .switch-slider {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  background-color: rgba(255, 255, 255, 0.1) !important;
  border: 2px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 20px !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2) !important;
  overflow: visible !important;
  cursor: pointer !important;
  display: block !important;
  visibility: visible !important;
  z-index: 1 !important;
}

/* Switch Thumb (the sliding circle) - More prominent and techy */
.switch-slider::before,
.profile-fields-table .switch-slider::before {
  content: '' !important;
  position: absolute !important;
  height: 22px !important;
  width: 22px !important;
  left: 3px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  background: #ffffff !important;
  border-radius: 50% !important;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.2) !important;
  z-index: 2 !important;
  display: block !important;
  visibility: visible !important;
}

/* When checkbox is checked - Use exact posts button blue (#1d9bf0) */
.switch-wrapper .toggle-switch:checked + .switch-slider,
.profile-fields-table .switch-wrapper .toggle-switch:checked + .switch-slider {
  background-color: #1d9bf0 !important;
  border-color: #1d9bf0 !important;
  box-shadow: 0 0 0 3px rgba(29, 155, 240, 0.2), inset 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.switch-wrapper .toggle-switch:checked + .switch-slider::before,
.profile-fields-table .switch-wrapper .toggle-switch:checked + .switch-slider::before {
  transform: translateY(-50%) translateX(23px) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25), 0 1px 3px rgba(0, 0, 0, 0.15) !important;
  background: #ffffff !important;
}

/* Hover states - Techy interactive feedback */
.switch-wrapper:hover .switch-slider,
.profile-fields-table .switch-wrapper:hover .switch-slider {
  border-color: rgba(255, 255, 255, 0.3) !important;
  background-color: rgba(255, 255, 255, 0.15) !important;
}

.switch-wrapper:hover .toggle-switch:checked + .switch-slider,
.profile-fields-table .switch-wrapper:hover .toggle-switch:checked + .switch-slider {
  background-color: #1a8cd8 !important;
  border-color: #1a8cd8 !important;
  box-shadow: 0 0 0 4px rgba(29, 155, 240, 0.25), inset 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.switch-wrapper:hover .switch-slider::before,
.profile-fields-table .switch-wrapper:hover .switch-slider::before {
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3), 0 1px 4px rgba(0, 0, 0, 0.2) !important;
}

/* Active state (when clicking) - Smooth techy feedback */
.switch-wrapper:active .switch-slider::before,
.profile-fields-table .switch-wrapper:active .switch-slider::before {
  width: 26px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35), 0 1px 3px rgba(0, 0, 0, 0.25) !important;
}

.switch-wrapper:active .toggle-switch:checked + .switch-slider::before,
.profile-fields-table .switch-wrapper:active .toggle-switch:checked + .switch-slider::before {
  width: 26px !important;
  transform: translateY(-50%) translateX(21px) !important;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.35), 0 1px 4px rgba(0, 0, 0, 0.25) !important;
}

/* Focus state for accessibility */
.switch-wrapper .toggle-switch:focus + .switch-slider,
.profile-fields-table .switch-wrapper .toggle-switch:focus + .switch-slider {
  outline: 2px solid rgba(29, 155, 240, 0.5) !important;
  outline-offset: 2px !important;
}

/* Additional table-specific switch styling to ensure visibility */
.profile-fields-table td.field-switch {
  position: relative;
}

.profile-fields-table td.field-switch .switch-wrapper {
  margin: 12px auto;
  padding: 0;
  display: block;
}

/* Ensure no checkbox styling appears - override any default styles */
.switch-wrapper input[type="checkbox"],
.switch-wrapper input[type="checkbox"].toggle-switch,
.profile-fields-table .switch-wrapper input[type="checkbox"],
.profile-fields-table .switch-wrapper input[type="checkbox"].toggle-switch {
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  clip: rect(0, 0, 0, 0) !important;
  position: absolute !important;
  pointer-events: none !important;
}

.switch-wrapper input[type="checkbox"]::-webkit-checkbox,
.profile-fields-table .switch-wrapper input[type="checkbox"]::-webkit-checkbox {
  -webkit-appearance: none !important;
  appearance: none !important;
}

.switch-wrapper input[type="checkbox"]::-moz-checkbox,
.profile-fields-table .switch-wrapper input[type="checkbox"]::-moz-checkbox {
  -moz-appearance: none !important;
  appearance: none !important;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.input-with-icon .form-control {
  flex: 1;
  min-width: 0;
  visibility: visible;
  opacity: 1;
}

.input-icon {
  position: absolute;
  left: 16px;
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.form-control.with-icon {
  padding-left: 48px;
  transition: padding-left 0.2s ease;
}

.edit-profile-form input[type="date"] {
  color-scheme: dark;
}

.edit-profile-form input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
  cursor: pointer;
  opacity: 0.7;
}

.edit-profile-form input[type="date"]::-webkit-calendar-picker-indicator:hover {
  opacity: 1;
}

.form-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
}

.edit-profile-form .btn-primary {
  background-color: var(--text-primary);
  color: var(--bg-primary);
  padding: 12px 24px;
  font-weight: 700;
  border-radius: 24px;
  transition: all 0.2s ease;
}

.edit-profile-form .btn-primary:hover {
  background-color: #e7e9ea;
  transform: translateY(-1px);
}

.edit-profile-form .btn-secondary {
  background-color: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 12px 24px;
  font-weight: 700;
  border-radius: 24px;
  transition: all 0.2s ease;
}

.edit-profile-form .btn-secondary:hover {
  background-color: var(--bg-hover);
  border-color: var(--bg-hover);
}

.error-messages {
  background-color: rgba(244, 33, 46, 0.1);
  border: 1px solid #f4212e;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 24px;
  color: #f4212e;
  font-size: 15px;
  line-height: 1.5;
}

.error-messages p {
  margin: 0;
}

.error-messages p:not(:last-child) {
  margin-bottom: 4px;
}

/* Profile Fields Table */
.profile-fields-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 40px;
  table-layout: fixed;
}

.profile-fields-table col.field-label-col {
  width: 30.875%;
}

.profile-fields-table col.field-input-col {
  width: 38.25%;
}

.profile-fields-table col.field-switch-col {
  width: 30.875%;
}

.profile-fields-table tr {
  border-bottom: 1px solid var(--border-color);
}

.profile-fields-table tr:last-child {
  border-bottom: none;
}

.profile-fields-table td {
  padding: 24px 0;
  vertical-align: middle;
}

.profile-fields-table td.field-label {
  width: 200px;
  padding-right: 40px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.profile-fields-table td.field-label label {
  margin: 0;
  cursor: pointer;
}

.profile-fields-table td.field-input {
  flex: 1;
  padding-right: 40px;
  width: 100%;
}

.profile-fields-table td.field-input .form-control {
  width: 100%;
}

.profile-fields-table td.field-input .input-with-icon,
.profile-fields-table td.field-input .form-control.with-icon {
  width: 100%;
  box-sizing: border-box;
}

.profile-fields-table td.field-switch {
  width: 120px;
  text-align: center;
  padding-left: 60px;
  padding-right: 20px;
}

.profile-fields-table td.field-switch strong {
  display: block;
  text-align: center;
  margin-bottom: 8px;
}

.profile-fields-table td.field-switch .toggle-switch {
  margin: 8px auto;
  display: block;
}

/* Edit Profile Responsive */
@media (max-width: 768px) {
  .edit-profile-form {
    padding: 24px 20px;
    max-width: 100%;
  }

  .edit-profile-header {
    padding: 16px 20px;
    max-width: 100%;
  }

  .avatar-preview-wrapper {
    width: 100px;
    height: 100px;
  }

  .avatar-preview-placeholder {
    font-size: 40px;
  }

  .form-actions {
    flex-direction: column-reverse;
  }

  .edit-profile-form .btn-primary,
  .edit-profile-form .btn-secondary {
    width: 100%;
  }

  .profile-fields-table {
    display: block;
  }

  .profile-fields-table tr {
    display: block;
    border-bottom: 1px solid var(--border-color);
    padding: 16px 0;
  }

  .profile-fields-table tr:last-child {
    border-bottom: none;
  }

  .profile-fields-table td {
    display: block;
    padding: 8px 0;
    width: 100%;
  }

  .profile-fields-table td.field-label {
    width: 100%;
    padding-right: 0;
    margin-bottom: 8px;
  }

  .profile-fields-table td.field-input {
    padding-right: 0;
    margin-bottom: 12px;
  }

  .profile-fields-table td.field-switch {
    width: 100%;
    text-align: left;
    padding-left: 0;
  }
}

/* Responsive */
@media (max-width: 1264px) {
  .right-sidebar {
    display: none;
  }
  
  .main-content {
    margin-right: 0;
  }
}

@media (max-width: 1000px) {
  .left-sidebar {
    width: 88px;
  }
  
  .left-sidebar .nav-item span,
  .left-sidebar .post-button span,
  .left-sidebar .profile-name,
  .left-sidebar .profile-username {
    display: none;
  }
  
  .left-sidebar .post-button {
    padding: 16px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
  }
  
  .main-content {
    margin-left: 88px;
  }
}

@media (max-width: 688px) {
  .app-container {
    flex-direction: column;
  }
  
  .left-sidebar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    height: auto;
    width: 100%;
    border-right: none;
    border-top: 1px solid var(--border-color);
    z-index: 100;
    background-color: var(--bg-primary);
  }
  
  .sidebar-content {
    flex-direction: row;
    justify-content: space-around;
    padding: 0;
  }
  
  .logo-container {
    display: none;
  }
  
  .sidebar-nav {
    flex-direction: row;
    width: 100%;
    justify-content: space-around;
  }
  
  .nav-item {
    flex-direction: column;
    padding: 8px;
    min-width: 64px;
  }
  
  .nav-item span {
    font-size: 11px;
  }
  
  .post-button-container {
    display: none;
  }
  
  .user-profile-card {
    display: none;
  }
  
  .nav-item.hide-on-mobile,
  .sidebar-nav .nav-item.hide-on-mobile {
    display: none !important;
  }
  
  .main-content {
    margin-left: 0;
    margin-bottom: 60px;
  }
}

/* Admin Pages */
.admin-page {
  background-color: var(--bg-primary);
  min-height: 100vh;
  max-width: 600px !important;
  width: 100%;
}

/* Override main-content width for admin pages */
.main-content:has(.admin-page) {
  max-width: 600px;
}

.admin-header {
  padding: 20px 16px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.admin-header h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.admin-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  margin-bottom: 12px;
}

.back-link:hover {
  color: var(--text-primary);
}

.back-link .back-icon {
  width: 16px;
  height: 16px;
}

.admin-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
}

.admin-push-test-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 9999px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  transition: background-color 0.2s;
}

.admin-push-test-btn:hover {
  background-color: var(--accent-hover);
}

.admin-create-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 9999px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  transition: background-color 0.2s;
}

.admin-create-btn:hover {
  background-color: var(--accent-hover);
}

.admin-cleanup-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 9999px;
  border: none;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s;
}

.admin-cleanup-btn:hover {
  background-color: var(--accent-hover);
}

.admin-btn-icon {
  width: 20px;
  height: 20px;
}

.admin-stats {
  display: flex;
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
}

.stat-card {
  flex: 1;
  background-color: var(--bg-secondary);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.stat-card .stat-number {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
}

.stat-card .stat-label {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.admin-table-container {
  padding: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  min-width: 550px;
  border-collapse: collapse;
  table-layout: fixed;
}

.admin-table thead {
  background-color: var(--bg-secondary);
}

.admin-table th {
  padding: 8px 6px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-table th:nth-child(1) { width: 15%; } /* Code */
.admin-table th:nth-child(2) { width: 22%; } /* Email */
.admin-table th:nth-child(3) { width: 10%; } /* Type */
.admin-table th:nth-child(4) { width: 11%; } /* Status */
.admin-table th:nth-child(5) { width: 18%; } /* Used By */
.admin-table th:nth-child(6) { width: 12%; } /* Created */
.admin-table th:nth-child(7) { width: 12%; } /* Actions */

.admin-table td {
  padding: 10px 6px;
  border-bottom: 1px solid var(--border-color);
  font-size: 13px;
  color: var(--text-primary);
}

.admin-table tr:hover {
  background-color: var(--bg-hover);
}

.admin-table tr.used-row {
  opacity: 0.7;
}

.code-cell {
  display: flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  overflow: hidden;
}

.invite-code {
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', monospace;
  font-size: 11px;
  background-color: var(--bg-secondary);
  padding: 3px 6px;
  border-radius: 4px;
  color: var(--accent-color);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}

.copy-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.copy-btn:hover {
  background-color: var(--bg-secondary);
  color: var(--accent-color);
}

.copy-icon {
  width: 14px;
  height: 14px;
}

.email-cell {
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 600;
}

.badge-icon {
  width: 12px;
  height: 12px;
}

.status-available {
  background-color: rgba(0, 186, 124, 0.1);
  color: var(--retweet-color);
}

.status-used {
  background-color: rgba(113, 118, 122, 0.2);
  color: var(--text-secondary);
}

.user-link-cell {
  text-decoration: none;
}

.user-cell {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--text-primary);
  overflow: hidden;
  font-size: 13px;
}

.user-cell span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-cell:hover span {
  text-decoration: underline;
}

.user-avatar-small {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

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

.not-used {
  color: var(--text-secondary);
}

.date-cell {
  color: var(--text-secondary);
  font-size: 12px;
  white-space: nowrap;
}

.action-cell {
  text-align: center;
  white-space: nowrap;
  padding-right: 8px !important;
}

.delete-code-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.delete-code-btn:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: var(--like-color);
}

.delete-icon {
  width: 18px;
  height: 18px;
}

.empty-admin-state {
  text-align: center;
  padding: 64px 16px;
  color: var(--text-secondary);
}

.empty-icon {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-admin-state p {
  font-size: 18px;
  margin-bottom: 8px;
}

.empty-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
}

.admin-form-container {
  padding: 24px 16px;
  max-width: 500px;
}

.admin-form .form-group {
  margin-bottom: 24px;
}

.admin-form label {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.admin-form .form-control {
  width: 100%;
  padding: 12px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-size: 15px;
}

.admin-form .form-control:focus {
  outline: none;
  border-color: var(--accent-color);
}

.form-help {
  display: block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

/* Search Page */
.search-page {
  background-color: var(--bg-primary);
  min-height: 100vh;
  max-width: 600px;
  width: 100%;
}

.search-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.search-header h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
}

.search-input-container {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  position: relative;
}

.search-form-main {
  position: relative;
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input-icon {
  position: absolute;
  left: 16px;
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  pointer-events: none;
}

.search-input-main {
  width: 100%;
  padding: 12px 16px 12px 48px;
  background-color: var(--bg-secondary);
  border: 1px solid transparent;
  border-radius: 9999px;
  color: var(--text-primary);
  font-size: 15px;
  outline: none;
  transition: all 0.2s;
}

.search-input-main:focus {
  background-color: var(--bg-primary);
  border-color: var(--accent-color);
}

.search-input-main::placeholder {
  color: var(--text-secondary);
}

.search-clear-btn {
  position: absolute;
  right: 12px;
  padding: 4px;
  color: var(--accent-color);
}

.clear-icon {
  width: 20px;
  height: 20px;
}

.hashtag-suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  margin-top: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  z-index: 100;
}

.suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s;
}

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

.suggestion-icon {
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
}

.suggestion-info {
  display: flex;
  flex-direction: column;
}

.suggestion-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.suggestion-count {
  font-size: 13px;
  color: var(--text-secondary);
}

.suggestion-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

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

.trending-hashtags-section {
  padding: 0;
}

.trending-hashtags-section h2 {
  padding: 12px 16px;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}

.trending-hashtags-list {
  padding: 0;
}

.trending-hashtag-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none;
  transition: background-color 0.2s;
}

.trending-hashtag-item:hover {
  background-color: var(--bg-hover);
}

.trending-rank {
  width: 24px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-secondary);
}

.trending-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.trending-category {
  font-size: 13px;
  color: var(--text-secondary);
}

.trending-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.trending-posts {
  font-size: 13px;
  color: var(--text-secondary);
}

.search-results {
  padding: 0;
}

.hashtag-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
}

.hashtag-header h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.hashtag-post-count {
  font-size: 15px;
  color: var(--text-secondary);
}

.search-section {
  border-bottom: 1px solid var(--border-color);
}

.section-title {
  padding: 12px 16px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  background-color: var(--bg-secondary);
}

.hashtags-results {
  padding: 0;
}

.hashtag-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none;
  transition: background-color 0.2s;
}

.hashtag-result-item:hover {
  background-color: var(--bg-hover);
}

.hashtag-icon-wrapper {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hashtag-icon {
  width: 24px;
  height: 24px;
  color: var(--text-secondary);
}

.hashtag-result-info {
  display: flex;
    flex-direction: column;
}

.hashtag-result-name {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

.hashtag-result-count {
  font-size: 15px;
  color: var(--text-secondary);
}

.users-results {
  padding: 0;
}

.user-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none;
  transition: background-color 0.2s;
}

.user-result-item:hover {
  background-color: var(--bg-hover);
}

.user-result-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

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

.user-result-info {
  flex: 1;
  display: flex;
    flex-direction: column;
}

.user-result-name {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

.user-result-username {
  font-size: 17px;
  color: var(--text-secondary);
}

.user-result-bio {
  font-size: 17px;
  color: var(--text-primary);
  margin-top: 4px;
}

.follow-status {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 4px 12px;
  border: 1px solid var(--border-color);
  border-radius: 9999px;
}

.posts-results {
  padding: 0;
}

.no-results {
    text-align: center;
  padding: 64px 16px;
}

.no-results-icon {
  width: 64px;
  height: 64px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  opacity: 0.5;
}

.no-results h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.no-results p {
  font-size: 15px;
  color: var(--text-secondary);
}

/* Follow/Following Page */
.follow-page-wrapper {
  max-width: 600px;
  width: 100%;
  min-height: 100vh;
  background-color: var(--bg-primary);
}

.follow-page-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
  background-color: rgba(0, 0, 0, 0.65);
  border-bottom: 1px solid var(--border-color);
}

.follow-page-header .back-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  transition: background-color 0.15s;
  color: var(--text-primary);
  text-decoration: none;
  flex-shrink: 0;
}

.follow-page-header .back-button:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.follow-page-header .back-icon {
  width: 40px;
  height: 40px;
  fill: currentColor;
}

.follow-page-title {
  flex: 1;
  min-width: 0;
}

.follow-page-title h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.follow-page-username {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 2px 0 0 0;
  line-height: 1.2;
}

.follow-page-nav {
  display: flex;
  border-bottom: 1px solid var(--border-color);
}

.follow-nav-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  transition: background-color 0.15s;
  position: relative;
}

.follow-nav-link:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.follow-nav-link.active {
  color: var(--text-primary);
  font-weight: 700;
}

.follow-nav-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background-color: var(--accent-color);
  border-radius: 4px 4px 0 0;
}

.follow-page-content {
  min-height: 300px;
}

.follows-list {
  background-color: var(--bg-primary);
}

/* User Row */
.user-row-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  text-decoration: none;
  transition: background-color 0.15s;
  cursor: pointer;
}

.user-row-link:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.user-row-avatar {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
}

.user-row-avatar .avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.user-row-avatar .avatar-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: var(--accent-color);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
}

.user-row-info {
  flex: 1;
  min-width: 0;
}

.user-row-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.user-row-details {
  font-size: 15px;
  color: var(--text-secondary);
  display: flex;
  gap: 4px;
  align-items: center;
}

.user-row-username {
  flex-shrink: 0;
}

.user-row-separator {
  flex-shrink: 0;
}

.user-row-bio {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.user-row-date {
  font-size: 13px;
  color: var(--text-secondary);
  flex-shrink: 0;
  margin-left: 12px;
}

/* Empty State */
.follow-empty-state {
  text-align: center;
  padding: 64px 32px;
  max-width: 380px;
  margin: 0 auto;
}

.empty-state-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background-color: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
}

.empty-state-title {
  font-size: 31px;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.empty-state-text {
  font-size: 15px;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
}

/* Toggle Switch */
.toggle-switch-container {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.toggle-label {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.2s;
}

.toggle-label.active {
  color: var(--text-primary);
  font-weight: 600;
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 26px;
  cursor: pointer;
}

.toggle-input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.toggle-slider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 26px;
  transition: all 0.3s;
}

.toggle-slider::before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 2px;
  bottom: 2px;
  background-color: var(--text-secondary);
  border-radius: 50%;
  transition: all 0.3s;
}

.toggle-input:checked + .toggle-slider {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
}

.toggle-input:checked + .toggle-slider::before {
  transform: translateX(22px);
  background-color: white;
}

.toggle-input:focus + .toggle-slider {
  box-shadow: 0 0 0 2px rgba(29, 155, 240, 0.3);
}

/* Type badges */
.type-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 9999px;
  font-size: 10px;
  font-weight: 600;
}

.type-badge .badge-icon {
  width: 12px;
  height: 12px;
}

.type-admin {
  background-color: rgba(249, 24, 128, 0.15);
  color: #f91880;
}

.type-user {
  background-color: rgba(29, 155, 240, 0.15);
  color: var(--accent-color);
}

/* Hashtag links in posts */
.hashtag-link {
  color: var(--accent-color);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s;
}

.hashtag-link:hover {
  text-decoration: underline;
}

/* URL links in posts */
a.url-link,
a.url-link:link,
a.url-link:visited,
a.url-link:hover,
a.url-link:active {
  color: #1d9bf0 !important;
  text-decoration: none;
  word-break: break-all;
}

a.url-link:hover {
  text-decoration: underline;
}

/* Notifications Page */
.notifications-page {
  background-color: var(--bg-primary);
  min-height: 100vh;
  max-width: 600px;
  width: 100%;
}

.notifications-header {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.notifications-header h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.mark-all-read-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background-color: transparent;
  border: 1px solid var(--border-color);
  border-radius: 9999px;
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.mark-all-read-btn:hover {
  background-color: var(--bg-hover);
}

.mark-read-icon {
  width: 16px;
  height: 16px;
}

.notifications-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
}

.notification-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  position: relative;
  transition: color 0.15s, background-color 0.15s;
  cursor: pointer;
  background: none;
  border: none;
}

.notification-tab:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.notification-tab.active {
  color: var(--text-primary);
  font-weight: 700;
}

.notification-tab .tab-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background-color: var(--accent-color);
  border-radius: 4px 4px 0 0;
}

.notifications-list {
  padding: 0;
}

.notification-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.2s;
  position: relative;
}

.notification-card:hover {
  background-color: var(--bg-hover);
}

.notification-card.unread {
  background-color: rgba(29, 155, 240, 0.03);
}

.notification-icon-wrapper {
  flex-shrink: 0;
}

.notification-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notification-icon svg {
  width: 18px;
  height: 18px;
}

.notification-icon.like-icon {
  background-color: rgba(249, 24, 128, 0.15);
  color: #f91880;
}

.notification-icon.retweet-icon {
  background-color: rgba(0, 186, 124, 0.15);
  color: #00ba7c;
}

.notification-icon.reply-icon {
  background-color: rgba(29, 155, 240, 0.15);
  color: var(--accent-color);
}

.notification-icon.follow-icon {
  background-color: rgba(29, 155, 240, 0.15);
  color: var(--accent-color);
}

.notification-content {
  flex: 1;
  display: flex;
  gap: 12px;
  min-width: 0;
}

.notification-user-avatar {
  flex-shrink: 0;
}

.notification-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

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

.notification-details {
  flex: 1;
  min-width: 0;
}

.notification-text {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.notification-actor {
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
}

.notification-actor:hover {
  text-decoration: underline;
}

.notification-post-preview {
  display: block;
  margin-top: 8px;
  padding: 12px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  text-decoration: none;
  transition: background-color 0.2s;
}

.notification-post-preview:hover {
  background-color: var(--bg-hover);
}

.notification-post-preview p {
  font-size: 14px;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.4;
}

.notification-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.notification-time {
  font-size: 13px;
  color: var(--text-secondary);
}

.unread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent-color);
}

.mark-read-single-btn {
  position: absolute;
  right: 16px;
  top: 16px;
  padding: 8px;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: 50%;
  transition: all 0.2s;
}

.mark-read-single-btn:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--accent-color);
}

.check-icon {
  width: 18px;
  height: 18px;
}

.notifications-empty {
    text-align: center;
  padding: 64px 32px;
}

.empty-icon-wrapper {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background-color: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.empty-bell-icon {
  width: 32px;
  height: 32px;
  color: var(--text-secondary);
}

.notifications-empty h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.notifications-empty p {
  font-size: 15px;
  color: var(--text-secondary);
  max-width: 320px;
  margin: 0 auto;
  line-height: 1.4;
}

/* Mention icon */
.notification-icon.mention-icon {
  background-color: rgba(120, 86, 255, 0.15);
  color: #7856ff;
}

/* Mention links in posts */
.mention-link {
  color: var(--accent-color);
  font-weight: 600;
  text-decoration: none;
}

.mention-link:hover {
  text-decoration: underline;
}

/* Mention autocomplete dropdown */
.textarea-wrapper {
  position: relative;
}

.mention-suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  margin-top: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  z-index: 100;
  max-height: 280px;
  overflow-y: auto;
}

.mention-suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.mention-suggestion-item:hover,
.mention-suggestion-item.active {
  background-color: var(--bg-hover);
}

.mention-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

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

.mention-info {
  display: flex;
  flex-direction: column;
}

.mention-display-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.mention-username {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Hashtag autocomplete dropdown */
.hashtag-suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  margin-top: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  z-index: 100;
  max-height: 280px;
  overflow-y: auto;
}

.hashtag-suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.hashtag-suggestion-item:hover,
.hashtag-suggestion-item.active {
  background-color: var(--bg-hover);
}

.hashtag-suggestion-item .suggestion-icon {
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.hashtag-suggestion-info {
  display: flex;
  flex-direction: column;
}

.hashtag-suggestion-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.hashtag-suggestion-count {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Files Page */
.files-page {
  background-color: var(--bg-primary);
  min-height: 100vh;
  max-width: 600px;
  width: 100%;
}

.files-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
  z-index: 10;
}

.files-header h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.files-header .back-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  text-decoration: none;
  color: var(--text-primary);
  transition: background-color 0.2s;
}

.files-header .back-button:hover {
  background-color: var(--bg-hover);
}

.files-header .back-icon {
  width: 20px;
  height: 20px;
}

:root.light-mode .files-header {
  background-color: #ffffff !important;
  border-bottom-color: var(--border-color) !important;
  backdrop-filter: none !important;
}

:root.light-mode .files-header h1,
:root.light-mode .files-header .back-button {
  color: #000000 !important;
}

:root.light-mode .upload-folder-banner {
  background-color: #ffffff !important;
  color: #000000 !important;
  border: 1px solid var(--border-color);
}

:root.light-mode .upload-folder-banner strong {
  color: #000000 !important;
}

.files-header-title {
  flex: 1;
}

.files-header-title h1 {
  margin: 0;
}

.files-header-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 2px 0 0 0;
}

.files-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
}

.files-toolbar-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  background-color: var(--bg-secondary);
  border: none;
  color: var(--text-primary);
  cursor: pointer;
}

.files-toolbar-btn:hover {
  background-color: var(--bg-hover);
}

.files-toolbar-btn.primary {
  background-color: var(--accent-color);
  color: white;
}

.files-toolbar-btn.primary:hover {
  background-color: var(--accent-hover);
}

.files-toolbar-btn.danger {
  color: #f4212e;
}

.files-toolbar-btn.danger:hover {
  background-color: rgba(244, 33, 46, 0.1);
}

.files-toolbar-spacer {
  flex: 1;
}

.toolbar-icon {
  width: 16px;
  height: 16px;
}

.files-content {
  padding: 0;
}

.files-list-view {
  padding: 0;
}

.file-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  text-decoration: none;
  transition: background-color 0.15s;
}

.file-row:hover {
  background-color: var(--bg-hover);
}

.file-row-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background-color: var(--bg-secondary);
}

.file-row-icon svg {
  width: 20px;
  height: 20px;
}

.file-row-icon.folder {
  background-color: rgba(255, 212, 59, 0.15);
  color: #ffd43b;
}

.file-row-icon.pdf {
  background-color: rgba(244, 33, 46, 0.15);
  color: #f4212e;
}

.file-row-icon.doc {
  background-color: rgba(29, 155, 240, 0.15);
  color: var(--accent-color);
}

.file-row-icon.xls {
  background-color: rgba(0, 186, 124, 0.15);
  color: #00ba7c;
}

.file-row-icon.ppt {
  background-color: rgba(255, 122, 0, 0.15);
  color: #ff7a00;
}

.file-row-icon.image {
  background-color: rgba(120, 86, 255, 0.15);
  color: #7856ff;
}

.file-row-icon.video {
  background-color: rgba(249, 24, 128, 0.15);
  color: #f91880;
}

.file-row-icon.audio {
  background-color: rgba(255, 212, 0, 0.15);
  color: #ffd400;
}

.file-row-icon.zip,
.file-row-icon.file {
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
}

.file-row-info {
  flex: 1;
  min-width: 0;
}

.file-row-name {
  display: block;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-row-meta {
  font-size: 13px;
  color: var(--text-secondary);
}

.file-row-date {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.file-row-actions {
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.15s;
}

.file-row:hover .file-row-actions {
  opacity: 1;
}

.file-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
}

.file-action-btn:hover {
  background-color: rgba(29, 155, 240, 0.1);
  color: var(--accent-color);
}

.file-action-btn.danger:hover {
  background-color: rgba(244, 33, 46, 0.1);
  color: #f4212e;
}

.file-action-btn svg {
  width: 16px;
  height: 16px;
}

.files-empty-state {
  text-align: center;
  padding: 64px 32px;
}

.files-empty-state .empty-icon-wrapper {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background-color: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.files-empty-state .empty-folder-icon {
  width: 32px;
  height: 32px;
  color: var(--text-secondary);
}

.empty-state-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  color: var(--text-secondary);
  opacity: 0.4;
}

.files-empty-state h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 8px 0;
}

.files-empty-state p {
  font-size: 15px;
  color: var(--text-secondary);
  margin: 0;
  max-width: 320px;
  margin: 0 auto;
  line-height: 1.4;
}

.empty-state-actions {
  margin-top: 24px;
}

.empty-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 9999px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  transition: background-color 0.2s;
}

.empty-action-btn:hover {
  background-color: var(--accent-hover);
}

/* Old file styles cleaned up */

/* Files Form */
.files-form-container {
  max-width: 480px;
  margin: 0 auto;
  padding: 24px 16px;
}

.files-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-location {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background-color: var(--bg-secondary);
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
}

.form-location-icon {
  width: 18px;
  height: 18px;
  color: #ffd43b;
}

.form-location strong {
  color: var(--text-primary);
}

.form-errors {
  padding: 12px 16px;
  background-color: rgba(244, 33, 46, 0.1);
  border-radius: 8px;
}

.form-errors p {
  color: #f4212e;
  font-size: 14px;
  margin: 4px 0;
}

.form-field {
  display: flex;
  flex-direction: column;
}

.form-input {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 15px;
  color: var(--text-primary);
  transition: border-color 0.15s;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-color);
}

.form-input::placeholder {
  color: var(--text-secondary);
}

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

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

.btn-cancel {
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  background: none;
  border: none;
  border-radius: 9999px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s;
}

.btn-cancel:hover {
  background-color: var(--bg-hover);
}

/* Upload Drop Zone */
.upload-drop-zone {
  position: relative;
  border: 1px dashed var(--border-color);
  border-radius: 12px;
  padding: 32px 24px;
  text-align: center;
  transition: all 0.15s;
  cursor: pointer;
}

.upload-drop-zone:hover,
.upload-drop-zone.dragover {
  border-color: var(--accent-color);
  background-color: rgba(29, 155, 240, 0.05);
}

.upload-file-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.upload-drop-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.upload-drop-icon {
  width: 32px;
  height: 32px;
  color: var(--accent-color);
}

.upload-drop-text {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
}

.upload-drop-hint {
  font-size: 13px;
  color: var(--text-secondary);
}

:root.light-mode #upload-drop-content span {
  color: #536471 !important;
}

:root.light-mode #upload-drop-content span:first-of-type,
:root.light-mode #upload-file-selected span {
  color: #000000 !important;
}

.upload-file-selected {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.upload-file-icon {
  width: 24px;
  height: 24px;
  color: var(--accent-color);
}

.upload-file-selected span {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Old file-selected kept for compat */
.file-selected {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.file-selected .file-icon {
  width: 32px;
  height: 32px;
  color: var(--accent-color);
}

.file-selected span {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
}

:root.light-mode #document_name,
:root.light-mode #document_description {
  background-color: #ffffff !important;
  color: #000000 !important;
  border-color: var(--border-color) !important;
}

.current-file-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background-color: var(--bg-secondary);
  border-radius: 12px;
}

.current-file-details {
  display: flex;
  flex-direction: column;
}

.current-file-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.current-file-meta {
  font-size: 13px;
  color: var(--text-secondary);
}
