﻿/* ========================================= */
/* FONTS                                    */
/* ========================================= */
@font-face {
  font-family: SFMono;
  src: url('/assets/fonts/SFMonoMedium.otf');
  font-weight: normal;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: MIB;
  src: url("/assets/fonts/MIB.ttf");
  font-display: block;
}

@font-face {
  font-family: Inconsolata;
  src: url("/assets/fonts/Inconsolata.ttf");
  font-display: block;
}

@font-face {
  font-family: SourceCode;
  src: url("/assets/fonts/SourceCodePro.ttf");
  font-display: block;
}

@font-face {
  font-family: Terminus;
  src: url("/assets/fonts/Terminus.ttf");
  font-display: block;
}

@font-face {
  font-family: Hack;
  src: url("/assets/fonts/Hack.ttf");
  font-display: block;
}

/* ========================================= */
/* GLOBAL VARIABLES                          */
/* ========================================= */

/* @media (prefers-color-scheme: dark) {
    :root {
      --bg-color: linear-gradient(173deg,rgba(0, 0, 0, 1) 0%, rgb(33, 33, 33) 100%);
      --terminal-bg: rgba(0, 0, 0, 0.3);
      --terminal-border: rgba(255, 255, 255, 0.12);
      --box-shadow: 0 0px 10px rgba(0, 0, 0, 0.5);
      --blur: none;
      --terminal-font: Inconsolata, monospace, "Courier New", Courier;
      --terminal-output: #969696;
      --text-color: #969696;
      --text-color-main: #969696;
      --accent-color: #00ff00;
      --accent-color-b: #a7a7a7e1; 
      --cmd-color: #00ff00;
      --input-bg: transparent;
      --input-bg-mobile: rgba(255, 255, 255, 0.2);
      --input-border: rgba(255, 255, 255, 0.12);
      --input-focus: rgba(0, 0, 0, 0.3);
      --input-focus-border: #00ff00;
      --input-shadow: rgba(255, 255, 255, 0.3);
      --input-placeholder-text: #969696;
      --scroll-thumb: #00ff00;
      --scroll-track: rgba(0, 0, 0, 0);
      --resp: rgb(182, 182, 182);   
    }
  }
*/

:root {
  /* Colors */
  --logo-color: #A0A0A0;
  --bg-color: #333;
  --bg-color-solid: #040405;
  --text-color: #888888;
  --text-color-main: #a0a0a0;
  --accent-color: #7CCF00;
  --accent-color-b: #5EA500;
  --cmd-color: #7CCF00;
  --resp: rgb(182, 182, 182);

  /* Terminal Specifics */
  --terminal-bg: rgba(0, 0, 0, 0.7);
  --terminal-border: rgba(255, 255, 255, 0.05);
  --terminal-font: SFMono, Inconsolata, Terminus, monospace;
  --terminal-output: #888888;
  --terminal-border-radius: 16px;
  --box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
  --blur: none; 
  --new-terminal-shadow: 10px 20px 30px rgba(0, 0, 0, 0.5);
  --new-window-shadow: 10px 30px rgba(0, 0, 0, .5);

  /* Inputs */
  --input-bg: transparent;
  --input-bg-mobile: rgba(255, 255, 255, 0.2);
  --input-border: rgba(255, 255, 255, 0.12);
  --input-focus: rgba(0, 0, 0, 0.3);
  --input-focus-border: #7CCF00;
  --input-shadow: rgba(255, 255, 255, 0.3);
  --input-placeholder-text: rgb(182, 182, 182);

  /* Scrollbars */
  --scroll-thumb: #7CCF00;
  --scroll-track: rgba(0, 0, 0, 0);

  /* UI Components */
  --menu-dropdown-bg: rgba(10, 10, 10, 0.69);
  --menu-dropdown-text-color: #a0a0a0;
  --menu-dropdown-text-color-hover: #111;
  --menu-dropdown-icon-color: #6F6F6F;
  --menu-dropdown-border-color: rgba(255, 255, 255, 0.12);
  --window-border-radius: 16px;
  --menu-border-radius: 13px;
  --sidebar-border-radius: 16px;
}

