/* ══════════════════════════════════════════════════════════════
   AHAVA=ECHAD Global Bar — CSS + Theme System
   v2.0 | 2 Adar II 5786 / March 2, 2026
   New: date/time, apps dropdown, fullscreen, RTL, collapsible
   ══════════════════════════════════════════════════════════════ */

/* === THEME VARIABLES === */
/* dark theme handled by CSS filter invert */

/* light theme is the default */

/* CSS inversion removed — light mode now uses native light CSS, dark mode uses JS inversion */

/* light-native rules removed — no longer needed */

/* === GLOBAL BAR === */
.global-bar {
  --ae-navbar-font: 'Montserrat', sans-serif;
  direction: ltr;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 32px;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  background: rgba(26, 26, 26, 0.97);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  color: #fafafa;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-sizing: border-box;
  direction: ltr;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* === RTL support === */
.global-bar[dir="rtl"] {
  direction: rtl;
}

.global-bar[dir="rtl"] .global-bar__left {
  flex-direction: row-reverse;
}

.global-bar[dir="rtl"] .global-bar__controls {
  flex-direction: row-reverse;
}

.global-bar[dir="rtl"] .global-bar__dropdown {
  right: auto;
  left: 0;
}

/* === COLLAPSED STATE === */
.global-bar--collapsed {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.global-bar--collapsed:hover,
.global-bar.global-bar--collapsed.expanding {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* === LEFT SIDE: Brand + Date === */
.global-bar__left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.global-bar__brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #fafafa;
  font-weight: 900;
  font-size: 16px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  flex-shrink: 0;
  height: 32px;
}

.global-bar__brand:hover {
  opacity: 0.85;
}

.global-bar__brand-logo {
  width: 38px;
  height: 30px;
  border-radius: 7px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}
.global-bar__brand-home {
  display: flex;
  align-items: center;
}
.global-bar__brand-home:hover {
  opacity: 0.85;
}
.global-bar__brand-text {
  font-family: 'Montserrat', sans-serif;
  font-family: var(--ae-navbar-font, 'Montserrat', sans-serif);
  font-size: 0.7rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  white-space: nowrap;
  margin-left: 6px;
}

.global-bar__center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  z-index: 1;
}


/* DATE/TIME styles moved below */

/* === RIGHT: CONTROLS === */
.global-bar__controls {
  display: flex;
  align-items: center;
  gap: 1px;
  flex-shrink: 0;
}

.global-bar__btn--xp {
  white-space: nowrap;
}

.global-bar__btn {
  background: none;
  border: none;
  color: #7fff00;
  cursor: pointer;
  padding: 0 2px;
  border-radius: 4px;
  font-size: 10px;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  height: 28px;
  line-height: 28px;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}

.global-bar__btn:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}
a.global-bar__btn,
a.global-bar__btn:hover,
a.global-bar__btn:visited,
a.global-bar__btn:active,
a.global-bar__btn span {
  text-decoration: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
  outline: none !important;
}

.global-bar__btn--icon {
  font-size: 15px;
  padding: 3px 5px;
}

/* Apps button now uses base .global-bar__btn style */

/* === DROPDOWN (shared) === */
.global-bar__dropdown-wrap {
  position: relative;
}

.global-bar__dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 190px;
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
  padding: 4px 0;
  display: none;
  z-index: 10001;
  font-size: 13px;
}

.global-bar__dropdown.open {
  display: block;
}

.global-bar__dropdown-section {
  padding: 4px 10px;
}

.global-bar__dropdown-label {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 3px;
  font-weight: 600;
}

.global-bar__dropdown-row {
  display: flex;
  gap: 3px;
  margin-bottom: 2px;
}

.global-bar__dropdown-option {
  flex: 1;
  padding: 4px 6px;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 4px;
  background: transparent;
  color: #fafafa;
  font-size: 10px;
  font-family: inherit;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s;
}

.global-bar__dropdown-option:hover {
  background: rgba(255,255,255,0.1);
}

.global-bar__dropdown-option.active {
  background: #2d5016;
  color: #fff;
  border-color: #2d5016;
}

.global-bar__dropdown-divider {
  height: 1px;
  background: rgba(255,255,255,0.06);
  margin: 2px 0;
}

