/* Universal Optional Sign-in Header Pill & Dropdown (Google Style) */
.eee-auth-container {
  display: inline-flex;
  align-items: center;
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Google Sans", sans-serif;
  font-size: 13px;
  z-index: 100;
  margin-left: auto;
  flex-shrink: 0;
}

/* Ensure Site Header always places Auth in the Top-Right Corner */
header.site-header .site-header-inner,
header.site-header .site-header-content {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  position: relative;
  min-height: 52px !important;
}

@media (max-width: 992px) {
  header.site-header .site-header-inner,
  header.site-header .site-header-content {
    flex-wrap: wrap !important;
    padding: 6px 12px !important;
    gap: 6px !important;
  }
  header.site-header .brand {
    order: 1 !important;
  }
  .eee-auth-container {
    order: 2 !important;
    margin-left: auto !important;
  }
  header.site-header nav.site-nav {
    order: 3 !important;
    width: 100% !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    gap: 8px !important;
    padding: 2px 0 4px !important;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  header.site-header nav.site-nav::-webkit-scrollbar {
    display: none;
  }
  header.site-header nav.site-nav a {
    font-size: 12px !important;
    min-height: 30px !important;
    padding: 2px 6px !important;
    flex-shrink: 0 !important;
  }
}

.eee-auth-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  height: 36px;
  box-sizing: border-box;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid #dadce0;
  color: #3c4043;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.08);
}

.eee-auth-pill:hover {
  background: #f8fafc;
  border-color: #bdc1c6;
  color: #202124;
  box-shadow: 0 1px 3px rgba(60, 64, 67, 0.16);
}

.eee-auth-pill.signed-in {
  background: #f0fdf4;
  border-color: #86efac;
  color: #14532d;
}

.eee-auth-pill.signed-in:hover {
  background: #dcfce7;
  border-color: #4ade80;
}

.eee-auth-user-display {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.eee-auth-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 250px;
  background: #ffffff;
  border: 1px solid #dadce0;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 14px;
  display: none;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
}

.eee-auth-dropdown.open {
  display: flex;
}

.eee-auth-user-info {
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 8px;
}

.eee-auth-user-name {
  font-weight: 700;
  color: #0f172a;
  font-size: 14px;
}

.eee-auth-sync-status {
  font-size: 11px;
  color: #15803d;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}

.eee-auth-logout-btn {
  width: 100%;
  padding: 6px 12px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: #475569;
  font-weight: 600;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.15s ease;
  text-align: center;
}

.eee-auth-logout-btn:hover {
  background: #fee2e2;
  border-color: #fca5a5;
  color: #991b1b;
}

#eee-google-btn-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(2px);
}

#eee-google-btn-modal.open {
  display: flex;
}

.eee-auth-modal-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  max-width: 360px;
  width: 90%;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
  text-align: center;
  position: relative;
}

.eee-auth-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: #94a3b8;
  padding: 4px 8px;
  border-radius: 6px;
}
.eee-auth-modal-close:hover {
  color: #0f172a;
  background: #f1f5f9;
}