/* ========================================= */
/* RESET & BASE                              */
/* ========================================= */
html {
  scrollbar-color: var(--scroll-thumb) var(--scroll-track);
  scrollbar-width: thin;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--terminal-bg-color, var(--bg-color, #000)) !important;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  background-attachment: fixed;
  color: var(--text-color);
  font-family: var(--terminal-font);
  font-size: 14px;
  padding: 0;
  overflow-x: hidden;
  overflow-y: hidden;
}

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

a:hover {
  color: var(--accent-color-b);
  text-decoration: none;
}

::selection {
  background: var(--accent-color, #00FF00);
  color: var(--selection-font-color, #000000);
}

h1 {
  font-family: MIB;
  font-size: 2em;
  color: var(--logo-color, #A0A0A0);
  letter-spacing: 2px;
}

h2 {
  margin-bottom: 0;
}

/* ========================================= */
/* BOOT SCREEN                   */
/* ========================================= */
#boot {
  position: fixed;
  inset: 0;
  background-color: black;
  z-index: 9999;
  display: none;
  width: 100dvw;
  height: 100dvh;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.init {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.circle {
  width: 360px;
  height: 360px;
  border: 10px solid #333;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.dot {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: red;
  box-shadow: 0 0 30px red;
  animation: blink 0.6s infinite alternate;
}

@keyframes blink {
  from { opacity: 1; }
  to { opacity: 0.1; }
}

.title {
  font-family: MIB;
  font-size: 3rem;
  letter-spacing: 4px;
  font-weight: bold;
  margin: 20px 0;
  color: #444;
}

.subtitle {
  font-size: 1.2rem;
  color: #444;
  margin-bottom: 40px;
}

.progress-container {
  width: 100%;
  max-width: 500px;
  height: 14px;
  background-color: #111;
  border: 1px solid #444;
  border-radius: 8px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background-color: #444;
  transition: width 0.2s ease-in-out;
}

/* ========================================= */
/* MAIN LAYOUT                                */
/* ========================================= */
#os {
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.5s ease;
}

#os.fade-in.show {
  opacity: 1;
  visibility: visible;
}

.terminal-window {
  max-width: 950px;
  margin: 0 auto;
  opacity: 0;
}

.terminal-window.show {
  opacity: 1;
  padding: 10px;
}

/* ========================================= */
/* TOP MENU BAR                               */
/* ========================================= */
#menubar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 28px;
  background-color: rgba(0, 0, 0, 0.0);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 15px;
  color: #FFFFFF;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  z-index: 99999;
}

.menu-bar-left {
  display: flex;
  align-items: center;
  gap: 15px;
  height: 100%;
}

.innertel-logo a{
  font-size: 16px;
  color: #FFFFFF;
  cursor: pointer;
  padding: 0 5px;
  margin-left: -5px;
  transition: background-color 0.1s;
  font-weight: bold;
}

.innertel-logo a:hover{
   color: var(--accent-color-b);
}

.menu-item:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.app-name {
  font-weight: 600;
  color: #FFFFFF;
  margin-right: 5px;
}

.app-menu-items {
  display: flex;
  gap: 15px;
}

.menu-item {
  cursor: pointer;
  padding: 0 5px;
  color: rgba(255, 255, 255, 0.9);
  transition: background-color 0.1s;
}

.menu-item a {
  color: rgba(255, 255, 255, 0.9);
}

.menu-bar-right {
  display: flex;
  align-items: center;
  gap: 15px;
}

.system-icon,
.system-icon a {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  padding: 0 3px;
  height: 28px;
  line-height: 28px;
  transition: background-color 0.1s;
}

.system-icon:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.system-time-date {
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  padding: 0 3px;
  height: 28px;
  line-height: 28px;
  cursor: default;
}

/* ========================================= */
/* DROPDOWNS & MENUS               */
/* ========================================= */
#account-menu,
#places-dropdown,
#new-dropdown,
#app-menu-dropdown {
  position: fixed;
  z-index: 100000;
  background-color: var(--menu-dropdown-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--menu-dropdown-border-color);
  border-radius: var(--menu-border-radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px) scale(0.98);
  transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.2s;
  will-change: transform, opacity, backdrop-filter;
}

#account-menu.show,
#places-dropdown.show,
#new-dropdown.show,
#app-menu-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

#account-menu {
  top: 34px;
  right: 10px;
  width: 200px;
  max-width: 280px;
  padding: 8px;
}

.account-menu-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

#places-dropdown,
#new-dropdown {
  top: 28px;
  left: 10px;
  min-width: 200px;
  padding: 6px;
}

/* User Profile Header */
.menu-header {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  margin-bottom: 4px;
}

.user-avatar {
  width: 32px;
  height: 32px;
  background-color: var(--accent-color-b);
  color: white;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  margin-right: 12px;
  flex-shrink: 0;
}

.user-info {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  overflow: hidden;
}

.user-name {
  font-weight: 500;
  font-size: 14px;
  color: #FFFFFF;
}

.user-email {
  font-size: 12px;
  color: #8A8F98;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.active-indicator {
  color: lime;
  font-size: 10px;
  margin-left: 8px;
}

/* Dropdown Menu Items */
.account-menu-list li .menu-item {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--menu-dropdown-text-color);
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 13px;
  transition: background-color 0.15s ease;
  margin-bottom: 2px;
}

.account-menu-list li .menu-item:hover {
  background-color: var(--accent-color-b);
  color: var(--menu-dropdown-text-color-hover);
}

.account-menu-list li .menu-item i {
  width: 20px;
  margin-right: 10px;
  color: var(--menu-dropdown-icon-color);
  text-align: center;
  font-size: 14px;
}

.account-menu-list li .menu-item:hover i {
  color: var(--menu-dropdown-text-color-hover);
}

.menu-divider {
  height: 1px;
  background-color: var(--menu-dropdown-border-color);
  margin: 6px 0;
  list-style: none;
}

.menu-item.danger:hover,
.menu-item.danger:hover i {
  color: #ff6b6b;
}

/* Theme Toggle */
.menu-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  color: var(--menu-dropdown-text-color);
  font-family: inherit;
}

.menu-label {
  font-size: 13px;
  font-weight: 500;
}

.theme-toggle-pill {
  display: flex;
  background-color: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--menu-dropdown-border-color);
  border-radius: 50px;
  padding: 2px;
  gap: 2px;
}

.theme-btn {
  background: transparent;
  border: none;
  color: #666;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-size: 12px;
}

.theme-btn:hover {
  color: #EDEDED;
}

.theme-btn.active {
  background-color: #36383A;
  color: #EDEDED;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Generic Dropdown */
.dropdown-list {
  list-style: none;
  margin: 0;
  padding: 4px;
}

.dropdown-list li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  color: var(--menu-dropdown-text-color);
  text-decoration: none;
  border-radius: 8px;
  transition: background-color 0.15s ease;
}

.dropdown-list li a i {
  width: 18px;
  text-align: center;
  color: var(--menu-dropdown-icon-color);
}

.dropdown-list li a:hover {
  background-color: var(--accent-color-b);
  color: var(--menu-dropdown-text-color-hover);
}

.dropdown-list li a:hover i {
  color: var(--menu-dropdown-text-color-hover);
}

/* ========================================= */
/* SIDEBAR & FEEDS                           */
/* ========================================= */

/* --- Overlay ---  
.panel-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1; 
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
    backdrop-filter: blur(2px);
}

.panel-overlay.active {
    opacity: 1;
    visibility: visible;
}
*/

.sidebar {
  position: fixed;
  top: 30px;
  right: -400px;
  width: 370px;
  height: calc(100dvh - 35px - 35px) !important; /* 45px gives a 5px safety buffer above taskbar */
  /* Ensure it doesn't get cut off horizontally on small screens */
  max-width: 98vw;
  background-color: rgba(0, 0, 0, 0.84);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid #1a1a1a;
  border-radius: var(--sidebar-border-radius);
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.7);
  z-index: 3000;
  transition: right 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  font-family: var(--font-family);
}

.sidebar.open {
  right: 5px;
}

.sidebar-header {
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: transparent;
}

.sidebar-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--text-color-main, #e0e0e0);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.close-btn {
  background: none;
  border: none;
  color: #666;
  font-size: 1.2rem;
  cursor: pointer;
  transition: color 0.2s;
}

.close-btn:hover {
  color: #ff5555;
}

