@font-face {
   font-family: GohuFont14NerdFont;
   src: url(./GohuFont14NerdFontMono-Regular.ttf);
}

* {
   font-family: GohuFont14NerdFont;
}

:root {
    --bg-color: #1F282E;
    --bg-secondary: #1a2228;
    --text-primary: #59C99C;
    --text-secondary: #A5A9AB;
    --border-accent: #326B78;
    --border-color: #2a3a42;
    --hover-color: #326B78;
    --shadow-color: #353E4344;
    --nav-height: 92px;
}

html {
    background-color: var(--bg-color);
    scroll-behavior: smooth;
    scroll-padding-top: var(--nav-height, 92px);
}

[data-theme="light"] {
    --bg-color: #0C1012;
    --bg-secondary: #1a2228;
    --text-primary: #e8d5b7;
    --text-secondary: #b8bcc0;
    --border-accent: #b88968;
    --border-color: #3a4a52;
    --hover-color: #c9a878;
    --shadow-color: #353E4344;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 0;
}

#page-content {
    box-sizing: border-box;
    width: 100%;
    min-height: calc(100vh - var(--nav-height, 92px));
    padding-top: var(--nav-height, 92px);
}

.search_box {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    margin: 10px auto 0;
    gap: 8px;
    width: 100%;
    max-width: 80rem; /* Increased from 60rem */
}

.search_box form {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 80rem; /* Increased from 60rem */
}

.search_box #q,
.search_box input[type="text"],
.search_box input[name="q"] {
    padding: 12px 16px;
    font-size: 16px;
    background-color: var(--bg-color);
    color: var(--text-primary);
    border: 4px solid var(--border-accent);
    box-shadow: 3px 3px 1px 1px var(--shadow-color);
    border-radius: 8px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    font-family: GohuFont14NerdFont, monospace;
    height: auto;
    line-height: normal;
    flex: 1;
    min-width: 0;
    box-sizing: border-box;
}

.search_box #q:focus,
.search_box input[type="text"]:focus,
.search_box input[name="q"]:focus {
    outline: none;
    border-color: var(--hover-color);
    box-shadow: 4px 4px 2px 2px var(--shadow-color);
}

.search_box #clear_search,
.search_box #send_search,
.search_box button[type="reset"],
.search_box button[type="submit"] {
    background-color: transparent;
    color: var(--text-primary);
    border: none;
    box-shadow: none;
    padding: 12px 16px;
    cursor: pointer;
    transition: color 0.3s ease;
    font-family: GohuFont14NerdFont, monospace;
    height: auto;
    width: auto;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    border-radius: 0;
}

.search_box #clear_search:hover,
.search_box #send_search:hover,
.search_box button[type="reset"]:hover,
.search_box button[type="submit"]:hover {
    color: var(--hover-color);
    background-color: transparent;
}

.search_box .search-icon {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
}

.search_box button {
    font-size: 16px;
}

.search_box .hide_if_nojs {
    display: inline-block;
}

.search_box .show_if_nojs {
    display: none;
}

button {
    background-color: var(--bg-color);
    font-size: 30px;
    color: var(--text-primary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    height: 50px;
    width: 50px;
    margin-top: 5px;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.reaction-btn, .share-btn {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
    text-shadow: none !important;
    border-radius: 0 !important;
    height: auto !important;
    width: auto !important;
    margin: 0 !important;
    color: var(--text-primary) !important;
}

[data-theme="dark"] .reaction-btn,
[data-theme="dark"] .share-btn {
    color: #59C99C !important;
}

[data-theme="dark"] .reaction-btn:hover,
[data-theme="dark"] .share-btn:hover {
    color: #326B78 !important;
}

input {
    width: 690px;
    height: 40px;
    margin: 5px;
    background-color: var(--bg-color);
    font-size: 30px;
    color: var(--text-primary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding-left: 10px;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus, input:active {
    width: 690px;
    height: 40px;
    margin: 5px;
    background-color: var(--bg-color);
    color: var(--text-primary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    outline: none;
}

.info {
    display: flex;
    justify-content: center;
    flex-direction: row;
    margin-left: 20px;
    line-height: 0;
    margin-top: 10px;
    margin-bottom: 10px;
}

#greeting, #time {
    font-size: 48px;
    font-weight: 200;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

#blogMessage, #cheatsheetsMessage {
    font-size: 48px;
    font-weight: 200;
    color: var(--text-primary);
    margin: 0;
    text-align: center;
    transition: color 0.3s ease;
}


#blogMessage .blog-link, #cheatsheetsMessage .blog-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 48px;
    font-weight: 200;
    text-indent: 1px;
    line-height: 1.6;
    transition: color 0.3s ease;
}

#blogMessage .blog-link:visited, #blogMessage .blog-link:link, #blogMessage .blog-link:active,
#cheatsheetsMessage .blog-link:visited, #cheatsheetsMessage .blog-link:link, #cheatsheetsMessage .blog-link:active {
    color: var(--text-primary);
    text-decoration: none;
}

#blogMessage .blog-link:hover, #cheatsheetsMessage .blog-link:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

/* Weather Banner */
.weather-banner {
    text-align: center;
    margin: 20px auto 30px;
    padding: 0 20px;
}

#weatherBanner {
    font-size: 32px;
    font-weight: 200;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.6;
    transition: color 0.3s ease;
}

@media only screen and (max-width: 400px) {
    #weatherBanner {
        font-size: 20px;
    }
}

@media only screen and (max-width: 400px) {
    input {
        width: 50%;
        height: 40px;
        margin: 5px;
        background-color: var(--bg-color);
        color: var(--text-primary);
        box-shadow: 5px 5px 1px 2px var(--shadow-color);
        border-radius: 8px;
        border: var(--border-accent) solid 4px;
        padding-left: 10px;
    }

    input:focus, input:active {
        width: 50%;
        height: 40px;
        margin: 5px;
        background-color: var(--bg-color);
        color: var(--text-primary);
        box-shadow: 5px 5px 1px 2px var(--shadow-color);
    	  border-radius: 8px;
    	  border: var(--border-accent) solid 4px;
        outline: none;
    }
   .name {
	font-size: 10px;
        position: relative;
        text-align: center;
        white-space: pre;
        color: var(--text-primary);
        transition: color 0.3s ease;
    }
    
    #greeting, #time {
        font-size: 24px;
    }
    
    #blogMessage {
        font-size: 20px;
    }
}

.list_title {
    font-size: 36px;
    border-bottom: solid 2px var(--border-accent);
    transition: border-color 0.3s ease;
}

.lists {
    display: flex;
    margin-top: 25px;
    flex-wrap: wrap;
    vertical-align: center;
    justify-content: center;
}

.name {
    font-size: 20px;
    position: relative;
    text-align: center;
    white-space: pre;
    color: var(--text-primary);
    transition: color 0.3s ease;
    margin-top: 20px;
}

/* Center name header with blog-main-content on blog pages */
body:has(.blog-layout) .name {
    margin-left: calc(20px + 200px + 30px + 60px); /* Align with blog-main-content: layout padding + sidebar width + gap + header margin-left */
}

.watch, .social, .dev, .linux, .other {
    display: flex;
    flex-direction: column;
    text-align: center;
    background-color: var(--bg-secondary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    margin-top: 5px;
    margin-left: 10px;
    margin-right: 10px;
    margin-bottom: 5px;
    width: 280px;
    padding: 30px;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
}

.watch:hover, .social:hover, .dev:hover, .linux:hover, .other:hover {
    transform: scale(1.05);
}

a {
    transition: color 0.3s ease;
}

a:visited, a:link, a:active {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 30px;
    text-indent: 1px;
    line-height: 1.6;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

#w,#s,#d,#l,#e,#b {
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.gemini-link {
    position: fixed;
    top: 20px;
    left: 20px;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 8px;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
    z-index: 1000;
}

.gemini-link:hover {
    color: var(--hover-color);
}

.onion-link {
    position: fixed;
    top: 55px;
    left: 20px;
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 8px;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
    z-index: 1000;
}

.onion-link:hover {
    color: var(--hover-color);
}

/* Hamburger Menu Button (Minimal Style) */
.nav-hamburger-btn {
  background: none;
  border: none;
  color: var(--text-primary);
  height: 32px;
  width: 32px;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  flex-shrink: 0;
  margin-right: 12px;
  opacity: 0.8;
}

.nav-hamburger-btn:hover {
  opacity: 1;
  color: var(--hover-color);
  transform: scale(1.1);
}

.nav-hamburger-btn:focus {
  outline: none;
}

.hamburger-icon {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  transition: stroke 0.3s ease;
}

/* Menu Drawer Overlay */
.nav-menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 2999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.nav-menu-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* Menu Drawer */
.nav-menu-drawer {
  position: fixed;
  top: 0;
  left: -320px;
  width: 320px;
  height: 100%;
  background-color: var(--bg-secondary);
  border-right: 2px solid var(--border-accent);
  box-shadow: 4px 0 20px var(--shadow-color);
  z-index: 3000;
  overflow-y: auto;
  transition: left 0.3s ease;
}

.nav-menu-drawer.active {
  left: 0;
}

/* Menu Header */
.nav-menu-header {
  padding: 20px;
  border-bottom: 2px solid var(--border-accent);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-color);
  position: sticky;
  top: 0;
  z-index: 1;
}

.nav-menu-title {
  font-size: 24px;
  font-weight: bold;
  color: var(--text-primary);
  margin: 0;
  font-family: GohuFont14NerdFont, monospace;
}

.nav-menu-close {
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 32px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.2s ease;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-menu-close:hover {
  color: var(--hover-color);
}

/* Menu Content */
.nav-menu-content {
  padding: 10px 0;
}

/* Home Link (Special Styling) */
.nav-menu-home {
  background-color: rgba(0, 255, 0, 0.08);
  border-left-color: var(--text-primary);
  font-weight: bold;
  margin-bottom: 10px;
}

.nav-menu-home:hover {
  background-color: rgba(0, 255, 0, 0.15);
}

/* Expandable Section */
.nav-menu-expandable {
  margin-bottom: 0;
  border-bottom: 1px solid rgba(89, 201, 156, 0.1);
}

.nav-menu-section-toggle {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  padding: 16px 20px;
  font-size: 18px;
  font-weight: bold;
  font-family: GohuFont14NerdFont, monospace;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
  text-align: left;
}

.nav-menu-section-toggle:hover {
  background-color: rgba(0, 255, 0, 0.05);
  border-left-color: var(--text-primary);
}

.nav-menu-section-toggle.active {
  background-color: rgba(0, 255, 0, 0.08);
  border-left-color: var(--text-primary);
}

.nav-menu-section-label {
  flex: 1;
  font-size: 18px;
}

.nav-menu-chevron {
  font-size: 10px;
  transition: transform 0.3s ease;
  color: var(--text-secondary);
}

.nav-menu-section-toggle.active .nav-menu-chevron {
  transform: rotate(180deg);
}

/* Section Content (Collapsible) */
.nav-menu-section-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background-color: rgba(0, 0, 0, 0.15);
}

.nav-menu-section-content.expanded {
  max-height: 500px;
  padding: 4px 0;
}

/* Menu Items (Base - for Home, Login, etc.) */
.nav-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 14px;
  font-family: GohuFont14NerdFont, monospace;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.nav-menu-item:hover {
  background-color: rgba(0, 255, 0, 0.1);
  border-left-color: var(--text-primary);
}

/* Subitems (Indented, Compact) - More specific selector */
.nav-menu-section-content .nav-menu-subitem {
  padding: 8px 20px 8px 56px;
  font-size: 13px;
  font-weight: normal;
  border-bottom: 1px solid rgba(89, 201, 156, 0.05);
  color: var(--text-secondary);
  line-height: 1.4;
  gap: 8px;
  position: relative;
}

/* Marker for subitems */
.nav-menu-section-content .nav-menu-subitem::before {
  content: '›';
  position: absolute;
  left: 40px;
  color: var(--text-secondary);
  font-size: 14px;
  opacity: 0.6;
  transition: all 0.2s ease;
}

.nav-menu-section-content .nav-menu-subitem:last-child {
  border-bottom: none;
}

.nav-menu-section-content .nav-menu-subitem:hover {
  padding-left: 60px;
  background-color: rgba(0, 255, 0, 0.08);
  color: var(--text-primary);
}

.nav-menu-section-content .nav-menu-subitem:hover::before {
  left: 44px;
  color: var(--text-primary);
  opacity: 1;
}

/* SVG Icons in Menu */
.nav-menu-svg-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
}