/* === APPS DROPDOWN === */
.global-bar__apps-dropdown {
  min-width: 280px;
  padding: 12px;
}

.global-bar__apps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.global-bar__app-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 8px;
  border-radius: 10px;
  text-decoration: none;
  color: #fafafa;
  transition: background 0.15s;
}

.global-bar__app-item:hover {
  background: rgba(255,255,255,0.1);
}

.global-bar__app-icon {
  font-size: 24px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(127, 255, 0, 0.1);
  border-radius: 10px;
}

.global-bar__app-label {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  color: rgba(255,255,255,0.6);
}

.global-bar__app-item:hover .global-bar__app-label {
  color: #fafafa;
}

/* === COLLAPSED PILL === */
.global-bar__pill {
  position: fixed;
  top: 8px;
  z-index: 10001;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2d5016, #4a8c28);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s, opacity 0.3s;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.8);
}

.global-bar__pill.visible {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.global-bar__pill:hover {
  transform: scale(1.1);
}

.global-bar__pill-text {
  color: #fff;
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.05em;
}

.global-bar__pill-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  /* filter removed for light mode */
}

/* === LOGIN MODAL === */
.global-bar__modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 10002;
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.global-bar__modal-overlay.open {
  display: flex;
}

.global-bar__modal {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 14px;
  padding: 32px;
  width: 360px;
  max-width: 90vw;
  text-align: center;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
}

.global-bar__modal h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: #fafafa;
}

.global-bar__modal p {
  margin: 0 0 20px;
  color: rgba(255,255,255,0.6);
  font-size: 14px;
  line-height: 1.5;
}

.global-bar__modal-close {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fafafa;
  padding: 8px 24px;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  transition: background 0.15s;
}

.global-bar__modal-close:hover {
  background: rgba(255,255,255,0.2);
}

/* === BODY OFFSET === */
body.has-global-bar {
  padding-top: 32px !important;
}

body.has-global-bar.global-bar-collapsed {
  padding-top: 0 !important;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .global-bar {
    padding: 0 6px;
    height: 28px;
    direction: ltr !important;
    overflow: visible;
    /* [2026-07-09] mobile-GPU crash pattern (same as omer chart): a fixed,
       always-on element with a continuous blur backdrop-filter can crash/blank
       out on some phone GPUs. Bar is opaque enough (rgba .97) without it. */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  body.has-global-bar {
    padding-top: 28px !important;
  }

  body.has-global-bar.global-bar-collapsed {
    padding-top: 0 !important;
  }

  .global-bar__date-time {
    display: none;
  }

  .global-bar__btn-label {
    display: none;
  }

  .global-bar__btn--xp {
  white-space: nowrap;
}

.global-bar__btn {
    padding: 2px 5px;
    font-size: 12px;
  }

  .global-bar__btn--icon {
    font-size: 12px;
    padding: 0 2px;
  }
  .global-bar__btn {
    padding: 0 1px;
    font-size: 9px;
    gap: 0;
    min-width: 0;
  }
  .global-bar__left {
    gap: 0;
    overflow: hidden;
  }


  .global-bar__apps-dropdown {
    min-width: 240px;
    right: -40px;
  }

  .global-bar__apps-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }

  .global-bar__app-icon {
    width: 36px;
    height: 36px;
    font-size: 20px;
  }

  .global-bar__left {
    gap: 6px;
  }

  .global-bar__controls {
    gap: 1px;
  }
}

@media (max-width: 480px) {
  .global-bar__controls {
    gap: 1px;
  }

  .global-bar__date {
    font-size: 10px;
    gap: 4px;
  }

  .global-bar__apps-dropdown {
    position: fixed;
    top: 32px;
    left: 8px;
    right: 8px;
    min-width: auto;
  }
  .global-bar__controls button,
  .global-bar__left button {
    padding: 4px 6px;
    min-width: 28px;
  }
}

@media (max-width: 600px) {
  .global-bar__brand-text { display: none; }
  .global-bar__center { position: static; transform: none; flex: 1 1 auto; min-width: 0; overflow: visible; text-align: center; justify-content: center; }
  .gb-date-eng { display: none; }
  .gb-date-caret { display: none; }
  .global-bar__date { justify-content: center; }
}