.sidebar-body {
  flex: 1;
  overflow-y: auto;
  padding: 5px;
}

.feed-item-card {
  padding: 15px 20px;
  border: 1px solid #1a1a1a5c;
  transition: background 0.2s;
  border-radius: 10px;
  margin-top: 5px;
}

.feed-item-card:hover {
  background: #0f0f0f;
}

.feed-item-card .icon-col,
.feed-item-card .user,
.user {
  color: var(--text-color-main, #a0a0a0);
}

.feed-item-card .icon-col {
  margin-right: 5px;
}

.feed-item-card .user {
  font-weight: bold;
}

.feed-item-card .action {
  color: #b0b0b0;
}

.feed-item-card .meta {
  display: block;
  margin-top: 5px;
  font-size: 0.75rem;
  color: #555;
}

.date {
  color: #CB5489;
}

/* ========================================= */
/* WINDOW MANAGER & TASKBAR                  */
/* ========================================= */
#window-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 40px;
  pointer-events: none;
}

.new-terminal-window {
  border-radius: var(--terminal-border-radius);
  position: absolute;
  background: var(--terminal-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: var(--text-color-main);
  border: 1px solid var(--terminal-border);
  box-shadow: var(--new-terminal-shadow);
  width: 950px;
  height: 555px;
  resize: both;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  pointer-events: auto;
  z-index: 1;
}

.window-header {
  padding: 4px 8px;
  cursor: move;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.controls {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 15px;
  background: rgba(0, 0, 0, 0.3);
}

.window-header2 .controls button {
  background: none;
  color: var(--cmd-color);
  border: none;
  font-size: 14px;
  cursor: pointer;
  margin-left: 5px;
}

.window-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.window-output {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  white-space: pre-wrap;
}

.window-form {
  display: flex;
  border-top: 0 solid #333;
}

.window-input {
  flex: 1;
  background: transparent;
  color: var(--text-color-main);
  border: none;
  padding: 8px;
  font-family: var(--terminal-font);
  outline: none;
}

/* Hide the send button on desktop */
.window-send-btn {
  display: none;
}

.new-terminal-window.maximized {
  top: 30px !important;
  left: 0 !important;
  width: 100% !important;
  height: calc(100dvh - 70px) !important; 
  /* height: calc(100vh - 28px - 40px) !important; */
  resize: none;
}

#taskbar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: transparent;
  display: flex;
  align-items: center;
  padding: 0 10px;
  gap: 8px;
  border-top: 0 solid #333;
  z-index: 9999;
}

.taskbar-btn {
  background: rgba(0, 0, 0, 0.3);
  color: var(--cmd-color);
  border: 1px solid var(--cmd-color);
  padding: 4px 8px;
  font-size: 12px;
  cursor: pointer;
  border-radius: 15px;
}

/* ========================================= */
/* COMMAND / NAVIGATION MENU         */
/* ========================================= */
#command-menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 15vh;
  z-index: 4000;
  opacity: 1;
  transition: opacity 0.2s ease-in-out;
}

#command-menu {
  width: 100%;
  max-width: 600px;
  background-color: rgba(10, 10, 10, 0.90);
  border-radius: var(--menu-border-radius);
  border: 1px solid var(--menu-dropdown-border-color);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  margin: 10px;
}

.search-container {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--menu-dropdown-border-color);
}

.search-container i {
  color: #888;
  margin-right: 12px;
}

.search-container input {
  width: 100%;
  background: none;
  border: none;
  outline: none;
  color: #f0f0f0;
  font-size: 1rem;
}

.search-container input::placeholder {
  color: #888;
}

.navigation-list {
  padding: 8px;
}

.navigation-list p {
  font-size: 0.8rem;
  color: #888;
  padding: 4px 12px;
  margin: 0;
}

.navigation-list ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.navigation-list li a {
  display: flex;
  align-items: center;
  padding: 12px;
  text-decoration: none;
  color: #dcdcdc;
  border-radius: 8px;
  transition: background-color 0.15s ease;
}

.navigation-list li a:hover {
  background-color: #2D2D2D;
  color: #fff;
}

.navigation-list li a i {
  width: 20px;
  margin-right: 16px;
  text-align: center;
  color: #888;
}

.navigation-list li a:hover i {
  color: #fff;
}

.hidden {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

/* ========================================= */
/* UPLOADS                      */
/* ========================================= */
.upload-wrapper {
  margin-top: 10px;
  font-family: monospace;
  transition: opacity 0.5s ease;
  margin-left: 2px;
}

.upload-wrapper.fade-out {
  opacity: 0;
}

.upload-status {
  color: #ccc;
  margin-bottom: 5px;
}

.upload-progress-bar {
  width: 230px;
  border: 0px solid lime;
  height: 10px;
  border-radius: 0px;
  overflow: hidden;
  position: relative;
}

.upload-progress-fill {
  height: 10px;
  width: 0%;
  background: lime;
  border: 1px solid lime;
  height: 10px;
  border-radius: 0px;
  transition: width 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: bold;
  color: black;
}

.upload-progress-percent {
  pointer-events: none;
}

.upload-prompt-button {
  display: inline-block;
  padding: 10px 18px;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #000;
  background: var(--cmd-color, #00C4FF);
  border: 2px solid var(--cmd-color, #00C4FF);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  white-space: nowrap;
}

.upload-prompt-button:hover,
.upload-prompt-button:active {
  background: var(--cmd-color, #00C4FF);
  color: #111;
  box-shadow: 0 4px 12px rgba(0, 196, 255, 0.3);
}

.upload-prompt-button i {
  margin-right: 8px;
}

/* ========================================= */
/* TERMINAL COMPONENT           */
/* ========================================= */
.terminal {
  margin-top: 50px;
  padding: 10px;
  background-color: var(--terminal-bg);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  opacity: 1;
  border: 1px solid var(--terminal-border);
  border-radius: var(--terminal-border-radius);
  box-shadow: var(--box-shadow);
  transition: all 0.3s ease;
}

#output {
  display: block;
  white-space: pre-wrap;
  min-height: 200px;
  max-height: 50dvh;
  overflow-y: auto;
  scroll-behavior: smooth;
  word-break: break-word;
  box-sizing: border-box;
  margin-right: -10px;
  padding-bottom: 5px;
  padding-right: 9px;
}

#output pre {
  font-family: inconsolata;
  font-size: 16px;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
}

.raw_html {
  white-space: normal;
}

.cli {
  margin: 0;
  display: flex;
}

.prompt {
  position: relative;
  width: 100%;
}

#commandInput {
  background-color: transparent;
  color: var(--cmd-color);
  border: none;
  outline: none;
  width: 100%;
  font-size: 1em;
  font-family: inherit;
  text-decoration: none;
  padding-right: 10px;
}

input::placeholder {
  color: var(--input-placeholder-text);
  opacity: 1;
}

#mobileSendBtn {
  display: none;
}

