:root {
  --accent-color: #f9c73b;
  --light-accent-color: #f8e7b9;
  --button-background: rgba(249, 198, 59, 0.33);
  --button-background-dark: rgba(249, 199, 59, 0.25);
  --background-light: #ffffff;
  --background-dark: #111;
  --text-light: #2d383f;
  --text-dark: #ffffff;
  --card-bg-light: #ffffff;
  --card-bg-dark: #161616;
  --input-bg-light: #eeeeee;
  --input-bg-dark: #2a2a2a;
  --shadow-light: rgba(0, 0, 0, 0.3);
  --shadow-dark: rgba(0, 0, 0, 0.7);
}

* {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  display: block;
}


body {
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #d4a91a;
}

input:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 5px var(--accent-color);
}

button {
  cursor: pointer;
}

/* Remove focus outline everywhere except auth pages */
body:not(.auth-page) *:focus {
  outline: none !important;
  box-shadow: none !important;
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 260px;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.5rem 0;
  box-sizing: border-box;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top-right-radius: 24px;
  border-bottom-right-radius: 24px;
  z-index: 1000;
}


.sidebar-logo {
  display: flex;
  justify-content: center;
}

.sidebar-logo img {
  width: 140px;
}

.sidebar-menu,
.sidebar-bottom {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 0;
}

.sidebar-menu ul,
.sidebar-bottom ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-menu a,
.sidebar-bottom a {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0.4rem 1rem;
  padding: 0.8rem 1rem;
  text-decoration: none;
  border-radius: 14px;
  font-weight: 600;
  transition: background-color 0.25s ease, transform 0.1s ease;
  color: white;
}

.sidebar-menu a.active,
.sidebar-bottom a.active,
.sidebar-menu a:hover,
.sidebar-bottom a:hover {
  background-color: var(--button-background-dark);
  transform: scale(1.02);
}


@media (prefers-color-scheme: light) {
  body {
    background-color: var(--hover-bg-light);
    color: var(--text-light);
  }

  input,
  select,
  textarea {
    background-color: var(--input-bg-light);
    color: var(--text-light);
  }

  button[type="submit"] {
    background-color: var(--accent-color);
    color: #000;
  }

  button[type="submit"]:hover {
    background-color: #e6b72f;
  }

  .sidebar {
    color: var(--text-light);
    background-color: var(--card-bg-light);
  }

  .sidebar-menu a,
  .sidebar-bottom a {
    color: var(--text-light);
  }
}


@media (prefers-color-scheme: dark) {
  .logo {
    content: url("/assets/logos/MindHiveDark.svg");
  }

  body {
    background-color: var(--background-dark);
    color: var(--text-dark);
  }

  input,
  select,
  textarea {
    background-color: var(--input-bg-dark);
    color: var(--text-dark);
    border: 1px solid #666;
  }

  button[type="submit"] {
    background-color: var(--accent-color);
    color: #000;
  }

  button[type="submit"]:hover {
    background-color: #e6b72f;
  }

  .sidebar {
    color: var(--text-dark);
    background-color: var(--card-bg-dark);
  }
}


@media (max-width: 480px) {

  input[type="email"],
  input[type="password"],
  input[type="text"] {
    font-size: 0.9rem;
    padding: 0.55rem 0.8rem;
  }

  button[type="submit"] {
    font-size: 1rem;
    padding: 0.65rem 0.9rem;
  }
}

@media (max-width: 1024px) {
  .sidebar {
    width: 100%;
    position: relative;
    height: auto;
    flex-direction: row;
    align-items: center;
    justify-content: space-around;
    border-radius: 0;
  }

  .sidebar-menu a {
    margin: 0.2rem 0.5rem;
    padding: 0.5rem 0.8rem;
  }
}

/* ============================
   MOBILE NAV – iOS 26 Glass Pill
   ============================ */
.mobile-nav {
  display: none;
  /* hidden on desktop */
}

@media (max-width: 1024px) {

  .sidebar {
    display: none !important;
  }

  .mobile-nav {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 85%;
    padding: 12px 16px;
    border-radius: 40px;

    display: flex;
    justify-content: space-between;
    align-items: center;

    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.25);

    z-index: 9999;
  }

  @media (prefers-color-scheme: dark) {
    .mobile-nav {
      background: rgba(20, 20, 20, 0.55);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }
  }

  .mobile-nav a {
    flex: 1;
    text-align: center;

    padding: 10px;
    border-radius: 30px;

    color: var(--text-dark);
    opacity: 0.7;
    font-size: 1.3rem;

    transition: all 0.25s ease;
  }

  .mobile-nav a i {
    pointer-events: none;
  }

  .mobile-nav a.active {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);

    color: var(--accent-color);
    opacity: 1;
    transform: translateY(-3px);
  }

  @media (prefers-color-scheme: dark) {
    .mobile-nav a.active {
      background: rgba(255, 255, 255, 0.08);
      color: var(--accent-color);
    }
  }
}

.pomodoro-popup {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--card-bg-dark);
  color: white;
  backdrop-filter: blur(12px);
  padding: 18px 24px;
  border-radius: 14px;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: 0.3s ease;
  z-index: 9999;
}

.pomodoro-popup.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

#pomodoro-close {
  height: 24px;
  width: 24px;
  background: none;
  color: rgb(169, 1, 1);
  border: none;
  border-radius: 50%;
  padding: 6px 12px;
  font-size: 0.9rem;
  cursor: pointer;
}