/* ── Date display: English left, time center, Hebrew right ── */
.global-bar__date {
  display: flex;
  align-items: center;
  gap: 8px;
}
.gb-date-eng {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
  white-space: nowrap;
}
.gb-date-heb {
  font-family: 'TorahFont', serif;
  font-size: 0.85rem;
  color: #ffffff;
  direction: rtl;
  white-space: nowrap;
}
.global-bar__date-time {
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  background: #111;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  cursor: pointer;
}
.global-bar__date:hover .gb-date-eng {
  color: #daa520;
}
.global-bar__date:hover .global-bar__date-time {
  color: #fff;
}
.global-bar__date:hover .gb-date-heb {
  color: #daa520;
}
.global-bar__date:hover .gb-date-caret {
  color: #fff;
}
@media (max-width: 600px) {
  .gb-date-eng { font-size: 0.65rem; }
  .gb-date-heb { font-size: 0.75rem; }
  .global-bar__date { gap: 5px; }
}


/* ── TimeFlow Dropdown (shell) ── */
.gb-timeflow-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #1a1a1a;
  border: 1px solid rgba(127,255,0,0.25);
  border-radius: 10px;
  padding: 14px 18px;
  min-width: 320px;
  max-width: 420px;
  z-index: 100001;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6);
  margin-top: 4px;
}
.gb-timeflow-dropdown.open { display: block; }
.gb-tf__view-toggles {
  display: flex;
  gap: 4px;
  margin-bottom: 12px;
}
.gb-tf__view-btn {
  flex: 1;
  padding: 6px 8px;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 4px;
  background: transparent;
  color: #aaa;
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
}
.gb-tf__view-btn:hover { background: rgba(255,255,255,0.06); }
.gb-tf__view-btn.active {
  background: #2d5016;
  color: #7fff00;
  border-color: #2d5016;
}
.gb-tf__content {
  min-height: 120px;
  color: #ccc;
  font-size: 12px;
  text-align: center;
}
.gb-tf__events-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.gb-tf__events-title {
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  font-weight: 600;
  letter-spacing: 0.06em;
}
.gb-tf__add-btn {
  background: none;
  border: 1px solid rgba(127,255,0,0.3);
  color: #7fff00;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  cursor: pointer;
  font-family: 'Montserrat', sans-serif;
  transition: background 0.15s;
}
.gb-tf__add-btn:hover { background: rgba(127,255,0,0.1); }
.gb-tf__event-list {
  margin-top: 8px;
  max-height: 160px;
  overflow-y: auto;
}
.gb-tf__event-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 11px;
}
.gb-tf__event-name { color: #ccc; }
.gb-tf__event-countdown { color: #7fff00; font-weight: 600; font-size: 10px; }
.gb-tf__event-delete {
  background: none; border: none; color: #666; cursor: pointer; font-size: 12px; padding: 0 4px;
}
.gb-tf__event-delete:hover { color: #cc3333; }
.gb-tf__empty {
  color: rgba(255,255,255,0.3);
  font-style: italic;
  font-size: 11px;
  padding: 16px 0;
}
.gb-tf__add-form {
  margin-top: 8px;
  display: flex;
  gap: 4px;
}
.gb-tf__add-form input {
  flex: 1;
  background: #111;
  border: 1px solid #333;
  border-radius: 4px;
  color: #fafafa;
  padding: 5px 8px;
  font-size: 11px;
  font-family: 'Montserrat', sans-serif;
}
.gb-tf__add-form input:focus { border-color: #7fff00; outline: none; }
.gb-tf__add-form button {
  background: #2d5016;
  border: none;
  color: #7fff00;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}

/* ── Year Dropdown (Crown of Egypt manuscript counters) ── */

.gb-year-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #1a1a1a;
  border: 1px solid rgba(127,255,0,0.25);
  border-radius: 10px;
  padding: 18px 22px;
  min-width: 380px;
  max-width: 480px;
  z-index: 100001;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6);
  text-align: center;
  margin-top: 4px;
}
.gb-year-dropdown.open { display: block; }
.gb-year__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 4px;
}
.gb-year__heb-group {
  direction: rtl;
  text-align: right;
}
.gb-year__ashurith {
  font-family: 'TorahFont', serif;
  font-size: 1.6rem;
  color: #c9a84c;
  direction: rtl;
}
.gb-year__regular {
  font-family: 'TorahFont', serif;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  direction: rtl;
}
.gb-year__english {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.82rem;
  color: #c9a84c;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-align: left;
}

.gb-year__adam-heb {
  font-family: 'TorahFont', serif;
  font-size: 0.9rem;
  color: #c9a84c;
  direction: rtl;
  display: block;
  text-align: center;
  margin-top: 4px;
  opacity: 0.85;
}
.gb-year__divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 10px 0;
}
.gb-year__row { padding: 2px 0; }
.gb-year__event-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}
.gb-year__event {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.68rem;
  color: #cc3333;
  font-weight: 700;
  text-align: left;
}
.gb-year__event-subtitle {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.68rem;
  color: #c9a84c;
  font-weight: 500;
  text-align: left;
}
.gb-year__event-heb {
  font-family: 'TorahFont', serif;
  font-size: 0.82rem;
  color: #cc3333;
  direction: rtl;
  text-align: right;
  white-space: nowrap;
}
.gb-year__counts {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.gb-year__count-en {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.82rem;
  color: #cc3333;
  font-weight: 600;
  text-align: left;
}
.gb-year__count-heb-group {
  direction: rtl;
  text-align: right;
}
.gb-year__count-he {
  font-family: 'TorahFont', serif;
  font-size: 1.05rem;
  color: #cc3333;
  direction: rtl;
}
.gb-year__count-reg {
  font-family: 'TorahFont', serif;
  font-size: 0.75rem;
  color: #cc3333;
  direction: rtl;
}
.gb-year__link {
  display: inline-block;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.75rem;
  color: #7fff00;
  text-decoration: none;
  font-weight: 600;
  padding: 6px 0 2px;
  transition: opacity 0.2s;
}
.gb-year__link:hover { opacity: 0.8; text-decoration: underline; }
.gb-date-caret {
  font-size: 9px;
  margin-left: 3px;
  opacity: 0.5;
  transition: transform 0.2s;
}
@media (max-width: 600px) {
  .gb-year-dropdown { min-width: 0; padding: 14px 16px; }
  .gb-year__ashurith { font-size: 1.9rem; }
}

/* ══════════════════════════════════════════════════════════════
   AUTH SYSTEM — Login/Signup/Forgot Password Modal Styles
   ══════════════════════════════════════════════════════════════ */

/* Auth Modal — overrides the basic .global-bar__modal */
.global-bar__modal--auth {
  direction: ltr;
  text-align: left;
  padding: 28px 32px;
  width: 380px;
}

.global-bar__modal--auth h3 {
  text-align: center;
  margin-bottom: 4px;
}

/* Tab bar */
.gb-auth__tabs {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.gb-auth__tab {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: rgba(255,255,255,0.4);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 0;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.gb-auth__tab:hover {
  color: rgba(255,255,255,0.7);
}
.gb-auth__tab.active {
  color: #7fff00;
  border-bottom-color: #7fff00;
}

/* Form panels */
.gb-auth__panel {
  display: none;
}
.gb-auth__panel.active {
  display: block;
}

/* Form inputs */
.gb-auth__field {
  margin-bottom: 14px;
}
.gb-auth__label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 5px;
}
.gb-auth__input {
  width: 100%;
  padding: 10px 12px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  color: #fafafa;
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
  box-sizing: border-box;
}
.gb-auth__input:focus {
  border-color: #7fff00;
  background: rgba(255,255,255,0.09);
}
.gb-auth__input::placeholder {
  color: rgba(255,255,255,0.25);
}

/* Submit button */
.gb-auth__submit {
  width: 100%;
  padding: 11px;
  background: linear-gradient(135deg, #2d5016, #4a8c28);
  border: none;
  border-radius: 8px;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.1s;
  margin-top: 4px;
  position: relative;
}
.gb-auth__submit:hover {
  opacity: 0.9;
}
.gb-auth__submit:active {
  transform: scale(0.98);
}
.gb-auth__submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Loading spinner on button */
.gb-auth__submit.loading {
  color: transparent;
}
.gb-auth__submit.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: gb-auth-spin 0.6s linear infinite;
}
@keyframes gb-auth-spin {
  to { transform: rotate(360deg); }
}

/* Error / success messages */
.gb-auth__msg {
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12px;
  margin-bottom: 12px;
  display: none;
  line-height: 1.4;
}
.gb-auth__msg.error {
  display: block;
  background: rgba(220, 38, 38, 0.15);
  border: 1px solid rgba(220, 38, 38, 0.3);
  color: #fca5a5;
}
.gb-auth__msg.success {
  display: block;
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #86efac;
}

/* Forgot password link */
.gb-auth__forgot {
  display: block;
  text-align: center;
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  margin-top: 12px;
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  width: 100%;
}
.gb-auth__forgot:hover {
  color: rgba(255,255,255,0.7);
}

/* Back link (in forgot password panel) */
.gb-auth__back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
  margin-bottom: 12px;
  padding: 0;
}
.gb-auth__back:hover {
  color: rgba(255,255,255,0.7);
}

/* Close X button */
.gb-auth__close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.3);
  font-size: 20px;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
}
.gb-auth__close:hover {
  color: #fff;
}