/* Login/Register Buttons in Menu */
.nav-menu-auth-buttons {
  padding: 8px 20px;
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 10px;
}

.nav-menu-auth-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 2px;
  text-decoration: none;
  font-size: 7px;
  font-weight: bold;
  font-family: GohuFont14NerdFont, monospace;
  transition: all 0.2s ease;
  border: 1px solid var(--border-accent);
}

.nav-menu-auth-btn .nav-menu-svg-icon {
  width: 8px;
  height: 8px;
}

.nav-menu-auth-btn.login-btn {
  background-color: var(--text-primary);
  color: var(--bg-color);
  border-color: var(--text-primary);
}

.nav-menu-auth-btn.login-btn:hover {
  background-color: var(--hover-color);
  border-color: var(--hover-color);
  box-shadow: 0 0 10px rgba(89, 201, 156, 0.3);
}

.nav-menu-auth-btn.register-btn {
  background-color: transparent;
  color: var(--text-primary);
  border-color: var(--border-accent);
}

.nav-menu-auth-btn.register-btn:hover {
  border-color: var(--text-primary);
  background-color: rgba(0, 255, 0, 0.1);
}

.nav-menu-icon {
  font-size: 20px;
  line-height: 1;
  flex-shrink: 0;
}

/* Section Divider */
.nav-menu-section {
  margin-bottom: 10px;
}

.nav-menu-divider {
  height: 1px;
  background-color: var(--border-accent);
  margin: 15px 20px;
}

/* Main Navigation Bar - Floatplane Style */
.main-nav-bar {
  width: 100%;
  background: radial-gradient(ellipse 60% 100% at 50% 50%, color-mix(in srgb, var(--bg-secondary) 75%, var(--border-accent) 25%) 0%, var(--bg-secondary) 100%);
  border-bottom: 2px solid var(--border-accent);
  box-shadow: 0 2px 10px var(--shadow-color);
  padding: 15px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  overflow: visible;
  min-height: 80px;
  transition: background 0.3s ease, border-color 0.3s ease;
}

/* Left Section - Logo + Date */
.nav-left-section {
  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: flex-start;
}

.nav-branding {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-home-link {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 0.2s ease;
}

.nav-home-link:hover {
  transform: scale(1.1);
}

.nav-home-icon {
  width: 28px;
  height: 28px;
  stroke: var(--text-primary);
  transition: stroke 0.3s ease;
}

.nav-home-link:hover .nav-home-icon {
  stroke: var(--hover-color);
}

.nav-logo-link {
  text-decoration: none;
  display: flex;
  align-items: center;
}

.nav-logo-link:hover .nav-logo-text {
  color: var(--hover-color);
}

.nav-logo-text {
  font-size: 24px;
  font-weight: bold;
  color: var(--text-primary);
  font-family: GohuFont14NerdFont, monospace;
  letter-spacing: 2px;
  transition: color 0.3s ease;
}

.nav-date-display {
  font-size: 14px;
  color: var(--text-secondary);
  font-family: GohuFont14NerdFont, monospace;
  transition: color 0.3s ease;
}

/* Center Section - Inspirational Quotes */
.nav-quote-container {
  flex: 1;
  max-width: 500px;
  min-width: 200px;
  text-align: center;
  padding: 0 20px;
  font-family: GohuFont14NerdFont, monospace;
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nav-quote-text {
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-quote-text.selected {
  background-color: var(--text-primary);
  color: var(--bg-color);
}

.nav-quote-cursor {
  animation: blink-cursor 1s step-end infinite;
  color: var(--text-primary);
}

.nav-quote-cursor.hidden {
  opacity: 0;
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Right Section - Controls */
.nav-right-section {
  display: flex;
  align-items: center;
  gap: 15px;
}

/* Theme Selector Dropdown */
.theme-selector-container {
  position: relative;
}

.theme-selector-btn {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  width: 45px;
  padding: 0;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  flex-direction: column;
}

.theme-selector-btn:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
  background-color: rgba(0, 255, 0, 0.1);
}

.theme-selector-btn:focus {
  outline: none;
}

.theme-selector-icon {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  transition: stroke 0.3s ease;
}

.theme-selector-chevron {
  font-size: 10px;
  transition: transform 0.3s ease;
}

.theme-selector-btn.open .theme-selector-chevron {
  transform: rotate(180deg);
}

/* Theme Dropdown Menu */
.theme-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background-color: var(--bg-secondary);
  border: 2px solid var(--border-accent);
  border-radius: 8px;
  box-shadow: 0 4px 20px var(--shadow-color);
  min-width: 200px;
  z-index: 2000;
  animation: dropdownSlideIn 0.2s ease;
  overflow: hidden;
}

@keyframes dropdownSlideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.theme-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  cursor: pointer;
  transition: background-color 0.2s ease;
  border-bottom: 1px solid var(--border-color);
  font-family: GohuFont14NerdFont, monospace;
  font-size: 14px;
  color: var(--text-primary);
}

.theme-option:last-child {
  border-bottom: none;
}

.theme-option:hover {
  background-color: rgba(0, 255, 0, 0.1);
}

.theme-option.active {
  background-color: rgba(0, 255, 0, 0.15);
  font-weight: bold;
}

.theme-option-swatch {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  border: 2px solid var(--border-accent);
  flex-shrink: 0;
}

.theme-option-name {
  flex: 1;
}

.theme-option-check {
  font-size: 16px;
  color: var(--text-primary);
}

/* Common Icon Button Styles */
.nav-icon-btn {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  width: 45px;
  padding: 0;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  text-decoration: none;
  line-height: 1;
  box-sizing: border-box;
}

.nav-volume-control {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-mute-btn .mute-slash {
  opacity: 0;
  transition: opacity 0.2s ease;
}

.nav-mute-btn .volume-waves {
  opacity: 1;
  transition: opacity 0.2s ease;
}

.nav-mute-btn.muted {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
}

.nav-mute-btn.muted .mute-slash {
  opacity: 1;
}

.nav-mute-btn.muted .volume-waves {
  opacity: 0;
}

.nav-volume-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background-color: var(--bg-secondary);
  border: 2px solid var(--border-accent);
  border-radius: 10px;
  box-shadow: 0 4px 20px var(--shadow-color);
  padding: 12px 8px 14px;
  min-width: 72px;
  width: 72px;
  max-width: 72px;
  z-index: 2100;
  display: none;
  flex-direction: column;
  align-items: center;
  animation: dropdownSlideIn 0.2s ease;
  overflow: hidden;
  box-sizing: border-box;
}

.nav-volume-panel.open {
  display: flex;
}

.nav-volume-label {
  text-align: center;
  font-size: 10px;
  color: var(--text-secondary);
  letter-spacing: 1px;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.nav-volume-slider {
  -webkit-appearance: none;
  appearance: none;
  writing-mode: vertical-rl;
  direction: rtl;
  width: 18px !important;
  height: 140px !important;
  min-width: 18px;
  max-width: 18px;
  min-height: 140px;
  max-height: 140px;
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  outline: none;
  box-shadow: none;
  box-sizing: border-box;
}

.nav-volume-slider:focus,
.nav-volume-slider:active {
  width: 18px !important;
  height: 140px !important;
  outline: none;
  border: none;
  box-shadow: none;
}

.nav-volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: var(--text-primary);
  border: 2px solid var(--border-accent);
  box-shadow: 0 0 6px var(--shadow-color);
}

.nav-volume-slider::-webkit-slider-runnable-track {
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to top,
    var(--text-primary) 0%,
    var(--text-primary) var(--volume-percent, 100%),
    var(--bg-color) var(--volume-percent, 100%),
    var(--bg-color) 100%
  );
  border: 1px solid var(--border-color);
  border-radius: 10px;
}

.nav-volume-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: var(--text-primary);
  border: 2px solid var(--border-accent);
  box-shadow: 0 0 6px var(--shadow-color);
}

.nav-volume-slider::-moz-range-track {
  width: 100%;
  height: 100%;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 10px;
}

.nav-volume-slider::-moz-range-progress {
  background: var(--text-primary);
  border-radius: 10px;
}

.nav-icon-btn:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
  background-color: rgba(0, 255, 0, 0.1);
}