.no-pre {
  white-space: normal;
  display: inline-block;
  margin: 0;
}

/* Terminal Forms */
.terminal-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  font-family: monospace;
  margin: 0.5rem 0;
}

.terminal-form input {
  background-color: #000;
  color: var(--cmd-color);
  border: 1px solid var(--terminal-border);
  font-family: inherit;
  font-size: 1rem;
  padding: 0.25rem 0.5rem;
  border-radius: 2px;
  outline: none;
  width: 10rem;
  transition: box-shadow 0.1s ease-in-out;
}

.terminal-form input:focus {
  box-shadow: 0 0 5px var(--terminal-border);
}

.terminal-form button {
  background-color: #000;
  color: var(--cmd-color);
  border: 1px solid var(--terminal-border);
  font-family: inherit;
  font-size: 1rem;
  padding: 0.25rem 0.75rem;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.1s, color 0.1s;
}

.terminal-form button:hover {
  background-color: var(--terminal-border);
  color: #000;
  box-shadow: 0 0 5px var(--terminal-border);
}

#login-feedback {
  margin-left: 0.5rem;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--cmd-color);
}

.mobile-send {
  display: none;
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  font-size: 1.2rem;
  color: var(--accent-color);
  cursor: pointer;
}

/* ========================================= */
/* WELCOME & OUTPUT             */
/* ========================================= */
.welcome {
  font-size: 1em;
  color: var(--text-color-main);
  white-space: normal !important;
  margin: 0;
  line-height: 1.1;
}

.welcome-header {
  font-size: 1em;
  font-weight: bold;
  text-align: left;
  margin-bottom: 0px;
  color: var(--text-color-main);
}

.welcome-line {
  margin: 0px 0;
}

.welcome-divider {
  border-top: 1px solid #8D8D94;
  width: 50%;
  margin: 15px 0;
}

.welcome-instructions {
  margin-top: 30px;
  margin-bottom: 10px;
  margin-left: 2px;
  line-height: 1.4;
}

#welcome-dot, #net-dot {
  font-weight: bold;
  animation: blink 1s infinite;
}

/* Animation Container */
.terminal-animation {
  width: 100%;
  max-width: 800px;
}

.typed-line {
  display: flex;
  align-items: center;
}

.cursor {
  display: inline-block;
  width: 10px;
  height: 1.2rem;
  background-color: var(--cmd-color);
  margin-left: 5px;
  animation: blinkBlock 1s step-end infinite;
}

@keyframes blinkBlock {
  0%, 100% { background-color: transparent; }
  50% { background-color: var(--cmd-color); }
}

.response-text {
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  margin-top: 0.5rem;
  padding-left: 0;
  color: var(--text-color-main);
}

.response-text.visible {
  opacity: 1;
}

.response-text a {
  color: var(--cmd-color);
  text-decoration: none;
}

.response-text a:hover {
  color: var(--text-color-main);
}

.cmd {
  color: var(--cmd-color);
  font-weight: bold;
}

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

.cmd-box {
  color: var(--accent-color);
  font-weight: bold;
  border: 1px solid var(--accent-color);
  padding: 2px;
  border-radius: 5px;
}

.stats {
  white-space: normal;
  line-height: 1.5;
  margin-left: 3px;
}

/* ========================================= */
/* APP WINDOWS                  */
/* ========================================= */
.app-window {
  position: absolute;
  background-color: #2b2b2b;
  border: 1px solid #444;
  border-radius: var(--window-border-radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 200px;
  min-height: 150px;
}

.app-window-header {
  background: #000000;
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: grab;
  user-select: none;
  border-bottom: 0px solid #111;
}

.app-window-header:active {
  cursor: grabbing;
}

.app-window-title {
  color: #eee;
  font-size: 0.9rem;
  font-family: var(--terminal-font);
  display: flex;
  align-items: center;
  gap: 8px;
}

.app-window-content {
  flex: 1;
  position: relative;
  background-color: #fff;
  overflow: hidden;
}

@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  50% { transform: translateX(5px); }
  75% { transform: translateX(-5px); }
  100% { transform: translateX(0); }
}

.shake-window {
  animation: shake 0.3s ease-in-out;
}

.app-window-controls {
  display: flex;
  gap: 2px;
  background-color: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 16px;
  padding: 2px;
}

.app-window.maximized {
  top: 30px !important;
  height: calc(100dvh - 70px) !important; 
}

.app-minimize-btn,
.app-maximize-btn,
.app-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.8rem;
}