/* ── Logged-in state: user button replaces LOGIN ── */
.gb-auth__user-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  color: #7fff00;
  cursor: pointer;
  padding: 0 10px;
  font-size: 11px;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  height: 32px;
  line-height: 32px;
  border-radius: 6px;
  transition: background 0.15s;
  white-space: nowrap;
}
.gb-auth__user-btn:hover {
  background: rgba(255,255,255,0.1);
}

.gb-auth__avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2d5016, #4a8c28);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

/* User dropdown */
.gb-auth__user-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 160px;
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
  padding: 8px 0;
  display: none;
  z-index: 10001;
}
.gb-auth__user-dropdown.open {
  display: block;
}
.gb-auth__user-dropdown-item {
  display: block;
  width: 100%;
  padding: 8px 16px;
  background: none;
  border: none;
  color: #fafafa;
  font-family: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s;
}
.gb-auth__user-dropdown-item:hover {
  background: rgba(255,255,255,0.08);
}
.gb-auth__user-dropdown-email {
  padding: 8px 16px 4px;
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 4px;
}
.gb-auth__user-dropdown-item.logout {
  color: #f87171;
}

/* Responsive: hide display name on small screens */
@media (max-width: 768px) {
  .gb-auth__user-name {
    display: none;
  }
  .global-bar__modal--auth {
  direction: ltr;
    width: 90vw;
    padding: 24px 20px;
  }
}