/* Nav Icon Link (for anchor-based icon buttons like Radio) */
.nav-icon-link {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  width: 45px;
  min-height: 45px;
  max-height: 45px;
  min-width: 45px;
  max-width: 45px;
  padding: 0;
  margin: 0;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  text-decoration: none;
  box-sizing: border-box;
  flex-shrink: 0;
  align-self: center;
  vertical-align: middle;
  line-height: 1;
}

.nav-icon-link:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
  background-color: rgba(0, 255, 0, 0.1);
}

.nav-icon {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}

/* Radio Waveform Button */
.nav-radio-btn {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  width: 180px;
  padding: 0;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  box-sizing: border-box;
  overflow: hidden;
  position: relative;
}

.nav-radio-btn:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
  background-color: color-mix(in srgb, var(--text-primary) 4%, transparent);
}

.nav-radio-waveform {
  display: block;
  width: 100%;
  height: 100%;
}

/* Now-playing mini display (visible when radio is playing) */
.nav-radio-nowplaying {
  display: flex;
  position: absolute;
  inset: 0;
  align-items: center;
  gap: 6px;
  padding: 0 4px;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.nav-radio-waveform {
  transition: opacity 0.4s ease;
}

.nav-radio-btn.radio-playing .nav-radio-waveform {
  opacity: 0;
}

.nav-radio-btn.radio-playing .nav-radio-nowplaying {
  opacity: 1;
  pointer-events: auto;
}

.nav-radio-mini-art {
  flex-shrink: 0;
  width: 33px;
  height: 33px;
  border-radius: 4px;
  object-fit: cover;
  filter: blur(0.7px);
  mask-image: radial-gradient(circle, #000 55%, transparent 90%);
  -webkit-mask-image: radial-gradient(circle, #000 55%, transparent 90%);
}

.nav-radio-mini-scroll {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 6px, #000 calc(100% - 12px), transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6px, #000 calc(100% - 12px), transparent);
}

.nav-radio-mini-track {
  display: inline-block;
  white-space: nowrap;
  font-family: GohuFont14NerdFont, monospace;
  font-size: 11px;
  color: var(--text-primary);
  animation: radioMarquee 18s linear infinite;
}

@keyframes radioMarquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Radio Dropdown */
.nav-radio-container {
  position: relative;
}

.nav-radio-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background-color: var(--bg-color);
  border: 2px solid var(--border-accent);
  border-radius: 8px;
  box-shadow: 0 4px 24px var(--shadow-color);
  width: 300px;
  z-index: 2000;
  animation: dropdownSlideIn 0.2s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Terminal chrome header */
.radio-dd-chrome {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  background-color: var(--bg-secondary);
  border-bottom: 2px solid var(--border-accent);
}

.radio-dd-dots {
  display: flex;
  gap: 5px;
  margin-right: 12px;
}

.radio-dd-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  opacity: 0.7;
}

.radio-dd-title {
  font-size: 11px;
  font-weight: bold;
  color: var(--text-secondary);
  font-family: GohuFont14NerdFont, monospace;
  letter-spacing: 3px;
}

/* Body with scanlines */
.radio-dd-body {
  position: relative;
  display: flex;
  flex-direction: column;
}

.radio-dd-body::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.03) 2px,
    rgba(0, 0, 0, 0.03) 4px
  );
  pointer-events: none;
  z-index: 1;
}

/* Now Playing panel */
.radio-dd-now {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  border-bottom: 1px solid var(--border-color);
  transition: box-shadow 0.4s ease, background-color 0.15s ease;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.radio-dd-now:hover {
  background-color: color-mix(in srgb, var(--text-primary) 3%, transparent);
}

.radio-dd-now.active {
  box-shadow: inset 0 0 24px var(--shadow-color);
}

.radio-dd-art {
  width: 52px;
  height: 52px;
  border-radius: 4px;
  border: 1px solid var(--border-accent);
  object-fit: cover;
  flex-shrink: 0;
}

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

.radio-dd-label {
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--text-secondary);
  opacity: 0.6;
  font-family: GohuFont14NerdFont, monospace;
  margin-bottom: 3px;
}

.radio-dd-track {
  font-size: 13px;
  font-weight: bold;
  color: var(--text-primary);
  font-family: GohuFont14NerdFont, monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.radio-dd-artist {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: GohuFont14NerdFont, monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

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

.radio-dd-station-tag {
  font-size: 10px;
  color: var(--text-secondary);
  font-family: GohuFont14NerdFont, monospace;
  opacity: 0.7;
}

/* EQ bars (shared with radio page) */
.radio-eq-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
  flex-shrink: 0;
}

.radio-eq-bar {
  display: block;
  width: 3px;
  background-color: var(--text-primary);
  border-radius: 1px;
  height: 4px;
  opacity: 0.3;
  transition: opacity 0.3s ease;
}

.radio-eq-bars.active .radio-eq-bar {
  opacity: 1;
  animation: eqBounce 0.6s ease-in-out infinite alternate;
}

.radio-eq-bars.active .radio-eq-bar:nth-child(1) { animation-delay: 0s; }
.radio-eq-bars.active .radio-eq-bar:nth-child(2) { animation-delay: 0.15s; }
.radio-eq-bars.active .radio-eq-bar:nth-child(3) { animation-delay: 0.3s; }
.radio-eq-bars.active .radio-eq-bar:nth-child(4) { animation-delay: 0.1s; }

@keyframes eqBounce {
  0% { height: 4px; }
  100% { height: 14px; }
}

/* Tune button — terminal command style */
.radio-dd-transport {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-color);
}

.radio-tune-btn {
  background: none;
  border: 1px solid var(--border-accent);
  color: var(--text-primary);
  width: 100%;
  height: 34px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  font-family: GohuFont14NerdFont, monospace;
  font-size: 13px;
  transition: all 0.2s ease;
}

.radio-tune-btn:hover {
  border-color: var(--text-primary);
  box-shadow: 0 0 8px var(--shadow-color);
  background-color: color-mix(in srgb, var(--text-primary) 4%, transparent);
}

.radio-tune-btn.tuned-in {
  border-color: var(--text-primary);
  box-shadow: 0 0 6px var(--shadow-color);
}

.radio-tune-prompt {
  color: var(--text-primary);
  font-weight: bold;
  flex-shrink: 0;
}

.radio-tune-icon {
  display: block;
  flex-shrink: 0;
}

.radio-tune-label {
  flex-shrink: 0;
}

.radio-tune-cursor::after {
  content: '\2588';
  font-size: 13px;
  animation: radioCursorBlink 1s step-end infinite;
  opacity: 0.6;
}

@keyframes radioCursorBlink {
  0%, 49% { opacity: 0.6; }
  50%, 100% { opacity: 0; }
}

/* Station list */
.radio-dd-stations {
  display: flex;
  flex-direction: column;
  max-height: 240px;
  overflow-y: auto;
}

.radio-dd-stn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
  font-family: GohuFont14NerdFont, monospace;
  font-size: 12px;
  cursor: pointer;
  transition: background-color 0.15s ease;
  text-align: left;
  width: 100%;
}

.radio-dd-stn:last-child {
  border-bottom: none;
}

.radio-dd-stn:hover {
  background-color: color-mix(in srgb, var(--text-primary) 4%, transparent);
}

.radio-dd-stn.active {
  background-color: color-mix(in srgb, var(--text-primary) 8%, transparent);
}

.radio-dd-stn-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  transition: box-shadow 0.3s ease;
}

.radio-dd-stn.active .radio-dd-stn-dot {
  animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.radio-dd-stn-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.radio-dd-stn-name {
  font-size: 12px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.radio-dd-stn-onair {
  font-size: 10px;
  color: var(--text-secondary);
  opacity: 0.6;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.radio-dd-stn-active {
  font-size: 10px;
  color: var(--text-primary);
  flex-shrink: 0;
  width: 12px;
}


/* Notifications Bell */
.nav-notifications-container {
  position: relative;
}

.nav-notifications-btn {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  width: 45px;
  padding: 0;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  position: relative;
}

.nav-notifications-btn:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 10px var(--hover-color);
  background-color: rgba(0, 255, 0, 0.1);
}

.nav-notifications-btn.has-unread {
  border-color: var(--link-color);
}

.nav-notifications-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #ff0000;
  color: #ffffff;
  font-size: 10px;
  font-weight: bold;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
  box-shadow: 0 0 5px rgba(255, 0, 0, 0.5);
  animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.nav-notifications-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background-color: var(--bg-secondary);
  border: 2px solid var(--border-accent);
  border-radius: 8px;
  box-shadow: 0 4px 20px var(--shadow-color);
  width: 350px;
  max-height: 450px;
  z-index: 2000;
  animation: dropdownSlideIn 0.2s ease;
  display: flex;
  flex-direction: column;
}

.notifications-header {
  padding: 15px;
  border-bottom: 2px solid var(--border-accent);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-color);
}

.notifications-title {
  font-size: 16px;
  font-weight: bold;
  color: var(--text-primary);
  font-family: GohuFont14NerdFont, monospace;
}

.notifications-mark-read {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 11px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s ease;
  font-family: GohuFont14NerdFont, monospace;
}

.notifications-mark-read:hover {
  color: var(--text-primary);
  background-color: rgba(0, 255, 0, 0.1);
}

.notifications-list {
  overflow-y: auto;
  max-height: 350px;
}

.notification-item {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
  transition: background-color 0.2s ease;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

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

.notification-item:hover {
  background-color: rgba(0, 255, 0, 0.05);
}

.notification-item.unread {
  background-color: rgba(0, 255, 0, 0.08);
}

.notification-icon {
  font-size: 24px;
  flex-shrink: 0;
  line-height: 1;
}

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

.notification-title {
  font-size: 13px;
  font-weight: bold;
  color: var(--text-primary);
  margin-bottom: 4px;
  font-family: GohuFont14NerdFont, monospace;
}

.notification-message {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 4px;
}

.notification-time {
  font-size: 10px;
  color: var(--text-secondary);
  opacity: 0.6;
  font-style: italic;
}

.notifications-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-secondary);
  font-style: italic;
  font-size: 13px;
}