.app-minimize-btn { color: #febc2e; }
.app-minimize-btn:hover { color: #e0a628; }

.app-maximize-btn { color: #28c840; }
.app-maximize-btn:hover { color: #1e9e30; }

.app-close-btn { color: #ff5f56; padding: 0 5px; }
.app-close-btn:hover { color: #ff3b30; }

/* Resizers */
.resizer {
  position: absolute;
  z-index: 100;
}

.resizer.bottom-right {
  width: 15px;
  height: 15px;
  right: 0;
  bottom: 0;
  cursor: se-resize;
}

.resizer.bottom {
  height: 5px;
  bottom: 0;
  left: 0;
  right: 0;
  cursor: s-resize;
}

.resizer.right {
  width: 5px;
  right: 0;
  top: 0;
  bottom: 0;
  cursor: e-resize;
}

/* ========================================= */
/* NEWS & FEEDS                 */
/* ========================================= */
.news-output {
  white-space: normal;
  line-height: 1.5;
  font-family: inherit;
}

.news-article {
  display: block;
  text-decoration: none;
  color: var(--text-color-main);
  margin-bottom: 6px;
}

.news-article:hover {
  color: var(--accent-color-b);
}

.news-article .source {
  display: block;
  font-size: 0.9em;
  opacity: 0.7;
  margin-top: 2px;
}

.news-separator {
  border-bottom: 1px dashed #444;
  margin: 10px 0;
  opacity: 0.4;
}

.weather-info {
  white-space: none;
  color: var(--text-color-main);
}

.archive-entry {
  margin-bottom: 10px;
  white-space: normal;
}

.archive-output a,
.concerts-output a {
  color: #33ff33;
  text-decoration: underline;
}

.events-container {
  color: var(--text-color-main);
}

.event-item {
  padding-bottom: 20px;
  border-bottom: 0px dashed #ccc;
}

.concert-entry {
  margin-bottom: 12px;
  white-space: normal;
}

.artist-output {
  white-space: normal;
  color: #888888;
}

/* ========================================= */
/* INBOX / CHAT                 */
/* ========================================= */
.inbox {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.msg {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  font-family: var(--terminal-font, monospace);
  transition: background 0.2s ease;
  white-space: normal;
}

.msg:hover {
  background: rgba(255, 255, 255, 0.08);
}

.msg-content {
  flex: 1;
  overflow: hidden;
  padding-left: 2px;
}

.msg-header {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-bottom: 4px;
  color: #ccc;
}

.username {
  font-weight: bold;
  color: #fff;
  text-transform: lowercase;
}

.time {
  font-size: 0.8rem;
  color: #777;
}

.msg-body {
  color: #ddd;
  line-height: 1.4;
}

.msg-actions {
  margin-left: 10px;
}

.inline-thread-content {
  padding-left: 10px;
  font-size: 0.9em;
  margin-bottom: 12px;
}

.thread-messages-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.thread-status-indicators {
  display: inline-flex;
  align-items: center;
  margin-right: 3px;
}

.read-status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-left: 6px;
  flex-shrink: 0;
}
.read-status-dot.green { background-color: lime; }
.read-status-dot.red { background-color: #dc3545; }
.read-status-dot.grey { background-color: #adb5bd; }

/* Bubbles */
.message-bubble-wrapper {
  display: flex;
  align-items: center;
  max-width: 90%;
}

.message-bubble-wrapper.message-other { align-self: flex-start; }
.message-bubble-wrapper.message-self { align-self: flex-end; flex-direction: row-reverse; }

.message-bubble-container {
  display: flex;
  flex-direction: column;
}

.message-bubble-wrapper.message-self .message-bubble-container { align-items: flex-end; }

.message-bubble-inline {
  padding: 8px 12px;
  border-radius: 18px;
  background-color: rgba(255, 255, 255, 0.08);
  word-break: break-word;
  text-align: left !important;
}

.message-bubble-wrapper.message-self .message-bubble-inline {
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.message-footer {
  font-size: 0.8rem;
  opacity: 0.7;
  margin-top: 5px;
  padding: 0 5px;
}

.message-bubble-wrapper.message-self .message-footer { text-align: right; }
.message-bubble-wrapper.message-other .message-footer { text-align: left; }

.reply-btn,
.delete-msg-btn {
  background: transparent;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  transition: color 0.2s ease;
}

.reply-btn { color: #fff; }
.delete-msg-btn { color: #ff5555; }
.delete-msg-btn:hover { color: #ff0404; }

.delete-inline-msg-btn {
  opacity: 0;
  width: 0;
  overflow: hidden;
  transition: width 0.2s ease, opacity 0.2s ease;
  margin: auto 0;
  cursor: pointer;
  height: 18px;
  line-height: 18px;
  font-size: 14px;
  font-weight: bold;
  text-align: center;
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
}

.message-bubble-wrapper:hover .delete-inline-msg-btn {
  opacity: 1;
  width: 18px;
  margin: auto 5px;
}

.thread img, .thread video, .thread audio {
  max-width: 100%;
  display: block;
  margin-top: 8px;
  border: 1px solid #444;
  border-radius: 4px;
}

.hide-preview { display: none; }

.new-message-alert {
  padding: 0px;
  margin-bottom: 5px;
  border-left: 0px solid #00ff66;
  background-color: transparent;
}

.new-message-alert .important {
  color: magenta;
  font-weight: bold;
}

.new-message-alert .fa-bell {
  color: magenta;
  margin-right: 8px;
  animation: notification-shake 0.82s cubic-bezier(.36, .07, .19, .97) both;
}

@keyframes notification-shake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}

.notification-shake {
  animation: notification-shake 0.82s cubic-bezier(.36, .07, .19, .97) both;
}

/* ========================================= */
/* HELP & UTILS                 */
/* ========================================= */
.terminal-output { padding-left: 2px; }

.terminal-output hr {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

#help-submenu { margin-top: 10px; }

.links { color: #05CDE5; }
.resp { color: var(--resp); }
.output { color: #05CDE5; }
.error { color: #FF5555; margin-left: 5px; }
.info { color: var(--terminal-output); }
.info2 { color: var(--terminal-output); white-space: normal; }
.cmd_output { color: var(--terminal-output); white-space: normal; }
.whois { padding-left: 2px; margin: 0px; }

/* Icon Colors */
.err { color: #E7000B; }
.nutral { color: #999999; }
.warn { color: #DBAB09; }
.important { color: rgb(255, 0, 234); }

.output a { text-decoration: none; }
.output a:hover { text-decoration: underline; }

.help {
  white-space: normal;
  margin-top: -30px;
}

.help-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 20px 0;
}

.help-grid > div {
  flex: 1 1 45%;
  min-width: 180px;
  color: var(--text-color-main);
  font-weight: bold;
}

.help-header {
  font-weight: bold;
  font-size: 1em;
  margin-bottom: 1px;
}

#help-submenu { margin-top: 20px; }

/* File Directory */
.ls-column-view {
  display: flex;
  flex-wrap: wrap;
  column-gap: 30px;
  row-gap: 6px;
  white-space: pre;
  margin: 0px 0;
  padding-left: 2px;
}

.ls-entry {
  color: var(--accent-color);
  cursor: pointer;
  min-width: 120px;
  padding: 3px;
  user-select: none;
}

.ls-entry:hover {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 3px;
  border: 0px solid #ccc;
  border-radius: 3px;
}

.ls-sub {
  margin-left: 16px;
  margin-top: 4px;
}

/* File Types */
.file-txt { color: #00ffff; }
.file-md { color: #ffaa00; }
.file-css { color: #00DDFF; }
.file-json { color: #ffff00; }
.fa-file-zipper { color: #888888; }
.file-js { color: #f7df1e; }
.file-pdf { color: #ff4444; }
.file-html { color: #66ccff; }
.file-env { color: #ff00ff; }
.file-db { color: #00ff00; }
.file-cfg { color: #00ffcc; }
.file-key { color: #ff4444; }
.file-enc { color: #888888; }
.file-default { color: #00ff00; }

.back-button {
  font-size: 1em;
  padding: 2px;
  cursor: pointer;
  width: fit-content;
}

.back-button:hover {
  color: var(--text-color-main);
}

/* ========================================= */
/* TEXT EDITOR                   */
/* ========================================= */
.editor-toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.editor-toolbar button {
  background: none;
  border: none;
  color: var(--cmd-color);
  font-size: 18px;
  padding: 10px;
}

#popup-editor {
  flex: 1;
  min-height: 0;
  background: transparent;
  border: none;
  width: 99%;
  padding-left: 10px;
  font-size: 16px;
  height: 180px;
  font-family: var(--terminal-font);
  color: var(--text-color-main);
  overflow-y: auto;
}

#popup-editor:focus {
  outline: none;
  box-shadow: none;
}

#popup-status {
  font-size: 14px;
  color: #0f0;
  padding: 10px;
}

.editor-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
  margin-left: 5px;
}

#popup-save {
  border: 0;
  color: #111;
  border-radius: 10px;
  padding: 10px;
  background: var(--cmd-color);
  margin-right: 10px;
}

#popup-cancel {
  border: 1px solid red;
  border-radius: 10px;
  background: red;
}

.word-count-circle {
  width: 25px;
  height: 25px;
  border-radius: 50%;
  border: 3px solid #444;
  background-color: #1a1a1a;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Courier New', monospace;
  font-weight: bold;
  font-size: 14px;
  transition: border-color 0.3s ease, color 0.3s ease;
}

.word-count-circle.empty { border-color: #555; color: #777; }
.word-count-circle.safe { border-color: #4caf50; color: #ccc; }
.word-count-circle.warning { border-color: #ffeb3b; color: #ffeb3b; }
.word-count-circle.danger {
  border-color: #f44336;
  color: #f44336;
  animation: pulse-red 1s infinite;
}

@keyframes pulse-red {
  0% { box-shadow: 0 0 0 0 rgba(244, 67, 54, 0.4); }
  70% { box-shadow: 0 0 0 6px rgba(244, 67, 54, 0); }
  100% { box-shadow: 0 0 0 0 rgba(244, 67, 54, 0); }
}

/* Markdown / Cat */
.cat-output-block,
.MDblock {
  margin-top: 1rem;
  white-space: normal;
  color: var(--text-color-main);
  border-top: 1px dashed #444;
  padding-top: 8px;
}

.MDblock { font-family: var(--terminal-font); }
.MDH1 { color: var(--cmd-color); }
.MDH2 { color: magenta; }
.MDH3 { color: #fff; }

/* Chat Header */
.chat-header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-weight: bold;
  font-family: Inconsolata, monospace;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}

.chat-header > div {
  min-width: 40%;
}

/* ========================================= */
/* BSOD                         */
/* ========================================= */
#bsod {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color-solid);
  color: #fff;
  font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif;
  display: none;
  z-index: 99999;
  cursor: none;
}

#bsod-content {
  width: 80%;
  max-width: 950px;
  margin: auto;
  text-align: left;
  padding-top: 10vh;
}

.smiley-face {
  font-size: 8vh;
  font-weight: 200;
  line-height: 1;
  margin-bottom: 3vh;
}

.main-text {
  font-size: 2.5vh;
  margin-bottom: 4vh;
  font-weight: 300;
}

.progress-container-bsod {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  background-color: #000;
  padding: 10px;
}

.qr-code img {
  width: 12vh;
  height: 12vh;
  background-color: white;
}

.stop-code-info {
  font-size: 1.8vh;
  font-weight: 300;
}

#percentage-counter {
  font-size: 2.5vh;
  margin-bottom: 2vh;
}

.info-text {
  margin-top: 2vh;
  line-height: 1.5;
}

#line-counter {
  margin-top: 1vh;
}

/* ========================================= */
/* NOJS & MISC                  */
/* ========================================= */
.nojs {
  font-family: terminus;
  color: #00FF41;
  font-size: 1rem;
  text-align: center;
  padding: 2rem;
  text-shadow: 0 0 5px rgba(0, 255, 65, 0.5), 0 0 10px rgba(0, 255, 65, 0.3);
  border: 0px solid #00FF41;
  max-width: 90vw;
}

.nojs::after {
  content: '█';
  display: inline-block;
  margin-left: 5px;
  animation: blink-caret 1s infinite steps(1);
}

@keyframes blink-caret {
  50% { opacity: 0; }
}

.contact, .sitemap, .books, .status {
  white-space: normal !important;
}

.focus-mode {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: black;
  color: #808080;
  font-family: terminus;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

.focus-title {
  font-weight: 800;
  color: #333;
  font-family: terminus;
  font-size: 48px;
}

.focus-timer {
  font-size: 36px;
  margin-top: 20px;
}

.focus-exit {
  margin-top: 30px;
  font-size: 18px;
}

/* ========================================= */
/* TELEGRAM FEED                 */
/* ========================================= */
.telegram-feed-container {
  padding: 10px;
  border: 1px solid #333;
  border-radius: 6px;
  margin-top: 10px;
  font-family: var(--terminal-font, 'SourceCode', monospace);
  font-size: 0.95em;
}

.telegram-feed-container strong {
  display: block;
  margin-bottom: 5px;
  font-size: 1.1em;
  color: var(--terminal-accent, #00FF00);
}

hr.tight-hr {
  border: 0;
  border-top: 1px solid #444;
  margin-top: 5px;
  margin-bottom: 15px;
}

.telegram-message-item {
  margin-bottom: 15px;
  padding-bottom: 10px;
}

.telegram-message-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.telegram-message-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
}

.telegram-user {
  color: var(--terminal-accent-dim, #00aa00);
  font-weight: bold;
}

.telegram-date {
  font-size: 0.8em;
  color: #777;
}

.telegram-message-text {
  white-space: pre-wrap;
  word-wrap: break-word;
  line-height: 1.5;
  color: var(--terminal-foreground-dim, #ccc);
}

.telegram-message-media {
  margin-top: 8px;
}

.telegram-message-media img,
.telegram-message-media video {
  max-width: 100%;
  height: auto;
  max-height: 300px;
  border-radius: 4px;
  display: block;
  margin-top: 5px;
}

hr.faint-hr {
  border: 0;
  border-top: 1px solid #2f2f2f;
  margin-top: 10px;
  margin-bottom: 10px;
}

.telegram-message-text a {
  color: var(--terminal-link-color, #61dafb);
  text-decoration: underline;
}

.telegram-message-text a:hover {
  text-decoration: none;
}

/* ========================================= */
/* LIGHTBOX                     */
/* ========================================= */
.lightbox-overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10000;
  cursor: pointer;
  transform: none !important;
  filter: none !important;
}

.lightbox-img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  border: 1px solid var(--accent-color);
  border-radius: 15px;
  margin: 20px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

/* ========================================= */
/* POPUP & SUPPORT                 */
/* ========================================= */
#popup-window {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100dvh;
  display: none;
  justify-content: center;
  align-items: center;
  background: rgba(0,0,0,0.8);
  z-index: 9999;
  overflow: hidden;
  backdrop-filter: blur(1px);
}

#popup-window .window-box {
  position: relative;
  width: 90vw;
  max-height: 90dvh;
  background: rgba(0,0,0,.8);
  overflow-y: auto;
  border: 1px solid var(--terminal-border);
  border-radius: var(--window-border-radius);
  padding: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.window-content {
  flex: 1;
  width: 100%;
  overflow: hidden;
  padding: 0;
  box-sizing: border-box;
}

.window-content iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

#popup-window .window-box::-webkit-scrollbar { width: 8px; }
#popup-window .window-box::-webkit-scrollbar-thumb { background: #000; border-radius: 4px; }
#popup-window .window-box iframe { width: 100%; height: 100%; border: none; }

#popup-window .window-close {
  position: absolute;
  top: 8px;
  right: 8px;
  background: none;
  border: none;
  color: #000;
  background-color: transparent;
  font-size: 1.8em;
  cursor: pointer;
}

/* Support Box */
.innertel-support-box {
  padding: 15px;
  border-top: 0px solid #333;
}

.innertel-support-box h2 {
  margin-top: 0;
  margin-bottom: 80px;
  font-size: 1.5rem;
  color: var(--text-color-main);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.support-list {
  list-style-type: none;
  padding: 0;
  margin: 0 0 0px 0;
}

.support-list li {
  margin-bottom: 5px;
  display: flex;
  align-items: center;
}

.info-label {
  font-weight: bold;
  margin-right: 10px;
  min-width: 110px;
  color: var(--text-color-main);
}

.info-label i {
  margin-right: 0px;
  color: var(--text-color-main);
  width: 16px;
  text-align: center;
}

.innertel-support-box a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.innertel-support-box a:hover {
  color: var(--cmd-color);
  text-decoration: underline;
}

.footer_text {
  display: block;
  color: var(--text-color-main);
  font-weight: bold;
  border-top: 1px dashed #333;
  padding-top: 15px;
}

/* About Box */
.innertel-about-box {
  padding: 45px 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: var(--text-color-main);
  font-family: SF Mono, monospace;
}

.innertel-about-box h2 {
  margin: 0;
  font-family: 'MIB', monospace;
  font-size: 2.2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-color-main);
  line-height: 1;
}

.innertel-about-box .version {
  margin-top: 5px;
  margin-bottom: 25px;
  font-family: SF Mono, monospace;
  font-size: 0.95rem;
  color: #888;
}

.about-grid {
  display: grid;
  grid-template-columns: auto auto;
  column-gap: 15px;
  row-gap: 6px;
  margin-bottom: 115px;
  font-size: 0.9rem;
}

.about-grid .label {
  text-align: right;
  font-weight: 600;
  color: var(--text-color-main);
}

.about-grid .value {
  text-align: left;
  color: #b3b3b3;
}

.about-btn {
  background-color: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(0, 0, 0, 0.5);
  color: white;
  padding: 6px 16px;
  font-size: 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0,0,0,0.3);
  transition: background 0.2s;
  margin-bottom: 30px;
}

.about-btn:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

.innertel-about-box a.cmd-link {
  color: var(--cmd-color);
  font-weight: bold;
  text-decoration: none;
  margin-left: 6px;
  font-family: monospace;
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.innertel-about-box a.cmd-link:hover {
  background: var(--accent-color);
  color: #000;
}

.about-footer {
  font-size: 0.75rem;
  color: #666;
  font-family: SF Mono, monospace;
}

.about-footer .heart {
  color: #ff5555;
  font-size: 0.8rem;
}

.about-footer a {
  color: inherit;
  text-decoration: none;
  font-weight: bold;
}

.about-footer a:hover {
  text-decoration: underline;
}

.success-message {
  display: block;
  color: #4caf50;
  font-weight: bold;
  border-top: 1px dashed #333;
  padding-top: 15px;
}

#debug-status {
  position: fixed;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  max-width: 90%;
  width: auto;
  background: rgba(0, 0, 0, 0.7);
  color: rgb(219, 7, 0);
  font-family: SF Mono, monospace;
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 6px;
  z-index: 9999;
  text-align: center;
  opacity: 0;
  animation: fadeIn 0.4s ease-in forwards;
  white-space: nowrap;
  display: inline-block;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ========================================= */
/* MOBILE STYLES                */
/* ========================================= */
@media (max-width: 940px) {
  html {
    height: 100%;
    margin: 0;
    padding: 0;
    overscroll-behavior: none;
  }

  body {
    display: block;
    margin: 0;
    padding: 0;
    height: 100%;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    max-width: 100%;
    overflow: hidden;
    background: var(--bg-color-solid);
    overscroll-behavior: none;
  }

  /* INIT */
  #boot {
    position: fixed;
    top: 0;
    left: 0;
    width: 100dvw;
    height: 100dvh;
    background: black;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999;
    box-sizing: border-box;
  }

  .init {
    text-align: center;
    width: 100%;
    max-width: 90%;
    padding: 20px;
    box-sizing: border-box;
    margin: 0;
  }
  
  .circle {
    width: 300px;
    height: 300px;
    border-radius: 50%;
  }

  .dot {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: red;
    animation: blink 0.6s infinite alternate;
  }

  .progress-container {
    width: 100%;
    max-width: 300px;
    height: 12px;
    background: #111;
    border: 1px solid #444;
    border-radius: 8px;
    margin: 0 auto;
    overflow: hidden;
    margin-top: 0px;
  }

  .progress-bar {
    width: 0%;
    height: 100%;
    background: #444;
    transition: width 0.1s linear;
  }

  .title {
    font-family: MIB;
    font-size: 2.4rem;
    letter-spacing: 4px;
    font-weight: bold;
    margin-top: 10px;
  }

  .subtitle {
    font-size: 1.2rem;
    margin-bottom: 40px;
  }

  .app-name, .menu-item { display: none; }
  
  .os {
    width: 100vw;
    height: 100%;
    padding: 10px;
    box-sizing: border-box;
  }

  .os.show { opacity: 1; }

  .welcome-divider { width: 95%; }

  h1 { font-size: 1.8em; text-align: left; }

  .help-grid { flex-direction: column; }
  .help-grid > div { flex: 1 1 100%; }

  /* TERMINAL MOBILE */
  .terminal {
    padding: 10px;
    border-radius: 15px;
    box-sizing: border-box;
    max-width: 100%;
  }

  #output {
    max-height: 70dvh;
    font-size: 1em;
    overflow-y: auto;
    box-sizing: border-box;
    transition: max-height 0.3s ease;
  }

  .prompt {
    display: flex;
    align-items: center;
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    background-color: var(--input-bg-mobile);
    border: 1px solid var(--input-border);
    box-shadow: inset 0 0 0 0.2px var(--input-shadow);
    transition: all 0.3s ease;
    box-sizing: border-box;
  }

  .prompt:focus-within {
    border: 1px solid var(--input-focus-border);
    background-color: var(--input-focus);
  }

  #commandInput {
    flex: 1;
    background: transparent;
    border: none;
    padding: 0.6em .1em 0.6em .6em;
    font-size: 1em;
    font-family: inherit;
    color: var(--cmd-color);
    min-width: 0;
    outline: none;
    border-radius: 0;
  }

  #mobileSendBtn {
    border: none;
    background: none;
    font-size: 1.3em;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
  }

  input[type="text"] { font-size: 16px; }

  .focus-title { text-align: center; }

  /* Popup Mobile */
  #popup-window .window-box {
    width: 100dvw;
    height: 100dvh;
    border-radius: 15px;
    margin: 10px;
    padding: 0;
  }

  #popup-window textarea {
    width: 100%;
    height: 15dvh;
    resize: none;
    background: #000;
    color: var(--text-color-main);
    padding: 1rem;
    border: 0px solid var(--terminal-border);
    font-family: var(--terminal-font, monospace);
    box-sizing: border-box;
  }

  .editor-toolbar, .editor-actions {
    padding: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: left;
  }

  .editor-actions button { flex: 1 1 auto; }

  .chat-header > div { min-width: 100%; }

  .sidebar.open { right: 1px; }

  /* Target both Terminals and Apps */
  .new-terminal-window,
  .app-window {
    /* Force full screen override */
    width: 100vw !important;
    
    /* OLD LINE (Causes the bug in Safari): */
    /* height: calc(100vh - 80px) !important; */

    /* NEW FIX: Use dvh (Dynamic Viewport Height) */
    /* We use a fallback for old browsers, then the dvh fix */

    height: calc(100dvh - 75px) !important; 

    /* Positioning */
    top: 30px !important; /* Push down below menu */
    left: 0 !important;
    transform: none !important;
    border-radius: var(--window-border-radius);
    
    /* Ensure it doesn't overlap the taskbar visually if z-index fails */
    margin-bottom: 45px;
  }
  
  .new-terminal-window.maximized {
    height: calc(100dvh - 70px) !important; 
    
    /* 2. Anchor the Top: Below the Menu */
    top: 30px !important; 
    
    /* 3. Anchor the Bottom: Above the Taskbar + Safe Area */
    /* 40px (Taskbar) + 10px (Gap) + Safe Area (Home Indicator) */
    bottom: calc(50px + env(safe-area-inset-bottom)) !important; 
    
    /* 4. Ensure Full Width */
    left: 0 !important;
    width: 100% !important;

  }

  .resizer { display: none !important; }
  .app-maximize-btn { display: none; }

  /* 1. Turn the form container into the "Pill" shape */
  .window-form {
  display: flex;
  align-items: center;
  
  /* Positioning and Spacing */
  margin: 0 10px 10px 10px; /* Spacing from edges (Bottom/Left/Right) */
  padding: 4px 12px;        /* Internal padding */
  
  /* The Mobile "Prompt" Look */
  border-radius: 20px;
  background-color: var(--input-bg-mobile, rgba(255, 255, 255, 0.2));
  border: 1px solid var(--input-border, rgba(255, 255, 255, 0.12));
  box-shadow: inset 0 0 0 0.2px var(--input-shadow, rgba(255, 255, 255, 0.3));
  transition: all 0.3s ease;
  }

  /* 2. Glow effect when typing (Focus State) */
  .window-form:focus-within {
    border: 1px solid var(--input-focus-border, #00ff00);
    background-color: var(--input-focus, rgba(0, 0, 0, 0.3));
  }

  /* 3. Reset the input style to fit inside the pill */
  .window-input {
    flex: 1;              /* Take up available space */
    border: none !important;
    background: transparent !important;
    padding: 5px 0 !important;
    margin: 0 !important;
    outline: none;
    font-size: 16px;      /* Prevents iOS zoom */
    color: var(--cmd-color);
  }

  /* 4. Reveal and style the Send Button */
  .window-send-btn {
    display: flex;        /* Show it on mobile */
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--accent-color);
    font-size: 1.3em;
    padding-left: 10px;
    cursor: pointer;
  }

  /* Optional: Press effect for the button */
  .window-send-btn:active {
    transform: scale(0.9);
    color: var(--cmd-color);
  }
}