/* Mobile: settings dropdown escapes overflow:hidden */
@media (max-width: 768px) {
  .global-bar__dropdown {
    position: fixed;
    top: 28px;
    right: 4px;
    left: auto;
    max-height: calc(100vh - 36px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
}


/* Mobile: year dropdown escapes overflow:hidden */
@media (max-width: 768px) {
  /* [2026-08-07] ONE mobile truth: transform:none (the base translateX(-50%) plus
     these insets was shoving the panel half off-screen); symmetric insets = centered
     under the bar; slightly compact, scrollable (operator). */
  .gb-year-dropdown.open {
    position: fixed;
    top: 50px;
    left: 12px;
    right: 12px;
    transform: none;
    font-size: 93%;
    max-height: 74vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 10002;
  }
}
/* MENU label over burger */
.nav-burger-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin-left: 8px;
  cursor: pointer;
}
.nav-burger-label {
  font-size: 7px;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1;
  margin-bottom: -2px;
  font-family: inherit;
}

/* PIN input with eye toggle */
.gb-auth__pin-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.gb-auth__pin {
  letter-spacing: 0.4em;
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  padding-right: 38px;
}
.gb-auth__eye {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  padding: 4px;
  opacity: 0.4;
  transition: opacity 0.2s;
  line-height: 1;
}
.gb-auth__eye:hover {
  opacity: 0.8;
}
.gb-auth__eye.showing {
  opacity: 0.9;
}

/* [v11.791] Never print the signed-out sync nudge (leaked into Ctrl+P on the editor). */
@media print {
  #aeSyncNudge { display: none !important; visibility: hidden !important; }
}