/* Common Button Styling for Nav Controls */
.nav-user-btn {
  background: none;
  border: 2px solid var(--border-accent);
  color: var(--text-primary);
  height: 45px;
  padding: 0 15px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--shadow-color);
  font-family: GohuFont14NerdFont, monospace;
  font-weight: bold;
  font-size: 14px;
}

.nav-user-btn:focus {
  outline: none;
}

/* User Button Specific - Larger than icon buttons to fit text */
.nav-user-btn {
  height: 50px;
  padding: 8px 20px;
  min-width: 140px;
  background-color: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid var(--border-accent);
}

.nav-user-btn:hover {
  background-color: var(--hover-color);
  border-color: var(--hover-color);
  color: var(--bg-color);
  box-shadow: 0 0 15px var(--shadow-color);
}

.nav-user-btn.logged-in {
  background-color: var(--text-primary);
  color: var(--bg-color);
  border-color: var(--text-primary);
}

.nav-user-btn.logged-in:hover {
  background-color: var(--hover-color);
  border-color: var(--hover-color);
  box-shadow: 0 0 15px var(--shadow-color);
}

.nav-user-label-stacked {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.1;
  gap: 1px;
}

.user-label-top,
.user-label-bottom {
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  letter-spacing: 0.5px;
}

/* Larger text when logged in (single "PROFILE" text) */
.nav-user-btn.logged-in .user-label-top {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .main-nav-bar {
    padding: 10px 15px;
    min-height: auto;
  }

  .nav-left-section {
    gap: 3px;
  }

  .nav-home-icon {
    width: 24px;
    height: 24px;
  }

  .nav-logo-text {
    font-size: 18px;
  }

  .nav-date-display {
    font-size: 11px;
  }

  .nav-right-section {
    gap: 10px;
  }

  .nav-hamburger-btn {
    height: 28px;
    width: 28px;
    margin-right: 10px;
  }

  .nav-icon-link,
  .nav-notifications-btn {
    height: 40px;
    width: 40px;
  }

  .nav-radio-btn {
    height: 40px;
    width: 155px;
  }

  .nav-radio-mini-art {
    width: 28px;
    height: 28px;
  }

  .nav-menu-drawer {
    width: 280px;
    left: -280px;
  }

  .nav-notifications-dropdown {
    width: 300px;
    max-width: calc(100vw - 40px);
  }

  .theme-selector-btn {
    height: 40px;
    width: 40px;
  }

  .nav-user-btn {
    height: 45px;
    padding: 8px 12px;
    min-width: 100px;
  }

  .user-label-top,
  .user-label-bottom {
    font-size: 10px;
  }

  .theme-dropdown {
    min-width: 180px;
  }
}

@media (max-width: 480px) {
  .nav-right-section {
    gap: 8px;
  }

  .theme-selector-btn {
    width: 40px;
    height: 40px;
  }

  .theme-selector-icon {
    width: 18px;
    height: 18px;
  }

  .nav-notifications-dropdown {
    width: 280px;
    right: -50px;
  }

  .nav-user-btn {
    padding: 6px 10px;
    height: 40px;
    min-width: 90px;
  }

  .user-label-top,
  .user-label-bottom {
    font-size: 9px;
  }

  .theme-dropdown {
    min-width: 160px;
    right: -10px;
  }

  .theme-option {
    padding: 12px 14px;
    font-size: 12px;
  }

  .nav-radio-btn {
    height: 36px;
    width: 135px;
  }

  .nav-radio-mini-art {
    width: 24px;
    height: 24px;
  }

  .nav-radio-mini-track {
    font-size: 10px;
  }

  .nav-radio-dropdown {
    width: 260px;
    right: -20px;
  }
}


.blog-links {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 20px 40px;
    width: fit-content;
    min-width: 300px;
    margin-left: auto;
    margin-right: auto;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.cheatsheets-links {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.blog-links > a {
    font-size: 24px;
}

#recentPosts {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

#recentPosts a {
    font-size: 24px;
    padding: 5px;
}

.blog-page-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 30px;
    margin-bottom: 30px;
    margin-left: 60px;
    position: relative;
}

.blog-header-content {
    position: relative;
    width: 100%;
    max-width: 1100px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    min-height: 48px;
    padding: 0 60px; /* Add padding for absolute positioned buttons */
}

.back-link {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    text-decoration: none;
    transition: filter 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    z-index: 1;
}

.back-link:hover .home-icon {
    filter: brightness(0) saturate(100%) invert(50%) sepia(15%) saturate(800%) hue-rotate(120deg) brightness(95%) contrast(85%);
    transition: filter 0.3s ease;
}

.home-icon {
    width: 42px;
    height: 42px;
    display: block;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

[data-theme="dark"] .home-icon {
    color: #59C99C;
    filter: none !important;
}

[data-theme="dark"] .back-link:hover .home-icon {
    color: #326B78;
    filter: none !important;
}

.rss-icon-link {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-primary);
    text-decoration: none;
    transition: filter 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    z-index: 1;
}

.rss-icon-link:hover .rss-icon {
    color: var(--hover-color);
    transition: color 0.3s ease;
}

.rss-icon {
    width: 32px;
    height: 32px;
    display: block;
    color: #904b59;
    transition: color 0.3s ease;
}

[data-theme="dark"] .rss-icon {
    color: #9F789A;
}

[data-theme="dark"] .rss-icon-link:hover .rss-icon {
    color: #326B78;
}

.rss-link {
    font-size: 24px !important;
    margin-top: 10px;
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.rss-link:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

.blog-page-title {
    font-size: 48px;
    color: var(--text-primary);
    margin: 0;
    line-height: 1;
    display: flex;
    align-items: center;
    transition: color 0.3s ease;
}

.blog-posts-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    padding: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.blog-post {
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 40px;
    width: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.blog-post:hover {
    box-shadow: 7px 7px 2px 3px var(--shadow-color);
}

.blog-post-title {
    font-size: 36px;
    color: var(--text-primary);
    margin: 0 0 15px 0;
    border-bottom: solid 2px var(--border-accent);
    padding-bottom: 15px;
    line-height: 1.3;
    transition: color 0.3s ease, border-color 0.3s ease;
}

.analytics-section-title {
    font-size: 30px;
    color: var(--text-primary);
    margin: 30px 0 20px 0;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.timezone-note {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 400;
}

.blog-post-date {
    font-size: 20px;
    color: var(--text-secondary);
    margin: 0 0 20px 0;
    font-weight: 300;
    transition: color 0.3s ease;
}

.blog-post-excerpt {
    font-size: 24px;
    color: var(--text-primary);
    margin: 0 0 25px 0;
    font-style: italic;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--border-accent);
    line-height: 1.6;
    transition: color 0.3s ease, border-color 0.3s ease;
}

.blog-post-content {
    font-size: 22px;
    color: var(--text-primary);
    line-height: 1.8;
    margin-top: 20px;
    transition: color 0.3s ease;
}

.blog-post-content p {
    margin: 0 0 20px 0;
    text-align: justify;
    text-justify: inter-word;
}

.blog-post-content p:last-child {
    margin-bottom: 0;
}

.blog-post-content p:first-of-type {
    margin-top: 0;
}

.blog-post-content pre {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 15px;
    overflow-x: auto;
    margin: 15px 0;
    max-width: 100%;
}

.blog-post-content code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9em;
    background-color: var(--bg-secondary);
    padding: 2px 6px;
    border-radius: 4px;
}

.blog-post-content pre code {
    padding: 0;
    background-color: transparent;
    font-size: 0.85em;
    white-space: pre;
    display: block;
}

.blog-post-signature {
    text-align: center;
    font-size: 22px;
    color: var(--text-secondary);
    margin: 0;
    font-style: italic;
    padding: 0;
    border: none;
    flex: 1;
    min-width: 200px;
    transition: color 0.3s ease;
}

.reactions-share-wrapper {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 3px solid var(--border-accent);
    flex-wrap: wrap;
    transition: border-color 0.3s ease;
}

.reactions-container, .share-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.reactions-label, .share-label {
    font-size: 20px;
    color: var(--text-secondary);
    font-weight: 300;
    transition: color 0.3s ease;
}

.reactions-buttons, .share-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.reaction-btn {
    background: none;
    border: none;
    padding: 5px 10px;
    color: var(--text-primary);
    cursor: pointer;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
    box-shadow: none;
    outline: none;
    text-shadow: none;
}

[data-theme="dark"] .reaction-btn {
    color: #59C99C;
}

.reaction-btn:hover {
    color: var(--hover-color);
    box-shadow: none;
    outline: none;
}

[data-theme="dark"] .reaction-btn:hover {
    color: #326B78;
}

.reaction-btn:focus {
    outline: none;
    box-shadow: none;
}

.reaction-icon-img,
.share-icon-img {
    width: 20px;
    height: 20px;
    display: inline-block;
    vertical-align: middle;
    transition: fill 0.3s ease, opacity 0.3s ease, color 0.3s ease;
    color: inherit;
}

.reaction-icon-img path,
.reaction-icon-img g[fill="currentColor"],
.reaction-icon-img g[fill="currentColor"] path,
.reaction-icon-img g[fill="currentColor"] g path,
.share-icon-img path,
.share-icon-img polyline {
    fill: currentColor;
    stroke: currentColor;
    transition: fill 0.3s ease, stroke 0.3s ease;
}

[data-theme="dark"] .reaction-icon-img {
    color: #59C99C !important;
}

[data-theme="dark"] .reaction-icon-img g[fill="currentColor"],
[data-theme="dark"] .reaction-icon-img g[fill="currentColor"] path,
[data-theme="dark"] .reaction-icon-img g[fill="currentColor"] g path,
[data-theme="dark"] .reaction-icon-img path,
[data-theme="dark"] .share-icon-img {
    color: #59C99C !important;
}

[data-theme="dark"] .share-icon-img path,
[data-theme="dark"] .share-icon-img polyline,
[data-theme="dark"] .reaction-icon-img g[fill="currentColor"],
[data-theme="dark"] .reaction-icon-img g[fill="currentColor"] path,
[data-theme="dark"] .reaction-icon-img g[fill="currentColor"] g path,
[data-theme="dark"] .reaction-icon-img path {
    fill: #59C99C !important;
    stroke: #59C99C !important;
}

[data-theme="dark"] .reaction-btn:hover .reaction-icon-img {
    color: #326B78 !important;
}

[data-theme="dark"] .reaction-btn:hover .reaction-icon-img g[fill="currentColor"],
[data-theme="dark"] .reaction-btn:hover .reaction-icon-img g[fill="currentColor"] path,
[data-theme="dark"] .reaction-btn:hover .reaction-icon-img g[fill="currentColor"] g path,
[data-theme="dark"] .reaction-btn:hover .reaction-icon-img path {
    fill: #326B78 !important;
    stroke: #326B78 !important;
}

[data-theme="dark"] .share-btn:hover .share-icon-img {
    color: #326B78 !important;
}

[data-theme="dark"] .share-btn:hover .share-icon-img path,
[data-theme="dark"] .share-btn:hover .share-icon-img polyline {
    fill: #326B78 !important;
    stroke: #326B78 !important;
}

.reaction-btn:hover .reaction-icon-img,
.share-btn:hover .share-icon-img {
    opacity: 0.8;
}

[data-theme="dark"] .reaction-btn:hover .reaction-icon-img,
[data-theme="dark"] .share-btn:hover .share-icon-img {
    opacity: 1;
}

.reaction-count {
    font-size: 20px;
    color: var(--text-secondary);
    font-weight: 300;
    transition: color 0.3s ease;
}

.share-btn {
    background: none;
    border: none;
    padding: 5px 10px;
    color: var(--text-primary);
    cursor: pointer;
    transition: color 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
    outline: none;
    text-shadow: none;
}

[data-theme="dark"] .share-btn {
    color: #59C99C;
}

.share-btn:hover {
    color: var(--hover-color);
    box-shadow: none;
    outline: none;
}

[data-theme="dark"] .share-btn:hover {
    color: #326B78;
}

.share-btn:focus {
    outline: none;
    box-shadow: none;
}

.error {
    color: var(--border-accent);
    font-size: 24px;
    text-align: center;
    padding: 20px;
    transition: color 0.3s ease;
}

.analytics-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.stat-card {
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 20px;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.stat-value {
    font-size: 48px;
    color: var(--text-primary);
    font-weight: 200;
    transition: color 0.3s ease;
}

.stat-label {
    font-size: 20px;
    color: var(--text-secondary);
    margin-top: 10px;
    transition: color 0.3s ease;
}

.hour-chart {
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 4px;
    margin-top: 20px;
    padding: 20px 10px 40px 10px;
    height: 300px;
}

.hour-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    flex: 1;
    max-width: calc(100% / 24);
    height: 260px;
}

.hour-visual {
    width: 100%;
    background-color: var(--text-primary);
    border-radius: 4px 4px 0 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 5px 0;
    color: var(--bg-color);
    font-size: 12px;
    transition: background-color 0.3s ease, opacity 0.3s ease, color 0.3s ease;
    opacity: 0.85;
    flex: none;
    height: var(--bar-height, 0px);
    flex-basis: var(--bar-height, 0px);
    min-height: 0;
}

.hour-visual:hover {
    background-color: var(--hover-color);
    opacity: 1;
}

.hour-label {
    font-size: 14px;
    color: var(--text-secondary);
    writing-mode: horizontal-tb;
    text-align: center;
    margin-top: 5px;
    transition: color 0.3s ease;
}

.date-selector-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    margin: 0;
    width: 200px;
    min-width: 200px;
    max-width: 200px;
}

.date-selector {
    margin: 0;
    padding: 10px;
    font-size: 20px;
    border: 4px solid var(--border-accent);
    border-radius: 8px;
    background-color: var(--bg-color);
    color: var(--text-primary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    cursor: pointer;
    width: 200px !important;
    min-width: 200px !important;
    max-width: 200px !important;
    box-sizing: border-box;
    flex-shrink: 0;
    position: relative;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.date-selector:hover {
    border-color: var(--hover-color);
    width: 200px !important;
}

.date-selector:focus {
    outline: none;
    border-color: var(--hover-color);
    width: 200px !important;
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
}

.date-selector:active {
    width: 200px !important;
}

.date-selector::-webkit-calendar-picker-indicator {
    display: none;
}

.date-selector::-webkit-datetime-edit {
    color: var(--text-primary);
}

.date-selector::-webkit-datetime-edit-fields-wrapper {
    color: var(--text-primary);
}

.date-selector::-webkit-datetime-edit-text {
    color: var(--text-secondary);
}

.date-selector::-webkit-datetime-edit-month-field,
.date-selector::-webkit-datetime-edit-day-field,
.date-selector::-webkit-datetime-edit-year-field {
    color: var(--text-primary);
}

.custom-calendar {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 5px;
    background-color: var(--bg-color);
    border: 4px solid var(--border-accent);
    border-radius: 8px;
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    padding: 15px;
    z-index: 1000;
    display: none;
    width: 350px;
    box-sizing: border-box;
    min-width: 350px;
    max-width: 350px;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.custom-calendar.show {
    display: block;
}

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

.calendar-nav-btn {
    background-color: var(--bg-color);
    border: 4px solid var(--border-accent);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 18px;
    padding: 5px 15px;
    cursor: pointer;
    box-shadow: 3px 3px 1px 1px var(--shadow-color);
    transition: border-color 0.3s ease, color 0.3s ease, background-color 0.3s ease;
}

.calendar-nav-btn:hover {
    border-color: var(--hover-color);
    color: var(--hover-color);
}

.calendar-month-year {
    font-size: 20px;
    color: var(--text-primary);
    font-weight: 200;
    transition: color 0.3s ease;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.calendar-weekday {
    text-align: center;
    font-size: 16px;
    color: var(--text-secondary);
    font-weight: 300;
    transition: color 0.3s ease;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.calendar-day {
    background-color: var(--bg-color);
    border: 2px solid var(--border-accent);
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 16px;
    padding: 10px 8px;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.calendar-day:hover {
    background-color: var(--hover-color);
    border-color: var(--hover-color);
    color: var(--bg-color);
}

.calendar-day.other-month {
    color: var(--text-secondary);
    opacity: 0.5;
}

.calendar-day.today {
    border-color: var(--text-primary);
    border-width: 3px;
    font-weight: 400;
}

.calendar-day.selected {
    background-color: var(--text-primary);
    border-color: var(--text-primary);
    color: var(--bg-color);
}

.visitors-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.visitors-table thead {
    background-color: var(--bg-color);
    border-bottom: 2px solid var(--border-accent);
}

.visitors-table th {
    padding: 12px 8px;
    text-align: left;
    color: var(--text-primary);
    font-weight: bold;
    font-size: 14px;
}

.visitors-table td {
    padding: 10px 8px;
    border-bottom: 1px solid var(--border-accent);
    color: var(--text-secondary);
    font-size: 13px;
}

.visitors-table tbody tr:hover {
    background-color: var(--hover-color);
    transition: background-color 0.2s ease;
}

.visitor-time {
    font-family: monospace;
    color: var(--text-primary);
}

.visitor-ip {
    font-family: monospace;
    color: var(--text-primary);
}

.visitor-location {
    color: var(--text-secondary);
}

.country-code {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 6px;
    background-color: var(--border-accent);
    color: var(--bg-color);
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
}

.visitor-isp {
    color: var(--text-secondary);
    font-size: 12px;
}

.visitor-page {
    font-family: monospace;
    color: var(--text-secondary);
    font-size: 12px;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

[data-theme="dark"] .visitors-table thead {
    background-color: var(--bg-color);
}

[data-theme="dark"] .visitors-table tbody tr:hover {
    background-color: rgba(50, 107, 120, 0.2);
}

[data-theme="dark"] .country-code {
    background-color: var(--border-accent);
    color: var(--bg-color);
}

.blog-posts-stats {
    margin-top: 30px;
}

.post-stat-card {
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 20px;
    margin-bottom: 20px;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.post-stat-title {
    font-size: 24px;
    color: var(--text-primary);
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    transition: color 0.3s ease;
}

.post-stat-row {
    display: flex;
    gap: 20px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.post-stat-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.post-stat-item-label {
    font-size: 16px;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.post-stat-item-value {
    font-size: 28px;
    color: var(--text-primary);
    font-weight: 200;
    transition: color 0.3s ease;
}

.date-selector-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
    flex-shrink: 0;
    margin-bottom: 20px;
}

.date-selectors-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 20px;
    flex-wrap: nowrap;
}

.date-label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    height: 20px;
    line-height: 20px;
    flex-shrink: 0;
}

.date-go-button-wrapper {
    display: flex;
    align-items: flex-end;
    height: 100%;
    padding-bottom: 0;
}

.go-button {
    padding: 10px;
    font-size: 20px;
    border: 4px solid var(--border-accent);
    border-radius: 8px;
    background-color: var(--bg-color);
    color: var(--text-primary);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    font-family: inherit;
    box-sizing: border-box;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    width: 40px;
    min-width: 40px;
    max-width: 40px;
    min-height: 40px;
    max-height: 40px;
}

.go-button:hover {
    border-color: var(--hover-color);
    background-color: var(--hover-color);
    color: var(--bg-color);
}

.go-button:active {
    box-shadow: 3px 3px 1px 1px var(--shadow-color);
    transform: translate(2px, 2px);
}

/* Blog Layout with Sidebar */
.blog-layout {
    display: flex;
    flex-direction: row;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    align-items: flex-start;
}

.blog-sidebar {
    position: sticky;
    top: 20px;
    width: 200px;
    flex-shrink: 0;
    background-color: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-left: 20px;
    padding-right: 20px;
    padding-bottom: 20px;
    padding-top: 20px;
    margin-top: 0;
}

.sidebar-post-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 10px;
    padding: 4px 8px;
    border-radius: 3px;
    transition: background-color 0.3s ease, color 0.3s ease;
    display: block;
    line-height: 1.4;
}

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

.sidebar-post-link.active {
    background-color: var(--border-accent);
    color: var(--text-primary);
    font-weight: 400;
    padding: 4px 8px;
}

.blog-main-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.blog-post-container {
    display: flex;
    flex-direction: column;
    padding: 0;
    width: 100%;
    flex: 1;
}

.cheatsheet-category {
    margin-top: 40px !important;
    margin-bottom: 20px !important;
    font-size: 38px !important;
    font-weight: 600 !important;
    color: var(--text-primary) !important;
    border-bottom: solid 2px var(--border-accent) !important;
    padding-bottom: 10px !important;
    text-align: center !important;
    width: 100% !important;
}

.blog-post-preview {
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 30px;
    width: 100%;
    margin-bottom: 20px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.blog-post-preview:hover {
    box-shadow: 7px 7px 2px 3px var(--shadow-color);
    transform: translateY(-2px);
}

.blog-post-preview p {
    color: var(--text-secondary);
    margin: 10px 0 0 0;
    font-size: 18px;
    line-height: 1.5;
    transition: color 0.3s ease;
}

.blog-post-link {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-post-link:hover {
    color: var(--hover-color);
}

.blog-read-more {
    display: inline-block;
    margin-top: 15px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.blog-read-more:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

/* Responsive design for mobile */
@media only screen and (max-width: 768px) {
    .blog-layout {
        flex-direction: column;
        padding: 10px;
    }
    
    .blog-sidebar {
        position: static;
        width: 100%;
        order: 2;
    }
    
    .blog-main-content {
        order: 1;
    }
    
    .sidebar-nav {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 10px;
    }
}

/* Error page styles */
.error-container {
    text-align: center;
    margin-top: 50px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    padding: 20px;
}

.error-code {
    font-size: 4em;
    margin-bottom: 20px;
}

.error-title {
    margin-bottom: 30px;
}

.error-message {
    font-size: 1.2em;
    margin-bottom: 30px;
    font-style: italic;
    color: var(--text-secondary, #62696D);
}

.error-back-link {
    margin-top: 40px;
}

.error-back-link a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.2em;
    transition: color 0.3s ease;
}

.error-back-link a:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

/* Game Server Browser Styles */
.games-card {
    position: relative;
}

.games-server-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
}

.game-server-item {
    display: flex;
    flex-direction: column;
    padding: 8px;
    border-left: 3px solid var(--border-accent);
    transition: border-color 0.3s ease;
}

.game-server-item:hover {
    border-left-color: var(--hover-color);
}

.server-link {
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    font-size: 24px;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.server-link:hover {
    color: var(--hover-color);
    text-decoration: none;
}

.server-status {
    font-size: 16px;
}

.server-name {
    flex: 1;
}

.server-players {
    font-size: 18px;
    color: var(--text-secondary);
}

.server-details-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    font-size: 14px;
    align-self: flex-start;
    margin-top: 4px;
    box-shadow: none;
    width: auto;
    height: auto;
    transition: color 0.3s ease;
}

.server-details-btn:hover {
    color: var(--hover-color);
}

.server-details {
    margin-top: 8px;
    padding-left: 12px;
    font-size: 16px;
    color: var(--text-secondary);
}

.server-details p {
    margin: 4px 0;
    line-height: 1.4;
}

.server-details strong {
    color: var(--text-primary);
}

.player-list {
    list-style: none;
    padding-left: 0;
    margin: 4px 0;
}

.player-list li {
    padding: 2px 0;
    color: var(--text-primary);
}

.games-last-updated {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid var(--border-accent);
    font-size: 14px;
    color: var(--text-secondary);
    text-align: center;
}

.games-last-updated small {
    font-style: italic;
}

.games-last-updated .stale {
    color: var(--border-accent);
}

.error-text {
    color: var(--border-accent);
    font-size: 14px;
}

.no-servers, .error {
    text-align: center;
    color: var(--text-secondary);
    font-style: italic;
    padding: 10px 0;
}

/* Individual Server Cards - dark outer card (like homepage cards) */
.server-card {
    background-color: var(--bg-color);
    box-shadow: 5px 5px 1px 2px var(--shadow-color);
    border-radius: 8px;
    border: var(--border-accent) solid 4px;
    padding: 30px;
    margin: 30px auto;
    max-width: 800px;
    transition: transform 0.2s ease;
    scroll-margin-top: 90px;
}

.server-card:first-child {
    margin-top: 20px;
}

.server-card:hover {
    transform: scale(1.02);
}

/* Lighter foreground card with live data */
.server-foreground-card {
    background-color: #1a2328;
    border: 2px solid var(--border-accent);
    padding: 20px;
    margin: 20px 0;
    border-radius: 4px;
}

.server-info-section {
    margin-top: 20px;
}

.server-info-section h2 {
    margin-bottom: 15px;
}

.server-info-section p {
    font-size: 16px;
    line-height: 1.5;
}

.servers-footer {
    text-align: center;
    margin: 30px auto;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 14px;
    font-style: italic;
}

.server-status-card:hover {
    transform: scale(1.02);
}

.server-name {
    margin: 0 0 10px 0;
    font-size: 36px;
    color: var(--text-primary);
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-accent);
}

.server-status-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-accent);
}

.server-status-header h3 {
    margin: 0;
    font-size: 24px;
    color: var(--text-primary);
}

.status-indicator {
    font-size: 32px;
    line-height: 1;
}

.status-indicator.online {
    color: #59C99C;
}

.status-indicator.offline {
    color: #ff6b6b;
}

.server-status-content {
    min-height: 100px;
}

.server-stats {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-accent);
}

.stat-label {
    font-weight: bold;
    color: var(--text-primary);
    font-size: 18px;
    min-width: 150px;
}

.stat-value {
    color: var(--text-secondary);
    font-size: 18px;
    text-align: right;
    flex: 1;
}

.online-text {
    color: #59C99C;
    font-weight: bold;
    font-size: 24px;
}

.offline-text {
    color: #ff6b6b;
    font-weight: bold;
    font-size: 24px;
}

.players-online {
    flex-direction: column;
    align-items: flex-start;
}

.players-online .player-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
    width: 100%;
}

.player-name {
    background-color: rgba(89, 201, 156, 0.2);
    padding: 5px 12px;
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 16px;
    border: 1px solid var(--border-accent);
}

.server-status-footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid var(--border-accent);
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
    font-style: italic;
}

.error-message {
    color: var(--border-accent);
    font-size: 16px;
    text-align: center;
    padding: 20px;
}

/* Copy Address Button Styles */
.copy-address-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 4px 6px;
    margin-left: 8px;
    vertical-align: middle;
    transition: color 0.3s ease, transform 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
    width: auto;
    height: auto;
}

.copy-address-btn:hover {
    color: var(--hover-color);
    transform: scale(1.1);
}

.copy-address-btn.copied {
    color: #59C99C;
}

.copy-icon {
    width: 16px;
    height: 16px;
    stroke: currentColor;
}

.server-motd {
    color: var(--text-secondary);
    font-style: italic;
    font-size: 16px;
}

/* Profile Page Styles - Cleaner, Less Card-Heavy */
.profile-container {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 30px;
}

.profile-section {
  padding: 40px 0;
  border-bottom: 2px solid var(--border-accent);
  transition: border-color 0.3s ease;
}

.profile-section:last-child {
  border-bottom: none;
}

.profile-section-title {
  font-size: 28px;
  color: var(--text-primary);
  margin: 0 0 25px 0;
  font-weight: 600;
  transition: color 0.3s ease;
}

.profile-section-description {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: 1.6;
  transition: color 0.3s ease;
}

/* Account Info Grid */
.profile-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.profile-info-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  background-color: var(--bg-secondary);
  border-left: 4px solid var(--border-accent);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.profile-info-item:hover {
  border-left-color: var(--hover-color);
}

.profile-info-label {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color 0.3s ease;
}

.profile-info-value {
  font-size: 20px;
  color: var(--text-primary);
  font-weight: 500;
  font-family: GohuFont14NerdFont, monospace;
  transition: color 0.3s ease;
}

.profile-info-id {
  color: var(--text-secondary);
  font-size: 16px;
}

/* Profile Forms */
.profile-form {
  max-width: 600px;
  margin-top: 25px;
}

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

.profile-form-label {
  display: block;
  margin-bottom: 10px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.profile-form-input {
  width: 100%;
  padding: 14px 16px;
  font-size: 16px;
  background-color: var(--bg-color);
  color: var(--text-primary);
  border: 2px solid var(--border-accent);
  border-radius: 6px;
  font-family: GohuFont14NerdFont, monospace;
  box-sizing: border-box;
  transition: border-color 0.3s ease, background-color 0.3s ease, color 0.3s ease;
}

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

.profile-form-hint {
  display: block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
  transition: color 0.3s ease;
}

/* Profile Buttons */
.profile-btn {
  width: 100%;
  max-width: 400px;
  padding: 16px 24px;
  font-size: 16px;
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  font-family: GohuFont14NerdFont, monospace;
  transition: all 0.3s ease;
  letter-spacing: 1px;
  border: 2px solid transparent;
}

.profile-btn-link {
  display: inline-block;
  text-align: center;
  text-decoration: none;
}

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

.profile-btn-primary:hover {
  background-color: var(--hover-color);
  border-color: var(--hover-color);
  box-shadow: 0 4px 12px rgba(89, 201, 156, 0.3);
}

.profile-btn-danger {
  background-color: #660000;
  color: #ff0000;
  border-color: #ff0000;
}

.profile-btn-danger:hover {
  background-color: #880000;
  box-shadow: 0 4px 12px rgba(255, 0, 0, 0.3);
}

.profile-btn-danger-alt {
  background-color: transparent;
  color: #ff0000;
  border-color: #ff0000;
}

.profile-btn-danger-alt:hover {
  background-color: #330000;
  box-shadow: 0 4px 12px rgba(255, 0, 0, 0.3);
}

/* Danger Zone Styling - Expandable */
.profile-danger-section {
  border: none;
  padding: 20px 0;
}

.danger-zone-toggle {
  width: 100%;
  padding: 20px;
  background-color: transparent;
  border: 2px solid #ff0000;
  border-radius: 6px;
  color: #ff0000;
  font-size: 18px;
  font-weight: 600;
  font-family: GohuFont14NerdFont, monospace;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.3s ease;
  box-shadow: none;
  height: auto;
  margin: 0;
}

.danger-zone-toggle:hover {
  background-color: rgba(255, 0, 0, 0.1);
  border-color: #ff3333;
}

.danger-zone-icon {
  font-size: 24px;
  margin-right: 10px;
}

.danger-zone-text {
  flex: 1;
  text-align: left;
}

.danger-zone-chevron {
  font-size: 16px;
  transition: transform 0.3s ease;
}

.danger-zone-toggle.expanded .danger-zone-chevron {
  transform: rotate(180deg);
}

.danger-zone-content {
  padding: 30px 20px 10px;
  border-left: 3px solid #ff0000;
  margin-top: 20px;
  background-color: rgba(255, 0, 0, 0.05);
  border-radius: 0 6px 6px 0;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Message Box */
#messageBox {
  border-radius: 6px;
  font-family: GohuFont14NerdFont, monospace;
}

#messageBox.success {
  border-left-color: var(--text-primary);
  color: var(--text-primary);
}

#messageBox.error {
  border-left-color: #ff0000;
  color: #ff0000;
}

/* Achievements Browser */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.achievement-card {
  background-color: var(--bg-color);
  border: 2px solid var(--border-accent);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 3px 3px 0 var(--shadow-color);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.achievement-card:hover {
  border-color: var(--hover-color);
  box-shadow: 0 0 15px var(--hover-color);
  transform: translateY(-2px);
}

.achievement-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.achievement-icon {
  font-size: 32px;
  line-height: 1;
  flex-shrink: 0;
}

.achievement-name {
  font-size: 18px;
  font-weight: bold;
  color: var(--text-primary);
  margin: 0;
  flex: 1;
}

.achievement-rarity {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 10px;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 4px;
  font-weight: bold;
  letter-spacing: 0.5px;
}

.achievement-rarity.common {
  background-color: rgba(150, 150, 150, 0.2);
  color: #999;
  border: 1px solid #666;
}

.achievement-rarity.rare {
  background-color: rgba(89, 201, 156, 0.2);
  color: var(--text-primary);
  border: 1px solid var(--text-primary);
}

.achievement-rarity.epic {
  background-color: rgba(138, 43, 226, 0.2);
  color: #a855f7;
  border: 1px solid #8b5cf6;
}

.achievement-rarity.legendary {
  background-color: rgba(255, 215, 0, 0.2);
  color: #ffd700;
  border: 1px solid #ffa500;
}

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

.achievement-unlocks {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background-color: rgba(89, 201, 156, 0.1);
  border-left: 3px solid var(--text-primary);
  border-radius: 4px;
  margin-bottom: 10px;
}

.achievement-unlocks-label {
  font-size: 12px;
  font-weight: bold;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.achievement-unlocks-value {
  font-size: 13px;
  color: var(--text-secondary);
  font-style: italic;
}

.achievement-date {
  font-size: 11px;
  color: var(--text-secondary);
  opacity: 0.7;
  margin-top: 8px;
  text-align: right;
  font-style: italic;
}

.achievements-loading,
.achievements-error,
.achievements-empty {
  padding: 40px 20px;
  text-align: center;
  font-size: 14px;
}

/* Responsive Profile */
@media (max-width: 768px) {
  .profile-container {
    padding: 0 20px;
  }

  .profile-section {
    padding: 30px 0;
  }

  .profile-section-title {
    font-size: 24px;
  }

  .profile-info-grid {
    grid-template-columns: 1fr;
  }

  .profile-btn {
    max-width: none;
  }

  .achievements-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .achievement-card {
    padding: 16px;
  }

  .achievement-icon {
    font-size: 28px;
  }

  .achievement-name {
    font-size: 16px;
  }
}

/* Player Statistics Styles */
.top-players-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.top-player-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    border: 1px solid var(--border-accent);
}

.player-rank {
    font-weight: bold;
    color: var(--border-accent);
    font-size: 18px;
    min-width: 35px;
}

.top-player-item .player-name {
    flex: 1;
    background-color: rgba(89, 201, 156, 0.15);
    font-size: 16px;
}

.player-playtime {
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: bold;
    min-width: 80px;
    text-align: right;
}

/* ==================== WIDGETS CONTAINER ==================== */

.widgets-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    padding: 20px;
    max-width: 1300px;
    margin: 0 auto;
}

/* ==================== SERVER STATUS WIDGET ==================== */

.server-status-widget {
    width: 340px;
    height: 400px;
    flex: 0 0 auto;
    margin: 0;
    padding: 20px;
    background-color: var(--bg-secondary);
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    box-shadow: 0 4px 15px var(--shadow-color);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.widget-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 15px;
}

.widget-icon {
    font-size: 20px;
    color: var(--text-primary);
    font-weight: bold;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.widget-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-primary);
    margin: 0;
    flex: 1;
}

.widget-status {
    font-size: 12px;
    color: var(--text-secondary);
}

.server-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

.server-list::-webkit-scrollbar {
    width: 6px;
}

.server-list::-webkit-scrollbar-track {
    background: var(--bg-color);
}

.server-list::-webkit-scrollbar-thumb {
    background: var(--border-accent);
    border-radius: 3px;
}

.server-loading {
    text-align: center;
    color: var(--text-secondary);
    padding: 20px;
    font-style: italic;
}

.server-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.server-item:hover {
    background-color: rgba(0, 255, 0, 0.1);
    border-color: var(--hover-color);
    transform: translateX(5px);
}

.server-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.server-status-dot.online {
    background-color: #00ff00;
    box-shadow: 0 0 8px #00ff00;
    animation: statusPulse 2s ease-in-out infinite;
}

.server-status-dot.offline {
    background-color: #666666;
}

@keyframes statusPulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 8px #00ff00; }
    50% { opacity: 0.7; box-shadow: 0 0 4px #00ff00; }
}

.server-status-widget .server-info {
    flex: 1;
    min-width: 0;
}

.server-status-widget .server-item-name {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.server-status-widget .server-game {
    font-size: 12px;
    color: var(--text-secondary);
}

.server-status-widget .server-item-players {
    font-size: 13px;
    color: var(--text-primary);
    white-space: nowrap;
}

.server-status-widget .server-players-count {
    color: var(--link-color);
    font-weight: bold;
}

.server-empty-state {
    text-align: center;
    color: var(--text-secondary);
    padding: 30px 20px;
}

.server-empty-state svg {
    width: 48px;
    height: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.server-empty-text {
    font-size: 14px;
    margin-bottom: 5px;
}

.server-empty-subtext {
    font-size: 12px;
    opacity: 0.7;
}

/* ==================== BOOKMARKS WIDGET ==================== */

.bookmarks-widget {
    width: 340px;
    height: 400px;
    flex: 0 0 auto;
    margin: 0;
    padding: 20px;
    background-color: var(--bg-secondary);
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    box-shadow: 0 4px 15px var(--shadow-color);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.widget-manage-link {
    font-size: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s;
}

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

.bookmarks-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

.bookmarks-list::-webkit-scrollbar {
    width: 6px;
}

.bookmarks-list::-webkit-scrollbar-track {
    background: var(--bg-color);
}

.bookmarks-list::-webkit-scrollbar-thumb {
    background: var(--border-accent);
    border-radius: 3px;
}

.bookmarks-loading {
    text-align: center;
    color: var(--text-secondary);
    padding: 20px;
    font-style: italic;
}

.bookmark-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
    min-height: 0;
}

.bookmark-item:hover {
    background-color: rgba(0, 255, 0, 0.1);
    border-color: var(--hover-color);
    transform: translateX(3px);
}

.bookmark-pin {
    font-size: 12px;
    flex-shrink: 0;
}

.bookmark-favicon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    border-radius: 2px;
}

.bookmark-title {
    font-size: 13px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
}

.bookmark-folder-group {
    margin-top: 4px;
}

.bookmark-folder-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    padding: 6px 10px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
    text-align: left;
    transition: color 0.2s;
}

.bookmark-folder-toggle:hover {
    color: var(--text-primary);
}

.bookmark-folder-chevron {
    font-size: 10px;
}

.bookmark-folder-count {
    opacity: 0.6;
    font-size: 11px;
}

.bookmark-folder-items {
    padding-left: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.bookmarks-empty {
    text-align: center;
    color: var(--text-secondary);
    padding: 30px 20px;
}

.bookmarks-empty-text {
    font-size: 13px;
    margin-bottom: 8px;
}

.bookmarks-empty-link {
    font-size: 12px;
    color: var(--link-color, var(--text-primary));
    text-decoration: none;
}

.bookmarks-empty-link:hover {
    text-decoration: underline;
}

/* Responsive adjustments for widgets */
@media (max-width: 550px) {
    .widgets-container {
        padding: 10px;
        gap: 15px;
    }

    .server-status-widget {
        width: calc(100vw - 40px);
        max-width: 320px;
        padding: 15px;
    }

    .news-feed-widget {
        width: calc(100vw - 40px);
        max-width: 500px;
        padding: 15px;
    }

    .bookmarks-widget {
        width: calc(100vw - 40px);
        max-width: 340px;
        padding: 15px;
    }

    .server-status-widget .server-item {
        padding: 10px 12px;
    }

    .server-status-widget .server-item-name {
        font-size: 13px;
    }

    .server-status-widget .server-item-players {
        font-size: 12px;
    }
}

/* News Feed Widget */
.news-feed-widget {
    width: 500px;
    height: 400px;
    flex: 0 0 auto;
    margin: 0;
    padding: 20px;
    background-color: var(--bg-secondary);
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    box-shadow: 0 4px 15px var(--shadow-color);
    display: flex;
    flex-direction: column;
}

.news-tabs {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.news-tab {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    transition: all 0.2s ease;
    height: auto;
    width: auto;
    margin: 0;
    box-shadow: none;
}

.news-tab:hover {
    border-color: var(--hover-color);
    color: var(--text-primary);
}

.news-tab.active {
    background-color: var(--border-accent);
    border-color: var(--border-accent);
    color: var(--text-primary);
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    overflow-y: auto;
}

.news-item {
    display: block;
    padding: 12px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

a.news-item:hover {
    background-color: rgba(0, 255, 0, 0.1);
    border-color: var(--hover-color);
}

.news-item.priority-high {
    border-left: 3px solid #ff6b6b;
}

.news-title {
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 6px;
    line-height: 1.4;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-secondary);
}

.news-source {
    opacity: 0.8;
}

.news-loading, .news-empty {
    text-align: center;
    color: var(--text-secondary);
    padding: 30px;
    font-style: italic;
}

/* News list scrollbar styling */
.news-list::-webkit-scrollbar {
    width: 6px;
}

.news-list::-webkit-scrollbar-track {
    background: var(--bg-color);
}

.news-list::-webkit-scrollbar-thumb {
    background: var(--border-accent);
    border-radius: 3px;
}

/* Additional responsive adjustments for news feed widget */
@media (max-width: 600px) {
    .news-tabs {
        flex-wrap: wrap;
    }

    .news-tab {
        padding: 6px 12px;
        font-size: 12px;
    }

    .news-item {
        padding: 10px;
    }

    .news-title {
        font-size: 13px;
    }
}

/* ==================== IM CHAT WIDGET (right sidebar) ==================== */

.im-chat-widget {
    position: fixed;
    right: 95px;
    top: calc(var(--nav-height, 92px) + 4px);
    bottom: 2px;
    width: 340px;
    padding: 16px;
    background-color: var(--bg-secondary);
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    box-shadow: 0 4px 15px var(--shadow-color);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 50;
}

.im-chat-widget .widget-status {
    font-size: 11px;
}

.im-chat-widget .widget-status.connected {
    color: #00ff00;
}

.im-online-count {
    font-size: 11px;
    color: var(--text-secondary);
    padding: 2px 10px 4px;
    border-bottom: 1px solid var(--border-color);
    font-family: monospace;
}

/* Chat screen (always visible) */
.im-chat-screen {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.im-message-list {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding-bottom: 8px;
}

.im-message-list::-webkit-scrollbar {
    width: 6px;
}

.im-message-list::-webkit-scrollbar-track {
    background: var(--bg-color);
}

.im-message-list::-webkit-scrollbar-thumb {
    background: var(--border-accent);
    border-radius: 3px;
}

.im-msg {
    padding: 3px 6px;
    font-size: 13px;
    line-height: 1.4;
    word-break: break-word;
    position: relative;
}

.im-msg:hover {
    background: rgba(255, 255, 255, 0.03);
}

.im-msg-time {
    color: var(--text-secondary);
    font-size: 11px;
    opacity: 0.7;
    margin-right: 4px;
}

.im-msg-badge {
    font-size: 10px;
    color: #ff6b6b;
    font-weight: bold;
    text-transform: uppercase;
    margin-right: 2px;
}

.im-msg-nick {
    font-weight: bold;
    color: var(--link-color);
    margin-right: 4px;
}

.im-msg-nick.is-admin {
    color: #ff6b6b;
}

.im-msg-text {
    color: var(--text-primary);
}

.im-msg-deleted {
    color: var(--text-secondary);
    font-style: italic;
    opacity: 0.6;
}

/* Admin hover controls */
.im-msg-actions {
    display: none;
    position: absolute;
    right: 4px;
    top: 2px;
    gap: 4px;
}

.im-msg:hover .im-msg-actions {
    display: flex;
}

.im-msg-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: max-content;
    white-space: nowrap;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 10px;
    padding: 1px 6px;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.4;
}

.im-msg-action-btn:hover {
    border-color: #ff6666;
    color: #ff6666;
}

/* Inline nickname bar */
.im-nickname-bar {
    display: flex;
    gap: 6px;
    padding: 8px 0 4px;
}

.im-nickname-bar.hidden {
    display: none;
}

.im-nickname-input {
    flex: 1;
    padding: 6px 10px;
    background: var(--bg-color);
    border: 1px solid var(--border-accent);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 12px;
    box-sizing: border-box;
}

.im-nickname-input:focus {
    outline: none;
    border-color: var(--link-color);
}

.im-join-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: max-content;
    white-space: nowrap;
    padding: 6px 12px;
    background: none;
    border: 1px solid var(--border-accent);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.im-join-btn:hover {
    border-color: var(--link-color);
    color: var(--link-color);
}

.im-nickname-error {
    font-size: 11px;
    color: #ff6666;
    min-height: 0;
    padding: 0 2px;
}

.im-nickname-error:empty {
    display: none;
}

/* Input bar */
.im-input-bar {
    display: flex;
    gap: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border-color);
    margin-top: 4px;
}

.im-input {
    flex: 1;
    padding: 8px 10px;
    background: var(--bg-color);
    border: 1px solid var(--border-accent);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 13px;
    box-sizing: border-box;
}

.im-input:focus {
    outline: none;
    border-color: var(--link-color);
}

.im-input:disabled {
    opacity: 0.5;
}

.im-send-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: max-content;
    white-space: nowrap;
    padding: 8px 14px;
    background: none;
    border: 1px solid var(--border-accent);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.im-send-btn:hover:not(:disabled) {
    border-color: var(--link-color);
    color: var(--link-color);
}

.im-send-btn:disabled {
    opacity: 0.4;
    cursor: default;
}

/* ── Ambient decoration strip (right gutter) ── */

.im-ambient-strip {
    position: fixed;
    right: 0;
    top: 0;
    width: 95px;
    height: 100vh;
    height: 100dvh;
    z-index: 50;
    pointer-events: none;
}

/* Responsive — stack below page on narrow screens */
@media (max-width: 1100px) {
    .im-chat-widget {
        position: static;
        width: calc(100vw - 40px);
        max-width: 500px;
        height: 400px;
        margin: 20px auto;
        right: auto;
    }

    .im-ambient-strip {
        display: none;
    }
}

/* ==========================================
   Modal Dialog System
   Custom replacements for alert/confirm/prompt
   ========================================== */

.modal-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.modal-dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-dialog-box {
    background: var(--bg-color);
    border: 2px solid var(--border-accent);
    padding: 24px;
    min-width: 300px;
    max-width: 450px;
    width: 90%;
    transform: scale(0.9);
    transition: transform 0.2s ease;
    overflow: hidden;
}

/* Override global input:focus width for modal dialogs */
.modal-dialog-box input,
.modal-dialog-box input:focus,
.modal-dialog-box input:active {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
}

.modal-dialog-box.active {
    transform: scale(1);
}

.modal-dialog-content {
    margin-bottom: 20px;
}

.modal-dialog-message {
    color: var(--text-primary);
    font-size: 1rem;
    line-height: 1.5;
    margin: 0;
    word-wrap: break-word;
}

.modal-dialog-input,
.modal-dialog-input:focus,
.modal-dialog-input:active,
input.modal-dialog-input,
input.modal-dialog-input:focus,
input.modal-dialog-input:active {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    margin-top: 15px !important;
    padding: 10px 12px !important;
    background: var(--bg-secondary) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 4px !important;
    color: var(--text-primary) !important;
    font-family: inherit !important;
    font-size: 0.9rem !important;
    box-sizing: border-box !important;
    outline: none !important;
}

.modal-dialog-input:focus,
input.modal-dialog-input:focus {
    border-color: var(--border-accent) !important;
}

.modal-dialog-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.modal-dialog-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    min-width: max-content;
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    border: 2px solid var(--border-color);
    transition: all 0.2s ease;
}

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

.modal-dialog-btn-secondary:hover {
    border-color: var(--border-accent);
}

.modal-dialog-btn-primary {
    background: var(--border-accent);
    border-color: var(--border-accent);
    color: var(--bg-color);
}

.modal-dialog-btn-primary:hover {
    filter: brightness(1.1);
}

.modal-dialog-btn:focus {
    outline: 2px solid var(--border-accent);
    outline-offset: 2px;
}

@media (max-width: 400px) {
    .modal-dialog-box {
        padding: 18px;
        min-width: unset;
    }

    .modal-dialog-buttons {
        flex-direction: column;
    }

    .modal-dialog-btn {
        width: 100%;
    }
}

/* ============================================
   Two-Factor Authentication Styles
   ============================================ */

.profile-status-box {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    border-radius: 8px;
    border: 2px solid;
}

.profile-status-box .status-icon {
    font-size: 20px;
}

.profile-status-box.profile-status-success {
    background: rgba(0, 255, 0, 0.05);
    border-color: #00aa00;
    color: #00ff00;
}

.profile-status-box.profile-status-warning {
    background: rgba(255, 170, 0, 0.05);
    border-color: #aa7700;
    color: #ffaa33;
}

.profile-status-box.profile-status-info {
    background: rgba(0, 170, 255, 0.05);
    border-color: #0077aa;
    color: #00aaff;
}

.qr-code-container {
    background: white;
    padding: 15px;
    border-radius: 8px;
    display: inline-block;
}

.manual-code-display {
    display: block;
    padding: 15px;
    background: var(--bg-secondary);
    border: 2px solid var(--border-accent);
    border-radius: 4px;
    font-size: 16px;
    letter-spacing: 2px;
    word-break: break-all;
    user-select: all;
}

.totp-input {
    letter-spacing: 8px !important;
    text-align: center !important;
    font-size: 24px !important;
}

.twofa-setup-steps {
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    padding: 20px;
    background: var(--bg-secondary);
}

.twofa-step-title {
    color: var(--text-primary);
    margin: 0 0 10px 0;
    font-size: 16px;
}

.recovery-codes-warning {
    background: rgba(255, 170, 0, 0.1);
    border: 2px solid #aa7700;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.recovery-codes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
}

.recovery-code {
    display: block;
    padding: 10px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-accent);
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
    letter-spacing: 1px;
    user-select: all;
}

/* ============================================
   Connected Services Styles
   ============================================ */

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.service-card {
    border: 2px solid var(--border-accent);
    border-radius: 8px;
    padding: 20px;
    background: var(--bg-secondary);
}

.service-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.service-icon {
    font-size: 24px;
    font-weight: bold;
    color: var(--link-color);
    flex-shrink: 0;
}

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

.service-name {
    margin: 0;
    font-size: 16px;
    color: var(--text-primary);
}

.service-status {
    margin: 4px 0 0 0;
    font-size: 12px;
    color: var(--text-secondary);
}

.service-description {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 0 0 15px 0;
}

.service-setup,
.service-request,
.service-pending,
.service-connected {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-accent);
}

.service-id {
    display: block;
    padding: 10px;
    background: var(--bg-color);
    border: 1px solid var(--border-accent);
    border-radius: 4px;
    font-size: 14px;
    word-break: break-all;
    margin-top: 5px;
}

/* Toggle Switch */
.service-toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
    flex-shrink: 0;
}

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

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border-accent);
    transition: 0.3s;
    border-radius: 26px;
}

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

.service-toggle input:checked + .toggle-slider {
    background-color: #00aa00;
}

.service-toggle input:checked + .toggle-slider:before {
    transform: translateX(24px);
    background-color: #00ff00;
}

.service-toggle input:disabled + .toggle-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Profile button variants */
.profile-btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-accent);
}

.profile-btn-secondary:hover:not(:disabled) {
    background-color: var(--border-accent);
    border-color: var(--link-color);
}

@media (max-width: 600px) {
    .services-grid {
        grid-template-columns: 1fr;
    }

    .recovery-codes-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
